Divide
Divide two signals: y = a / b. Keep the denominator away from zero.
- signal
- Gradara equations
- 3 ports
divideLibraryMathDescription
Divides the first input by the second.
Example
Arithmetic Sum, difference, product, quotient, minimum, and maximum of a ramp and a constant.
a = tb = 2a + ba − ba · ba / bmin(a, b)max(a, b)
Ports
Inputs 2
-
a
Numerator.
-
b
Denominator.
Outputs 1
-
y
Output signal, a / b.
Equations
Modelica
y = a / b
Implementation
The block’s Modelica model
y = a / b;
Assumptions and limitations
- The denominator is not guarded. If b reaches 0 during a run, the division fails and the simulation stops with an error.
Tips
- If b can pass through zero, keep it away from zero first, for example with Max against a small constant or with Saturation.
See also
Select a block in Gradara and press F1 to open its page offline.