©SQL :: Manager
HomeProgram InformationTechnical detailsFree downloadDonate for a cup of coffee
myway SQL Manager for MySQL and MariaDB, Download on Uptodown
SQL functionMySQLMariaDB

The ACOS SQL Function in MySQL and MariaDB - Arc-cosine calculation

ACOSSyntax:ACOS(Number)
Return value:FLOAT
Function type:Numeric function
Function Description

The ACOS() function returns the arc-cosine (inverse cosine) of "Number". "Number" is the cosine of a radians.

The result of the ACOS() function is a value between 0 and PI, or between 0 and 180 degrees if the result is converted to degrees.

The DEGREES() function can be used to calculate the angle from a radians.

The function returns NULL if "Number" is not in a valid cosine range -1 to 1.

SQL Examples for the ACOS function

 1
 2
 3
 4
 5
 6
 7
 8
 9

select acos(0.7071067811865476);
select degrees(acos(0.7071067811865476));
select acos(-0.7071067811865476);
select degrees(acos(-0.7071067811865476));
select acos(0);
select degrees(acos(0));
select acos(2);

acos(0.7071067811865476)
double(23)
0.7853981633974483
degrees(acos(0.7071067811865476))
double(23)
45
acos(-0.7071067811865476)
double(23)
2.356194490192345
degrees(acos(-0.7071067811865476))
double(23)
135
acos(0)
double(23)
1.5707963267948966
degrees(acos(0))
double(23)
90
acos(2)
double(23)
NULL
The examples were created with the MyWAY SQL manager: Download

How to use the ACOS() function in MySQL and MariaDB databases

The ACOS() function in MySQL and MariaDB is commonly used in trigonometric calculations and applications involving angles. An angle associated with a particular cosine value may need to be determined.
ABSACOSADDDATEADDTIMEAES_DECRYPTAES_ENCRYPTANY_VALUE

Further MySQL und MariaDB SQL Numeric functions

BIT_COUNTBIT_COUNT(Integer)
More about BIT_COUNT Function

CEILCEIL(Number)
More about CEIL Function

CEILINGCEILING(Number)
More about CEILING Function

CRC32CRC32(String)
More about CRC32 Function

CRC32CCRC32C([Parameter], String)

FLOORFLOOR(Number)
More about FLOOR Function

SIGNSIGN(Number)
More about SIGN Function

ABSABS(Number)
More about ABS Function

ASINASIN(Number)
More about ASIN Function

ATANATAN(Number [, Number2])
More about ATAN Function

ATAN2ATAN2(Number [, Number2])
More about ATAN2 Function

COSCOS(Number)
More about COS Function

COTCOT(Number)
More about COT Function

DEGREESDEGREES(Number)
More about DEGREES Function

EXPEXP(Number)
More about EXP Function

LNLN(Number)
More about LN Function

LOGLOG([Base], Number)
More about LOG Function

LOG10LOG10(Number)
More about LOG10 Function

LOG2LOG2(Number)
More about LOG2 Function

MODMOD(Number, Divider)
More about MOD Function

POWPOW(Number, Exponent)
More about POW Function

POWERPOWER(Number, Exponent)
More about POWER Function

PIPI()
More about PI Function

RADIANSRADIANS(Number)
More about RADIANS Function

RANDRAND([Number])
More about RAND Function

ROUNDROUND(Number [, Decimals])
More about ROUND Function

SINSIN(Number)
More about SIN Function

SQRTSQRT(Number)
More about SQRT Function

TANTAN(Number)
More about TAN Function

TRUNCATETRUNCATE(Number, Decimals)
More about TRUNCATE Function

Numeric functionsString functionsRegular ExpressionsDate and Time functions
Comparison functionsEncryption & CompressionConversion functionsNULL functions
Aggregate functionsWindow functionsJSON functionsGeometric functions
Sequence functionsInformation functionsDynamic ColumnsMiscellaneous functions
More information about the ACOS SQL function: mysql.com and mariadb.com and w3schools.com
Updated: 2023-09-24ImprintContactTerms & conditionsPrivacy & CookiesUpdatesSitemapFacebookLinkedinTwitterStatistics©2020-2024 Heino Cunze-Fischer