SEC in ONLYOFFICE: Secant of a Radian Angle
How to use the ONLYOFFICE SEC function: documented radians/numeric input, worksheet examples, reciprocal formulas, limitations and platform notes.
Verification status: See the evidence and test scope described in this guide. How formula examples are checked
Quick answer. SEC(number) returns the secant of an angle expressed in radians. Mathematically, secant is 1 divided by cosine, wherever cosine is nonzero. See ONLYOFFICE’s current SEC reference for the vendor’s one-argument signature. The examples are independently calculated mathematical expectations; native ONLYOFFICE execution was not performed.
Availability and version history
- Introduced: The original introduction version and date are not established by the official sources checked.
- Availability: Documented in the current ONLYOFFICE Spreadsheet Editor help; no final working-version endpoint is established.
- Scope: Docs and Desktop Editors release separately. This unversioned help does not establish availability in every older build, mobile client or deployment.
- Checked: October 14, 2026, against the official function reference. Documentation check; not a new native test.
What SEC does—and what its number means
The result is dimensionless; it is useful when a projection or path-length correction involves a cosine denominator. The mathematical definition is:
SEC(x)=1/COS(x) whenever COS(x)≠0. This identity is a mathematical derivation, not an execution claim for ONLYOFFICE.
Exact official syntax, arguments, and defaults
=SEC(number)
| Argument | Position | Required? | Input type and unit described by ONLYOFFICE | Default |
|---|---|---|---|---|
number |
1 | Yes; the only documented argument | Numeric angle in radians; its absolute value must be strictly less than 2^27 (134,217,728) | No optional argument/default documented |
The official page explicitly states the strict bound abs(number)<2^27; an argument equal to the boundary is outside the documented input range. It does not establish a particular returned error code for violating that limit, nor specify how blank cells, quoted numerals or Boolean inputs are coerced. This guide uses ordinary numeric cells. Official evidence.
Documented radian angles: The values in column A are deliberately degrees for human readability, but the input actually given to SEC/CSC/COT is RADIANS(A2) and so on. This transformation is essential.
Reproduce the worksheet from a blank file
- Open an editable spreadsheet in ONLYOFFICE Spreadsheet Editor. Its current function-entry guide shows Formula → Function or manually entering a formula beginning with
=. - Put
angle (°)in A1 andSEC resultin B1. Type the following numeric values, one per row, into A2:A9: 0, 30, 45, 60, 120, 180, 240, 300. - Enter
=SEC(RADIANS(A2))in B2 and fill down through B9. The row references should change automatically. Use English formula language for these exact names. - Compare B2:B9 to the independent mathematical expectations, not to claimed screenshots or observed runtime outputs:
| Cell / row | Value in column A | Enter in column B (or fill down) | Independently calculated expectation |
|---|---|---|---|
| A2 | 0 | =SEC(RADIANS(A2)) |
≈ 1 |
| A3 | 30 | =SEC(RADIANS(A3)) |
≈ 1.1547005384 |
| A4 | 45 | =SEC(RADIANS(A4)) |
≈ 1.4142135624 |
| A5 | 60 | =SEC(RADIANS(A5)) |
≈ 2 |
| A6 | 120 | =SEC(RADIANS(A6)) |
≈ -2 |
| A7 | 180 | =SEC(RADIANS(A7)) |
≈ -1 |
| A8 | 240 | =SEC(RADIANS(A8)) |
≈ -2 |
| A9 | 300 | =SEC(RADIANS(A9)) |
≈ 2 |
- For extra verification, open Formula → Function and search for
SECas described in the vendor’s insertion instructions. This checks that the feature is exposed in your installation; it is not proof that every historical release supports it.
Additional reproducible formulas and independently calculated results
These are directly pasteable English-language examples in separate empty cells. They are expected results from independent mathematical calculations, not native ONLYOFFICE observations. Answers marked ≈ are rounded for display; compare a few decimals.
| English-locale formula | Mathematical expected result | Why it matters |
|---|---|---|
=SEC(0) |
≈ 1 | secant at 0 radians |
=SEC(PI()/3) |
≈ 2 | 60° in radians |
=SEC(-PI()/3) |
≈ 2 | secant is even |
=SEC(RADIANS(30)) |
≈ 1.1547005384 | 30° conversion |
=SEC(RADIANS(60)) |
≈ 2 | 60° conversion |
=SEC(RADIANS(120)) |
≈ -2 | negative secant in quadrant II |
=SEC(RADIANS(180)) |
≈ -1 | secant of π |
=SEC(RADIANS(45)) |
≈ 1.4142135624 | square-root-of-two relation |
=5*SEC(RADIANS(60)) |
≈ 10 | straight ray path across 5-cm layer |
=1/COS(RADIANS(60)) |
≈ 2 | independent reciprocal expression |
=SEC(RADIANS(45))*COS(RADIANS(45)) |
≈ 1 | identity near 1 |
=ABS(SEC(RADIANS(120))) |
≈ 2 | magnitude of a signed secant |
Advanced applications and important mathematical limits
1. Correcting a slanted path length
Suppose a layer is 5 cm thick perpendicular to its surface, and a straight ray crosses it at 60° from the surface normal. Under this simplified geometric model, the ray travels =5*SEC(RADIANS(60)) cm through the layer, an independently calculated 10 cm. This relation applies to a straight ray and a nonzero cosine; it does not model refraction or absorption.
2. Sanity check against the cosine identity
Where cosine is nonzero, SEC(x)*COS(x) is 1 in exact mathematics. Use =SEC(RADIANS(45))*COS(RADIANS(45)) as a numerical cross-check; the expected value is approximately 1, not necessarily bit-for-bit exact. This identity is a mathematical check, not evidence of native ONLYOFFICE output.
3. Negative secants and projection direction
At 120°, cosine is negative, so =SEC(RADIANS(120)) has mathematical value −2. If you require a positive magnitude, use =ABS(SEC(RADIANS(120))), expected 2. A negative answer is not automatically an error: it often indicates the signed direction of a projection.
Errors, apparent surprises and safe troubleshooting
| Formula or symptom | Explanation and action |
|---|---|
=SEC(PI()/2) |
Mathematically secant is undefined where cosine is zero. Because π and trigonometric results are approximated, the actual spreadsheet might show a very large finite number or an error. No exact ONLYOFFICE error code is asserted. |
=SEC(RADIANS(90)) |
Same theoretical singularity as above; do not use it as a robust division-by-zero detector. |
=SEC(60) when you mean 60° |
60 is treated as a radian argument by the documented function, not automatically converted to degrees. Use RADIANS(60). |
=SEC(134217728) |
Outside the documented range: the vendor requires absolute argument strictly smaller than 2^27. The function page does not promise a specific error code; do not assert one. |
A quoted numeral ("1"), blank reference, logical TRUE or multiple arguments |
The one-argument vendor reference does not specify coercion or precise errors for these cases. Enter a genuine numeric value and check the real Desktop/web version instead of assuming behaviour from a different spreadsheet program. |
| Formula name appears unknown | Check the installed ONLYOFFICE editor version, Formula Language, and actual Function picker. A vendor’s current unversioned help article is not a guarantee about an old or custom-hosted installation. |
| Last decimal digits differ | Formatting, finite-precision π/radian conversion, argument reduction or transcendental evaluation can affect displayed digits. Use a tolerance rather than exact floating-point equality. |
A safer check for boundary-sensitive formulas
If your model will ever evaluate a mathematically singular point, test the domain before evaluation rather than relying on a specific error message or last-digit numerical coincidence. Avoid building critical logic around comparing COS(RADIANS(90)) or SIN(PI()) to exactly zero; floating-point values near the mathematical singularity need a numeric tolerance. This is mathematical design advice, not a verified ONLYOFFICE evaluation rule.
Related ONLYOFFICE references
- RADIANS — official ONLYOFFICE documentation (checked 2026-10-13 UTC).
- COS — official ONLYOFFICE documentation (checked 2026-10-13 UTC).
Documentation and evidence classification (checked 2026-10-13 UTC)
- ONLYOFFICE function-page evidence: SEC documents the displayed formula name, the one-argument signature, an input described as an angle in radians, and the magnitude restriction. It does not document native results for this article’s custom worksheet.
- Function entry workflow: ONLYOFFICE Docs: Inserting functions describes selecting Formula → Function, searching by name, and entering formulas with an equals sign. It gives English formula examples using commas as argument separators.
- Regional settings: Spreadsheet Editor Advanced Settings describes Formula Language, region, and decimal/thousands separators. Examples here use the English function name and decimal dot. Verify formula translation and separators in your installation rather than asserting a tested locale matrix.
- Product editions and versions: The ONLYOFFICE Docs changelog lists Docs 10.0.0, released 10 October 2026, whereas the Desktop Editors changelog separately lists Desktop Editors 9.4.0, released 19 May 2026. The official Desktop GitHub releases also lists 10.0.0 released 13 October 2026. These release references do not establish the first version supporting this function, nor prove Desktop/web runtime parity.
- Runtime confidence: Custom numerical expectations were independently recalculated at high precision. Native ONLYOFFICE Desktop/web execution and locale-specific parsing were not tested.
Native compatibility checks
For compatibility checks, record the named Docs web version and Desktop build, cell results, function availability, extreme-input behavior and relevant singular boundaries. Repeat with the formula language and regional settings actually used.