Saturation
Clamp a signal between lower and upper limits.
- signal
- Modelica Standard Library
- 2 ports
- 2 parameters
saturationLibraryNonlinearDescription
Clamps its input between a lower and an upper limit (the Modelica library limiter). Inside the limits the input passes unchanged.
Example
Nonlinearities Saturation, dead zone, relay, and rate limiter acting on the same sine.
Sine, amplitude 2Saturation ±1Dead zone ±0.5RelayRate limit 2/s
Also in this example:RelaySine waveDead zoneRate limiter
Ports
Inputs 1
-
u
Input signal.
Outputs 1
-
y
Output signal, u limited to the range from Lower limit to Upper limit.
Parameters
-
Lower limit
lower-1Lower limit. Must not exceed Upper limit.
-
Upper limit
upper1Upper limit. Must not be below Lower limit.
Equations
Modelica
y = max(lower, min(upper, u))
Implementation
Modelica Standard Library 4.1.0
MSL documentation Modelica.Blocks.Nonlinear.LimiterAssumptions and limitations
- A lower limit above the upper limit is a model error; the run stops with a message.
Tips
- To limit an integrator itself rather than its output, use Limited integrator.
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.