Math and Arithmetic

# What is the rationale for defining 0 factorial to be 1?

345

###### 2009-11-28 06:08:50

What is the rationale for defining 0 factorial to be 1?
The defining 0 factorial to be 1 is not a rationale.
"Why is zero factorial equal to one?" is a problem that one has to prove.
When 0 factorial to be 1 to be proved,
the defining 0 factorial to be 1 is unvaluable.
One has only one general primitive definition of a factorial number:
n! = n x (n-1) x (n-2) x (n-3) x ... x 2 x 1.
After that zero factorial denoted 0! is a problem that one has to accept
by convention 0!=1 as a part of definition.
One has to prove zero factorial to be one.
Only from the definition of a factorial number and by dividing both sides
by n one has: n!/n (n-1)! or (n-1)! = n!/n
when n=2 one has (2-1)! = 2!/2 or 1! = 2x1/2 or 1! = 1
when n=1 one has (1-1)! = 1!/1 or 0! = 1/1 or 0! = 1. =
This is a proof that zero factorial is equal to one to be known.
But a new proof is:
A Schema Proof Without Words
That Zero Factorial Is Equal To One.

... ... ...

Now the expression 0! = 1 is already a proof, not need a definition
nor a convention. So the defining 0 factorial to be 1 is unvaluable.
The proof "without words" above
that zero factorial is equal to one is a New that:
*One has not to accept by convention 0!=1 anymore.
*Zero factorial is not an empty product.
*This Schema leads to a Law of Factorial.
Note that the above schema is true but should not be used in a formal proof for 0!=1.
The problem arises when you simplify the pattern formed by this schema into a MacLauren Series, which is the mathematical basis for it in the first place. Upon doing so you arrive with,

. This representation illustrates that upon solving it you use 0!.
In proofs you cannot define something by using that which you are defining in the definition. (ie) 0! can't be used when solving a problem within a proof of 0!.
For clarification, the above series will represent the drawn out solution for the factorial of a number, i. (ie) 1×76 -6×66 +15×56 -20×46 +15×36 -6×26 +1×16 , where i=6.

🙏
0
🤨
0
😮
0
😂
0

## Related Questions

That is related with the fact that 1 is the identity element (or neutral element) of multiplication - and factorials are defined as multiplications. Defining 0 factorial thus simplifies several formulae.

This is related to the fact that 1 is the neutral element for multiplication. Defining the factorial this way makes some equations simpler, making it unnecessary to include additional conditions every time a rule is stated.

The simple answer is that it is defined to be 1. But there is reason behind the decision.As you know, the factorial of a number (n) is equal to:n! = n * (n-1) * (n-2) ... * 1Another way of writing this is:n! = n * (n-1)!Suppose n=1:1! = 1 * 0!or1 = 1 * 0!or1 = 0!So by defining 0! as 1, formula involving factorials will work for all integers, including 0.

Definition of FactorialLet n be a positive integer. n factorial, written n!, is defined by n! = 1 * 2 * 3 * ... (n - 1) * nThe special case when n = 0, 0 factorial is given by: 0! = 1

Zero factorial, written as 0!, equals 1. This is a simple math equation.

Zero factorial is one because n! = n-1! X n. For example: 4! = (4-1) X 4. If zero factorial was zero, that would mean 1! =(1-1) X 1 = 0 X 1=0. Then if 1!=0, then even 999! would equal zero. Therefore, zero factorial equals 1.

Factorial (n) = n * Factorial (n-1) for all positive values n given Factorial (1) = Factorial (0) = 1. Pseudo-code: Function: factorial, f Argument: positive number, n IF n&lt;=1 THEN RETURN 1 ELSE RETURN n * f(n-1) END IF

A recursive formula for the factorial is n! = n(n - 1)!. Rearranging gives (n - 1)! = n!/n, Substituting 'n - 1' as 0 -- i.e. n = 1 -- then 0! = 1!/1, which is 1/1 = 1.

First of all we will define what factorial is and how to it is calculated.Factional is non negative integer. Notation would be n! It is calculated by multiplying all integers from 1 to n;For example:5! = 1 x 2 x 3 x 4 x 5 = 120.Note: 0! = 1Small C program that illustrates how factorial might be counted:#include int factorial(int num);int main() {int num;printf("Enter number: ");scanf("%d", &num);printf("Factorial: %d\n", factorial(num));return 0;}int factorial(int num) {if (num == 0) {return 1;}return num * factorial(num - 1);}Testing:Enter number: 5Factorial: 120Enter number: 0Factorial: 1

For any positive integer, n, factorial (n) can be calculated as follows: - if n&lt;2, return 1. - otherwise, return n * factorial (n-1). The algorithm is recursive, where n&lt;2 represents the end-point. Thus for factorial (5) we find the following recursive steps: factorial (5) = 5 * factorial (4) factorial (4) = 4 * factorial (3) factorial (3) = 3 * factorial (2) factorial (2) = 2 * factorial (1) factorial (1) = 1 We've now reached the end-point (1 is less than 2) and the results can now filter back up through the recursions: factorial (2) = 2 * factorial (1) = 2 * 1 = 2 factorial (3) = 3 * factorial (2) = 3 * 2 = 6 factorial (4) = 4 * factorial (3) = 4 * 6 = 24 factorial (5) = 5 * factorial (4) = 5 * 24 = 120 Thus factorial (5) = 120. We can also use a non-recursive algorithm. The factorial of both 0 and 1 is 1 thus we know that the return value will always be at least 1. As such, we can initialise the return value with 1. Then we begin iterations; while 1&lt;n, multiply the return value by n and then subtract 1 from n. We can better represent this algorithm using pseudocode: Function: factorial (n), where n is an integer such that 0&lt;=n. Returns an integer, f. Let f = 1 Repeat while 1&lt;n Let f = f * n Let n = n - 1 End repeat Return f

double Factorial(int i) { double x = 1; if (i &lt;= 1) return 1; do { x *= i--; } while (i &gt; 0); return x; }

== == using recursions: unsigned int Factorial( unsigned int x) { if(x&gt;0) { return ( x * Factorial(x-1)); } else { return(1); } } factorial: unsigned int Factorial( unsigned int x) { unsigned int u32fact = 1; if( x == 0) { return(1); } else { while(x&gt;0) { u32fact = u32fact *x; x--; } } }

As we know product of no numbers at all is 1 and for this reason factorial of zero =1and we know factorial of 1=1

int main() { // Variable declarations. unsigned long int factorial = 1 , number = 1; // reads a number for finding its factorial. cout > number; while( number > 1 ) { factorial *= number * ( number - 1 ); number -= 2; } cout return 0;

#include &lt;iostream&gt; using namespace std; int main() { int i, number=0, factorial=1; // User input must be an integer number between 1 and 10 while(number&lt;1 number&gt;10) { cout &lt;&lt; "Enter integer number (1-10) = "; cin &gt;&gt; number; } // Calculate the factorial with a FOR loop for(i=1; i&lt;=number; i++) { factorial = factorial*i; } // Output result cout &lt;&lt; "Factorial = " &lt;&lt; factorial &lt;&lt; endl;

/* gcc -ansi -Wall -Wextra -pedantic -s -static 0.c -o 0 */ #include &lt;stdio.h&gt; int main ( ) { int n , factorial = 1 ; printf ( "enter the value of n\n") ; scanf ( "%i" , &amp; n ) ; while ( n != 0 ) { factorial *= n ; n -- ; } printf ( "The factorial of n is\n%i\n" , factorial ) ; return 0; }

double factorial(double N){double total = 1;while (N > 1){total *= N;N--;}return total; // We are returning the value in variable title total//return factorial;}int main(){double myNumber = 0;cout cin >> myNumber;cout return 0;}

Factorial is a Mathematical Function.Factorial returns the product of all numbers from 1 to itselfe.g. Factorial 5 = 5*4*3*2*1 = 120It is expressed as n! = factorial of nTo implement it in Visual Basic, there are two methods-Function factorial(ByVal n as Integer) as IntegerIf n =factorial = n * factorial(n-1)End FunctionFunction factorial(ByVal n as Integer) as Integerfactorial = 1Dim a as IntegerFor a = 1 to nfactorial = factorial * aNext 'aEnd Function

#include int factorial(int n){if(n 1)return 1;return n*factorial(n-1);}int main(int argc, char *argv[]){if(argc != 2){printf("%s number", argv[0]);exit(1);}printf("%s! = %d", argv[0], factorial(atoi(argv[1])));return 0;}

AnswerAnswer: ( 0! + 0! + 0! + 0! + 0! ) ! = 120 Explanation: Here we have used operator called " factorial ". As you know that 0! = 1 so, = ( 0! + 0! + 0! + 0! + 0! ) ! = ( 1 + 1 + 1 + 1 + 1 ) ! = (5 )! = 120 : ( 0! + 0! + 0! + 0! + 0! ) ! = 120 Explanation: Here we have used operator called " factorial ". As you know that 0! = 1 so, = ( 0! + 0! + 0! + 0! + 0! ) ! = ( 1 + 1 + 1 + 1 + 1 ) ! = (5 )! = 120

A C, C#/Java code segment:int Factorial(int n) {if (n return Factorial(n-1) * n;}

#include &lt;stdio.h&gt; int main() { int fact=1,num; printf("Enter number: "); scanf("%d",&amp;num); if((num==0) (num==1)) { printf("Factorial = %d",fact); return 0; } else { while(num!=1) { fact=fact*num; num--; } printf("Factorial = %d",fact); return 0; } }

###### Math and ArithmeticComputer ProgrammingAlgebraC ProgrammingSoftware and Applications (non-game)Java ProgrammingVisual Basic ProgrammingDatabase Programming

Copyright © 2020 Multiply Media, LLC. All Rights Reserved. The material on this site can not be reproduced, distributed, transmitted, cached or otherwise used, except with prior written permission of Multiply.