SIN()
All functions > MATH > SIN()
Returns the sine of an angle in radians.
Signatures
Sine
Returns: Sine value in [-1, 1]
SIN(radians: T) → DOUBLE sql
| Parameter | Type | Required | Description |
|---|---|---|---|
radians | T | Yes | Angle in radians |
With:
T: Floating-point type (FLOAT, DOUBLE)
Signature notes:
- Input must be in radians; use RADIANS() to convert from degrees
- Period of 2π; odd function:
SIN(-x) = -SIN(x) - Returns NULL if the input is NULL
Examples
FeatureQL
SELECT
f1 := SIN(0E0), -- sin(0) = 0
f2 := SIN(1.5707963267948966E0), -- sin(π/2) = 1
f3 := SIN(0.7853981633974483E0), -- sin(π/4) = √2/2
f4 := SIN(0.5235987755982988E0) -- sin(π/6) ≈ 0.5
;Result
| f1 VARCHAR | f2 VARCHAR | f3 VARCHAR | f4 VARCHAR |
|---|---|---|---|
| 0.0 | 1.0 | 0.7071067811865475 | 0.49999999999999994 |
On this page