COT()

Description

The COT() function returns the cotangent of input number(given in radians).

Syntax

  1. > COT(number)

Arguments

ArgumentsDescription
numberRequired. Any numeric data type supported now.

Examples

  1. mysql> SELECT COT(12);
  2. +---------------------+
  3. | cot(12) |
  4. +---------------------+
  5. | -1.5726734063976895 |
  6. +---------------------+
  7. 1 row in set (0.00 sec)
  1. drop table if exists t1;
  2. create table t1(a int,b float);
  3. insert into t1 values(1,3.14159);
  4. insert into t1 values(-1,12);
  5. mysql> select cot(a), cot(b) from t1;
  6. +---------------------+---------------------+
  7. | cot(a) | cot(b) |
  8. +---------------------+---------------------+
  9. | 0.6420926159343306 | -394449.0619219334 |
  10. | -0.6420926159343308 | -1.5726734063976895 |
  11. +---------------------+---------------------+
  12. 2 rows in set (0.01 sec)