Learn more  » Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Bower components Debian packages RPM packages NuGet packages

aaronreidsmith / scipy   python

Repository URL to install this package:

Version: 1.3.3 

/ special / __init__.py

"""
========================================
Special functions (:mod:`scipy.special`)
========================================

.. currentmodule:: scipy.special

Nearly all of the functions below are universal functions and follow
broadcasting and automatic array-looping rules. Exceptions are
noted.

.. seealso::

   `scipy.special.cython_special` -- Typed Cython versions of special functions


Error handling
==============

Errors are handled by returning NaNs or other appropriate values.
Some of the special function routines can emit warnings or raise
exceptions when an error occurs. By default this is disabled; to
query and control the current error handling state the following
functions are provided.

.. autosummary::
   :toctree: generated/

   geterr                 -- Get the current way of handling special-function errors.
   seterr                 -- Set how special-function errors are handled.
   errstate               -- Context manager for special-function error handling.
   SpecialFunctionWarning -- Warning that can be emitted by special functions.
   SpecialFunctionError   -- Exception that can be raised by special functions.

Available functions
===================

Airy functions
--------------

.. autosummary::
   :toctree: generated/

   airy     -- Airy functions and their derivatives.
   airye    -- Exponentially scaled Airy functions and their derivatives.
   ai_zeros -- [+]Compute `nt` zeros and values of the Airy function Ai and its derivative.
   bi_zeros -- [+]Compute `nt` zeros and values of the Airy function Bi and its derivative.
   itairy   -- Integrals of Airy functions


Elliptic Functions and Integrals
--------------------------------

.. autosummary::
   :toctree: generated/

   ellipj    -- Jacobian elliptic functions
   ellipk    -- Complete elliptic integral of the first kind.
   ellipkm1  -- Complete elliptic integral of the first kind around `m` = 1
   ellipkinc -- Incomplete elliptic integral of the first kind
   ellipe    -- Complete elliptic integral of the second kind
   ellipeinc -- Incomplete elliptic integral of the second kind

Bessel Functions
----------------

.. autosummary::
   :toctree: generated/

   jv       -- Bessel function of the first kind of real order and complex argument.
   jve      -- Exponentially scaled Bessel function of order `v`.
   yn       -- Bessel function of the second kind of integer order and real argument.
   yv       -- Bessel function of the second kind of real order and complex argument.
   yve      -- Exponentially scaled Bessel function of the second kind of real order.
   kn       -- Modified Bessel function of the second kind of integer order `n`
   kv       -- Modified Bessel function of the second kind of real order `v`
   kve      -- Exponentially scaled modified Bessel function of the second kind.
   iv       -- Modified Bessel function of the first kind of real order.
   ive      -- Exponentially scaled modified Bessel function of the first kind
   hankel1  -- Hankel function of the first kind
   hankel1e -- Exponentially scaled Hankel function of the first kind
   hankel2  -- Hankel function of the second kind
   hankel2e -- Exponentially scaled Hankel function of the second kind

The following is not an universal function:

.. autosummary::
   :toctree: generated/

   lmbda -- [+]Jahnke-Emden Lambda function, Lambdav(x).

Zeros of Bessel Functions
^^^^^^^^^^^^^^^^^^^^^^^^^

These are not universal functions:

.. autosummary::
   :toctree: generated/

   jnjnp_zeros -- [+]Compute zeros of integer-order Bessel functions Jn and Jn'.
   jnyn_zeros  -- [+]Compute nt zeros of Bessel functions Jn(x), Jn'(x), Yn(x), and Yn'(x).
   jn_zeros    -- [+]Compute zeros of integer-order Bessel function Jn(x).
   jnp_zeros   -- [+]Compute zeros of integer-order Bessel function derivative Jn'(x).
   yn_zeros    -- [+]Compute zeros of integer-order Bessel function Yn(x).
   ynp_zeros   -- [+]Compute zeros of integer-order Bessel function derivative Yn'(x).
   y0_zeros    -- [+]Compute nt zeros of Bessel function Y0(z), and derivative at each zero.
   y1_zeros    -- [+]Compute nt zeros of Bessel function Y1(z), and derivative at each zero.
   y1p_zeros   -- [+]Compute nt zeros of Bessel derivative Y1'(z), and value at each zero.

Faster versions of common Bessel Functions
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/

   j0  -- Bessel function of the first kind of order 0.
   j1  -- Bessel function of the first kind of order 1.
   y0  -- Bessel function of the second kind of order 0.
   y1  -- Bessel function of the second kind of order 1.
   i0  -- Modified Bessel function of order 0.
   i0e -- Exponentially scaled modified Bessel function of order 0.
   i1  -- Modified Bessel function of order 1.
   i1e -- Exponentially scaled modified Bessel function of order 1.
   k0  -- Modified Bessel function of the second kind of order 0, :math:`K_0`.
   k0e -- Exponentially scaled modified Bessel function K of order 0
   k1  -- Modified Bessel function of the second kind of order 1, :math:`K_1(x)`.
   k1e -- Exponentially scaled modified Bessel function K of order 1

Integrals of Bessel Functions
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/

   itj0y0     -- Integrals of Bessel functions of order 0
   it2j0y0    -- Integrals related to Bessel functions of order 0
   iti0k0     -- Integrals of modified Bessel functions of order 0
   it2i0k0    -- Integrals related to modified Bessel functions of order 0
   besselpoly -- [+]Weighted integral of a Bessel function.

Derivatives of Bessel Functions
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/

   jvp  -- Compute nth derivative of Bessel function Jv(z) with respect to `z`.
   yvp  -- Compute nth derivative of Bessel function Yv(z) with respect to `z`.
   kvp  -- Compute nth derivative of real-order modified Bessel function Kv(z)
   ivp  -- Compute nth derivative of modified Bessel function Iv(z) with respect to `z`.
   h1vp -- Compute nth derivative of Hankel function H1v(z) with respect to `z`.
   h2vp -- Compute nth derivative of Hankel function H2v(z) with respect to `z`.

Spherical Bessel Functions
^^^^^^^^^^^^^^^^^^^^^^^^^^

.. autosummary::
   :toctree: generated/

   spherical_jn -- Spherical Bessel function of the first kind or its derivative.
   spherical_yn -- Spherical Bessel function of the second kind or its derivative.
   spherical_in -- Modified spherical Bessel function of the first kind or its derivative.
   spherical_kn -- Modified spherical Bessel function of the second kind or its derivative.

Riccati-Bessel Functions
^^^^^^^^^^^^^^^^^^^^^^^^

These are not universal functions:

.. autosummary::
   :toctree: generated/

   riccati_jn -- [+]Compute Ricatti-Bessel function of the first kind and its derivative.
   riccati_yn -- [+]Compute Ricatti-Bessel function of the second kind and its derivative.

Struve Functions
----------------

.. autosummary::
   :toctree: generated/

   struve       -- Struve function.
   modstruve    -- Modified Struve function.
   itstruve0    -- Integral of the Struve function of order 0.
   it2struve0   -- Integral related to the Struve function of order 0.
   itmodstruve0 -- Integral of the modified Struve function of order 0.


Raw Statistical Functions
-------------------------

.. seealso:: :mod:`scipy.stats`: Friendly versions of these functions.

.. autosummary::
   :toctree: generated/

   bdtr         -- Binomial distribution cumulative distribution function.
   bdtrc        -- Binomial distribution survival function.
   bdtri        -- Inverse function to `bdtr` with respect to `p`.
   bdtrik       -- Inverse function to `bdtr` with respect to `k`.
   bdtrin       -- Inverse function to `bdtr` with respect to `n`.
   btdtr        -- Cumulative distribution function of the beta distribution.
   btdtri       -- The `p`-th quantile of the beta distribution.
   btdtria      -- Inverse of `btdtr` with respect to `a`.
   btdtrib      -- btdtria(a, p, x)
   fdtr         -- F cumulative distribution function.
   fdtrc        -- F survival function.
   fdtri        -- The `p`-th quantile of the F-distribution.
   fdtridfd     -- Inverse to `fdtr` vs dfd
   gdtr         -- Gamma distribution cumulative distribution function.
   gdtrc        -- Gamma distribution survival function.
   gdtria       -- Inverse of `gdtr` vs a.
   gdtrib       -- Inverse of `gdtr` vs b.
   gdtrix       -- Inverse of `gdtr` vs x.
   nbdtr        -- Negative binomial cumulative distribution function.
   nbdtrc       -- Negative binomial survival function.
   nbdtri       -- Inverse of `nbdtr` vs `p`.
   nbdtrik      -- Inverse of `nbdtr` vs `k`.
   nbdtrin      -- Inverse of `nbdtr` vs `n`.
   ncfdtr       -- Cumulative distribution function of the non-central F distribution.
   ncfdtridfd   -- Calculate degrees of freedom (denominator) for the noncentral F-distribution.
   ncfdtridfn   -- Calculate degrees of freedom (numerator) for the noncentral F-distribution.
   ncfdtri      -- Inverse cumulative distribution function of the non-central F distribution.
   ncfdtrinc    -- Calculate non-centrality parameter for non-central F distribution.
   nctdtr       -- Cumulative distribution function of the non-central `t` distribution.
   nctdtridf    -- Calculate degrees of freedom for non-central t distribution.
   nctdtrit     -- Inverse cumulative distribution function of the non-central t distribution.
   nctdtrinc    -- Calculate non-centrality parameter for non-central t distribution.
   nrdtrimn     -- Calculate mean of normal distribution given other params.
   nrdtrisd     -- Calculate standard deviation of normal distribution given other params.
   pdtr         -- Poisson cumulative distribution function
   pdtrc        -- Poisson survival function
   pdtri        -- Inverse to `pdtr` vs m
   pdtrik       -- Inverse to `pdtr` vs k
   stdtr        -- Student t distribution cumulative distribution function
   stdtridf     -- Inverse of `stdtr` vs df
   stdtrit      -- Inverse of `stdtr` vs `t`
   chdtr        -- Chi square cumulative distribution function
   chdtrc       -- Chi square survival function
   chdtri       -- Inverse to `chdtrc`
   chdtriv      -- Inverse to `chdtr` vs `v`
   ndtr         -- Gaussian cumulative distribution function.
   log_ndtr     -- Logarithm of Gaussian cumulative distribution function.
   ndtri        -- Inverse of `ndtr` vs x
   chndtr       -- Non-central chi square cumulative distribution function
   chndtridf    -- Inverse to `chndtr` vs `df`
   chndtrinc    -- Inverse to `chndtr` vs `nc`
   chndtrix     -- Inverse to `chndtr` vs `x`
   smirnov      -- Kolmogorov-Smirnov complementary cumulative distribution function
   smirnovi     -- Inverse to `smirnov`
   kolmogorov   -- Complementary cumulative distribution function of Kolmogorov distribution
   kolmogi      -- Inverse function to `kolmogorov`
   tklmbda      -- Tukey-Lambda cumulative distribution function
   logit        -- Logit ufunc for ndarrays.
   expit        -- Expit ufunc for ndarrays.
   boxcox       -- Compute the Box-Cox transformation.
   boxcox1p     -- Compute the Box-Cox transformation of 1 + `x`.
   inv_boxcox   -- Compute the inverse of the Box-Cox transformation.
   inv_boxcox1p -- Compute the inverse of the Box-Cox transformation.
   owens_t      -- Owen's T Function.


Information Theory Functions
----------------------------

.. autosummary::
   :toctree: generated/

   entr         -- Elementwise function for computing entropy.
   rel_entr     -- Elementwise function for computing relative entropy.
   kl_div       -- Elementwise function for computing Kullback-Leibler divergence.
   huber        -- Huber loss function.
   pseudo_huber -- Pseudo-Huber loss function.


Gamma and Related Functions
---------------------------

.. autosummary::
   :toctree: generated/

   gamma        -- Gamma function.
   gammaln      -- Logarithm of the absolute value of the Gamma function for real inputs.
   loggamma     -- Principal branch of the logarithm of the Gamma function.
   gammasgn     -- Sign of the gamma function.
   gammainc     -- Regularized lower incomplete gamma function.
   gammaincinv  -- Inverse to `gammainc`
   gammaincc    -- Regularized upper incomplete gamma function.
   gammainccinv -- Inverse to `gammaincc`
   beta         -- Beta function.
   betaln       -- Natural logarithm of absolute value of beta function.
   betainc      -- Incomplete beta integral.
   betaincinv   -- Inverse function to beta integral.
   psi          -- The digamma function.
   rgamma       -- Gamma function inverted
   polygamma    -- Polygamma function n.
   multigammaln -- Returns the log of multivariate gamma, also sometimes called the generalized gamma.
   digamma      -- psi(x[, out])
   poch         -- Rising factorial (z)_m


Error Function and Fresnel Integrals
------------------------------------

.. autosummary::
   :toctree: generated/

   erf           -- Returns the error function of complex argument.
   erfc          -- Complementary error function, ``1 - erf(x)``.
   erfcx         -- Scaled complementary error function, ``exp(x**2) * erfc(x)``.
   erfi          -- Imaginary error function, ``-i erf(i z)``.
   erfinv        -- Inverse function for erf.
   erfcinv       -- Inverse function for erfc.
   wofz          -- Faddeeva function
   dawsn         -- Dawson's integral.
   fresnel       -- Fresnel sin and cos integrals
   fresnel_zeros -- Compute nt complex zeros of sine and cosine Fresnel integrals S(z) and C(z).
   modfresnelp   -- Modified Fresnel positive integrals
   modfresnelm   -- Modified Fresnel negative integrals

These are not universal functions:

.. autosummary::
   :toctree: generated/

   erf_zeros      -- [+]Compute nt complex zeros of error function erf(z).
   fresnelc_zeros -- [+]Compute nt complex zeros of cosine Fresnel integral C(z).
   fresnels_zeros -- [+]Compute nt complex zeros of sine Fresnel integral S(z).

Legendre Functions
------------------

.. autosummary::
   :toctree: generated/

   lpmv     -- Associated Legendre function of integer order and real degree.
   sph_harm -- Compute spherical harmonics.

These are not universal functions:

.. autosummary::
   :toctree: generated/

   clpmn -- [+]Associated Legendre function of the first kind for complex arguments.
   lpn   -- [+]Legendre function of the first kind.
Loading ...