Appearance
Saturation
Clamps a double signal between a lower and an upper limit: out = min(max(in, lower), upper). The limits come either from parameters or from two input ports (max on top, min at the bottom) for limits that move at run time. With fixed limits, a lower limit above the upper one is logged as an error and the two are swapped; with port limits the upper limit wins if they cross.
Category: Nonlinear
Ports
| Port | Kind | Signal | Notes |
|---|---|---|---|
in | Control input | Real | |
max | Control input | Real | Shown when Limits from is Input ports |
min | Control input | Real | Shown when Limits from is Input ports |
out | Control output | Real |
Parameters
| Parameter | Type | Default | Units | Description | ID |
|---|---|---|---|---|---|
| Limits from | Choice: Parameters / Input ports | Parameters | — | Parameters = fixed upper / lower limits below. Input ports = read the limits from the `max` and `min` ports every step. | limit_source |
| Upper limit | Number | 1 | — | Largest value the output can take. | upper_limit |
| Lower limit | Number | -1 | — | Smallest value the output can take. Must not exceed the upper limit. | lower_limit |