[SciPy-user] jn & lpmn or sph_jn...

fred fredantispam at free.fr
Thu Aug 3 05:26:37 CDT 2006


Robert Kern a écrit :

[snip]

> It's probably the easiest one. There is a reason that the current forms of the 
> spherical harmonic functions are not ufuncs like jn is: they can't be shoved 
> into the ufunc framework since they return arrays for scalar inputs.

marsu[pts/0]:~/{5}/> ipython
Python 2.4.3 (#1, Jul 25 2006, 18:55:45)
Type "copyright", "credits" or "license" for more information.

IPython 0.7.2 -- An enhanced Interactive Python.
?       -> Introduction to IPython's features.
%magic  -> Information about IPython's 'magic' % functions.
help    -> Python's own help system.
object? -> Details about 'object'. ?object also works, ?? prints more.

In [1]: from scipy.special import *

In [2]: help(lpmn)
Help on function lpmn in module scipy.special.basic:

lpmn(m, n, z)
    Associated Legendre functions of the first kind, Pmn(z) and its
    derivative, Pmn'(z) of order m and degree n.  Returns two
    arrays of size (m+1,n+1) containing Pmn(z) and Pmn'(z) for
    all orders from 0..m and degrees from 0..n.

    z can be complex.

In [3]: help(jn)
Help on ufunc object:

jn = class ufunc(__builtin__.object)
 |  Optimized functions make it possible to implement arithmetic with
arrays efficiently
 |
 |  Methods defined here:
 |
 |  __call__(...)
 |      x.__call__(...) <==> x(...)
 |
 |  __repr__(...)
 |      x.__repr__() <==> repr(x)
 |
 |  __str__(...)
 |      x.__str__() <==> str(x)
 |
 |  accumulate(...)
 |
 |  outer(...)
 |
 |  reduce(...)
 |
 |  reduceat(...)
.../...

How can I get info about jn functions ??

Cheers,

-- 
Fred.


More information about the SciPy-user mailing list