This information is part of the Modelica Standard Library maintained by the Modelica Association.
This block determines the hypotenuse
y = sqrt(u1^2 + u2^2)
if the boolean parameter
u1IsHyotenuse = false.
In this case the two inputs
u2 are interpreted as the legs of a right triangle
and the boolean output
valid is always equal to
u1IsHyotenuse = true, input
u1 is interpreted as hypotenuse and
is one of the two legs of a right triangle.
Then, the other of the two legs of the right triangle is the output, determined by
y = sqrt(u1^2 - u2^2), if
u1^2 - u2^2 ≥ 0; in this case the
valid is equal to
true. In case of
u1^2 - u2^2 < 0, the
y = 0 and
valid is set to
Description: If true, u1 is the hypotenuse and y is one leg
Output the total harmonic distortion (THD)