Method of separation of variables
We now turn our attention to the classes of linear PDEs outlined above, namely Eqs. (2.78)-(2.80). In all cases (and subject to specific boundary conditions) we assume that the solution is separable. For example, the solution for Eq. (2.78) can be expressed as the product of a -dependent function and a -dependent function:
where is only a function of the spatial variable, and is only a function of the temporal variable, .
Boundary/initial conditions
In situations where we look for transient solutions (like, for example, in solving the heat equation [see Eq. (2.79) ]), we are interested in knowing how the temperature, which we denote by varies in the spatial domain, for all time, ; the task of solving a PDE is usually referred to as an initial-boundaryvalue problem (IBVP). Equation (2.79), is first order in time and second order in space; we therefore need one initial condition describing the solution at all values of and at and two boundary conditions, describing the solution at all values of and at two, distinct points in . Generally, we expect the solution to a PDE to be separable if the PDE is linear and homogeneous (here, homogeneity refers to both the equation and the BCs). It is possible in some cases, to transform inhomogeneous BCs to homogeneous ones such that the transformed problem can be solved using the method of separation of variables. The physical problems we consider are subject to types of boundary conditions we have seen in Subsec. 2.3.2. we discuss them again here in the context of PDEs:
Dirichlet BCs represent the function at two distinct points in space, say , where and hold true for all values of
Neumann BCs represent the derivative of the function at two distinct points in space, say (where, again, ) and hold true for all values of
For Periodic BCs, at the boundaries, the conditions on the function and the derivative match each other:
In Eqs. (2.108) and (2.109) are constants. Recall that the BCs are said to be homogeneous if .
The 1D heat equation
Next, we outline the method of separation of variables; we use the 1D heat equation as an example but the method may be applied to equations like the ones given in (2.78)-(2.80) . The problem statement is given as follows: the heat equation is given by:
where represents the temperature in a thin rod as it varies with space, and time, . The thin rod is of length and so the interval of interest is . At the two boundaries, the temperature of the rod is fixed at 0 , so we have:
and, initially, at , the temperature distribution is given by a function . Mathematically, this is expressed as:
Algorithmic approach
- Motivated by the homogeneity of the boundary conditions, we assume the solution to the PDE is separable, i.e.,
where and are unknown functions to be determined;
- Differentiate (2.114), substitute the derivatives in Eq. (2.111) and separate the variables:
- Since the LHS of Eq.(2.115) is independent of and the RHS is independent of , the two sides can only be equal to a function that is independent of both and , i.e. a constant, which we set to . Next, we separate into two ODEs:
We now have 2 ODEs from which we can form an initial-value problem and a boundary-value problem. The IVP consists of Eq. (2.116) and an initial condition. Note this is a first order ODE for and we will require a condition for at ( is usually equal to 0 for physical problems, e.g. this time could mark the start of an experimental run). The BVP consists of Eq. (2.117) and two boundary conditions. This is a second order ODE and we will require conditions for at two different boundary values for . Note also the negative sign in . This allows the BVP given by Eq. (2.117) to be expressed in the form encountered in Subsec. 2.3.2,
- Now we essentially have 3 unknowns we need to solve for: the functions and the eigenvalue . We can use our knowledge of BVPs (see Subsec. 2.3.2) to determine the admissible form for the eigenvalues and thus find the corresponding eigenfunctions given by . find . Recall that eigenvalues exist for nontrivial (i.e. nonzero) eigenfunctions.
- Since Eq. (2.117) is a second order ODE for , we require two BCs in . These are given by Eq. (2.112) for the two-variable function .
- To transform the BCs, use the separated solution (2.114) evaluated at and (i.e. at the two ends). At , we have:
Now, Eq. (2.118) suggests that either or . Note that if is zero, it is zero for all values of which would the imply that the form of the suggested solution (2.114) is trivial. We therefore set which means that . With a similar argument, . So the appropriate BCs for Eq. (2.117) are and .
- Solving the BVP (ODE + BCs) gives and the corresponding eigenfunctions are: where, again, .
- Note that are not eigenvalues of the BVP.
- Next, we determine the form of the other separated function [i.e. ] using the eigenvalues, , from step 4 .
- Equation (2.116) is a first order separable ODE for :
- Solving (2.119), gives with .
- Now, we have and which we use to find a general solution for using the suggested solution in step 1 given by .
- Due to the linearity of the PDE and the orthogonality of eigenfunctions corresponding to distinct eigenvalues, we may sum across all solutions (for each ) to form a series representation of the solution,
- Determine the coefficients, in the series representation using the initial condition given at [given by (2.113)] and by making use of orthogonality properties (see Topic B1 on Fourier series).