Skip to content

ellipticK

specfun · scripts/specfun/ellipticK.m

: K = ellipticK (m)

Complete elliptic integral of the first kind K(m).

For each element of m,

K(m) = F(pi/2 | m) = integral from 0 to pi/2 of (1 - m*sin(theta)^2)^(-1/2) dtheta

Numeric inputs that are not symbolic objects return floating-point results (MATLAB Symbolic Math Toolbox numeric path). Real m with m <= 1 stays real; m > 1 uses the complex analytic continuation. Empty, NaN/Inf, and single inputs preserve size / IEEE / class as in MATLAB.