ARTS  2.2.66
legendre.cc File Reference

Contains the code to calculate Legendre polynomials. More...

#include "legendre.h"
#include "sstream.h"
#include "exceptions.h"
#include <cmath>
#include "math_funcs.h"
Include dependency graph for legendre.cc:

Go to the source code of this file.

Functions

Numeric legendre_poly (Index l, Index m, Numeric x)
 legendre_poly More...
 
Numeric legendre_poly_norm_schmidt (Index l, Index m, Numeric x)
 legendre_poly_norm_schmidt More...
 
Numeric legendre_poly_deriv (Index l, Index m, Numeric x)
 legendre_poly_deriv More...
 
Numeric legendre_poly_norm_schmidt_deriv (Index l, Index m, Numeric x)
 legendre_poly_norm_schmidt_deriv More...
 
Numeric g_legendre_poly (Index l, Index m, Numeric x)
 g_legendre_poly More...
 
Numeric g_legendre_poly_norm_schmidt (Index l, Index m, Numeric x)
 g_legendre_poly_norm_schmidt More...
 
Numeric g_legendre_poly_deriv (Index l, Index m, Numeric x)
 g_legendre_poly_deriv More...
 
Numeric g_legendre_poly_norm_schmidt_deriv (Index l, Index m, Numeric x)
 g_legendre_poly_norm_schmidt_deriv More...
 
Numeric g_legendre_poly_norm_schmidt_deriv1 (Index l, Index m, Numeric x)
 g_legendre_poly_norm_schmidt_deriv1 More...
 
Numeric g_legendre_poly_norm_schmidt_deriv2 (Index l, Index m, Numeric x)
 g_legendre_poly_norm_schmidt_deriv2 More...
 
Numeric g_legendre_poly_norm_schmidt_deriv3 (Index l, Index m, Numeric x)
 g_legendre_poly_norm_schmidt_deriv3 More...
 
Numeric g_legendre_poly_norm_schmidt_deriv4 (Index l, Index m, Numeric x)
 g_legendre_poly_norm_schmidt_deriv4 More...
 

Detailed Description

Contains the code to calculate Legendre polynomials.

Author
Oliver Lemke
Date
2003-08-14

Definition in file legendre.cc.

Function Documentation

◆ g_legendre_poly()

Numeric g_legendre_poly ( Index  l,
Index  m,
Numeric  x 
)

g_legendre_poly

Returns the associated Legendre polynomial Plm(x) without the factor (-1)^m.

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| <= 1

The code is based on the Numerical recipes. Results were compared to the Legendre calculations from the GNU Scientific library and found to be identical.

Returns
Plm
Parameters
lIndex
mIndex
xValue
Author
Nikolay Koulev
Date
2003-09-02

Definition at line 349 of file legendre.cc.

References abs, and ll.

Referenced by g_legendre_poly_deriv(), g_legendre_poly_norm_schmidt(), g_legendre_poly_norm_schmidt_deriv(), g_legendre_poly_norm_schmidt_deriv1(), g_legendre_poly_norm_schmidt_deriv2(), g_legendre_poly_norm_schmidt_deriv3(), and g_legendre_poly_norm_schmidt_deriv4().

◆ g_legendre_poly_deriv()

Numeric g_legendre_poly_deriv ( Index  l,
Index  m,
Numeric  x 
)

g_legendre_poly_deriv

Returns the derivative of the associated Legendre polynomial Plm(x)) without the factor (-1)^m..

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| < 1

Returns
dPlm
Parameters
lIndex
mIndex
xValue
Author
Nikolay Koulev
Date
2003-09-02

Definition at line 458 of file legendre.cc.

References g_legendre_poly().

◆ g_legendre_poly_norm_schmidt()

Numeric g_legendre_poly_norm_schmidt ( Index  l,
Index  m,
Numeric  x 
)

g_legendre_poly_norm_schmidt

Returns the Schmidt quasi-normalized associated Legendre polynomial Plm(x)) without the factor (-1)^m..

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| <= 1

The code is based on the Numerical recipes. Results were compared to the Legendre calculations from the GNU Scientific library and found to be identical.

Returns
Plm
Parameters
lIndex
mIndex
xValue
Author
Nikolay koulev
Date
2003-09-02

Definition at line 421 of file legendre.cc.

References fac(), and g_legendre_poly().

Referenced by g_legendre_poly_norm_schmidt_deriv2(), and magfield_nk().

◆ g_legendre_poly_norm_schmidt_deriv()

Numeric g_legendre_poly_norm_schmidt_deriv ( Index  l,
Index  m,
Numeric  x 
)

g_legendre_poly_norm_schmidt_deriv

Returns the derivative of the Schmidt quasi-normalized associated Legendre polynomial Plm(x)) without the factor (-1)^m.

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| < 1

Returns
dPlm
Parameters
lIndex
mIndex
xValue
Author
Nikolay Koulev
Date
2003-09-02

Definition at line 543 of file legendre.cc.

References fac(), and g_legendre_poly().

◆ g_legendre_poly_norm_schmidt_deriv1()

Numeric g_legendre_poly_norm_schmidt_deriv1 ( Index  l,
Index  m,
Numeric  x 
)

g_legendre_poly_norm_schmidt_deriv1

Returns the derivative of the Schmidt quasi-normalized associated Legendre polynomial Plm(x)) without the factor (-1)^m. Utilizes the simplest recurrence scheme.

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| < 1

Returns
dPlm
Parameters
lIndex
mIndex
xValue
Author
Nikolay Koulev
Date
2003-09-02

Definition at line 632 of file legendre.cc.

References fac(), and g_legendre_poly().

◆ g_legendre_poly_norm_schmidt_deriv2()

Numeric g_legendre_poly_norm_schmidt_deriv2 ( Index  l,
Index  m,
Numeric  x 
)

g_legendre_poly_norm_schmidt_deriv2

Returns the derivative of the Schmidt quasi-normalized associated Legendre polynomial Plm(x)) without the factor (-1)^m.

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| < 1

Returns
dPlm
Parameters
lIndex
mIndex
xValue
Author
Nikolay Koulev
Date
2003-09-02

Definition at line 724 of file legendre.cc.

References fac(), g_legendre_poly(), and g_legendre_poly_norm_schmidt().

◆ g_legendre_poly_norm_schmidt_deriv3()

Numeric g_legendre_poly_norm_schmidt_deriv3 ( Index  l,
Index  m,
Numeric  x 
)

g_legendre_poly_norm_schmidt_deriv3

Returns the derivative of the Schmidt quasi-normalized associated Legendre polynomial Plm(x)) without the factor (-1)^m.

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| < 1

Returns
dPlm
Parameters
lIndex
mIndex
xValue
Author
Nikolay Koulev
Date
2003-09-02

Definition at line 812 of file legendre.cc.

References fac(), and g_legendre_poly().

Referenced by magfield_nk().

◆ g_legendre_poly_norm_schmidt_deriv4()

Numeric g_legendre_poly_norm_schmidt_deriv4 ( Index  l,
Index  m,
Numeric  x 
)

g_legendre_poly_norm_schmidt_deriv4

Returns the derivative of the Schmidt quasi-normalized associated Legendre polynomial Plm(x)) without the factor (-1)^m.

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| < 1

Returns
dPlm
Parameters
lIndex
mIndex
xValue
Author
Nikolay Koulev
Date
2003-09-02

Definition at line 900 of file legendre.cc.

References fac(), and g_legendre_poly().

◆ legendre_poly()

Numeric legendre_poly ( Index  l,
Index  m,
Numeric  x 
)

legendre_poly

Returns the associated Legendre polynomial Plm(x).

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| <= 1

The code is based on the Numerical recipes. Results were compared to the Legendre calculations from the GNU Scientific library and found to be identical.

Returns
Plm
Parameters
lIndex
mIndex
xValue
Author
Oliver Lemke
Date
2003-08-14

Definition at line 66 of file legendre.cc.

References abs, and ll.

Referenced by legendre_poly_deriv(), legendre_poly_norm_schmidt(), and main().

◆ legendre_poly_deriv()

Numeric legendre_poly_deriv ( Index  l,
Index  m,
Numeric  x 
)

legendre_poly_deriv

Returns the derivative of the associated Legendre polynomial Plm(x).

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| < 1

Returns
dPlm
Parameters
lIndex
mIndex
xValue
Author
Oliver Lemke
Date
2003-08-18

Definition at line 173 of file legendre.cc.

References legendre_poly().

Referenced by main().

◆ legendre_poly_norm_schmidt()

Numeric legendre_poly_norm_schmidt ( Index  l,
Index  m,
Numeric  x 
)

legendre_poly_norm_schmidt

Returns the Schmidt quasi-normalized associated Legendre polynomial Plm(x).

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| <= 1

The code is based on the Numerical recipes. Results were compared to the Legendre calculations from the GNU Scientific library and found to be identical.

Returns
Plm
Parameters
lIndex
mIndex
xValue
Author
Oliver Lemke
Date
2003-08-15

Definition at line 137 of file legendre.cc.

References fac(), and legendre_poly().

Referenced by legendre_poly_norm_schmidt_deriv(), and main().

◆ legendre_poly_norm_schmidt_deriv()

Numeric legendre_poly_norm_schmidt_deriv ( Index  l,
Index  m,
Numeric  x 
)

legendre_poly_norm_schmidt_deriv

Returns the derivative of the Schmidt quasi-normalized associated Legendre polynomial Plm(x).

The input parameters must fulfill the following conditions: 0 <= m <= l and |x| < 1

Returns
dPlm
Parameters
lIndex
mIndex
xValue
Author
Nikolay Koulev
Date
2003-08-18

Definition at line 257 of file legendre.cc.

References fac(), and legendre_poly_norm_schmidt().

Referenced by main().