The Fauna service will be ending on May 30, 2025.

For more information on the service wind down, see our announcement and the Fauna Service End-of-Life FAQ.

Cos

This reference topic applies to FQL v4. Go to this page for the latest FQL v10 reference topics.

Copied!
Cos( value )

Description

The Cos function is a trigonometric function which calculates ratios of the lengths of the sides of right triangles. Cos returns the cosine of a number.

Parameters

Parameter Type Definition and Requirements

value

Number

The Number whose cosine should be returned.

Returns

A Number which is the cosine of value.

Examples

The following query returns the cosine of 0.5:

Copied!
Cos(0.5)
0.8775825618903728
Query metrics:
  •    bytesIn:  11

  •   bytesOut:  31

  • computeOps:   1

  •    readOps:   0

  •   writeOps:   0

  •  readBytes:   0

  • writeBytes:   0

  •  queryTime: 3ms

  •    retries:   0

\