lastValue function

Requirements.Internal.SlidingWindow.lastValue  ยท source

Icon of lastValue

Returns the oldest value

Extends Modelica.Icons.Function

Returns the Boolean value of the oldest element of the buffer (index last), the value of the signal at the oldest change still in the sliding window. It asserts that the buffer is not empty. The time of this element is indexTime(buffer, nElem); the newest value is returned by firstValue. Used by maxDuration and accumulatedDuration: if the oldest value is false, the signal was true before it, from the start of the window on.

Inputs

NameTypeDescription
buffer inputBufferMemory of sliding window

Outputs

NameTypeDescription
b outputBooleanOldest value