Google Sheets FACTDOUBLE Function: How to Use
In this article
The FACTDOUBLE function in Google Sheets returns the double factorial of a given number. In plain terms, it multiplies every other integer down from your number to 1 or 2, depending on whether the number is odd or even. For example, FACTDOUBLE(6) equals 6 × 4 × 2 = 48, and FACTDOUBLE(5) equals 5 × 3 × 1 = 15. You can use it by typing =FACTDOUBLE(number) into a cell, where number is a non-negative integer or a reference to a cell containing one. The function is built into Sheets and requires no add-ons or special setup.
What You'll Need
- A Google account with access to Google Sheets (the free web version or the mobile app).
- A spreadsheet open and ready for editing.
- Basic familiarity with entering formulas (starting with =).
Step-by-Step
- Open your Google Sheets spreadsheet. You can use the web version in a browser or the mobile app on Android or iOS. The steps are nearly identical; on mobile, tap the cell and then the formula bar or the function icon to enter a formula.
- Click the cell where you want the result to appear. This cell will hold the double factorial value.
- Type an equals sign (=) to start a formula. The cell enters edit mode.
- Type FACTDOUBLE followed by an opening parenthesis. As you type, Sheets may show a suggestion; you can ignore it or press Tab to autocomplete.
- Enter the number or cell reference. For a direct number, type it (e.g., 6). For a cell reference, type the cell address (e.g., A1) or click the cell. You can also use a calculation like 2+4. Close the parenthesis. Your formula should look like =FACTDOUBLE(6) or =FACTDOUBLE(A1).
- Press Enter (or the checkmark on mobile). The cell displays the double factorial result. If you entered a cell reference, the result updates automatically when that cell changes.
- To apply the function to multiple numbers, copy the formula down or across. Use the fill handle (small square at the bottom-right of the cell) and drag, or copy the cell and paste it into other cells. Relative references adjust automatically.
- If you need to use the result in further calculations, you can nest FACTDOUBLE inside other functions. For example, =FACTDOUBLE(5)+1 or =SUM(FACTDOUBLE(3), FACTDOUBLE(4)).
Common Mistakes
- Using a negative number. FACTDOUBLE only accepts non-negative numbers. If you enter a negative value, you'll get a #NUM! error.
- Using a non-integer. The function truncates decimal inputs? Actually, FACTDOUBLE requires an integer. If you enter 5.5, Sheets returns a #NUM! error because it does not accept non-integers. Ensure your input is a whole number.
- Forgetting the parentheses. A formula like =FACTDOUBLE 6 without parentheses will cause a parse error. Always include both opening and closing parentheses.
- Confusing FACTDOUBLE with FACT. FACT(n) is the regular factorial (n × (n-1) × ... × 1), while FACTDOUBLE(n) multiplies every other integer. For example, FACT(5)=120, FACTDOUBLE(5)=15.
- Referencing an empty cell. If you reference a blank cell, FACTDOUBLE treats it as 0, and FACTDOUBLE(0) returns 1. This might be unexpected if you meant to skip blanks.
- Using text instead of a number. If the referenced cell contains text, you'll get a #VALUE! error. Ensure the input is numeric.
Tips
- FACTDOUBLE(0) returns 1 by definition, which is useful in combinatorial formulas.
- You can use FACTDOUBLE in array formulas. For example, =ARRAYFORMULA(FACTDOUBLE(A1:A10)) will return double factorials for each number in the range, but be careful with blanks or non-integers.
- Combine FACTDOUBLE with other math functions for probability or statistics calculations. For instance, double factorials appear in expressions for the gamma function and in certain series expansions.
- If you need the double factorial of a large number, be aware that the result grows very quickly and may exceed the maximum value Sheets can handle (about 1.797E+308). In such cases, you'll get a #NUM! error.
- Use cell references instead of hard-coded numbers to make your spreadsheet dynamic. Changing the input cell updates the result instantly.
- Remember that FACTDOUBLE is not the same as multiplying two factorials. For example, FACTDOUBLE(4) = 8, while FACT(4)*FACT(4) = 576.
Troubleshooting
If you see a #NUM! error, check that your input is a non-negative integer. Negative numbers and decimals are not allowed. If the result is too large, the function returns #NUM! because it exceeds the maximum numeric value. If you see a #VALUE! error, the input is likely text or a reference to a text cell; convert it to a number. If you see a #NAME? error, the function name is misspelled or not recognized; ensure you typed FACTDOUBLE correctly. If the formula doesn't calculate, make sure the cell is formatted as a number, not text, and that you've pressed Enter to confirm. On mobile, ensure you've tapped the checkmark to apply the formula. If you're referencing a cell that contains a formula returning an error, FACTDOUBLE will propagate that error; fix the source cell first.
Frequently Asked Questions
What does FACTDOUBLE actually calculate?
It calculates the double factorial: for an even number n, it's the product of all even integers up to n; for an odd number, it's the product of all odd integers up to n. For example, FACTDOUBLE(6)=6×4×2=48, FACTDOUBLE(5)=5×3×1=15.
Can I use FACTDOUBLE with cell references?
Yes, you can reference any cell that contains a non-negative integer. For example, =FACTDOUBLE(A1). The result updates when A1 changes.
Why do I get a #NUM! error?
#NUM! occurs when the input is negative, a non-integer, or when the result is too large for Sheets to represent (over about 1.797E+308). Ensure your input is a non-negative integer and the result is within limits.
Is FACTDOUBLE available in all versions of Google Sheets?
Yes, it is a standard function in Google Sheets and works in the web version and mobile apps. No add-ons are required.
What is the difference between FACTDOUBLE and FACT?
FACT(n) is the product of all integers from 1 to n. FACTDOUBLE(n) is the product of every other integer from n down to 1 or 2. For example, FACT(5)=120, FACTDOUBLE(5)=15.
Can I use FACTDOUBLE in array formulas?
Yes, you can wrap it in ARRAYFORMULA to apply it to a range, but ensure the range contains only non-negative integers to avoid errors.