I was playing with numbers on calculator and to my amaze i could see that calculator calculated $(4.5)!$ or any real numbers but factorial is defined for integers how is this done any advanced function. (Note I am grade $11$ student)
-
14https://en.wikipedia.org/wiki/Gamma_function – 5xum Feb 22 '16 at 12:53
-
3Did your calculator give $4.5!=\frac{945}{32}\sqrt{\pi}\approx 29.53125$? Knowing the value your calculator gave will definitely make it easier for us to appropriately answer your question. – Feb 22 '16 at 12:59
-
See http://math.stackexchange.com/questions/396889/how-to-find-the-factorial-of-a-fraction – true blue anil Feb 22 '16 at 13:00
-
No it gave $53.09.....$ – Archis Welankar Feb 22 '16 at 13:01
-
@vrugtehagel its $53$ approx – Archis Welankar Feb 22 '16 at 13:01
-
I get 52. 3428... – true blue anil Feb 22 '16 at 13:04
-
Maybe due to different calculators i think yours is strong one – Archis Welankar Feb 22 '16 at 13:07
-
6Excuse me. I made a mistake in my calculation, actually $\Gamma(5.5)=\frac{945}{32}\sqrt{\pi}\approx 52.3427777845535$ – Feb 22 '16 at 13:08
5 Answers
In general, $~n!~=~\displaystyle\int_0^\infty\exp\Big(-\sqrt[n]x\Big)~dx,~$ which for $~n=\dfrac12~$ yields $~\Big(\tfrac12\Big)!~=~\displaystyle\int_0^\infty e^{-x^2}~dx.~$
But the value of the Gaussian integral is known to be $\sqrt\pi~,~$ implying that $~\Big(\tfrac12\Big)!~=~\dfrac{\sqrt\pi}2,~$
since the integrand is even. Now all that's left to do is to repeatedly employ the well-known
factorial property $(n+1)!=(n+1)~n!~$ for $~n+1=4+\dfrac12,~$ and the result follows.

- 48,334
- 2
- 83
- 154
-
2Nice, so 4.5! = 4.5 * 3.5 * 2.5 * 1.5 * 0.5! = 59.0625 * (pi^0.5)/2 = 52.34277 .... – sav Feb 22 '16 at 14:16
-
1Of course, the integral one usually sees is $n! = \int_0^\infty x^n e^{-x} dx$ but I guess they are related through a simple substitution. It is implicit in your answer that it is "obvious" to use the same integral for an $n$ that is not an integer. It is also implicit in the answer that the integral definition obeys the same "factorial property" $(n+1)!=(n+1)n!$ for non-integer $n$ as it does for integers. It is not too hard to prove, of course. A justification for using this integral as a generalization of the factorial functions comes from the characterization by H. Bohr and J. Mollerup. – Jeppe Stig Nielsen Feb 22 '16 at 19:19
-
-
-
There is a function called the Gamma function. It is similar to the factorial as the factorial could be thought of as a special case of the gamma function.
$\Gamma(n) = (n-1)!$
or rather, when you shift it by one, as shown in the above equation.
The gamma function happens to be
$\Gamma(t) = \int_0^\infty x^{t-1} e^{-x} dx$
Calculators often use the gamma function to calculate factorials of non-natural values.
The generalization is useful when you need to extend the definition of the factorial beyond the natural numbers. For example, some probability distributions use the factorial, and the gamma function can be used to generalize them.
The factorial and gamma function both have some interesting properties in common.
For example, the factorial function can be defined recursively.
$0!=1$
$(n+1)! = (n+1) \times n!$
The gamma function also has this property
$\Gamma (1) = 1$
$\Gamma(x+1) = (x+1) \times \Gamma(x) $

- 1,032
- 5
- 12
-
That wasnt really helpful as 5xum already included it in my link – Archis Welankar Feb 22 '16 at 13:19
-
-
-
Realistically functions like this are hard to compute and the calculator probably does it numerically http://math.stackexchange.com/questions/19236/algorithm-to-compute-gamma-function – sav Feb 22 '16 at 13:42
It's possible the calculator gave you the value of $\Gamma(5.5)$.
The $\Gamma$ function is a sort of generalization of the factorial in the sense that for every $n\in\mathbb N$, you have that $\Gamma(n) = (n-1)!$. So if you ever want to calculate $m!$, that's the same as calculating $\Gamma(m+1)$.

- 123,496
- 6
- 128
- 204
-
-
@ArchisWelankar It's not $4.5\cdot 3.5\cdots 0.5$. It's a lot more complicated than that. https://en.wikipedia.org/wiki/Gamma_function – 5xum Feb 22 '16 at 13:03
-
-
@ArchisWelankar Did you even read my answer? I said: it is possible the calculater gave the value of $\Gamma(5.5)$ – 5xum Feb 22 '16 at 13:09
-
-
-
An answer was never accepted so I’d like to take a stab at it. In particular the OP mentioned being grade 11, and I think “what is going on here” is an excellent question.
Faced with a function like x! -which is defined for positive integers- which we want to extend to other numbers, the most important question we can ask is:
Q: What are its properties?
A factorial is pretty simple. For any integer n > 1
(1). (n+1)! = (n+1) n!
In other words, to get (n+1)! we don’t have to start over from scratch. We just multiply n! by the next integer. For example 6! = 6 • 5!.
Hopefully this just sounds like a restatement of what “factorial” means.
Continuation
The factorial for non integers is called a continuation of the factorial for integers: we seek a function that obeys the known properties of the factorial, at all values of x. In math, we need (1) to be satisfied for any number x, not just the integers:
1’. (x+1)! = (x+1) x!
One way to visualize this question is to plot the integer factorial values on a graph. The continuous function x! will be a smooth curve passing through these points. Now, you can draw an infinite number of curves that do this. The curve we seek, is the one that satisfies 1’ everywhere on the curve. So we now have a new question:
Q: but what is this mystery function?
I didn’t take the op as looking for a proof. However, a word about how to solve problems of this kind:
The definition 1’ is nice but as written it does not tell us how to draw the curve. If I put my pencil on 3! = 6 and begin to draw upward toward 4! = 24, the first thing I need to know is what direction to start drawing — the slope of the curve. But also the curve is not a straight line, so I can’t keep drawing in that same direction. The curve changes continuously. In a nutshell, to draw it, we need to understand how the function changes as x varies.
The tools to answer this kind of problem —to identify how it changes; and how to assemble this information into a formula for practical calculation — come from the Calculus.
I hope that helps.

- 181
Along with the gamma function, it is much easier to approximate to good accuracy using Stirling's approximation.
It is defined as:
$$n!\approx \sqrt{2\pi n}\left(\frac ne\right)^n$$

- 74,685
-
Note that "good accuracy" is for larger values of $n$. The relative error is about $1/(12n)$, so the number of correct digits will be roughly equal to the number of digits in $n$. When $n=4.5$ it means you should only expect the first 1 or 2 digits to be accurate. – Erick Wong May 06 '16 at 06:57