Computes the principal value of the arc tangent of y/x, using the signs of both arguments to determine the quadrant of the return value.
#include <math.h>
double atan2 (
double y,
double x);
(IN) Specifies the arguments whose arc tangent is to be computed.
Returns the arc tangent of y/x, in the range (-pi, pi). When the arguments are outside the permissible range, errno is set and matherr is called.
A domain error occurs if both arguments are zero.