PS Repeating Sequence
Output periodic piecewise linear signal
Libraries:
Simscape /
Foundation Library /
Physical Signals /
Sources
Description
The PS Repeating Sequence block outputs a periodic
piecewise linear signal, y
. You can optionally specify an initial
signal value and an initial time offset. The repeating sequence consists of a number of linear
segments, connected to each other. The number of segments must be no greater than 100. You
specify how to connect the segments by choosing a signal type. For the same set of block
parameter values, the resulting output signal will be different depending on the signal
type:
Discontinuous
— Each linear segment in the repeating sequence is defined by its duration, start value, and end value. If the end value of a segment is not the same as the start value of the next segment, they are connected by a vertical line.Continuous
— Each linear segment in the repeating sequence is defined by its duration and start value. The end value of a segment is the same as the start value of the next segment.Discrete
— Each linear segment in the repeating sequence is defined by its duration and start value. The end value of a segment is the same as its start value.
Use this block to generate various types of physical signals, such as pulse, sawtooth, stair, and so on.
Discontinuous Repeating Sequence
This example shows the mapping between the block parameter values and the resulting output signal.
Set the block parameters as shown:
The following plot shows the resulting block output.
The signal starts at 0 and consists of two linear segments. The duration of the first segment is 1 second, the segment starts at 0 and ends at 4. The signal is discontinuous, and the end value of the first segment is different than the start value of the second segment, therefore they are connected by a vertical line. The second segment starts at 2, lasts for 2 seconds, and ends at 0, after which the sequence repeats.