IMSEC Function (Calligra Sheets)
Find complex secants in Calligra Sheets, using cosine reciprocals, imaginary-axis examples and clearly scoped near-pole engine results.
Verification status: 18 selected formulas were executed through the Calligra Sheets 25.04.2 calculation engine library. Complex outputs are reported as components, not GUI-cell display. Version 26.08.2 was source-checked only. How formula examples are checked
Quick answer: =IMSEC(COMPLEX(3;4)) gives (-0.036253496916,0.005164344608) in the tested Calligra calculation engine. The pair gives the real and imaginary components, not worksheet display text.
Availability and version history
- Introduced: First release not established; the name is present in Calligra 2.4.0 source.
- Supported in: Calligra Sheets 26.08.2, with no retirement established.
- Scope: Desktop Sheets with the Engineering module. Examples use English semicolon-separated formulas.
- Checked: October 14, 2026. Formulas were executed through the official 25.04.2 engine library and checked against source and independent mathematics. This is not GUI-cell or workbook-import evidence; 26.08.2 was source-checked, not executed.
What IMSEC returns
IMSEC returns sec(z) = 1/cos(z). It is a reciprocal trigonometric function, not an inverse cosine. Its poles lie where complex cosine is zero: at real π/2+kπ for integer k. Function help.
Syntax and arguments
=IMSEC(complexValue)
Exactly one complex value is accepted. The reference formulas use COMPLEX(real;imaginary); ordinary numbers represent a zero imaginary component. Real-angle input uses radians. Registration and implementation, with versioned help.
Reproducible engine examples
Results are shown as (real,imaginary) component pairs, rounded to twelve decimal places, not a literal cell format. Tiny or very large values use thirteen significant digits in scientific notation. A component rounded to zero is shown as 0; the stored value may still contain a tiny residual or signed zero. NaN means not-a-number; infinity and NaN are not finite results.
| Formula | Engine result |
|---|---|
=IMSEC(COMPLEX(3;4)) |
(-0.036253496916,0.005164344608) |
=IMSEC(COMPLEX(3;-4)) |
(-0.036253496916,-0.005164344608) |
=IMSEC(COMPLEX(-3;4)) |
(-0.036253496916,-0.005164344608) |
=IMSEC(COMPLEX(-3;-4)) |
(-0.036253496916,0.005164344608) |
=IMSEC(COMPLEX(1;0)) |
(1.850815717681,0) |
=IMSEC(COMPLEX(0;1)) |
(0.648054273664,0) |
=IMSEC(COMPLEX(-1;0)) |
(1.850815717681,0) |
=IMSEC(COMPLEX(0.5;0.25)) |
(1.085358604752,0.145220628661) |
Practical worksheet
For z = i, sec(i) = 1/cosh(1), approximately 0.648054273664. A secant below 1 is valid for this complex input; the familiar real secant restriction does not apply.
Use =IMSEC(COMPLEX(A2;B2)) when A2 and B2 contain the intended real and imaginary components. This avoids confusing a real reciprocal with the reciprocal of a complex cosine.
Advanced interpretation and checks
At z = 0.5+0.25i, the executed product of IMSEC(z) and IMCOS(z) returned (1,0). In component arithmetic, reciprocating u+vi uses (u−vi)/(u²+v²), not 1/u + i/v.
Secant is even because cosine is even. It also satisfies sec(ib)=sech(b) for real b. These identities supply checks on the purely imaginary row and on the reference pairs with opposite signs.
The exact advanced-check formula was:
=IMPRODUCT(IMSEC(COMPLEX(0.5;0.25));IMCOS(COMPLEX(0.5;0.25)))
Input boundaries and cautions
IMSEC(PI()/2) produced a large finite real component near 1.633123935320E16. It describes the represented input close to a pole; it does not make the exact mathematical secant at π/2 finite. A tiny cosine magnifies input and rounding errors.
Invalid or empty text became complex zero, whose secant is 1. That plausible output can hide malformed input. Wrong arity is separately reported as #VALUE! in the engine. No native cell-display behavior is inferred from these component values.
| Formula | Engine result |
|---|---|
=IMSEC("3+4i") |
(-0.036253496916,0.005164344608) |
=IMSEC("3+4j") |
(-0.036253496916,0.005164344608) |
=IMSEC("abc") |
(1,0) |
=IMSEC("") |
(1,0) |
=IMSEC(TRUE()) |
(1.850815717681,0) |
=IMSEC(0) |
(1,0) |
=IMSEC() |
#VALUE! |
=IMSEC(1;2) |
#VALUE! |
=IMSEC(PI()/2) |
(1.63312393532E+16,0) |
Conversion evidence
The complex conversion helper explains the text and Boolean cases above. The inspected Engineering module and complex converter are byte-identical between 25.04.2 and 26.08.2. That source comparison does not establish every locale, import path or extreme-value case.
Related guides
Use COMPLEX to construct values from numeric components, IMABS for magnitude, and IMARGUMENT for principal phase.