The Standard LibrarymathMethodsatan2On this pageatan2Computes the arc tangent of y/x, considering quadrants. atan2(45, -45); //2.356 Syntax atan2(y, x) Returns The computed value as a double (in radians).