Gain
The Gain block scales its input by the factor parameter.
Behavior
Section titled “Behavior”y = factor * x
| Port | Direction | Type |
|---|---|---|
| 0 | Input | Numeric scalar or fixed-size numeric array |
| 0 | Output | Same type as input |
For an array, the factor is applied to every element.
Parameters
Section titled “Parameters”| Parameter | Type | Default |
|---|---|---|
factor |
Number | 1.0 |
Example
Section titled “Example”With factor = 2.5 and input x = 4.0, the output is y = 10.0.