Fixed-Point Blockset
  Go to block:
    Search    Help Desk 
FixPt Matrix Gain

The FixPt Matrix Gain block is a masked S-function that multiplies the input by a constant matrix (referred to as the matrix gain). The block generates its output by multiplying the input by a specified matrix

where K is the matrix gain and u is the input. If the matrix has m rows and n columns, then the input to this block should be a vector of length n. The output is a vector of length m.

The gain is specified with the Gain matrix value parameter.

The Parameter data type parameter can have the same values as the Output data type parameter as discussed in "Block Parameters". Additionally, if Parameter data type is a generalized fixed-point number, then you can select from these scaling modes:

For a description of all other parameters, refer to "Block Parameters".

The block icon always displays a K. For a description of how the block icon displays the output data type, refer to "Block Icon Display".

Parameters and Dialog Box

Gain matrix value
Specify as a scalar or vector.
Parameter data type
Any data type supported by the Fixed-Point Blockset.
Parameter scaling
Radix point-only or slope/bias scaling. Additionally, the gain can be scaled using the constant matrix scaling modes for maximizing precision. These scaling modes are only available for generalized fixed-point data types.
Output data type
Any data type supported by the Fixed-Point Blockset.
Output scaling
Radix point-only or slope/bias scaling. These scaling modes are only available for generalized fixed-point data types.
Lock output scaling
If checked, Output scaling is locked.This feature is only available for generalized fixed-point output.
Round toward
Rounding mode for the fixed-point output.
Saturate to max or min when overflows occur
If checked, fixed-point overflows saturate. Otherwise, they wrap.
Override with doubles
If checked, the Output data type is overridden with doubles.
Log minimums and maximums
If checked, minimum and maximum simulation values are logged to the workspace.

Conversions and Operations

The Gain matrix value parameter is converted from doubles to the specified data type offline using round-to-nearest and saturation. Refer to "Parameter Conversions" in the manual for more information about parameter conversions.

The FixPt Matrix Gain block first multiples its inputs by the Gain matrix value parameter, converts those results to the output data type using the specified rounding and overflow modes, and then performs the summation. Refer to "Rules for Arithmetic Operations" in the manual for more information about the rules this block adheres to when performing operations.

Characteristics

Input Ports
Any data type supported by the blockset
Output Port
Any data type supported by the blockset
Direct Feedthrough
Yes
Sample Time
Inherited
Scalar Expansion
No
States
0
Vectorized
Yes



[ Previous | Help Desk | Next ]