A newer version of Max is available. Click here to access the latest version of this document.

atan2

Arc-tangent function (two variables)

Description

atan2 calculates and outputs the arc-tangent of any two given numbers where the left input is the y value and the right input is the x value.

Arguments

Name Type Opt Description
initial-values float or int opt Two ints may be used to set the initial value for the arc-tangent function.

Messages

bang In left inlet: Calculates the arc-tangent of the numbers currently stored. If there are no arguments, atan2 initially holds 0 for both input values.
int y-value [int]
In left input: y value input to an arc-tangent function.
  (inlet1) x-value [int]
In right input: x value input to an arc-tangent function.
float y-value [float]
In left input: y value input to an arc-tangent function.
  (inlet1) x-value [float]
In right input: x value input to an arc-tangent function.

Information for box attributes common to all objects

Output

float: The arc-tangent of the input values (i.e. Arc-tangent (y/x)).
int: The arc-tangent of the input values (i.e. Arc-tangent (y/x)).

Examples

See Also

Name Description
atan Arc-tangent function
atanh Hyperbolic arc-tangent function
tan Tangent function