Ramp
Rises linearly from 0 to Height over Duration after the start time, then holds.
- signal
- Modelica Standard Library
- 1 port
- 3 parameters
rampLibrarySourcesDescription
Outputs zero until Start time, then rises in a straight line to Height over Duration and holds Height from then on (the Modelica library ramp).
Example
Signal sources The signal sources side by side: step, ramp, sine, pulse, and clock, plus a constant.
ConstantStepRampSinePulseClock
Ports
Outputs 1
-
y
Output signal: 0 before Start time, rising to Height, then Height.
Parameters
-
Height
height1The value reached at the end of the ramp. Negative values ramp down.
-
Duration
duration1 s≥ 0
Time the rise takes, in seconds, so the slope is Height / Duration. 0 or more; 0 makes a step.
-
Start time
startTime0 s≥ 0
Time the ramp starts, in seconds. 0 or more.
Equations
Modelica
y = 0 for time < startTime y = height · (time − startTime) / duration for startTime ≤ time < startTime + duration y = height for time ≥ startTime + duration
Implementation
Modelica Standard Library 4.1.0
MSL documentation Modelica.Blocks.Sources.RampTips
- For a ramp that keeps rising for the whole run, set Duration to the run length and Height to slope · Duration.
Used in
These larger examples use it too. Open them from Examples in the app.
- EV drivetrain
- 480 VAC → 24 VDC flyback
See also
Select a block in Gradara and press F1 to open its page offline.