Marine systems simulation
Smooth trajectory

Creates a smooth, periodic trajectory.

+ Collaboration diagram for Smooth trajectory:

The trajectory is made as

\( y_n(t) = b_n + a_n * \sin^3(2*pi*(t-t_{0,n})/T_n + p_n), t>t_{0,n}\, \text{and}\, t < t_{stop,n}\), where

Author
Karl-Johan Reite
Date
27.08.2013 KJR: Initial version.

Example configuration excerpt

<Lib
LibName = "fhsim_base"
SimObject = "Src/SmoothTrajectory"
Name = "trajectory"
Start = "0,2"
Stop = "10,12"
Amplitude = "2,4"
Bias = "1, 0"
Phase = "0, 3.14"
Period = "10, 1"
PortWidth = "2"/>

Configuration parameters

Name Width Description
Start <PortWidth> The start time.
Stop <PortWidth> The stop time.
Phase <PortWidth> The phase (in radians).
Period <PortWidth> The period (in seconds).
Amplitude <PortWidth> The amplitude of the signal.
Bias <PortWidth> The signal bias.
PortWidth 1 The signal portwidt.

Output Ports

Name Width Description
Out 1 The output signal.

Initial conditions

This SimObject contains no initial conditions.

Full example file

<Contents>
<OBJECTS>
<Lib
LibName="base"
SimObject="Src/SmoothTrajectory"
Name="A"
Period="6.28318530718"
Phase ="0"
Stop="100"
Start="0"
Amplitude="1"
Bias="0"
/>
</OBJECTS>
<INTERCONNECTIONS>
<Connection
/>
</INTERCONNECTIONS>
<INITIALIZATION>
<InitialCondition
/>
</INITIALIZATION>
<INTEGRATION>
<Engine
IntegratorMethod="2"
NumCores="1"
TOutput="0, 0:0.5:10, 30"
LogStates ="1"
stepsize ="0"
HMax="0.002"
HMin="0.00000001"
AbsTol="1e-3" RelTol="1e-3"
UseRSSNormInsteadOfInfNorm="0"
FileOutput="objects:all"
/>
</INTEGRATION>
</Contents>

This SimObject is referred to as Src/SmoothTrajectory