IMCOSH Function (LibreOffice Calc)
Learn the IMCOSH function in LibreOffice Calc: Returns the hyperbolic cosine of a complex number.
Verification status: Selected examples were executed in LibreOffice Calc 25.2.3.2. This does not establish that every formula and edge case was tested. How formula examples are checked
Quick answer
IMCOSH returns the hyperbolic cosine of a complex number as text. =IMCOSH("4-3i") gives -27.0349456030742-3.85115333481178i in the tested Calc version. This is not ordinary cosine (IMCOS) and is not the numeric-only COSH function.
Function syntax and argument definition
=IMCOSH(Complex_number)
Complex_number (required): a complex string such as "4-3i", "1+j", a cell holding a complex-number string, COMPLEX(real;imaginary), or a real number (if the imaginary coefficient is zero). No optional arguments are defined. The return type is always string.
Version and locale: The displayed current English online documentation says LibreOffice 26.8 Help. All native examples below were executed in desktop LibreOffice Calc 25.2.3.2, not the documented 26.8 runtime. English Calc formula examples separate different function arguments with a semicolon (;); complex-number coefficients within one quoted string are not separate arguments. Actual separators and decimal marks can follow your locale. The documented IMCOSH/IMSINH entries specifically say the functions are available since LibreOffice 3.6; other two functions are confirmed in the Help and tested in 25.2 but no undocumented first-version claim is made.
How it works
For z=x+iy, cosh(z) = cosh(x)cos(y) + i sinh(x)sin(y). Although hyperbolic functions occur in exponentials and differential equations, the imaginary component uses the ordinary circular sine and cosine of y. The function is even: cosh(-z)=cosh(z); do not confuse that with cosh(conjugate(z)).
Reproducible worksheet setup
Enter complex text 4-3i in A3, numeric 3 in B2, numeric 4 in C2, and 1+j in A4. =IMCOSH(A3) returns -27.0349456030742-3.85115333481178i; =IMCOSH(COMPLEX(B2;C2)) returns -6.58066304055116-7.58155274274654i. Native =IMCOSH(A4) returned 0.833730025131149+0.988897705762865j, preserving the j suffix.
To recreate the result, enter the indicated literal complex values as cell text (without a leading equals sign), insert the formula into a different empty cell, and allow Calc to recalculate. Values listed below reflect the actual observed Calc results rather than screenshots or hypothetical applications.
Worked formulas and observed results
On a narrow screen, scroll this table sideways to see every column.
| Formula | Observed result in Calc 25.2.3.2 | Explanation |
|---|---|---|
=IMCOSH("4-3i") |
-27.0349456030742-3.85115333481178i |
Official native example. |
=IMCOSH(2) |
3.76219569108363 (text) |
Imaginary part equals zero and is omitted. |
=IMCOSH(0) |
1 (text) |
Complex hyperbolic cosine at origin. |
=IMCOSH(COMPLEX(3;4)) |
-6.58066304055116-7.58155274274654i |
Construct a complex value from two inputs. |
=IMCOSH("-1-i") |
0.833730025131149+0.988897705762865i |
Both real and imaginary coefficients are negative. |
Advanced example and interpretation
The identity cosh²(z)-sinh²(z)=1 can be checked with =IMSUB(IMPRODUCT(IMCOSH("1+i");IMCOSH("1+i"));IMPRODUCT(IMSINH("1+i");IMSINH("1+i"))). Native Calc returned 1.00000000000001 (a complex-number text value with small floating-point rounding). Avoid testing the string for exact equality to "1"; compare coefficients using a tolerance.
Errors, edge cases and limitations
=IMCOSH("oops") and =IMCOSH("3+4k") both returned Err:502 in the native test. Supported imaginary suffix letters are i or j; arbitrary k notation is invalid. Very large coefficients can also reduce numerical reliability; do not claim unrestricted range.
Type and precision: COSH(2) gives a numeric real hyperbolic cosine, whereas IMCOSH(2) gives text; prefer COSH when imaginary components will never occur. Floating-point computations should generally be checked by numeric tolerance rather than string exact-match. ODF/Excel/Sheets file-format round-trips can affect syntax, prefixes or formatting; export/import behaviour was not tested here.
Troubleshooting
Why is =ISTEXT(IMCOSH(2)) TRUE? This function always returns text, even when the output prints 3.76219569108363. Convert via IMREAL for numeric use. Sign surprises? For a complex argument, the imaginary sign follows sin(y) in sinh(x)sin(y); verify y was entered correctly. Err:502? Check the complex-number representation, suffix and nesting. Different rounded digits? Output precision and spreadsheet formatting are not mathematically exact.
If you cannot reproduce the result, first confirm the exact formula in the formula bar, check the cell’s source value, inspect decimal and list separators for your locale, and compare the software version. Use simple examples before adding other nested formulas.
Cross-software compatibility
LibreOffice Help marks IMCOSH available since LibreOffice 3.6 and lists it as an ODF 1.2 function. Excel documents IMCOSH (2013 onward per Excel category reference); Google Sheets lists IMCOSH. Syntax and math translate conceptually but error codes and exact text formatting differ across programs. See official cross-software references below; no native Excel or Google Sheets tests were performed.
Related LibreOffice function guides
Official evidence, check date, and test provenance
- LibreOffice official function page: Documentation for IMCOSH — accessed 2026-10-11, current display LibreOffice 26.8 Help. Supports named function, purpose, syntax, argument form, and its documented examples.
- LibreOffice official analysis-functions list: Add-in Functions, Part Two — accessed 2026-10-11. Explains
COMPLEX,IMARGUMENT,IMLOG2and related engineering functions. - Microsoft: Engineering functions reference — consulted 2026-10-11 for equivalent Excel function availability; no Excel execution claimed.
- Google: Sheets function list — consulted 2026-10-11 for function availability; no Sheets execution claimed.
- Native evidence: The accompanying
native_calc_results.jsonandnative_calc_test.pyrecord observed Calc output, numeric/error types and independent Python math comparisons. 34/34 assertions passed across this four-page batch and 8 additional error observations were recorded; not every explanatory derivative formula was executed.
How this guide was checked
Selected example formulas were run in LibreOffice Calc 25.2.3.2 on Linux on October 12, 2026. The official Help may cover a newer version. Tests of selected formulas do not certify every locale, interactive array operation or file round trip. View the example-check record.