Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Derivative of Associated Legendre Polynomials #13

Open
3allan opened this issue May 15, 2021 · 0 comments
Open

Derivative of Associated Legendre Polynomials #13

3allan opened this issue May 15, 2021 · 0 comments
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@3allan
Copy link
Owner

3allan commented May 15, 2021

The derivative of the associated Legendre polynomials needs adjustment for evaluating gravitational acceleration.

The associated Legendre polynomials, see also here and some theory documentation here (appx. B), serve as a basis in spherical coordinates which is a popular system in which to quantify Earth's gravity. In this particular field of study, often the (fully) normalized associated Legendre polynomials (without the Condon-Shortley phase) are used instead - this just adds a scaling to the polynomial determined by its degree and order; see documentation Earth Gravity (Rough, Rotating Spheroid) or its source IERS TN36 Sec. 6 (pg. 79 eqs. 6.2a and b) (obtained from here) for more information.

The particular lines that are currently incorrect are found here in the code and in the documentation.

Priority: High

  • Provides opportunity to work with spherical harmonics
  • Has a large role in determining gravitational acceleration
  • Known to be wrong by simple experiments of taking a numerical derivative and comparing it to the implemented closed form
    • The (incorrect) formula in the documentation seems only slightly more efficient than the implemented (incorrect) formula in Matlab as the former utilizes the same degree on both terms, though it may require some extra treatment for order 0. The latter formula (in Matlab) uses the same order on both terms, so there's no ambiguity about the Condon-Shortley phase.
    • Note that we need the derivative of P(cos(t)) with respect to t, though we can always use the chain rule with x = cos(t).

Current implementation of derivative (shown is a derivative of the (unnormalized) Legendre polynomial of degree l and order m)

Current documentation of derivative

@3allan 3allan added bug Something isn't working good first issue Good for newcomers labels May 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant