FACTDOUBLE in Calligra Sheets: Double Factorials
Learn step-two factorial calculations, examples, numeric input rules, aliases, errors and differences from Excel FACTDOUBLE.
Verification status: Consult the documentation, examples and any stated test scope below. How formula examples are checked
Quick answer: The FACTDOUBLE function multiplies every second whole number down to 1 or 2. =FACTDOUBLE(6) means 6 Ć 4 Ć 2 and has expected value 48; =FACTDOUBLE(7) means 7 Ć 5 Ć 3 Ć 1 and has expected value 105. Both examples appear in the official KDE function catalogue.
Source and testing: Calligra 26.08.2 C++ and XML checked against the official
v26.08.2tag; handbook consulted 2026-10-12. Outputs marked expected are checked by independent integer step-two multiplication. No native Calligra execution has been performed.
Availability and version history
- Introduced: Documented by 26.08.2; original introduction not established.
- Availability: Supported in Calligra Sheets 26.08.2, based on the function-specific registration.
- Scope: The official application listing provides Linux installation; other packaged builds are unverified here.
- Checked: October 14, 2026. Documentation/source check; no new native test in Calligra Sheets 26.08.2.
What is a double factorial?
For non-negative integer n, n!! means n Ć (nā2) Ć (nā4) Ć ..., stopping at 1 for odd n or 2 for even n. It is not FACT(FACT(n)), nor is it simply 2 Ć FACT(n). For example, 8!! = 8Ć6Ć4Ć2 = 384, while 8! = 40320. Mathematically, 0!! and 1!! are both 1; that domain convention should still be confirmed for the particular spreadsheet’s underlying calculation implementation. The official handbook defines the step-two factorial, and the shipped C++ function calls calc->factDouble after checking its argument.
Syntax, type checks, optional arguments, locale
=FACTDOUBLE(number)
| Parameter | Position | Required? | XML help type | Pinned C++ acceptance rule | Default |
|---|---|---|---|---|---|
number |
1 | Yes | Floating-point | isInteger() and non-negative integer (asInteger() >= 0) |
None |
The one-argument signature and parameter are in shipped math.xml, whereas the stricter guard appears in math.cpp. The C++ function registration exposes the canonical name FACTDOUBLE and the explicit compatibility alternate name COM.SUN.STAR.SHEET.ADDIN.ANALYSIS.GETFACTDOUBLE (source). That name is an alias, not a separate function, and its interoperability does not mean you should type the long internal name in a typical worksheet.
The function has no documented optional parameters or defaults; all inputs are passed in first position. Because there is only one argument, no separator occurs. The KDE English examples for multi-argument functions use ; separators; local decimal marks and type conversions can differ. Type-guard behaviour is checked in the pinned implementation, not in a running installed build.
Small worksheet: odd and even packing patterns
Enter A2:A7 as numeric integers, enter =FACTDOUBLE(A2) in B2, and fill B2 down. Column C is an explanatory check, not another formula.
| Row | A: n | B formula | Expected B, mathematically | C: multiplication |
|---|---|---|---|---|
| 2 | 2 | =FACTDOUBLE(A2) |
2 | 2 |
| 3 | 3 | =FACTDOUBLE(A3) |
3 | 3Ć1 |
| 4 | 4 | =FACTDOUBLE(A4) |
8 | 4Ć2 |
| 5 | 5 | =FACTDOUBLE(A5) |
15 | 5Ć3Ć1 |
| 6 | 6 | =FACTDOUBLE(A6) |
48 | 6Ć4Ć2 |
| 7 | 7 | =FACTDOUBLE(A7) |
105 | 7Ć5Ć3Ć1 |
Only the results for n=6 and n=7 are printed as examples in the official handbook; other rows were independently computed by multiplying the displayed factors. These are expected outputs, not screen-observed results.
Independent formula checks
| Formula | Expected value | Validation |
|---|---|---|
=FACTDOUBLE(1) |
1 | Mathematical odd base case |
=FACTDOUBLE(2) |
2 | 2 |
=FACTDOUBLE(4) |
8 | 4Ć2 |
=FACTDOUBLE(6) |
48 | Official KDE example, independent calculation |
=FACTDOUBLE(7) |
105 | Official KDE example, independent calculation |
=FACTDOUBLE(8) |
384 | 8Ć6Ć4Ć2 |
=FACTDOUBLE(9) |
945 | 9Ć7Ć5Ć3Ć1 |
Edge-case disclosure: =FACTDOUBLE(0) is mathematically expected to equal 1, and the pinned code calls ValueCalc::factDouble for a non-negative integer value, but that helper’s native result was not observed. The pinned ValueCalc::factDouble helper explicitly returns 1 for 0 and 1; actual application display remains untested. Helper.
Advanced uses: combinatorial identities
Recover the full factorial from odd/even factors. For a non-negative integer n, the identity n! = n!! Ć (nā1)!! holds for nā„1 when the conventional double factorial base cases apply. With n=7 in A2, try =FACTDOUBLE(A2)*FACTDOUBLE(A2-1): independent expectation 105Ć48 = 5040, matching =FACT(7) mathematically. This is helpful when reviewing formulas that separate even and odd terms. For high n, interim floating representation and overflow can spoil exact equality.
Compare even and odd growth. Given A2=6 and A3=7, =FACTDOUBLE(A2) and =FACTDOUBLE(A3) have expected values 48 and 105. Incrementing the input by one changes not only the number of terms but their parity: don’t treat successive outputs as a simple multiplication sequence. Each parity group follows the recurrence n!! = n Ć (nā2)!! for non-negative n with base 0!!=1 and 1!!=1.
Explain raw numeric versus display values. When a double factorial exceeds the spreadsheet’s safe precision, changing the number display to more decimal places cannot recover lost arithmetic precision. Use a mathematical check on small integers before depending on results in probability or combinatorics.
Errors, limits, and troubleshooting
- Decimal inputs:
=FACTDOUBLE(6.5)is not supported by the pinned path unless evaluation changes its stored type to integer. The function explicitly testsisInteger()and returnsValue::errorNUM()otherwise. Do not substitute Excel’s input-truncation rules without testing. - Negative inputs:
=FACTDOUBLE(-1)fails the source’s non-negative integer guard. Rendered error text depends on engine behavior; this guide labels the internal numeric error path rather than claiming a screenshot. - Text, empty cells, or booleans: the function body checks the evaluated
Valuetype, but input coercion may occur upstream. Do not invent blanket conversion rules from the C++ body alone. - Large arguments: values grow rapidly and may overflow or become inexact. No numeric maximum or precision guarantee is supplied in KDE’s one-parameter XML help, so this guide does not invent one.
- Using
FACTinstead ofFACTDOUBLE: FACT(8) has 40320 while FACTDOUBLE(8) has 384. Check the function name. 0!!and1!!: mathematical identities define both as 1, but inspect native results before relying on spreadsheet-specific edge behavior.- Copy-paste formulas: if your locale changes numeric literals, prefer integers stored in referenced cells; semicolons are not relevant inside this unary function.
Excel and other spreadsheet compatibility
Microsoft’s FACTDOUBLE documentation describes truncating noninteger input; the pinned Calligra implementation instead has an integer-type guard. The shared function name and matching small-integer outputs do not establish compatibility for decimals, stored numbers, errors or overflow thresholds. Some OpenDocument interoperability modes store or map vendor-specific aliases; the explicit Calligra COM.SUN...GETFACTDOUBLE registration is internal evidence, not a guarantee that Excel or LibreOffice imports are identical. Validate an imported spreadsheet using representative inputs.
Related functions and verified vendor links
The KDE FACT handbook covers ordinary factorial; KDE GAMMA concerns another related mathematical function; KDE PRODUCT multiplies supplied values without skipping parity terms.
Official documentation and pinned implementation (2026-10-12 access)
- KDE FACTDOUBLE documentation ā purpose, exact syntax, 6!! and 7!! published examples.
- Calligra 26.08.2 XML math help ā one typed argument, no optional defaults.
- Calligra 26.08.2 registration and explicit alias ā canonical
FACTDOUBLEandCOM.SUN.STAR.SHEET.ADDIN.ANALYSIS.GETFACTDOUBLEmapping. - Calligra 26.08.2
func_factdoubleā C++ non-negative integer guard andcalc->factDoublecall. - Official KDE release announcement ā version 26.08.2 released 2026-10-08, pinned tag resolves to
72123cc643f6625351139e7df294544255a1056f.