eeros_architecture:control_system:available_blocks:int
This is an old revision of the document!
Integrator
The gain block allows to amplify an input signal. In general, the input signal is of type matrix and hence, the gain will have to be a matrix as well. The following lines show various examples.
Gain<Vector2, Matrix<2,2>> g1({1,2.5,-1,-0.5});
The first template parameter denotes the input signal. The gain here is a 2×2-matrix.
If a Gain
block is declared with a single value each element of the input vector is multiplied with this value.
Gain<Vector2> g2(10); Gain<Vector2, double> g3(10); // this is the same
Another useful operation is a by multipliying an input matrix with a given gain matrix element by element. This is achieved by
Gain<Vector2, Vector2, true> g4({10,20});
The third template parameter specifies an element-by-element multiplication. Please beware of the fact that in this case input signal and gain matrix must be of the same dimensions.
eeros_architecture/control_system/available_blocks/int.1491478902.txt.gz · Last modified: 2017/04/06 13:41 by graf