PlexerGenerator class
#include <PlexerGenerator.hpp>
Contents
Base classes
- class SimpleGenerator
Constructors, destructors, conversion operators
- PlexerGenerator()
- PlexerGenerator(uint_fast32_t i_seed)
- PlexerGenerator(const GenerationParameters& i_param)
Public functions
- auto generatorMultiplexer(uint32_t i_bits) -> GraphPtr
- generatorMultiplexer represents the generation of a combinational multiplexer circuit.
- auto generatorDemultiplexer(uint32_t i_bits) -> GraphPtr
- generatorDemultiplexer represents the generation of the combinational circuit of the demultiplexer.
- auto generatorMultiplexer(const GenerationParameters& i_param) -> GraphPtr
- auto generatorDemultiplexer(const GenerationParameters& i_param) -> GraphPtr
- auto generatorMultiplexer() -> GraphPtr
- auto generatorDemultiplexer() -> GraphPtr
Function documentation
GraphPtr CG_Gen:: PlexerGenerator:: generatorMultiplexer(uint32_t i_bits)
generatorMultiplexer represents the generation of a combinational multiplexer circuit.
| Parameters | |
|---|---|
| i_bits | The number of bits, or in other words, input vertices (variables) in the graph. |
| Returns | the created OrientedGraph |
When generating to the standard input vertices, additional ones are created, which are control inputs in the multiplexer circuit. Their number is a power of two, which is equal to or greater than the number of input vertices, and is the closest to the number of input vertices. There is always one output vertex. If the number of input vertices is less than two, the generation will be rejected.
GraphPtr CG_Gen:: PlexerGenerator:: generatorDemultiplexer(uint32_t i_bits)
generatorDemultiplexer represents the generation of the combinational circuit of the demultiplexer.
| Parameters | |
|---|---|
| i_bits | The number of bits, or in other words, input vertices (variables) in the graph. |
| Returns | the created OrientedGraph |
The generation logic almost completely repeats the logic of generatorMultiplexer. The difference lies in the use of logical operations and the fact that the user sets the number of output vertices, while the input vertex is always one.