blockTriangleAndStep

Multiple steps and triangles

Information

The step output starts from stepOffset and increases to stepOffset + stepHeight in stepNumbersteps. The total duration of all step changes is equal to T.

During each step the triangle output is increased from triangleOffset to triangleOffset + triangleHeight and back to triangleOffset.

This way a variable sweep (triangleOffset) can be performed for different stepwise changed variables (step).

Parameters

TypeNameDefaultDescription
Modelica.Units.SI.TimeT1Total time of varying outputs
IntegerstepNumber5Number of steps
RealstepHeight1Total step height
RealstepOffset0Offset
Modelica.Units.SI.TimestartTime0Start time
RealtriangleHeight1Height of triangle output
RealtriangleOffset0Offset of triangle output

Connectors

TypeNameDefaultDescription
Modelica.Blocks.Interfaces.RealOutputstep
Modelica.Blocks.Interfaces.RealOutputtriangle

Components

TypeNameDefaultDescription
Modelica.Blocks.Sources.Rampramp
Modelica.Blocks.Math.RealToIntegerrealToInteger
Modelica.Blocks.Math.IntegerToRealintegerToReal
Modelica.Blocks.Math.Feedbackfeedback
Modelica.Blocks.Sources.ConstantconstantOffset
Modelica.Blocks.Math.Addadd
Modelica.Blocks.Math.Gaingain
Modelica.Blocks.Sources.Trapezoidtrapezoid
Modelica.Blocks.Sources.Stepconst
Modelica.Blocks.Nonlinear.Limiterlimiter