Kalpana Kalpana (Editor)

Separation of variables

Updated on
Edit
Like
Comment
Share on FacebookTweet on TwitterShare on LinkedInShare on Reddit
Separation of variables

In mathematics, separation of variables (also known as the Fourier method) is any of several methods for solving ordinary and partial differential equations, in which algebra allows one to rewrite an equation so that each of two variables occurs on a different side of the equation.

Contents

Ordinary differential equations (ODE)

Suppose a differential equation can be written in the form

d d x f ( x ) = g ( x ) h ( f ( x ) )

which we can write more simply by letting y = f ( x ) :

d y d x = g ( x ) h ( y ) .

As long as h(y) ≠ 0, we can rearrange terms to obtain:

d y h ( y ) = g ( x ) d x ,

so that the two variables x and y have been separated. dx (and dy) can be viewed, at a simple level, as just a convenient notation, which provides a handy mnemonic aid for assisting with manipulations. A formal definition of dx as a differential (infinitesimal) is somewhat advanced.

Alternative notation

Some who dislike Leibniz's notation may prefer to write this as

1 h ( y ) d y d x = g ( x ) ,

but that fails to make it quite as obvious why this is called "separation of variables". Integrating both sides of the equation with respect to x , we have

1 h ( y ) d y d x d x = g ( x ) d x , ( 1 )

or equivalently,

1 h ( y ) d y = g ( x ) d x

because of the substitution rule for integrals.

If one can evaluate the two integrals, one can find a solution to the differential equation. Observe that this process effectively allows us to treat the derivative d y d x as a fraction which can be separated. This allows us to solve separable differential equations more conveniently, as demonstrated in the example below.

(Note that we do not need to use two constants of integration, in equation (1) as in

1 h ( y ) d y + C 1 = g ( x ) d x + C 2 ,

because a single constant C = C 2 C 1 is equivalent.)

Example

Population growth is often modeled by the differential equation

d P d t = k P ( 1 P K )

where P is the population with respect to time t , k is the rate of growth, and K is the carrying capacity of the environment.

Separation of variables may be used to solve this differential equation.

d P d t = k P ( 1 P K ) d P P ( 1 P K ) = k d t

To evaluate the integral on the left side, we simplify the fraction

1 P ( 1 P K ) = K P ( K P )

and then, we decompose the fraction into partial fractions

K P ( K P ) = 1 P + 1 K P

Thus we have

( 1 P + 1 K P ) d P = k d t ln | P | ln | K P | = k t + C ln | K P | ln | P | = k t C ln | K P P | = k t C | K P P | = e k t C | K P P | = e C e k t K P P = ± e C e k t Let  A = ± e C . K P P = A e k t K P 1 = A e k t K P = 1 + A e k t P K = 1 1 + A e k t P = K 1 + A e k t

Therefore, the solution to the logistic equation is

P ( t ) = K 1 + A e k t

To find A , let t = 0 and P ( 0 ) = P 0 . Then we have

P 0 = K 1 + A e 0

Noting that e 0 = 1 , and solving for A we get

A = K P 0 P 0 .

Partial differential equations

The method of separation of variables is also used to solve a wide range of linear partial differential equations with boundary and initial conditions, such as the heat equation, wave equation, Laplace equation, Helmholtz equation and biharmonic equation.

Example: homogeneous case

Consider the one-dimensional heat equation. The equation is

The boundary condition is homogeneous, that is

Let us attempt to find a solution which is not identically zero satisfying the boundary conditions but with the following property: u is a product in which the dependence of u on x, t is separated, that is:

Substituting u back into equation (1) and using the product rule,

Since the right hand side depends only on x and the left hand side only on t, both sides are equal to some constant value − λ. Thus:

and

− λ here is the eigenvalue for both differential operators, and T(t) and X(x) are corresponding eigenfunctions.

We will now show that solutions for X(x) for values of λ ≤ 0 cannot occur:

Suppose that λ < 0. Then there exist real numbers B, C such that

X ( x ) = B e λ x + C e λ x .

From (2) we get

and therefore B = 0 = C which implies u is identically 0.

Suppose that λ = 0. Then there exist real numbers B, C such that

X ( x ) = B x + C .

From (7) we conclude in the same manner as in 1 that u is identically 0.

Therefore, it must be the case that λ > 0. Then there exist real numbers A, B, C such that

T ( t ) = A e λ α t ,

and

X ( x ) = B sin ( λ x ) + C cos ( λ x ) .

From (7) we get C = 0 and that for some positive integer n,

λ = n π L .

This solves the heat equation in the special case that the dependence of u has the special form of (3).

In general, the sum of solutions to (1) which satisfy the boundary conditions (2) also satisfies (1) and (3). Hence a complete solution can be given as

u ( x , t ) = n = 1 D n sin n π x L exp ( n 2 π 2 α t L 2 ) ,

where Dn are coefficients determined by initial condition.

Given the initial condition

u | t = 0 = f ( x ) ,

we can get

f ( x ) = n = 1 D n sin n π x L .

This is the sine series expansion of f(x). Multiplying both sides with sin n π x L and integrating over [0,L] result in

D n = 2 L 0 L f ( x ) sin n π x L d x .

This method requires that the eigenfunctions of x, here { sin n π x L } n = 1 , are orthogonal and complete. In general this is guaranteed by Sturm-Liouville theory.

Example: nonhomogeneous case

Suppose the equation is nonhomogeneous,

with the boundary condition the same as (2).

Expand h(x,t), u(x,t) and f(x) into

where hn(t) and bn can be calculated by integration, while un(t) is to be determined.

Substitute (9) and (10) back to (8) and considering the orthogonality of sine functions we get

u n ( t ) + α n 2 π 2 L 2 u n ( t ) = h n ( t ) ,

which are a sequence of linear differential equations that can be readily solved with, for instance, Laplace transform, or Integrating factor. Finally, we can get

u n ( t ) = e α n 2 π 2 L 2 t ( b n + 0 t h n ( s ) e α n 2 π 2 L 2 s d s ) .

If the boundary condition is nonhomogeneous, then the expansion of (9) and (10) is no longer valid. One has to find a function v that satisfies the boundary condition only, and subtract it from u. The function u-v then satisfies homogeneous boundary condition, and can be solved with the above method.

Example: mixed derivatives

For some equations involving mixed derivatives, the equation does not separate as easily as the heat equation did in the first example above, but nonetheless separation of variables may still be applied. Consider the two-dimensional biharmonic equation

4 u x 4 + 2 4 u x 2 y 2 + 4 u y 4 = 0.

Proceeding in the usual manner, we look for solutions of the form

u ( x , y ) = X ( x ) Y ( y )

and we obtain the equation

X ( 4 ) ( x ) X ( x ) + 2 X ( x ) X ( x ) Y ( y ) Y ( y ) + Y ( 4 ) ( y ) Y ( y ) = 0.

Writing this equation in the form

E ( x ) + F ( x ) G ( y ) + H ( y ) = 0 ,

we see that the derivative with respect to x and y eliminates the first and last terms, so that

F ( x ) G ( y ) = 0 ,

i.e. either F(x) or G(y) must be a constant, say -λ. This further implies that either E ( x ) = F ( x ) G ( y ) + H ( y ) or H ( y ) = E ( x ) + F ( x ) G ( y ) are constant. Returning to the equation for X and Y, we have two cases

X ( x ) = λ 1 X ( x ) X ( 4 ) ( x ) = μ 1 X ( x ) Y ( 4 ) ( y ) 2 λ 1 Y ( y ) = μ 1 Y ( y )

and

Y ( y ) = λ 2 Y ( y ) Y ( 4 ) ( y ) = μ 2 Y ( y ) X ( 4 ) ( x ) 2 λ 2 X ( x ) = μ 2 X ( x )

which can each be solved by considering the separate cases for λ i < 0 , λ i = 0 , λ i > 0 and noting that μ i = λ i 2 .

Curvilinear coordinates

In orthogonal curvilinear coordinates, separation of variables can still be used, but in some details different from that in Cartesian coordinates. For instance, regularity or periodic condition may determine the eigenvalues in place of boundary conditions. See spherical harmonics for example.

Matrices

The matrix form of the separation of variables is the Kronecker sum.

As an example we consider the 2D discrete Laplacian on a regular grid:

L = D x x D y y = D x x I + I D y y ,

where D x x and D y y are 1D discrete Laplacians in the x- and y-directions, correspondingly, and I are the identities of appropriate sizes. See the main article Kronecker sum of discrete Laplacians for details.

References

Separation of variables Wikipedia