Signup
Search Linux manpages For:  

tgammal(3) -- Linux man page

 

NAME

tgamma, tgammaf, tgammal - true gamma function  

SYNOPSIS

#include <math.h>

double tgamma(double x);
float tgammaf(float x);
long double tgammal(long double x);

 

DESCRIPTION

The Gamma function is defined by


 Gamma(x) = integral from 0 to infinity of t^(x-1) e^-t dt

It is defined for every real number except for nonpositive integers. For nonnegative integral m one has


 Gamma(m+1) = m!

and, more generally, for all x:


 Gamma(x+1) = x * Gamma(x)

For x < 0.5 one can use


 Gamma(x) * Gamma(1-x) = PI/sin(PI*x)

This function returns the value of the Gamma function for the argument x. It had to be called "true gamma function" since there is already a function gamma() that returns something else.  

ERRORS

An application wishing to check for error situations should set errno to zero and call feclearexcept(FE_ALL_EXCEPT) before calling these functions. On return, if errno is non-zero or fetestexcept(FE_INVALID | FE_DIVBYZERO | FE_OVERFLOW | FE_UNDERFLOW) is non-zero, an error has occurred.

A range error occurs if x is too large. A pole error occurs if x is zero. A domain error (or a pole error) occurs if x is a negative integer.  

CONFORMING TO

C99.  

SEE ALSO

lgamma(3), gamma(3)


 
LINUX MAN PAGES
Man1 -- User Commands (Intro)
Man2 -- System Calls (Intro)
Man3 -- Library Functions (Intro)
Man4 -- Special Files (Intro)
Man5 -- File Formats (Intro)
Man6 -- Games (Intro)
Man7 -- Miscellaneous (Intro)
Man8 -- Administration (Intro)
Mann -- TCL Functions (not available)


WEB HOSTING SHOWCASE




 
Cheap Web HostingBudget Web HostingEcommerce Web Hosting
Link to UsLink ExchangeAdvertisePrivacy PolicyTerms Of ServiceAbout UsContact UsSitemap
Copyright © 2006 - 2012 Broadband Media, Inc. All rights reserved.