Linear Gain block
The Linear Gain block scales and applies an offset to the input fields.
Linear Gain block
Description
The Linear Gain block scales (multiplies by some constant value) and applies an offset to (i.e. adds some constant value) the input fields.
linear gain block
Block Type
Mathematical block
Input/Output ports
The input port may contain only fields of type double.
There is an output field for every input field.
If new fields are added to the input port an output field will be created with the same name.
It is possible to rename the output fields during configuration.
Functions performed on tags
-
On the values - The output value is computed according to the following equation: output = scaling factor x input + offset
-
On the timestamp - The time stamp of the input field is always set on the output field.
-
On the quality - The output field takes the quality attribute of its associated input field.
Example
Assume we wish to apply a factor of 2 to an input field and then add 0.5. The sample block output below demonstrates this.
Related topics: