Astrodynamics Functions
|
Class that computes and stores the Associated Legendre Functions (ALFs) and its derivatives at a given co-latitude. More...
#include <Plm.hpp>
Public Member Functions | |
Plm () | |
Plm (int l_max, double theta, bool derivatives=false, bool second_derivatives=false) | |
Plm (const Plm &other) | |
Plm & | operator= (const Plm &other) |
double | get_Plm_bar (int l, int m) |
Getter for fully-normalized ALF. | |
double | get_Plm (int l, int m) |
Getter for unnormalized ALF. | |
double | get_dPlm_bar (int l, int m) |
Getter for fully-normalized ALF derivative. | |
double | get_dPlm (int l, int m) |
Getter for unnormalized ALF derivative. | |
double | get_ddPlm_bar (int l, int m) |
Getter for fully-normalized ALF 2nd order derivative. | |
double | get_ddPlm (int l, int m) |
Getter for unnormalized ALF derivative. | |
double | get_theta () const |
Getter for associated colatitude. | |
Class that computes and stores the Associated Legendre Functions (ALFs) and its derivatives at a given co-latitude.
This class computes the Associated Legendre Functions (ALFs) up to a certain degree and order employing a recursive standard forward column method, so-called Fixed-Order-Increase-Degree (FOID), as described by Holmes and Featherstone, 2002 (sec. 2.1).
First the following constants are defined:
\[ a_{lm} = \sqrt{\frac{(2l-1)(2l+1)}{(l-m)(l+m)}} \quad\quad\quad b_{lm} = \sqrt{\frac{(2l+1)(l+m-1)(l-m+1)}{(l-m)(l+m)(2l-3)}} \]
We define that \( t=\cos{\theta}, u=\sin{\theta}\) and the algorithm is initialised with \( \bar{P}_{0,0}(\theta)=1, \bar{P}_{1,1}(\theta)=\sqrt{3}u\). Then, sectorial recursive relationships are applied:
\[ \bar{P}_{mm} = u \sqrt{\frac{2m+1}{2m}} \bar{P}_{m-1,m-1}(\theta) \]
Next, we sequentially fix the order \( m\) and increase the degree \( l\) applying the following recursive relationships:
\[ \bar{P}_{lm}(\theta) = a_{lm} t \bar{P}_{lm}(\theta) - b_{lm} \bar{P}_{l-2,m} \]
Derivatives with respect to the co-latitude are of interest for multiple applications and can be computed from the ALFs with the following expressions:
\[ f_{lm} = \sqrt{\frac{(l^2-m^2)(2l+1)}{2l-1}} \]
\[ \frac{d \bar{P}_{lm}(\theta)}{d\theta} = \frac{1}{u} (lt \bar{P}_{lm}(\theta)-f_{lm} \bar{P}_{l-1,m}(\theta)) \]
Plm::Plm | ( | ) |
Default constructor
Plm::Plm | ( | int | l_max, |
double | theta, | ||
bool | derivatives = false , |
||
bool | second_derivatives = false |
||
) |
Class constructor
l_max | Maximum degree to which the ALFs (or its derivatives) are computed. Note that to compute the derivatives up to a degree L, it is necessary to compute the ALFs up to degree L+2. This is automatically handled based on derivative flags. |
theta | Co-latitude at which the ALFs (and its derivatives) are evaluated |
derivatives | Flag to indicate whether derivatives are computed or not |
second_derivatives | Flag to indicate whether 2nd order derivatives are computed or not |
double Plm::get_ddPlm | ( | int | l, |
int | m | ||
) |
Getter for unnormalized ALF derivative.
l | degree |
m | order |
double Plm::get_ddPlm_bar | ( | int | l, |
int | m | ||
) |
Getter for fully-normalized ALF 2nd order derivative.
l | degree |
m | order |
double Plm::get_dPlm | ( | int | l, |
int | m | ||
) |
Getter for unnormalized ALF derivative.
l | degree |
m | order |
double Plm::get_dPlm_bar | ( | int | l, |
int | m | ||
) |
Getter for fully-normalized ALF derivative.
l | degree |
m | order |
double Plm::get_Plm | ( | int | l, |
int | m | ||
) |
Getter for unnormalized ALF.
l | degree |
m | order |
double Plm::get_Plm_bar | ( | int | l, |
int | m | ||
) |
Getter for fully-normalized ALF.
l | degree |
m | order |