COSH

All functions > MATH > COSH

Returns the hyperbolic cosine of a number.

Signatures

Returns: Hyperbolic cosine result (always >= 1)

COSH(number: T) → DOUBLE
sql
ParameterTypeRequiredDescription
numberTYesAny real number (DOUBLE)

Notes

  • Definition: COSH(x) = (e^x + e^(-x)) / 2
  • Always returns values >= 1
  • COSH(0) = 1
  • Even function: COSH(-x) = COSH(x)
  • Grows exponentially for large |x|
  • Related to regular cosine but for hyperbolic geometry
  • Returns NULL if input is NULL

Examples

FeatureQL
SELECT
    f1 := COSH(0e0),  -- Hyperbolic cosine of 0 is 1
    f2 := COSH(1e0),  -- Hyperbolic cosine of 1
    f3 := COSH(-1e0),  -- Even function: COSH(-1) = COSH(1)
    f4 := COSH(2e0)  -- Hyperbolic cosine of 2
;
Result
f1 VARCHARf2 VARCHARf3 VARCHARf4 VARCHAR
1.01.54308063481524371.54308063481524373.7621956910836314

Last update at: 2026/03/03 16:47:38
Last updated: 2026-03-03 16:48:19