Marine systems simulation
Derivative

Output is the time derivative of input.

+ Collaboration diagram for Derivative:

Output is the time derivative of input. If this object is not combined with a system that needs constant evaluation it will give inaccurate results because it only updates input at the times specified for output.

Author
Karl-Johan Reite
Benjamin Scholz
Date
14.08.2007 KJR: Initial version.
20.07.2011 KGA: Ported to FhSim 2.0.
25.07.2011 KGA: Added documentation.

Example configuration excerpt

<Lib
LibName = "fhsim_base"
SimObject = "Math/Derivative"
Name = "A"
PortWidth = "2"
/>
...
<Connection
A.In = "1,2"
/>

Input Ports

Name Width Description
In <PortWidth> The input port

Output Ports

Name Width Description
Out <PortWidth> The derivative of the input signal

Configuration parameters

Name Width Description
PortWidth The number of elements in the input and output ports

Initial conditions

This SimObject contains no initial conditions.

Full example file

<Contents>
<OBJECTS>
<Lib
LibName="base"
SimObject="Math/Derivative"
Name="A"
/>
<Lib
LibName="base"
SimObject="Src/Clock"
Name="M"
/>
</OBJECTS>
<INTERCONNECTIONS>
<Connection
A.In="M.SimTime"
/>
</INTERCONNECTIONS>
<INITIALIZATION>
<InitialCondition
/>
</INITIALIZATION>
<INTEGRATION>
<Engine
IntegratorMethod="2"
NumCores="1"
TOutput="1, 1,2,3,4,5, 30"
LogStates ="1"
stepsize ="0"
HMax="0.002"
HMin="0.00000001"
AbsTol="1e-3" RelTol="1e-3"
UseRSSNormInsteadOfInfNorm="0"
FileOutput="object.A:ports"
/>
</INTEGRATION>
</Contents>

This SimObject is referred to as Math/Derivative