{"id":6878,"date":"2022-12-20T19:33:46","date_gmt":"2022-12-20T22:33:46","guid":{"rendered":"http:\/\/lode.uno\/linux-man\/index.php\/2022\/12\/20\/gamma-man3\/"},"modified":"2022-12-20T19:33:46","modified_gmt":"2022-12-20T22:33:46","slug":"gamma-man3","status":"publish","type":"post","link":"https:\/\/lode.uno\/linux-man\/2022\/12\/20\/gamma-man3\/","title":{"rendered":"GAMMA (man3)"},"content":{"rendered":"<h1 align=\"center\">GAMMA<\/h1>\n<p> <a href=\"#NAME\">NAME<\/a><br \/> <a href=\"#SYNOPSIS\">SYNOPSIS<\/a><br \/> <a href=\"#DESCRIPTION\">DESCRIPTION<\/a><br \/> <a href=\"#RETURN VALUE\">RETURN VALUE<\/a><br \/> <a href=\"#ERRORS\">ERRORS<\/a><br \/> <a href=\"#ATTRIBUTES\">ATTRIBUTES<\/a><br \/> <a href=\"#CONFORMING TO\">CONFORMING TO<\/a><br \/> <a href=\"#NOTES\">NOTES<\/a><br \/> <a href=\"#SEE ALSO\">SEE ALSO<\/a><br \/> <a href=\"#COLOPHON\">COLOPHON<\/a> <\/p>\n<hr>\n<h2>NAME <a name=\"NAME\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">gamma, gammaf, gammal \u2212 (logarithm of the) gamma function<\/p>\n<h2>SYNOPSIS <a name=\"SYNOPSIS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>#include <math.h><\/b><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>double gamma(double<\/b> <i>x<\/i><b>); <br \/> float gammaf(float<\/b> <i>x<\/i><b>); <br \/> long double gammal(long double<\/b> <i>x<\/i><b>);<\/b><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">Link with <i>\u2212lm<\/i>.<\/p>\n<p style=\"margin-left:5%; margin-top: 1em\">Feature Test Macro Requirements for glibc (see <b>feature_test_macros<\/b>(7)):<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>gamma<\/b>():<\/p>\n<p style=\"margin-left:17%;\">_XOPEN_SOURCE <br \/> || \/bin \/boot \/dead.letter \/dev \/etc \/home \/initrd \/lib \/lib64 \/lost+found \/media \/mnt \/opt \/proc \/release-notes.html \/release-notes.txt \/root \/run \/sbin \/srv \/sys \/tmp \/usr \/var Since glibc 2.19: bodies\/ usr\/ _DEFAULT_SOURCE <br \/> || \/bin \/boot \/dead.letter \/dev \/etc \/home \/initrd \/lib \/lib64 \/lost+found \/media \/mnt \/opt \/proc \/release-notes.html \/release-notes.txt \/root \/run \/sbin \/srv \/sys \/tmp \/usr \/var Glibc versions <= 2.19: bodies\/ usr\/ _BSD_SOURCE || _SVID_SOURCE<\/p>\n<p style=\"margin-left:11%;\"><b>gammaf<\/b>(), <b>gammal<\/b>():<\/p>\n<p style=\"margin-left:17%;\">_XOPEN_SOURCE >= 600 || (_XOPEN_SOURCE &#038;&#038; _ISOC99_SOURCE) <br \/> || \/bin \/boot \/dead.letter \/dev \/etc \/home \/initrd \/lib \/lib64 \/lost+found \/media \/mnt \/opt \/proc \/release-notes.html \/release-notes.txt \/root \/run \/sbin \/srv \/sys \/tmp \/usr \/var Since glibc 2.19: bodies\/ usr\/ _DEFAULT_SOURCE <br \/> || \/bin \/boot \/dead.letter \/dev \/etc \/home \/initrd \/lib \/lib64 \/lost+found \/media \/mnt \/opt \/proc \/release-notes.html \/release-notes.txt \/root \/run \/sbin \/srv \/sys \/tmp \/usr \/var Glibc versions <= 2.19: bodies\/ usr\/ _BSD_SOURCE || _SVID_SOURCE<\/p>\n<h2>DESCRIPTION <a name=\"DESCRIPTION\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">These functions are deprecated: instead, use either the <b>tgamma<\/b>(3) or the <b>lgamma<\/b>(3) functions, as appropriate.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">For the definition of the Gamma function, see <b>tgamma<\/b>(3).<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>*BSD version<\/b> <br \/> The libm in 4.4BSD and some versions of FreeBSD had a <b>gamma<\/b>() function that computes the Gamma function, as one would expect.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>glibc version<\/b> <br \/> Glibc has a <b>gamma<\/b>() function that is equivalent to <b>lgamma<\/b>(3) and computes the natural logarithm of the Gamma function.<\/p>\n<h2>RETURN VALUE <a name=\"RETURN VALUE\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">See <b>lgamma<\/b>(3).<\/p>\n<h2>ERRORS <a name=\"ERRORS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">See <b>lgamma<\/b>(3).<\/p>\n<h2>ATTRIBUTES <a name=\"ATTRIBUTES\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">For an explanation of the terms used in this section, see <b>attributes<\/b>(7).<\/p>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"> <\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"62%\"> <\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"8%\"> <\/td>\n<td width=\"8%\"><\/td>\n<td width=\"7%\"><\/td>\n<td width=\"62%\"> <\/td>\n<\/tr>\n<\/table>\n<p align=\"center\"><img decoding=\"async\" src=\"grohtml-1649251.png\" alt=\"Image grohtml-1649251.png\"><\/p>\n<h2>CONFORMING TO <a name=\"CONFORMING TO\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Because of historical variations in behavior across systems, this function is not specified in any recent standard. It was documented in SVID 2.<\/p>\n<h2>NOTES <a name=\"NOTES\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>History<\/b> <br \/> 4.2BSD had a <b>gamma<\/b>() that computed ln(|Gamma(|<i>x<\/i>|)|), leaving the sign of Gamma(|<i>x<\/i>|) in the external integer <i>signgam<\/i>. In 4.3BSD the name was changed to <b>lgamma<\/b>(3), and the man page promises<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">&#8220;At some time in the future the name gamma will be rehabilitated and used for the Gamma function&#8221;<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">This did indeed happen in 4.4BSD, where <b>gamma<\/b>() computes the Gamma function (with no effect on <i>signgam<\/i>). However, this came too late, and we now have <b>tgamma<\/b>(3), the &#8220;true gamma&#8221; function.<\/p>\n<h2>SEE ALSO <a name=\"SEE ALSO\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>lgamma<\/b>(3), <b>signgam<\/b>(3), <b>tgamma<\/b>(3)<\/p>\n<h2>COLOPHON <a name=\"COLOPHON\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">This page is part of release 5.10 of the Linux <i>man-pages<\/i> project. A description of the project, information about reporting bugs, and the latest version of this page, can be found at https:\/\/www.kernel.org\/doc\/man\u2212pages\/.<\/p>\n<hr>\n","protected":false},"excerpt":{"rendered":"<p>  gamma, gammaf, gammal \u2212 (logarithm of the) gamma function <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2536],"tags":[2538,3241,3007],"class_list":["post-6878","post","type-post","status-publish","format-standard","hentry","category-3-llamadas-de-bibliotecas","tag-2538","tag-gamma","tag-man3"],"gutentor_comment":0,"_links":{"self":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/6878","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/comments?post=6878"}],"version-history":[{"count":0,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/6878\/revisions"}],"wp:attachment":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/media?parent=6878"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/categories?post=6878"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/tags?post=6878"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}