1/* specfunc/gsl_sf_psi.h
2 *
3 * Copyright (C) 1996, 1997, 1998, 1999, 2000, 2004 Gerard Jungman
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 3 of the License, or (at
8 * your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 */
19
20/* Author: G. Jungman */
21
22#ifndef __GSL_SF_PSI_H__
23#define __GSL_SF_PSI_H__
24
25#include <gsl/gsl_sf_result.h>
26
27#undef __BEGIN_DECLS
28#undef __END_DECLS
29#ifdef __cplusplus
30# define __BEGIN_DECLS extern "C" {
31# define __END_DECLS }
32#else
33# define __BEGIN_DECLS /* empty */
34# define __END_DECLS /* empty */
35#endif
36
37__BEGIN_DECLS
38
39
40/* Poly-Gamma Functions
41 *
42 * psi(m,x) := (d/dx)^m psi(0,x) = (d/dx)^{m+1} log(gamma(x))
43 */
44
45
46/* Di-Gamma Function psi(n) = psi(0,n)
47 *
48 * n > 0
49 * exceptions: GSL_EDOM
50 */
51int gsl_sf_psi_int_e(const int n, gsl_sf_result * result);
52double gsl_sf_psi_int(const int n);
53
54
55/* Di-Gamma Function psi(x) = psi(0, x)
56 *
57 * x != 0.0, -1.0, -2.0, ...
58 * exceptions: GSL_EDOM, GSL_ELOSS
59 */
60int gsl_sf_psi_e(const double x, gsl_sf_result * result);
61double gsl_sf_psi(const double x);
62
63
64/* Di-Gamma Function Re[psi(1 + I y)]
65 *
66 * exceptions: none
67 */
68int gsl_sf_psi_1piy_e(const double y, gsl_sf_result * result);
69double gsl_sf_psi_1piy(const double y);
70
71
72/* Di-Gamma Function psi(z) for general complex argument z = x + iy
73 *
74 * exceptions: GSL_EDOM
75 */
76int gsl_sf_complex_psi_e(
77 const double x,
78 const double y,
79 gsl_sf_result * result_re,
80 gsl_sf_result * result_im
81 );
82
83
84/* Tri-Gamma Function psi^(1)(n)
85 *
86 * n > 0
87 * exceptions: GSL_EDOM
88 */
89int gsl_sf_psi_1_int_e(const int n, gsl_sf_result * result);
90double gsl_sf_psi_1_int(const int n);
91
92
93/* Tri-Gamma Function psi^(1)(x)
94 *
95 * x != 0.0, -1.0, -2.0, ...
96 * exceptions: GSL_EDOM, GSL_ELOSS
97 */
98int gsl_sf_psi_1_e(const double x, gsl_sf_result * result);
99double gsl_sf_psi_1(const double x);
100
101
102/* Poly-Gamma Function psi^(n)(x)
103 *
104 * n >= 0, x > 0.0
105 * exceptions: GSL_EDOM
106 */
107int gsl_sf_psi_n_e(const int n, const double x, gsl_sf_result * result);
108double gsl_sf_psi_n(const int n, const double x);
109
110
111__END_DECLS
112
113#endif /* __GSL_SF_PSI_H__ */
114