I've attached a simple patch to add support for assoc_legendre_p() to orthopoly_weight().
There are two orthogonality conditions for the associated Legendre polynomials over [-1,1]: both having the same order, with weight function 1 (much the same as the regular Legendre polynomials); and both having the same degree, with weight function 1/(1-x^2). See A&S 8.14.11 and 8.14.12. I've chosen for orthopoly_weight() to return the former because (please correct me if I'm wrong) I think that condition will be expected most often. I mention this other condition in a comment in the patch.
Perhaps this ambiguity is why this function hasn't been supported in orthopoly_weight()?
Log in to post a comment.