SQRT Function (OpenOffice Calc)
The SQRT function in OpenOffice Calc returns the square root of a number. Learn syntax, examples, error conditions, and best practices.
Verification status: Consult the documentation, examples and any stated test scope below. How formula examples are checked
Availability and version history
- Introduced: Documented by Apache OpenOffice 4.1.16; original introduction not established.
- Availability: Supported in Apache OpenOffice 4.1.16, verified against its function registry. This identifies a supported release, not a final working version.
- Scope: Desktop Calc, using the English function name. Availability in other spreadsheet applications is separate.
- Checked: 2026-10-14 — function reference; versioned support. Documentation/source check; not a new native test. Existing example-specific test claims below retain their stated scope.
The SQRT function in OpenOffice Calc returns the square root of a number. It is widely used in scientific calculations, geometry, engineering, statistics, and financial modeling. SQRT is a simpler, more readable alternative to using POWER(number; 0.5).
What the SQRT Function Does
- Returns the nonnegative principal square root of a number
- Works with integers and decimals
- Useful for geometry, physics, statistics, and financial modeling
- Equivalent to
POWER(number; 0.5) - Works across sheets
SQRT is ideal when you need clean, readable root calculations.
Syntax
SQRT(number)
Arguments:
- number — Any non‑negative numeric value or reference
A separate documented complex-root operation is needed for complex values. Wrapping a failed SQRT(-1) in IMAGINARY does not repair it.
Basic Examples
Square root of a positive number
=SQRT(25)
Result: 5
Square root of a decimal
=SQRT(2.25)
Result: 1.5
Square root using a cell reference
=SQRT(A1)
Square root of a formula result
=SQRT(A1 - B1)
Advanced Examples
Equivalent POWER expression
=POWER(A1; 0.5)
Square root across sheets
=SQRT(Sheet1.A1)
Square root of a product
=SQRT(A1 * B1)
Square root of a sum of squares (distance formula)
=SQRT(POWER(X2 - X1; 2) + POWER(Y2 - Y1; 2))
Root‑mean‑square (RMS)
=SQRT(AVERAGE(A1:A10 * A1:A10))
Confirm with Ctrl+Shift+Enter.
Standard deviation (manual form)
=SQRT(VAR(A1:A10))
Hypotenuse calculation
=SQRT(POWER(A1; 2) + POWER(B1; 2))
Common Errors and Fixes
The source accepts fVal>=0 and otherwise takes the illegal-argument path. Zero is valid. Wrapping SQRT(-1) inside IMAGINARY cannot turn the failed real root into a complex result. A physically empty scalar reference supplies zero through the reader, so its source expectation is SQRT=0, not a blanket empty-cell error. Overflow may occur in an earlier product or sum before SQRT; the root of an already finite nonnegative number does not grow beyond that number when the number is at least one.
For scalar numeric functions the checked reader distinguishes genuine empty references, strings, numeric values and errors. It can parse some numeric text, including ordinary integer text, and reads a physically empty referenced cell as zero. Therefore neither “all text is ignored” nor “all blanks always produce an invalid-argument error” is a safe general rule. A formula error propagates; it is not silently removed. Use explicit numeric cells in the reproducible tests, and inspect data types before changing a domain check.
Formula parsing errors are separate from mathematical domain errors. Check the function spelling, parentheses and the semicolon separator used in these examples. Number formatting affects display; the separate Calc precision-as-shown setting can also affect numeric reads, so the reference calculations assume ordinary stored-value precision. Dates and times are stored numeric values, but that does not make applying this mathematical operation physically meaningful to every date serial.
Best Practices
- Use SQRT for readability instead of
POWER(x; 0.5) - Validate that inputs cannot be negative
- Use ABS only when the mathematical model calls for magnitude, not to hide an invalid radicand
- Convert imported text numbers to real numbers
- Use named ranges for cleaner formulas
Reproducible numeric controls
| Formula | Independent reference result |
|---|---|
=SQRT(25) |
5 |
=SQRT(2.25) |
1.5 |
=SQRT(0) |
0 |
=SQRT(0.25) |
0.5 |
=ROUND(SQRT(2);10) |
1.4142135624 |
=SQRT(-1) |
ERROR |
These are independent mathematical/source controls, not new native application or GUI observations. ERROR denotes an invalid or non-finite source path without inventing an observed localized message. Decimal expectations use the shown rounding precision; full stored results should be retained for subsequent arithmetic.
Complete worksheet and changed-input checks
Enter squared quantities 0,2.25,9,25 in A2:A5. In B2 enter =SQRT(A2) and fill down. Expected roots are 0,1.5,3,5. In C2 enter =B2^2 and fill down; these particular exact-square controls recover the input values. For non-square values, use a numerical tolerance rather than demanding bit-for-bit equality after a square-root round trip.
For a distance control, put 3 in E2 and 4 in F2. =SQRT(E2^2+F2^2) returns 5. Changing E2 to 6 and F2 to 8 gives 10, as expected when both perpendicular components double.
Advanced validation and model boundaries
Distinguish the principal root from both algebraic solutions. SQRT(25)=5. The equation x^2=25 has solutions 5 and -5, but the function returns the nonnegative principal root. Likewise SQRT((-5)^2)=5, which is ABS(-5), not -5.
Check RMS with a concrete dataset. For 3 and 4 in A8:A9, the mean square is (9+16)/2=12.5 and the RMS is approximately 3.5355339059. This differs from the arithmetic mean 3.5. The existing array expression illustrates the general construction; the small scalar check =SQRT((A8^2+A9^2)/2) avoids ambiguity about array entry.
Do not fix a negative input blindly with ABS. A negative radicand may indicate incorrect units or an upstream subtraction. SQRT(ABS(x)) computes a different quantity. Only apply that transformation when the mathematical model calls for the magnitude.
Documentation and verification scope
The original useful examples, named-variable illustrations, shortcodes and design are retained; variables such as Radius, Rate, sd or Time must be defined as cells/names with the required units before those templates are executable. The earlier cross-sheet and Ctrl+Shift+Enter examples describe formula patterns, not a new GUI or array-entry test. Compatibility metadata does not certify identical coercion or boundary behavior in other products.
See the official SQRT reference, 4.1.16 mathematics help, scalar elementary functions, SIGN and logarithm callbacks, POWER implementation, numeric argument reading, and non-finite result handling. The first help/core snapshots retain October 13 retrieval dates; POWER retains October 14. Numeric-reader and result-handler sources were retrieved October 15. Original introduction and final functioning version remain unknown; the supported 4.1.16 evidence above is separate.