Figure below show the sum block..
- Sum, Add, Subtract, Sum of Elements
Add or subtract inputs
- Library
Math Operations
- Description
The Sum block performs addition or subtraction on its inputs. This block can add or subtract scalar, vector, or matrix inputs. It can also collapse the elements of a single input vector.
You specify the operations of the block with the List of signs parameter. Plus (+), minus (-), and spacer (|) characters indicate the operations to be performed on the inputs:
If there are two or more inputs, then the number of + and - characters must equal the number of inputs. For example, "+-+" requires three inputs and configures the block to subtract the second (middle) input from the first (top) input, and then add the third (bottom) input.
All nonscalar inputs must have the same dimensions. Scalar inputs will be expanded to have the same dimensions as the other inputs. A spacer character creates extra space between ports on the block's icon.
If only addition of all inputs is required, then a numeric parameter value equal to the number of inputs can be supplied instead of "+"characters. If only one vector is input, then a single "+" or "-" will collapse the vector using the specified operation.
The Sum block first converts the input data type(s) to the output data type using the specified rounding and overflow modes, and then performs the specified operations.
- Data Type Support
The Sum block accepts real or complex signals of any data type supported by Simulink, including fixed-point data types. The inputs may be of different data types unless you select the Require all inputs to have same data type parameter.
- Parameters and Dialog Box
The Main pane of the Sum block dialog appears as follows:
- Icon shape
- List of signs
Enter as many plus (+) and minus (-) characters as there are inputs. Addition is the default operation, so if you only want to add the inputs, enter the number of input ports. For a single vector input, "+" or "-" will collapse the vector using the specified operation.
You can manipulate the positions of the input ports on the block by inserting spacers (|) between the signs in the List of signs parameter. For example, "++|--" creates an extra space between the second and third input ports.
Thank You..
0 comments:
Post a Comment