diff --git a/dev/API/index.html b/dev/API/index.html index 66386cf..015b51d 100644 --- a/dev/API/index.html +++ b/dev/API/index.html @@ -10,13 +10,13 @@ 3-element Vector{Float64}: 0.4970941024642743 0.44605905843961735 - 0.2166003910391135

External links: DLMF, Wikipedia

See also: besselj!, besselj0(x), besselj1(x)

source
Bessels.BesselFunctions.besselj!Function
Bessels.besselj!(out::AbstractVector{T}, ν::AbstractRange, x::T)

Computes the Bessel function, $j_ν(x)$, of the first kind at many orders ν in-place using recurrence. The conditions ν[1] >= 0 and step(ν) == 1 must be met.

Examples

julia> nu = 1:3; x = 1.5; out = zeros(typeof(x), length(nu));
+ 0.2166003910391135

External links: DLMF, Wikipedia

See also: besselj!, besselj0(x), besselj1(x)

source
Bessels.BesselFunctions.besselj!Function
Bessels.besselj!(out::AbstractVector{T}, ν::AbstractRange, x::T)

Computes the Bessel function, $j_ν(x)$, of the first kind at many orders ν in-place using recurrence. The conditions ν[1] >= 0 and step(ν) == 1 must be met.

Examples

julia> nu = 1:3; x = 1.5; out = zeros(typeof(x), length(nu));
 
 julia> Bessels.besselj!(out, nu, x)
 3-element Vector{Float64}:
  0.5579365079100995
  0.2320876721442147
- 0.06096395114113963

See also: besselj(ν, x)

source
Bessels.BesselFunctions.besselj0Function
besselj0(x::T) where T <: Union{Float32, Float64, ComplexF32, ComplexF64}

Bessel function of the first kind of order zero, $J_0(x)$.

See also: besselj1(x), besselj(nu,x))

source
Bessels.BesselFunctions.besselj1Function
besselj1(x::T) where T <: Union{Float32, Float64, ComplexF32, ComplexF64}

Bessel function of the first kind of order one, $J_1(x)$.

See also: besselj0(x), besselj(nu,x))

source
Bessels.BesselFunctions.besselyFunction
bessely(ν::Real, x::Real)
+ 0.06096395114113963

See also: besselj(ν, x)

source
Bessels.BesselFunctions.besselj0Function
besselj0(x::T) where T <: Union{Float32, Float64, ComplexF32, ComplexF64}

Bessel function of the first kind of order zero, $J_0(x)$.

See also: besselj1(x), besselj(nu,x))

source
Bessels.BesselFunctions.besselj1Function
besselj1(x::T) where T <: Union{Float32, Float64, ComplexF32, ComplexF64}

Bessel function of the first kind of order one, $J_1(x)$.

See also: besselj0(x), besselj(nu,x))

source
Bessels.BesselFunctions.besselyFunction
bessely(ν::Real, x::Real)
 bessely(ν::AbstractRange, x::Real)

Returns the Bessel function, $Y_ν(x)$, of the second kind and order ν.

\[Y_{\nu}(x) = \frac{J_{\nu}(x) \cos(\nu \pi) - J_{-\nu}(x)}{\sin(\nu \pi)}\]

Routine supports single and double precision (e.g., Float32 or Float64) real arguments.

For ν isa AbstractRange, returns a vector of type float(x) using recurrence to compute $Y_ν(x)$ at many orders as long as the conditions ν[1] >= 0 and step(ν) == 1 are met. Consider the in-place version besselj! to avoid allocation.

Examples

julia> bessely(2, 1.5)
 -0.9321937597629739
 
@@ -27,13 +27,13 @@
 3-element Vector{Float64}:
   0.1459181379667858
  -0.38133584924180347
- -0.7560554967536713

External links: DLMF, Wikipedia

See also: bessely!, bessely0(x), bessely1(x)

source
Bessels.BesselFunctions.bessely!Function
Bessels.bessely!(out::AbstractVector{T}, ν::AbstractRange, x::T)

Computes the Bessel function, $Y_ν(x)$, of the second kind at many orders ν in-place using recurrence. The conditions ν[1] >= 0 and step(ν) == 1 must be met.

Examples

julia> nu = 1:3; x = 1.5; out = zeros(typeof(x), length(nu));
+ -0.7560554967536713

External links: DLMF, Wikipedia

See also: bessely!, bessely0(x), bessely1(x)

source
Bessels.BesselFunctions.bessely!Function
Bessels.bessely!(out::AbstractVector{T}, ν::AbstractRange, x::T)

Computes the Bessel function, $Y_ν(x)$, of the second kind at many orders ν in-place using recurrence. The conditions ν[1] >= 0 and step(ν) == 1 must be met.

Examples

julia> nu = 1:3; x = 1.5; out = zeros(typeof(x), length(nu));
 
 julia> Bessels.bessely!(out, nu, x)
 3-element Vector{Float64}:
  -0.41230862697391135
  -0.9321937597629739
- -2.0735413990606855

See also: bessely(ν, x)

source
Bessels.BesselFunctions.bessely0Function
bessely0(x::T) where T <: Union{Float32, Float64}

Bessel function of the second kind of order zero, $Y_0(x)$.

See also: bessely1(x), bessely(nu,x))

source
Bessels.BesselFunctions.bessely1Function
bessely1(x::T) where T <: Union{Float32, Float64}

Bessel function of the second kind of order one, $Y_1(x)$.

See also: bessely0(x), bessely(nu,x))

source
Missing docstring.

Missing docstring for Bessels.besseljy. Check Documenter's build log for details.

Modified Bessel functions

Bessels.BesselFunctions.besseliFunction
besseli(ν::Real, x::Real)
+ -2.0735413990606855

See also: bessely(ν, x)

source
Bessels.BesselFunctions.bessely0Function
bessely0(x::T) where T <: Union{Float32, Float64}

Bessel function of the second kind of order zero, $Y_0(x)$.

See also: bessely1(x), bessely(nu,x))

source
Bessels.BesselFunctions.bessely1Function
bessely1(x::T) where T <: Union{Float32, Float64}

Bessel function of the second kind of order one, $Y_1(x)$.

See also: bessely0(x), bessely(nu,x))

source
Missing docstring.

Missing docstring for Bessels.besseljy. Check Documenter's build log for details.

Modified Bessel functions

Bessels.BesselFunctions.besseliFunction
besseli(ν::Real, x::Real)
 besseli(ν::AbstractRange, x::Real)

Returns the modified Bessel function, $I_ν(x)$, of the first kind and order ν.

\[I_{\nu}(x) = \sum_{m=0}^{\infty} \frac{1}{m!\Gamma(m+\nu+1)}(\frac{x}{2})^{2m+\nu}\]

Routine supports single and double precision (e.g., Float32 or Float64) real arguments.

For ν isa AbstractRange, returns a vector of type float(x) using recurrence to compute $I_ν(x)$ at many orders as long as the conditions ν[1] >= 0 and step(ν) == 1 are met. Consider the in-place version besseli! to avoid allocation.

Examples

julia> besseli(2, 1.5)
 0.3378346183356807
 
@@ -44,13 +44,13 @@
 3-element Vector{Float64}:
  2.5167162452886984
  1.2764661478191641
- 0.47437040877803555

External links: DLMF, Wikipedia

See also: besseli!, besseli0(x), besseli1(x), besselix(nu,x))

source
Bessels.BesselFunctions.besseli!Function
Bessels.besseli!(out::AbstractVector{T}, ν::AbstractRange, x::T)

Computes the modified Bessel function, $I_ν(x)$, of the first kind at many orders ν in-place using recurrence. The conditions ν[1] >= 0 and step(ν) == 1 must be met.

Examples

julia> nu = 1:3; x = 1.5; out = zeros(typeof(x), length(nu));
+ 0.47437040877803555

External links: DLMF, Wikipedia

See also: besseli!, besseli0(x), besseli1(x), besselix(nu,x))

source
Bessels.BesselFunctions.besseli!Function
Bessels.besseli!(out::AbstractVector{T}, ν::AbstractRange, x::T)

Computes the modified Bessel function, $I_ν(x)$, of the first kind at many orders ν in-place using recurrence. The conditions ν[1] >= 0 and step(ν) == 1 must be met.

Examples

julia> nu = 1:3; x = 1.5; out = zeros(typeof(x), length(nu));
 
 julia> Bessels.besseli!(out, nu, x)
 3-element Vector{Float64}:
  0.9816664285779074
  0.3378346183356807
- 0.0807741130160923

See also: besseli(ν, x)

source
Bessels.BesselFunctions.besseli0Function
besseli0(x::T) where T <: Union{Float32, Float64, ComplexF32, ComplexF64}

Modified Bessel function of the first kind of order zero, $I_0(x)$.

See also: besseli0x(x), besseli1(x), besseli(nu,x))

source
Bessels.BesselFunctions.besseli0xFunction
besseli0x(x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the first kind of order zero, $I_0(x)*e^{-x}$.

See also: besseli0(x), besseli1x(x), besseli(nu,x))

source
Bessels.BesselFunctions.besseli1Function
besseli1(x::T) where T <: Union{Float32, Float64, ComplexF32, ComplexF64}

Modified Bessel function of the first kind of order one, $I_1(x)$.

See also: besseli0(x), besseli1x(x), besseli(nu,x))

source
Bessels.BesselFunctions.besseli1xFunction
besseli1x(x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the first kind of order one, $I_1(x)*e^{-x}$.

See also: besseli1(x), besseli(nu,x))

source
Bessels.BesselFunctions.besselixFunction
besselix(nu, x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the first kind of order nu, $I_{nu}(x)*e^{-x}$. Nu must be real.

source
Bessels.BesselFunctions.besselkFunction
besselk(ν::Real, x::Real)
+ 0.0807741130160923

See also: besseli(ν, x)

source
Bessels.BesselFunctions.besseli0Function
besseli0(x::T) where T <: Union{Float32, Float64, ComplexF32, ComplexF64}

Modified Bessel function of the first kind of order zero, $I_0(x)$.

See also: besseli0x(x), besseli1(x), besseli(nu,x))

source
Bessels.BesselFunctions.besseli0xFunction
besseli0x(x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the first kind of order zero, $I_0(x)*e^{-x}$.

See also: besseli0(x), besseli1x(x), besseli(nu,x))

source
Bessels.BesselFunctions.besseli1Function
besseli1(x::T) where T <: Union{Float32, Float64, ComplexF32, ComplexF64}

Modified Bessel function of the first kind of order one, $I_1(x)$.

See also: besseli0(x), besseli1x(x), besseli(nu,x))

source
Bessels.BesselFunctions.besseli1xFunction
besseli1x(x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the first kind of order one, $I_1(x)*e^{-x}$.

See also: besseli1(x), besseli(nu,x))

source
Bessels.BesselFunctions.besselixFunction
besselix(nu, x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the first kind of order nu, $I_{nu}(x)*e^{-x}$. Nu must be real.

source
Bessels.BesselFunctions.besselkFunction
besselk(ν::Real, x::Real)
 besselk(ν::AbstractRange, x::Real)

Returns the modified Bessel function, $K_ν(x)$, of the second kind and order ν.

\[K_{\nu}(x) = \frac{\pi}{2} \frac{I_{-\nu}(x) - I_{\nu}(x)}{\sin(\nu \pi)}\]

Routine supports single and double precision (e.g., Float32 or Float64) real arguments.

For ν isa AbstractRange, returns a vector of type float(x) using recurrence to compute $K_ν(x)$ at many orders as long as the conditions ν[1] >= 0 and step(ν) == 1 are met. Consider the in-place version besselk! to avoid allocation.

Examples

julia> besselk(2, 1.5)
 0.5836559632566508
 
@@ -61,44 +61,44 @@
 3-element Vector{Float64}:
  0.07389081634774707
  0.12146020627856384
- 0.26822714639344925

External links: DLMF, Wikipedia

See also: besselk!, besselk0(x), besselk1(x), besselkx(nu,x))

source
Bessels.BesselFunctions.besselk!Function
Bessels.besselk!(out::AbstractVector{T}, ν::AbstractRange, x::T)

Computes the modified Bessel function, $K_ν(x)$, of the second kind at many orders ν in-place using recurrence. The conditions ν[1] >= 0 and step(ν) == 1 must be met.

Examples

julia> nu = 1:3; x = 1.5; out = zeros(typeof(x), length(nu));
+ 0.26822714639344925

External links: DLMF, Wikipedia

See also: besselk!, besselk0(x), besselk1(x), besselkx(nu,x))

source
Bessels.BesselFunctions.besselk!Function
Bessels.besselk!(out::AbstractVector{T}, ν::AbstractRange, x::T)

Computes the modified Bessel function, $K_ν(x)$, of the second kind at many orders ν in-place using recurrence. The conditions ν[1] >= 0 and step(ν) == 1 must be met.

Examples

julia> nu = 1:3; x = 1.5; out = zeros(typeof(x), length(nu));
 
 julia> Bessels.besselk!(out, nu, x)
 3-element Vector{Float64}:
  0.2773878004568438
  0.5836559632566508
- 1.8338037024745792

See also: besselk(ν, x)

source
Bessels.BesselFunctions.besselk0Function
besselk0(x::T) where T <: Union{Float32, Float64}

Modified Bessel function of the second kind of order zero, $K_0(x)$.

See also: besselk0x(x), besselk1(x), besselk(nu,x))

source
Bessels.BesselFunctions.besselk0xFunction
besselk0x(x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the second kind of order zero, $K_0(x)*e^{x}$.

See also: besselk0(x), besselk1x(x), besselk(nu,x))

source
Bessels.BesselFunctions.besselk1Function
besselk1(x::T) where T <: Union{Float32, Float64}

Modified Bessel function of the second kind of order one, $K_1(x)$.

See also: besselk0(x), besselk1x(x), besselk(nu,x))

source
Bessels.BesselFunctions.besselk1xFunction
besselk1x(x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the second kind of order one, $K_1(x)*e^{x}$.

See also: besselk1(x), besselk(nu,x))

source
Bessels.BesselFunctions.besselkxFunction
besselkx(x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the second kind of order nu, $K_{nu}(x)*e^{x}$.

source

Hankel functions

Bessels.BesselFunctions.besselhFunction
besselh(nu, [k=1,] x)

Returns the Bessel function of the third kind of order nu (the Hankel function).

\[H^{(1)}_{\nu}(x) = J_{\nu}(x) + i Y_{\nu}(x) + 1.8338037024745792

See also: besselk(ν, x)

source
Bessels.BesselFunctions.besselk0Function
besselk0(x::T) where T <: Union{Float32, Float64}

Modified Bessel function of the second kind of order zero, $K_0(x)$.

See also: besselk0x(x), besselk1(x), besselk(nu,x))

source
Bessels.BesselFunctions.besselk0xFunction
besselk0x(x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the second kind of order zero, $K_0(x)*e^{x}$.

See also: besselk0(x), besselk1x(x), besselk(nu,x))

source
Bessels.BesselFunctions.besselk1Function
besselk1(x::T) where T <: Union{Float32, Float64}

Modified Bessel function of the second kind of order one, $K_1(x)$.

See also: besselk0(x), besselk1x(x), besselk(nu,x))

source
Bessels.BesselFunctions.besselk1xFunction
besselk1x(x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the second kind of order one, $K_1(x)*e^{x}$.

See also: besselk1(x), besselk(nu,x))

source
Bessels.BesselFunctions.besselkxFunction
besselkx(x::T) where T <: Union{Float32, Float64}

Scaled modified Bessel function of the second kind of order nu, $K_{nu}(x)*e^{x}$.

source

Hankel functions

Bessels.BesselFunctions.besselhFunction
besselh(nu, [k=1,] x)

Returns the Bessel function of the third kind of order nu (the Hankel function).

\[H^{(1)}_{\nu}(x) = J_{\nu}(x) + i Y_{\nu}(x) H^{(2)}_{\nu}(x) = J_{\nu}(x) - i Y_{\nu}(x)\]

k must be 1 or 2, selecting hankelh1 or hankelh2, respectively.

Examples

julia> besselh(1.2, 1, 9.2)
-0.2513215427211038 + 0.08073652619125624im

See also: Bessels.besseljy, besselj(nu,x)), bessely(nu,x))

source
Bessels.BesselFunctions.hankelh1Function
hankelh1(nu, x)

Bessel function of the third kind of order nu, $H^{(1)}_\nu(x)$.

source
Bessels.BesselFunctions.hankelh2Function
hankelh2(nu, x)

Bessel function of the third kind of order nu, $H^{(2)}_\nu(x)$.

source

Spherical Bessel functions

Bessels.BesselFunctions.sphericalbesseljFunction
sphericalbesselj(ν, x)

Spherical bessel function of the first kind of order ν, $j_ν(x)$. This is the non-singular solution to the radial part of the Helmholz equation in spherical coordinates.

\[j_{\nu}(x) = \sqrt(\frac{\pi}{2x}) J_{\nu + 1/2}(x)\]

where $J_{\nu}$ is the Bessel function of the first kind. Routine supports single and double precision (e.g., Float32, Float64) for real arguments.

Examples

julia> sphericalbesselj(1, 1.2)
+0.2513215427211038 + 0.08073652619125624im

See also: Bessels.besseljy, besselj(nu,x)), bessely(nu,x))

source
Bessels.BesselFunctions.hankelh1Function
hankelh1(nu, x)

Bessel function of the third kind of order nu, $H^{(1)}_\nu(x)$.

source
Bessels.BesselFunctions.hankelh2Function
hankelh2(nu, x)

Bessel function of the third kind of order nu, $H^{(2)}_\nu(x)$.

source

Spherical Bessel functions

Bessels.BesselFunctions.sphericalbesseljFunction
sphericalbesselj(ν, x)

Spherical bessel function of the first kind of order ν, $j_ν(x)$. This is the non-singular solution to the radial part of the Helmholz equation in spherical coordinates.

\[j_{\nu}(x) = \sqrt(\frac{\pi}{2x}) J_{\nu + 1/2}(x)\]

where $J_{\nu}$ is the Bessel function of the first kind. Routine supports single and double precision (e.g., Float32, Float64) for real arguments.

Examples

julia> sphericalbesselj(1, 1.2)
 0.34528456985779027
 
 julia> sphericalbesselj(1.5, 1.2)
-0.18231344932382995

External links: DLMF, Wikipedia

See also: besselj, sphericalbessely

source
Bessels.BesselFunctions.sphericalbesselyFunction
sphericalbessely(ν, x)

Spherical bessel function of the second kind of order ν, $y_ν(x)$. This is the non-singular solution to the radial part of the Helmholz equation in spherical coordinates. Sometimes known as a spherical Neumann function.

\[y_{\nu}(x) = \sqrt(\frac{\pi}{2x}) Y_{\nu + 1/2}(x)\]

where $Y_{\nu}$ is the Bessel function of the second kind. Routine supports single and double precision (e.g., Float32, Float64) for real arguments.

Examples

julia> sphericalbessely(1, 1.2)
+0.18231344932382995

External links: DLMF, Wikipedia

See also: besselj, sphericalbessely

source
Bessels.BesselFunctions.sphericalbesselyFunction
sphericalbessely(ν, x)

Spherical bessel function of the second kind of order ν, $y_ν(x)$. This is the non-singular solution to the radial part of the Helmholz equation in spherical coordinates. Sometimes known as a spherical Neumann function.

\[y_{\nu}(x) = \sqrt(\frac{\pi}{2x}) Y_{\nu + 1/2}(x)\]

where $Y_{\nu}$ is the Bessel function of the second kind. Routine supports single and double precision (e.g., Float32, Float64) for real arguments.

Examples

julia> sphericalbessely(1, 1.2)
 -1.028336567803712
 
 julia> sphericalbessely(1.5, 1.2)
--1.4453716277410136

External links: DLMF, Wikipedia

See also: bessely, sphericalbesselj

source
Bessels.BesselFunctions.sphericalbesseliFunction
Bessels.sphericalbesseli(ν, x)

Returns the modified spherical bessel function of the first kind of order ν, $i_ν(x)$.

\[i_{\nu}(x) = \sqrt(\frac{\pi}{2x}) I_{\nu + 1/2}(x)\]

where $I_{\nu}$ is the modified Bessel function of the first kind. Routine supports single and double precision (e.g., Float32, Float64) for real arguments.

Examples

julia> Bessels.sphericalbesseli(1, 1.2)
+-1.4453716277410136

External links: DLMF, Wikipedia

See also: bessely, sphericalbesselj

source
Bessels.BesselFunctions.sphericalbesseliFunction
Bessels.sphericalbesseli(ν, x)

Returns the modified spherical bessel function of the first kind of order ν, $i_ν(x)$.

\[i_{\nu}(x) = \sqrt(\frac{\pi}{2x}) I_{\nu + 1/2}(x)\]

where $I_{\nu}$ is the modified Bessel function of the first kind. Routine supports single and double precision (e.g., Float32, Float64) for real arguments.

Examples

julia> Bessels.sphericalbesseli(1, 1.2)
 0.4606425870674146
 
 julia> Bessels.sphericalbesseli(1.5, 1.2)
-0.23179256391926525

External links: DLMF, Wikipedia

See also: besseli, Bessels.sphericalbesselk

source
Bessels.BesselFunctions.sphericalbesselkFunction
Bessels.sphericalbesselk(ν, x)

Returns the modified spherical bessel function of the second kind of order ν, $k_ν(x)$.

\[k_{\nu}(x) = \sqrt(\frac{\pi}{2x}) K_{\nu + 1/2}(x)\]

where $K_{\nu}$ is the modified Bessel function of the second kind. Routine supports single and double precision (e.g., Float32, Float64) for real arguments.

Examples

julia> Bessels.sphericalbesselk(1, 1.2)
+0.23179256391926525

External links: DLMF, Wikipedia

See also: besseli, Bessels.sphericalbesselk

source
Bessels.BesselFunctions.sphericalbesselkFunction
Bessels.sphericalbesselk(ν, x)

Returns the modified spherical bessel function of the second kind of order ν, $k_ν(x)$.

\[k_{\nu}(x) = \sqrt(\frac{\pi}{2x}) K_{\nu + 1/2}(x)\]

where $K_{\nu}$ is the modified Bessel function of the second kind. Routine supports single and double precision (e.g., Float32, Float64) for real arguments.

Examples

julia> Bessels.sphericalbesselk(1, 1.2)
 0.46015782375475334
 
 julia> Bessels.sphericalbesselk(1.5, 1.2)
-0.7595606983594666

External links: DLMF, Wikipedia

See also: besselk, Bessels.sphericalbesseli

source

Airy functions

Bessels.AiryFunctions.airyaiFunction
airyai(z)

Returns the Airy function of the first kind, $\operatorname{Ai}(z)$, which is the solution to the Airy differential equation $f''(z) - z f(z) = 0$.

\[\operatorname{Ai}(z) = \frac{\sqrt{3}}{2 \pi} \int_{0}^^{\infty} \exp{-\frac{t^3}{3} - \frac{z^3}{3t^3}} dt\]

Routine supports single and double precision (e.g., Float32, Float64, ComplexF64) for real and complex arguments.

Examples

julia> airyai(1.2)
+0.7595606983594666

External links: DLMF, Wikipedia

See also: besselk, Bessels.sphericalbesseli

source

Airy functions

Bessels.AiryFunctions.airyaiFunction
airyai(z)

Returns the Airy function of the first kind, $\operatorname{Ai}(z)$, which is the solution to the Airy differential equation $f''(z) - z f(z) = 0$.

\[\operatorname{Ai}(z) = \frac{\sqrt{3}}{2 \pi} \int_{0}^^{\infty} \exp{-\frac{t^3}{3} - \frac{z^3}{3t^3}} dt\]

Routine supports single and double precision (e.g., Float32, Float64, ComplexF64) for real and complex arguments.

Examples

julia> airyai(1.2)
 0.10612576226331255
 
 julia> airyai(1.2 + 1.4im)
--0.03254458873613304 - 0.14708163733976673im

External links: DLMF, Wikipedia

See also: airyaiprime, airybi

source
Bessels.AiryFunctions.airyaiprimeFunction
airyaiprime(z)

Returns the derivative of the Airy function of the first kind, 1\operatorname{Ai}'(z). Routine supports single and double precision (e.g.,Float32,Float64,ComplexF64`) for real and complex arguments.

Examples

julia> airyaiprime(1.2)
+-0.03254458873613304 - 0.14708163733976673im

External links: DLMF, Wikipedia

See also: airyaiprime, airybi

source
Bessels.AiryFunctions.airyaiprimeFunction
airyaiprime(z)

Returns the derivative of the Airy function of the first kind, 1\operatorname{Ai}'(z). Routine supports single and double precision (e.g.,Float32,Float64,ComplexF64`) for real and complex arguments.

Examples

julia> airyaiprime(1.2)
 -0.13278537855722622
 
 julia> airyaiprime(1.2 + 1.4im)
--0.02884977394212135 + 0.21117856532576215im

External links: DLMF, Wikipedia

See also: airyai, airybi

source
Bessels.AiryFunctions.airybiFunction
airybi(z)

Returns the Airy function of the second kind, $\operatorname{Bi}(z)$, which is the second solution to the Airy differential equation $f''(z) - z f(z) = 0$. Routine supports single and double precision (e.g., Float32, Float64, ComplexF64) for real and complex arguments.

Examples

julia> airybi(1.2)
+-0.02884977394212135 + 0.21117856532576215im

External links: DLMF, Wikipedia

See also: airyai, airybi

source
Bessels.AiryFunctions.airybiFunction
airybi(z)

Returns the Airy function of the second kind, $\operatorname{Bi}(z)$, which is the second solution to the Airy differential equation $f''(z) - z f(z) = 0$. Routine supports single and double precision (e.g., Float32, Float64, ComplexF64) for real and complex arguments.

Examples

julia> airybi(1.2)
 1.4211336756103483
 
 julia> airybi(1.2 + 1.4im)
-0.3150484065220768 + 0.7138432162853446im

External links: DLMF, Wikipedia

See also: airybiprime, airyai

source
Bessels.AiryFunctions.airybiprimeFunction
airybiprime(z)

Returns the derivative of the Airy function of the second kind, $\operatorname{Bi}'(z)$. Routine supports single and double precision (e.g., Float32, Float64, ComplexF64) for real and complex arguments.

Examples

julia> airybiprime(1.2)
+0.3150484065220768 + 0.7138432162853446im

External links: DLMF, Wikipedia

See also: airybiprime, airyai

source
Bessels.AiryFunctions.airybiprimeFunction
airybiprime(z)

Returns the derivative of the Airy function of the second kind, $\operatorname{Bi}'(z)$. Routine supports single and double precision (e.g., Float32, Float64, ComplexF64) for real and complex arguments.

Examples

julia> airybiprime(1.2)
 1.221231398704895
 
 julia> airybiprime(1.2 + 1.4im)
--0.5250248310153249 + 0.9612736841097036im

External links: DLMF, Wikipedia

See also: airybi, airyai

source

Gamma functions

Bessels.GammaFunctions.gammaFunction
gamma(x::T) where T <: Union{Float16, Float32, Float64}

Returns the gamma function, $Γ(x)$, for real x.

\[\Gamma(x) = \int_x^\infty e^{-t} t^{x-1} dt \,\]

External links: DLMF, Wikipedia

source
+-0.5250248310153249 + 0.9612736841097036im

External links: DLMF, Wikipedia

See also: airybi, airyai

source

Gamma functions

Bessels.GammaFunctions.gammaFunction
gamma(x::T) where T <: Union{Float16, Float32, Float64}

Returns the gamma function, $Γ(x)$, for real x.

\[\Gamma(x) = \int_x^\infty e^{-t} t^{x-1} dt \,\]

External links: DLMF, Wikipedia

source
diff --git a/dev/contribute/index.html b/dev/contribute/index.html index 20733dc..5e47a11 100644 --- a/dev/contribute/index.html +++ b/dev/contribute/index.html @@ -1,2 +1,2 @@ -Contributing · Bessels.jl

Contributors Guide

Contributions of any kind are very welcome! Bessels.jl is a community-driven project and is under the JuliaMath organization. If you are interested in getting involved with the development of Bessels.jl please feel free to open an issue. In general, contributions will likely fall under four main categories:

1. Implementing a new function

Any Bessel type or related function is welcome for inclusion in this library. Please read the scope section for more details but in general any function listed here would be a good addition. Opening an issue would be a great start to further discuss a particular function or implementation details. If you already have an existing function ready to go please open a pull request. Porting functions from MIT compatible implementation is also acceptable.

In general, Bessels.jl aims to provide highly accurate implementations. We do not have a set error tolerance we are willing to accept as it will depend on the function. For example, the gamma function is a very important and widely used function so it is necessary to provide maximal errors less than 2 Units in the last place (ULP). For other functions, such as the Bessel function, which oscillate around zero it is much more difficult to provide such tight error tolerances. Therefore, relative tolerances better than 1e-14 would be a good target with a slightly less tolerance around the zeros. Single variable functions should be able to provide better tolerances than multi-variable functions.

Even if the function isn't quite to those error tolerances, please open a pull request to discuss further. It might be good for a single precision implementation or there might be opportunities to improve the errors of the existing implementation. Though, there are fairly strict criteria that the function should be non-allocating and type stable.

2. Improving existing function

Improving the accuracy or speed of any implementation would be a great contribution. There are plenty of opportunities so please open an issue if you are interested and we can point you to a good function to work with. Accuracy improvements are always welcome whereas any speed improvements would also need to maintain the current level of accuracy. Ideally, implementations could trend to more accurate and faster but there will always be some tradeoff.

3. Filing bug reports, writing tests, feature requests, improve documentation

Testing the accuracy and performance of each function is also welcome. In the future, we hope to have an automated way to print out the error and performance of each function so any help with this would be appreciated. Additionally, contributing better tests and writing documentation is very helpful. Filing feature requests are also very helpful.

4. Other miscellaneous contributions

Please also share any papers or discussions on implementation details!

Pull Requests

Contributions should be made via pull requests on GitHub. This can be done by forking Bessels.jl and making commits on your own fork. After you have made all necessary changes please submit a pull request against the main branch. We will then review and provide any feedback on the changes. Once you a submit a PR, the automated tests will run through CI. Therefore, please also include tests if you are implementing a new function and review the results of the CI run. We typically keep all tests passing on the main branch, so any CI failures are most likely related to the PR. By submitting a pull request, you are agreeing for contributed code to be under the MIT license.

Code Style: There is not an explicit code style that we use. Please try to keep it as consistent as possible with existing code.

+Contributing · Bessels.jl

Contributors Guide

Contributions of any kind are very welcome! Bessels.jl is a community-driven project and is under the JuliaMath organization. If you are interested in getting involved with the development of Bessels.jl please feel free to open an issue. In general, contributions will likely fall under four main categories:

1. Implementing a new function

Any Bessel type or related function is welcome for inclusion in this library. Please read the scope section for more details but in general any function listed here would be a good addition. Opening an issue would be a great start to further discuss a particular function or implementation details. If you already have an existing function ready to go please open a pull request. Porting functions from MIT compatible implementation is also acceptable.

In general, Bessels.jl aims to provide highly accurate implementations. We do not have a set error tolerance we are willing to accept as it will depend on the function. For example, the gamma function is a very important and widely used function so it is necessary to provide maximal errors less than 2 Units in the last place (ULP). For other functions, such as the Bessel function, which oscillate around zero it is much more difficult to provide such tight error tolerances. Therefore, relative tolerances better than 1e-14 would be a good target with a slightly less tolerance around the zeros. Single variable functions should be able to provide better tolerances than multi-variable functions.

Even if the function isn't quite to those error tolerances, please open a pull request to discuss further. It might be good for a single precision implementation or there might be opportunities to improve the errors of the existing implementation. Though, there are fairly strict criteria that the function should be non-allocating and type stable.

2. Improving existing function

Improving the accuracy or speed of any implementation would be a great contribution. There are plenty of opportunities so please open an issue if you are interested and we can point you to a good function to work with. Accuracy improvements are always welcome whereas any speed improvements would also need to maintain the current level of accuracy. Ideally, implementations could trend to more accurate and faster but there will always be some tradeoff.

3. Filing bug reports, writing tests, feature requests, improve documentation

Testing the accuracy and performance of each function is also welcome. In the future, we hope to have an automated way to print out the error and performance of each function so any help with this would be appreciated. Additionally, contributing better tests and writing documentation is very helpful. Filing feature requests are also very helpful.

4. Other miscellaneous contributions

Please also share any papers or discussions on implementation details!

Pull Requests

Contributions should be made via pull requests on GitHub. This can be done by forking Bessels.jl and making commits on your own fork. After you have made all necessary changes please submit a pull request against the main branch. We will then review and provide any feedback on the changes. Once you a submit a PR, the automated tests will run through CI. Therefore, please also include tests if you are implementing a new function and review the results of the CI run. We typically keep all tests passing on the main branch, so any CI failures are most likely related to the PR. By submitting a pull request, you are agreeing for contributed code to be under the MIT license.

Code Style: There is not an explicit code style that we use. Please try to keep it as consistent as possible with existing code.

diff --git a/dev/functions/index.html b/dev/functions/index.html index d548bd4..8b2f955 100644 --- a/dev/functions/index.html +++ b/dev/functions/index.html @@ -1,2 +1,2 @@ -Function list · Bessels.jl
+Function list · Bessels.jl
diff --git a/dev/index.html b/dev/index.html index c834c6f..a0d46cc 100644 --- a/dev/index.html +++ b/dev/index.html @@ -1,2 +1,2 @@ -Home · Bessels.jl

Bessels.jl

Introduction

Bessels.jl is a collection of mathematical algorithms to compute special functions written entirely in the Julia programming language. It is focused on providing high quality implementations of mathematical functions that are accurate and highly performant. Since it contains only Julia code and has no external dependencies, it is a lightweight package that can be used in any high performance application while taking advatnage of the dynamism of the Julia language.

Bessels.jl contains numerous definitions of special functions important in many fields of mathematical physics. Available functions include Bessel, Modified Bessel, Spherical Bessel, Airy, Hankel, and Gamma functions. A full list of available functions can be found in the API section of this documentation. Initial development has focused on providing implementations for real arguments, however, some functions (e.g., Airy) also accept complex numbers as input.

Scope

Bessels.jl started simply as a package to compute just the Bessel function of the first kind and zero order, but it has quickly grown to include several Bessel type functions. As mentioned earlier, Bessels.jl contains algorithms for computing Bessel, Modified Bessel, Spherical Bessel, Airy, and Hankel functions. These functions are contained in Chapters 9 and 10 of the NIST Digital Library of Mathematical Functions. However, there exists other types of related functions such as the Struve and Weber type functions contained in Chapters 11 and 12. In general, these are special cases of the confuent hypergeometric functions $_0F_1, _1F_1$, and $_1F_2$. Additionally, several other special functions such as the gamma functions are also needed to compute these types of functions.

Therefore, Bessels.jl seeks to be home to any Bessel or related functions (see the section provided by mpmath) which are typically contained in Chapters 9-12 of the NIST Digital library or to any other related function required to compute Bessel type functions.

Advantages

  • Typically 2-12x faster than other available implementations
  • Written entirely in Julia

Limitations

  • Does not yet support automatic differentiation
  • Limited support for complex arguments
  • No support for higher precision (above Float64)

Packages using Bessels.jl

If you are using Bessels.jl, please feel free to add yours to the list!

Julia packages

Other

This is by no means exhaustive so please add yours or any others that should be listed.

+Home · Bessels.jl

Bessels.jl

Introduction

Bessels.jl is a collection of mathematical algorithms to compute special functions written entirely in the Julia programming language. It is focused on providing high quality implementations of mathematical functions that are accurate and highly performant. Since it contains only Julia code and has no external dependencies, it is a lightweight package that can be used in any high performance application while taking advatnage of the dynamism of the Julia language.

Bessels.jl contains numerous definitions of special functions important in many fields of mathematical physics. Available functions include Bessel, Modified Bessel, Spherical Bessel, Airy, Hankel, and Gamma functions. A full list of available functions can be found in the API section of this documentation. Initial development has focused on providing implementations for real arguments, however, some functions (e.g., Airy) also accept complex numbers as input.

Scope

Bessels.jl started simply as a package to compute just the Bessel function of the first kind and zero order, but it has quickly grown to include several Bessel type functions. As mentioned earlier, Bessels.jl contains algorithms for computing Bessel, Modified Bessel, Spherical Bessel, Airy, and Hankel functions. These functions are contained in Chapters 9 and 10 of the NIST Digital Library of Mathematical Functions. However, there exists other types of related functions such as the Struve and Weber type functions contained in Chapters 11 and 12. In general, these are special cases of the confuent hypergeometric functions $_0F_1, _1F_1$, and $_1F_2$. Additionally, several other special functions such as the gamma functions are also needed to compute these types of functions.

Therefore, Bessels.jl seeks to be home to any Bessel or related functions (see the section provided by mpmath) which are typically contained in Chapters 9-12 of the NIST Digital library or to any other related function required to compute Bessel type functions.

Advantages

  • Typically 2-12x faster than other available implementations
  • Written entirely in Julia

Limitations

  • Does not yet support automatic differentiation
  • Limited support for complex arguments
  • No support for higher precision (above Float64)

Packages using Bessels.jl

If you are using Bessels.jl, please feel free to add yours to the list!

Julia packages

Other

This is by no means exhaustive so please add yours or any others that should be listed.

diff --git a/dev/install/index.html b/dev/install/index.html index 66ac73e..0bfdcbd 100644 --- a/dev/install/index.html +++ b/dev/install/index.html @@ -18,4 +18,4 @@ 0.6711327442643626 julia> besselj(1.8, 10.1) -0.2374319718222891 +0.2374319718222891 diff --git a/dev/roadmap/index.html b/dev/roadmap/index.html index 1e64a5d..1d1f5d0 100644 --- a/dev/roadmap/index.html +++ b/dev/roadmap/index.html @@ -1,2 +1,2 @@ -Roadmap · Bessels.jl

Bessels.jl Roadmap

The major development goals can be summarized by the following groups.

Support for complex arguments

The current development and immediate goals of this project is to provide support for complex variables in all the existing functions. Currently, the Airy functions airyai, airyaiprime, airybi, and airybiprime are the only supported functions using complex variables. This will be implemented in a step approach focusing on single argument functions with fixed order (e.g. $\nu=0, 1$) then expanded to the general case of arbitrary order. Therefore, current focus is on developing complex routines for besselj0(z), besselj1(z), bessely0(z), bessely1(z), besselk0(z), besselk1(z), besseli0(z), and besseli1(z).

Adding additional special functions

A nice list of Bessel and related functions is provided by mpmath. Any function listed there would be a good candidate for inclusion in this package. Functions on the current scope are the Kelvin, Struve, and Scorer type functions. If other functions (or the ones listed) are desired, please open an issue!

Develop higher precision routines

Current development has focused on single and double precision routine (Float32 and Float64). We intend to also provide support for higher precision types such as double-double (Double64) and/or quadruple (Float128) precision in the future.

Derivatives through automatic differentiation

Typically, the derivatives of certain special functions with respect to argument can be obtained through definitions. However, derivative with respect to the order usually does not have a simple expression. Automatic differentiation could be a powerful tool to quickly compute higher order derivatives using native Julia code. This is not an immediate goal but would be a welcome contribution.

Accuracy and Performance improvements

Speed improvements are beneficial in most cases as these low level functions are typically called many times. Performance gains can come from using better algorithms or through better support for parallelization (e.g., vectorization, SIMD). In general, any speed improvements will only be incorporated that maintain the current relative accuracy. Accuracy improvements may come at the cost of a slightly longer runtime. These type of improvements will come on a more ad-hoc basis.

+Roadmap · Bessels.jl

Bessels.jl Roadmap

The major development goals can be summarized by the following groups.

Support for complex arguments

The current development and immediate goals of this project is to provide support for complex variables in all the existing functions. Currently, the Airy functions airyai, airyaiprime, airybi, and airybiprime are the only supported functions using complex variables. This will be implemented in a step approach focusing on single argument functions with fixed order (e.g. $\nu=0, 1$) then expanded to the general case of arbitrary order. Therefore, current focus is on developing complex routines for besselj0(z), besselj1(z), bessely0(z), bessely1(z), besselk0(z), besselk1(z), besseli0(z), and besseli1(z).

Adding additional special functions

A nice list of Bessel and related functions is provided by mpmath. Any function listed there would be a good candidate for inclusion in this package. Functions on the current scope are the Kelvin, Struve, and Scorer type functions. If other functions (or the ones listed) are desired, please open an issue!

Develop higher precision routines

Current development has focused on single and double precision routine (Float32 and Float64). We intend to also provide support for higher precision types such as double-double (Double64) and/or quadruple (Float128) precision in the future.

Derivatives through automatic differentiation

Typically, the derivatives of certain special functions with respect to argument can be obtained through definitions. However, derivative with respect to the order usually does not have a simple expression. Automatic differentiation could be a powerful tool to quickly compute higher order derivatives using native Julia code. This is not an immediate goal but would be a welcome contribution.

Accuracy and Performance improvements

Speed improvements are beneficial in most cases as these low level functions are typically called many times. Performance gains can come from using better algorithms or through better support for parallelization (e.g., vectorization, SIMD). In general, any speed improvements will only be incorporated that maintain the current relative accuracy. Accuracy improvements may come at the cost of a slightly longer runtime. These type of improvements will come on a more ad-hoc basis.

diff --git a/dev/search/index.html b/dev/search/index.html index e2896cf..2dadf09 100644 --- a/dev/search/index.html +++ b/dev/search/index.html @@ -1,2 +1,2 @@ -Search · Bessels.jl

Loading search...

    +Search · Bessels.jl

    Loading search...