ATAN
ATAN(X)
Section titled “ATAN(X)”- x: This is the numeric value whose arc tangent is to be calculated. The value of X must be within the range of -∞ to +∞. The resulting angle is in the range of -π/2 to +π/2, and is expressed in radians.
Example
Section titled “Example”SELECT ATAN(1);Output
Section titled “Output”0.7853981633974483Explanation
Section titled “Explanation”The ATAN(1) function call in MySQL returns the arc tangent of 1, which is approximately 0.7854 in radian. ATAN returns the arc tangent of X that is, the value whose tangent is X.
ATAN(numeric) RETURNS double precision
Section titled “ATAN(numeric) RETURNS double precision”- numeric: This is the input parameter for the ATAN function. It represents the tangent of the angle you want to find and should be a numeric value. ATAN then returns the arc tangent of this numeric value, expressed as a float in the range of -π/2 to π/2.
Example
Section titled “Example”SELECT ATAN(1);Output
Section titled “Output”0.7853981633974483Explanation
Section titled “Explanation”In this example, the ATAN function returns the arctangent, in radians, of a specified number. The specified number here is 1, and the output 0.7853981633974483 is the arctangent of 1 in radians.
ATAN( float_expression )
Section titled “ATAN( float_expression )”- float_expression: A floating-point number or any valid expression that returns an approximate numeric, or exact numeric data type in SQL Server, for which the arctangent value is to be computed.
Example
Section titled “Example”SELECT ATAN(1) AS AtanValueOutput
Section titled “Output”| AtanValue |
|---|
| 0.78539816 |
Explanation
Section titled “Explanation”The ATAN function in SQL Server calculates the arctangent of the value 1 provided in the argument. As a result of the function, we get the value 0.78539816.
ATAN(number)
Section titled “ATAN(number)”- number: This represents a numeric value, i.e., floating-point numbers, or integers, for which the arc tangent needs to be computed. The value should be in the range of -1 to 1.
Example
Section titled “Example”SELECT ATAN(1) FROM dual;Output
Section titled “Output”0.7853981633974483Explanation
Section titled “Explanation”The ATAN function in Oracle calculates the arc tangent of a number. In the provided example, the ATAN function calculates the arc tangent of 1, which results in approximately 0.7854. The ATAN function in Oracle returns the result in radians.
ATAN(X)
Section titled “ATAN(X)”- x: This is a numeric value for which the arctangent is to be calculated. It represents the tangent of the angle you wish to find. The resulting angle is returned in radians. In SQL, this number can be a real, double precision, or any of the numeric types.
Example
Section titled “Example”SELECT ATAN(1.5);Output
Section titled “Output”0.982793723247329Explanation
Section titled “Explanation”ATAN() function in SQLite computes the arc tangent of a value. The above example takes the arc tangent of the number 1.5 and the output is approximately 0.982793723247329.