ellipke

Complete elliptic integrals of the first and second kind.

Category: Mathematics > Elementary Math

Syntax

K = ellipke(m)

Returns the complete elliptic integral of the first kind.

[K, E] = ellipke(m)

Also returns the integral of the second kind.

Description

At m = 0 both integrals equal pi/2. As m approaches 1, K grows without bound (K(1) is Inf) while E decreases to 1. These integrals give the period of a pendulum with large amplitude and the perimeter of an ellipse.

Input arguments

m
Parameter, 0 <= m <= 1 (the square of the modulus).

Output arguments

K
K(m), the integral of 1/sqrt(1 - m*sin(t)^2) for t from 0 to pi/2.
E
E(m), the integral of sqrt(1 - m*sin(t)^2) over the same range.

Example

Elliptic integrals

[k, e] = ellipke(0.5)
ellipke([0 0.5 1])
Output
k = 1.8541
e = 1.3506
ans = 1×3

    1.5708    1.8541       Inf

See also

ellipj legendre integral beta