2 Copyright 2019, Nick Thompson
3 Distributed under the Boost Software License, Version 1.0.
4 (See accompanying file LICENSE_1_0.txt or copy at
5 http://www.boost.org/LICENSE_1_0.txt).
8 [section:jacobi Jacobi Polynomials]
13 #include <boost/math/special_functions/jacobi.hpp>
16 namespace boost{ namespace math{
18 template<typename Real>
19 Real jacobi(unsigned n, Real alpha, Real beta, Real x);
21 template<typename Real>
22 Real jacobi_derivative(unsigned n, Real alpha, Real beta, Real x, unsigned k);
24 template<typename Real>
25 Real jacobi_prime(unsigned n, Real alpha, Real beta, Real x);
27 template<typename Real>
28 Real jacobi_double_prime(unsigned n, Real alpha, Real beta, Real x);
32 Jacobi polynomials are a family of orthogonal polynomials.
34 A basic usage is as follows:
36 using boost::math::jacobi;
41 double y = jacobi(n, alpha, beta, x);
43 All derivatives of the Jacobi polynomials are available.
44 The /k/-th derivative of the /n/-th Gegenbauer polynomial is given by
46 using boost::math::jacobi_derivative;
51 double y = jacobi_derivative(n, alpha, beta, x, k);
53 For consistency with the rest of the library, `jacobi_prime` is provided which simply returns `jacobi_derivative(n, lambda, x,1)`.
55 [$../graphs/jacobi.svg]
59 The implementation uses the 3-term recurrence for the Jacobi polynomials, rising.