blockAtan2
Output atan(u1/u2) of the inputs u1 and u2
Information
Block that outputs the tangent-inverse y = atan2(u1, u2)
of the input u1 divided by the input u2.
u1 and u2 shall not be zero at the same time instant.
Atan2 uses the sign of u1 and u2
in order to construct the solution in the range
-π ≤ y ≤ π, whereas
Buildings.Controls.OBC.CDL.Reals.Atan
gives a solution in the range
-π/2 ≤ y ≤ π/2.
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| Buildings.Controls.OBC.CDL.Interfaces.RealInput | u1 | Input u1 for the atan2(u1/u2) function | |
| Buildings.Controls.OBC.CDL.Interfaces.RealInput | u2 | Input u2 for the atan2(u1/u2) function | |
| Buildings.Controls.OBC.CDL.Interfaces.RealOutput | y | Output with atan2(u1/u2) |
Revisions
-
November 8, 2024, by Michael Wetter:
Addedfinalkeyword to unit declaration as block is only valid for this unit.
Also addeddisplayUnitkeyword. -
March 7, 2023, by Jianjun Hu:
Added unitradto the output.
This is for Buildings, issue 3277. -
March 2, 2020, by Michael Wetter:
Changed icon to display dynamically the output value. -
January 3, 2017, by Michael Wetter:
First implementation, based on the implementation of the Modelica Standard Library.