The output is the absolute value of the input.
The output of the function is the absolute value of the input.
- Author
- Benjamin Scholz
- Date
- 15.08.2007 BSC: Initial version.
-
20.07.2011 KGA: Ported to 2.0
Example configuration excerpt
<Lib LibName = "fhsim_base"
SimObject = "Math/Absolute"
Name = "A"
PorthWidth = "2"
/>
...
<Connection
A.In="-1,1"
/>
Input Ports
| Name | Width | Description |
| In | <PortWidth> | The input port |
Output Ports
| Name | Width | Description |
| Out | <PortWidth> | The absolute value of "In". |
Configuration parameters
| Name | Width | Description |
| PortWidth | 1 | The number of elements in the signal. |
Initial conditions
This SimObject contains no initial conditions.
Full example file
<Contents>
<OBJECTS>
<Lib
LibName="base"
SimObject="Math/Absolute"
Name="A"
PortWidth="3"
/>
</OBJECTS>
<INTERCONNECTIONS>
<Connection
A.In="-6.1,2,0"
/>
</INTERCONNECTIONS>
<INITIALIZATION>
<InitialCondition
/>
</INITIALIZATION>
<SIMULATION>
<Timing TStart="0" TEnd="2.0"/>
<Integrator Method="RK45_i" NumCores="1" LogStates="1" UseRSSNorm="0">
<StepControl StepMax="0.002" StepMin="0.00000001" AbsTol="1e-3" RelTol="1e-3"/>
</Integrator>
</SIMULATION>
<OBSERVERS>
<FileOutput TOutput="0, 1, 30" Select="objects:all"/>
</OBSERVERS>
</Contents>
This SimObject is referred to as Math/Absolute