Separation of Variables in Cartesian Coordinates

Separation of variables is the oldest analytic method for solving linear partial differential equations, and on a rectangular domain it is embarrassingly effective. The premise is one bold guess: a solution that factorizes, u(x,y,z,t)=X(x) Y(y) Z(z) T(t)u(x,y,z,t)=X(x)\,Y(y)\,Z(z)\,T(t), each factor depending on a single coordinate. When the operator is a sum of one-variable operators — as the Cartesian Laplacian ∂x2+∂y2+∂z2\partial_x^2+\partial_y^2+\partial_z^2 is — and the boundary is a coordinate surface — as the faces of a box are — that guess pays off: substituting and dividing through collapses one PDE in several variables into several ordinary differential equations, coupled only through constants of separation. Those constants are not free. The homogeneous boundary conditions quantize them into a discrete spectrum kn=nπ/Lk_n=n\pi/L, turning each ODE into a Sturm–Liouville eigenvalue problem whose eigenfunctions are orthogonal and complete. In Cartesian coordinates the ODEs have constant coefficients, so the eigenfunctions are elementary — sines, cosines, real exponentials, hyperbolic functions, and, at the degenerate constant, straight lines. Superposition rebuilds the answer: any sum of product modes still solves the PDE, and completeness lets the leftover inhomogeneous datum be matched, term by term, through orthogonality. The workflow is identical for Laplace, heat, wave, and Helmholtz on a box: classify, assign homogeneous conditions to the oscillating coordinates, separate, quantize, superpose, project. It is not universal — cross-derivatives, non-additive variable coefficients, and non-coordinate boundaries all defeat it — but where it works it returns exact closed-form answers and the system's spectral fingerprint: its normal modes, resonant frequencies, and decay rates.

Key takeaways
  • Separation of variables seeks a linear PDE's solution in product form u=X(x)Y(y)Z(z)T(t)u=X(x)Y(y)Z(z)T(t), converting one PDE in several variables into several coupled ordinary differential equations.
  • On a Cartesian box the spatial ODEs are constant-coefficient, so eigenfunctions are trigonometric, exponential, or hyperbolic — the special functions of curvilinear geometry never appear.
  • Homogeneous boundary conditions turn each ODE into a Sturm–Liouville problem; the separation constants form a discrete spectrum kn=nπ/Lk_n=n\pi/L and the eigenfunctions an orthogonal, complete basis.
  • The general solution is a Fourier-type superposition of product modes; the coefficients are fixed by the remaining inhomogeneous datum through orthogonality, one integral per mode.
  • The sign of each separation constant is not free: directions with homogeneous data must oscillate (sine/cosine); the direction carrying inhomogeneous data grows or decays (sinh/cosh).
  • The same scaffolding solves Laplace, heat, wave, and Helmholtz on boxes, and generalizes to cylinders and spheres where the ODEs become Bessel's and Legendre's.
  • Key idea: If a linear operator L=Lx+Ly+⋯\mathcal{L}=\mathcal{L}_x+\mathcal{L}_y+\cdots is a sum of single-variable pieces and the domain is a coordinate box, a product ansatz u=X(x)Y(y)⋯u=X(x)Y(y)\cdots turns Lu=0\mathcal{L}u=0 into the statement that a sum of functions of distinct variables is constant — forcing each piece to a constant and splitting the PDE into decoupled ODE eigenvalue problems.
The core insight

If a linear operator L=Lx+Ly+⋯\mathcal{L}=\mathcal{L}_x+\mathcal{L}_y+\cdots is a sum of single-variable pieces and the domain is a coordinate box, then a product ansatz u=X(x)Y(y)⋯u=X(x)Y(y)\cdots turns Lu=0\mathcal{L}u=0 into the statement that a sum of functions of distinct variables is constant — forcing each piece to equal a constant and splitting the PDE into decoupled ODE eigenvalue problems.

Where this lives today

The Cartesian-box calculation is the analytic backbone of several billion-dollar technologies. Semiconductor quantum wells and dots — the light-emitting layers of LEDs, diode lasers, and QLED displays — are engineered by choosing box dimensions so the particle-in-a-box gap of Example 1 lands on a target colour; a CdSe dot's emission is tuned across the visible by growing it a nanometre larger or smaller. In thermal engineering, the transient-conduction series of Example 2 (the Heisler charts) still sizes heat sinks and predicts how fast a microprocessor die reaches steady state. Rectangular microwave cavities and waveguides — the plumbing of radar, satellite links, and 5G — are specified entirely by their TEmn\mathrm{TE}_{mn} and TMmn\mathrm{TM}_{mn} mode charts, with cutoff frequencies read from equation (7). And numerically, spectral PDE solvers — workhorses of climate and turbulence simulation — expand the field in exactly these eigenfunctions, because box separation diagonalizes the Laplacian into a fast, FFT-decoupled algebraic system. An open frontier is the non-clean box: near a re-entrant corner or material interface the naive series develops singular gradients, and stitching solutions across sub-domains (spectral-element methods) remains active research.

The physical picture

Strike a rectangular drumhead and its complicated motion resolves instantly into a chord of pure standing-wave patterns, each at one frequency. Separation of variables is the precise statement that these patterns factorize: the spatial shape is a product sin⁡(mπx/Lx)sin⁡(nπy/Ly)\sin(m\pi x/L_x)\sin(n\pi y/L_y), the time dependence a single cos⁡(ωmnt)\cos(\omega_{mn}t), and the PDE binding space to time dissolves, for each pattern, into independent harmonic-oscillator equations. The first figure shows the lowest three modes of a square drum with the frequencies you would measure — and that the overtones are not integer multiples of the fundamental (a rectangular membrane is inharmonic, unlike a string).

Figure
Normal modes of a square membrane factorize as sin(mπx/L) sin(nπy/L): for a drum of side L = 0.30 m with wave speed c = 100 m/s the eigenfrequencies f_mn = (c/2L)√(m²+n²) are f₁₁ = 235.7 Hz, f₂₁ = 372.7 Hz and f₂₂ = 471.4 Hz, so the first overtone sits at the irrational ratio f₂₁/f₁₁ = √(5/2) = 1.58 and the drum is inharmonic
Modes of a square membrane: sin(mπx/L) sin(nπy/L), fanned into ± lobes by nodal lines + (1,1) f = 235.7 Hz + − (2,1) f = 372.7 Hz (2,2) f = 471.4 Hz f_mn = (c/2L)√(m²+n²), c = 100 m/s, L = 0.30 m → f₂₁/f₁₁ = √(5/2) = 1.58 (inharmonic)

The algebraic engine is the "function of xx equals function of yy" argument. Divide the separated equation by the product and you reach f(x)=−g(y)f(x)=-g(y): the left ignores yy, the right ignores xx, yet they are equal everywhere. The only way that holds is for both to be the same constant — one per coordinate, the seam that later stitches the ODEs back into a solution. The second figure shows the consequence: the conditions X(0)=X(L)=0X(0)=X(L)=0 admit only the ladder kn=nπ/Lk_n=n\pi/L, whose rungs are sine eigenfunctions with a growing count of interior nodes.

Figure
The separation mechanism and its spectrum: dividing Lu = 0 by the product forces X″/X = −Y″/Y = −k², a function of x equal to a function of y, so both equal one constant; imposing X(0) = X(L) = 0 quantizes it into the ladder k_n = nπ/L, whose eigenfunctions sin(nπx/L) are shown for n = 1, 2, 3 with 0, 1, 2 interior nodes
X″/X = −Y″/Y = −k² ⇒ each side a constant ⇒ X(0)=X(L)=0 quantizes k_n = nπ/L depends on x only depends on y only k₁ = π/L k₂ = 2π/L k₃ = 3π/L x = 0 x = L

Why constant coefficients matter is worth naming: the Cartesian Laplacian has no coordinate-dependent prefactors, so each separated ODE is simply X′′=λXX''=\lambda X, solvable by inspection. The moment a curvilinear metric introduces variable coefficients those ODEs become Bessel's and Legendre's equations — the whole zoo of special functions — so Cartesian separation is the clean base case all of that is measured against.

The core equations

The whole method rests on one substitution and one observation. The product ansatz guesses that the field factorizes into single-coordinate functions, so an operator built from single-variable pieces acts on each factor in turn.

Lu=0,u(x,y,z,t)=X(x) Y(y) Z(z) T(t)(1)\mathcal{L}u=0,\qquad u(x,y,z,t)=X(x)\,Y(y)\,Z(z)\,T(t) \qquad (1)

where: L\mathcal{L} — a linear operator that is a sum of single-variable operators; uu — the unknown field (displacement, temperature, potential, ...); X,Y,Z,TX,Y,Z,T — functions each of a single coordinate. This restrictive guess pays off exactly when L\mathcal{L} and the domain both respect the coordinate split. Substituting the ansatz into ∇2u=0\nabla^2u=0 and dividing by u=XYZu=XYZ gives the separated form — three terms, each a function of a different coordinate, adding to zero.

X′′X+Y′′Y+Z′′Z=0(2)\frac{X''}{X}+\frac{Y''}{Y}+\frac{Z''}{Z}=0 \qquad (2)

where: X′′X'' — second derivative of XX with respect to its single argument, likewise Y′′,Z′′Y'',Z''. Since the terms depend on independent variables yet sum to a fixed number, each is forced constant — the crux of the method. Fixing those constants is the one physical choice: two are taken negative so their directions oscillate, and the third is fixed by the sum-to-zero constraint (hyperbolic).

X′′X=−kx2,Y′′Y=−ky2,Z′′Z=+κ2,κ2=kx2+ky2(3)\frac{X''}{X}=-k_x^2,\quad\frac{Y''}{Y}=-k_y^2,\quad\frac{Z''}{Z}=+\kappa^2,\quad \kappa^2=k_x^2+k_y^2 \qquad (3)

where: kx,kyk_x,k_y — real wavenumbers for the oscillatory directions; κ\kappa — the dependent constant. At least one direction must carry the opposite sign — you cannot make all three oscillate under Laplace's equation. Homogeneous Dirichlet conditions on an oscillatory direction select a discrete set of allowed wavenumbers.

Xn(x)=sin⁡ ⁣(nπxL),kn=nπL,n=1,2,3,…(4)X_n(x)=\sin\!\left(\frac{n\pi x}{L}\right),\qquad k_n=\frac{n\pi}{L},\quad n=1,2,3,\dots \qquad (4)

where: LL — domain length in xx; nn — positive integer mode number. The boundary conditions, not the equation, make the spectrum discrete — continuous kk is cut to the ladder nπ/Ln\pi/L. These eigenfunctions are mutually orthogonal over the interval — the property that makes superposition solvable.

∫0Lsin⁡ ⁣(mπxL)sin⁡ ⁣(nπxL)dx=L2 δmn(5)\int_0^L \sin\!\left(\frac{m\pi x}{L}\right)\sin\!\left(\frac{n\pi x}{L}\right)\mathrm{d}x=\frac{L}{2}\,\delta_{mn} \qquad (5)

where: δmn\delta_{mn} — Kronecker delta, 11 if m=nm=n and 00 otherwise. Distinct modes are perpendicular, so each coefficient comes from its own integral. Applied to the heat equation on a slab held cold at both ends, the method yields a series in which every mode carries its own exponential decay, with coefficients read from the initial data by orthogonality.

u(x,t)=∑n=1∞bn sin⁡ ⁣(nπxL)e−α(nπ/L)2t,bn=2L∫0Lf(x) sin⁡ ⁣(nπxL)dx(6)u(x,t)=\sum_{n=1}^{\infty} b_n\,\sin\!\left(\frac{n\pi x}{L}\right)e^{-\alpha (n\pi/L)^2 t},\qquad b_n=\frac{2}{L}\int_0^L f(x)\,\sin\!\left(\frac{n\pi x}{L}\right)\mathrm{d}x \qquad (6)

where: α\alpha — thermal diffusivity; bnb_n — Fourier sine coefficients; f(x)f(x) — initial profile u(x,0)u(x,0). The decay rate scales as n2n^2, so fine structure is erased fastest. For the wave equation on a rectangle the same construction returns the standing-wave frequencies of a membrane.

ωmn=c π(mLx)2+(nLy)2(7)\omega_{mn}=c\,\pi\sqrt{\left(\frac{m}{L_x}\right)^2+\left(\frac{n}{L_y}\right)^2} \qquad (7)

where: cc — wave speed; Lx,LyL_x,L_y — side lengths; m,nm,n — mode numbers. A square root of a sum of squares is generally incommensurate — a rectangular drum has no harmonic series, so it thuds rather than sings.

Derivation ASeparating Laplace's equation on a rectangular box

The goal is to justify, without hand-waving, the single move everything depends on: that substituting a product into a sum-of-one-variable-operators PDE genuinely decouples it into ordinary differential equations. Starting from ∇2u=0\nabla^2u=0 with u=X(x)Y(y)Z(z)u=X(x)Y(y)Z(z), we do the substitution and division explicitly, run the constancy argument, and read off the three ODEs and the constraint tying their constants — the template the heat and wave derivations then instantiate.

Step 1. Insert u=XYZu=XYZ into ∇2u=∂x2u+∂y2u+∂z2u=0\nabla^2u=\partial_x^2u+\partial_y^2u+\partial_z^2u=0. Because YY and ZZ are constants as far as ∂x\partial_x is concerned, ∂x2(XYZ)=X′′YZ\partial_x^2(XYZ)=X''YZ, and likewise for the other two terms, giving X′′YZ+XY′′Z+XYZ′′=0X''YZ+XY''Z+XYZ''=0. Why: each Cartesian second derivative reaches only its own factor, which is exactly the structural property "operator is a sum of single-variable pieces" doing its work.

Step 2. Divide by u=XYZu=XYZ (legitimate wherever u≠0u\neq0) to obtain X′′/X+Y′′/Y+Z′′/Z=0X''/X+Y''/Y+Z''/Z=0; each term now depends on one coordinate only. Why: division converts a product structure into an additive one, and additivity lets the coordinates be argued about independently.

Step 3. Run the constancy argument. Hold y,zy,z fixed and vary xx: Y′′/YY''/Y and Z′′/ZZ''/Z cannot change and their sum is fixed, so X′′/XX''/X cannot change either — it is a constant. Repeating per coordinate, all three ratios are constants, say −kx2-k_x^2, −ky2-k_y^2, +κ2+\kappa^2. Why: this is exactly how "a function of xx equals a function of yy" forces constancy — differentiating in one variable annihilates the others.

Step 4. Impose the constraint. The three constants must sum to zero, so κ2=kx2+ky2\kappa^2=k_x^2+k_y^2: two directions may be chosen oscillatory but the third is then determined and hyperbolic, leaving three ODEs X′′+kx2X=0X''+k_x^2X=0, Y′′+ky2Y=0Y''+k_y^2Y=0, Z′′−κ2Z=0Z''-\kappa^2Z=0. Why: this is the sign rule — Laplace forbids all directions oscillating at once, so exactly one must grow or decay, and the data decide which.

Go deeper · Derivation B · 1 minThe heat equation on a finite rod
Derivation BThe heat equation on a finite rod

The aim is to build, end to end, the exact solution of the one-dimensional diffusion equation on a segment held at zero at both ends from an arbitrary start — the cleanest example of separation, quantization, superposition, and coefficient projection together. We solve ut=αuxxu_t=\alpha u_{xx} on 0<x<L0<x<L with u(0,t)=u(L,t)=0u(0,t)=u(L,t)=0 and u(x,0)=f(x)u(x,0)=f(x); every ingredient is forced by the data, and the boxed result is the master formula every transient-conduction calculation specializes.

u(x,t)=∑n=1∞[2L∫0Lf(ξ)sin⁡nπξL dξ]sin⁡nπxL  e−α(nπ/L)2t(Diffusion on a rod)u(x,t)=\sum_{n=1}^{\infty}\left[\frac{2}{L}\int_0^L f(\xi)\sin\frac{n\pi\xi}{L}\,\mathrm{d}\xi\right]\sin\frac{n\pi x}{L}\;e^{-\alpha(n\pi/L)^2 t} \qquad \text{(Diffusion on a rod)}

Step 1. Take the product ansatz u(x,t)=X(x)T(t)u(x,t)=X(x)T(t) and substitute, giving XT′=αX′′TXT'=\alpha X''T. Why: the heat operator ∂t−α∂x2\partial_t-\alpha\partial_x^2 is a sum of a pure-tt and a pure-xx piece, so the product guess is licensed exactly as in the Laplace template.

Step 2. Divide by αXT\alpha XT to separate: T′/(αT)=X′′/X=−λT'/(\alpha T)=X''/X=-\lambda, a single constant. The sign −λ-\lambda (with λ>0\lambda>0 to be confirmed) anticipates spatial oscillation and temporal decay. Why: the sign is a prediction that the boundary data will demand a decaying, oscillatory solution, not a growing one.

Step 3. Solve the spatial problem X′′+λX=0X''+\lambda X=0 with X(0)=X(L)=0X(0)=X(L)=0. Only λ=kn2=(nπ/L)2\lambda=k_n^2=(n\pi/L)^2 gives nontrivial Xn=sin⁡(nπx/L)X_n=\sin(n\pi x/L); negative λ\lambda would give hyperbolic functions, which cannot vanish at two points. Why: this is the Sturm–Liouville content — the two-end conditions quantize λ\lambda and hand back an orthogonal basis.

Step 4. Solve T′=−αλTT'=-\alpha\lambda T for each eigenvalue, giving Tn(t)=e−αkn2tT_n(t)=e^{-\alpha k_n^2 t}; each mode relaxes at its own rate, quadratic in nn. Why: the Step-2 sign is now vindicated — that heat must dissipate, not amplify, makes λ>0\lambda>0 the admissible branch.

Step 5. Superpose. By linearity any sum u=∑nbnsin⁡(nπx/L) e−αkn2tu=\sum_n b_n\sin(n\pi x/L)\,e^{-\alpha k_n^2 t} still solves the PDE and boundary conditions. Why: a single mode cannot match arbitrary initial data, but an infinite combination can — superposition is the second pillar after separation.

Step 6. Fit the data. Setting t=0t=0 demands f(x)=∑nbnsin⁡(nπx/L)f(x)=\sum_n b_n\sin(n\pi x/L); projecting against sin⁡(nπx/L)\sin(n\pi x/L) with orthogonality (5) isolates bn=(2/L)∫0Lf(ξ)sin⁡(nπξ/L) dξb_n=(2/L)\int_0^L f(\xi)\sin(n\pi\xi/L)\,\mathrm{d}\xi. Why: orthogonality decouples the infinitely many coefficients into one integral apiece — without it the bnb_n would be an unsolvable coupled system. Check: at t=0t=0 the series is the half-range Fourier sine expansion of ff, and termwise ∂te−αkn2tsin⁡(knx)=α ∂x2 ⁣[e−αkn2tsin⁡(knx)]\partial_t e^{-\alpha k_n^2 t}\sin(k_nx)=\alpha\,\partial_x^2\!\left[e^{-\alpha k_n^2 t}\sin(k_nx)\right], so the PDE holds.

Go deeper · Derivation C · 1 minLaplace's equation on a rectangle with one live face
Derivation CLaplace's equation on a rectangle with one live face

The purpose is to show how the same machinery handles a boundary-value problem in two dimensions, where the subtle step is not the separation but the assignment of signs — which coordinate oscillates and which grows hyperbolically. We solve uxx+uyy=0u_{xx}+u_{yy}=0 on 0<x<a0<x<a, 0<y<b0<y<b with three grounded sides u(0,y)=u(a,y)=u(x,0)=0u(0,y)=u(a,y)=u(x,0)=0 and one live face u(x,b)=V(x)u(x,b)=V(x) — the electrostatics-in-a-box archetype for every rectangular potential problem.

u(x,y)=∑n=1∞cn sinh⁡(nπy/a)sinh⁡(nπb/a) sin⁡nπxa,cn=2a∫0aV(ξ)sin⁡nπξa dξ(Dirichlet box)u(x,y)=\sum_{n=1}^{\infty}c_n\,\frac{\sinh(n\pi y/a)}{\sinh(n\pi b/a)}\,\sin\frac{n\pi x}{a},\qquad c_n=\frac{2}{a}\int_0^a V(\xi)\sin\frac{n\pi\xi}{a}\,\mathrm{d}\xi \qquad \text{(Dirichlet box)}

Step 1. Assign the signs by counting homogeneous faces. The xx-direction carries two homogeneous conditions (x=0x=0 and x=ax=a), so it must be the oscillatory one; the yy-direction carries the single inhomogeneous datum at y=by=b, so it must be hyperbolic. Why: only a sine can vanish at two distinct points and still be nontrivial, so a direction with two zero-faces is forced to oscillate — get this backwards and the expansion collapses to zero.

Step 2. Separate with the chosen signs: X′′/X=−k2X''/X=-k^2 and Y′′/Y=+k2Y''/Y=+k^2, which sum to zero as Laplace's equation requires. Why: the constraint κ2=kx2\kappa^2=k_x^2 from the box template here reads simply ky2=kx2k_y^2=k_x^2, tying the hyperbolic rate to the oscillatory wavenumber.

Step 3. Quantize xx using X(0)=X(a)=0X(0)=X(a)=0, giving Xn=sin⁡(nπx/a)X_n=\sin(n\pi x/a) with kn=nπ/ak_n=n\pi/a. Why: same Sturm–Liouville quantization as the rod — two grounded walls select the discrete sine ladder.

Step 4. Solve Y′′−kn2Y=0Y''-k_n^2Y=0, whose solution Acosh⁡(kny)+Bsinh⁡(kny)A\cosh(k_ny)+B\sinh(k_ny) is pinned by u(x,0)=0u(x,0)=0: at y=0y=0, cosh⁡=1\cosh=1 but sinh⁡=0\sinh=0, so drop the cosh and keep Yn∝sinh⁡(nπy/a)Y_n\propto\sinh(n\pi y/a). Why: the hyperbolic direction has one homogeneous face, and sinh⁡\sinh already vanishes there, leaving one amplitude to match the live face.

Step 5. Match the live face at y=by=b. Writing u(x,b)=∑ncnsin⁡(nπx/a)=V(x)u(x,b)=\sum_n c_n\sin(n\pi x/a)=V(x) and normalizing each mode by sinh⁡(nπb/a)\sinh(n\pi b/a) to equal unity at y=by=b, orthogonality gives cn=(2/a)∫0aV(ξ)sin⁡(nπξ/a) dξc_n=(2/a)\int_0^a V(\xi)\sin(n\pi\xi/a)\,\mathrm{d}\xi. Why: the inhomogeneous condition is where the Fourier coefficients finally enter; each term is harmonic and meets all four conditions by construction, since ∂x2sin⁡⋅sinh⁡+∂y2sin⁡⋅sinh⁡=(−kn2+kn2)sin⁡⋅sinh⁡=0\partial_x^2\sin\cdot\sinh+\partial_y^2\sin\cdot\sinh=(-k_n^2+k_n^2)\sin\cdot\sinh=0.

Limiting cases

The character of a separated solution is fixed entirely by the sign of each separation constant, which the boundary data set. The four regimes:

CaseResultMeaning
Oscillatory directionX′′+k2X=0  ⇒  X=Acos⁡kx+Bsin⁡kxX''+k^2X=0\;\Rightarrow\;X=A\cos kx+B\sin kxFor directions with homogeneous data on both faces; those conditions quantize kk into the spectrum kn=nπ/Lk_n=n\pi/L.
Hyperbolic / exponential directionX′′−k2X=0  ⇒  X=Acosh⁡kx+Bsinh⁡kxX''-k^2X=0\;\Rightarrow\;X=A\cosh kx+B\sinh kxFor the direction carrying inhomogeneous data; grows or decays rather than oscillating, matching a profile on one face.
Degenerate (zero) constantX′′=0  ⇒  X=A+BxX''=0\;\Rightarrow\;X=A+BxThe k=0k=0 mode; must be checked separately, often carrying the average (Neumann) or the ramp between unequal ends.
Decay in time (parabolic)T′+αk2T=0  ⇒  T=e−αk2tT'+\alpha k^2T=0\;\Rightarrow\;T=e^{-\alpha k^2 t}Heat: the time ODE is first order; each mode decays at rate ∝k2\propto k^2, so high-kk structure vanishes fastest.

Worked examples

1 · Energy levels of an electron in a 3D box (fully worked)

A single electron is confined to a cubic infinite well of side L=1.0L=1.0 nm, modelling a semiconductor quantum dot. The time-independent Schrödinger equation is −ℏ22m∇2ψ=Eψ-\tfrac{\hbar^2}{2m}\nabla^2\psi=E\psi with ψ=0\psi=0 on the walls. Find the ground-state energy, the first excited energy, and the degeneracy of each.

Step 1. Separate. With ψ=X(x)Y(y)Z(z)\psi=X(x)Y(y)Z(z) the equation splits into three copies of the particle-in-a-box problem, each with X(0)=X(L)=0X(0)=X(L)=0, so Xnx=sin⁡(nxπx/L)X_{n_x}=\sin(n_x\pi x/L) and likewise for y,zy,z. The Cartesian Laplacian splits the 3D well into three independent 1D wells, and the energy adds: E=ℏ2π22mL2(nx2+ny2+nz2)E=\tfrac{\hbar^2\pi^2}{2mL^2}\left(n_x^2+n_y^2+n_z^2\right), each ni=1,2,3,…n_i=1,2,3,\dots

Step 2. Evaluate the energy unit E0=ℏ2π22mL2E_0=\tfrac{\hbar^2\pi^2}{2mL^2}. With ℏ=1.0546×10−34\hbar=1.0546\times10^{-34} J·s, m=9.109×10−31m=9.109\times10^{-31} kg, L=10−9L=10^{-9} m: E0=6.02×10−20E_0=6.02\times10^{-20} J =0.376 eV=\mathbf{0.376\ eV}.

Step 3. Ground state. The lowest quantum numbers are (nx,ny,nz)=(1,1,1)(n_x,n_y,n_z)=(1,1,1), giving nx2+ny2+nz2=3n_x^2+n_y^2+n_z^2=3, so E111=3E0=1.13 eVE_{111}=3E_0=\mathbf{1.13\ eV}. It is unique — non-degenerate, degeneracy 11.

Step 4. First excited state. The next value ∑ni2=6\sum n_i^2=6 is reached by (2,1,1)(2,1,1), (1,2,1)(1,2,1), or (1,1,2)(1,1,2) — three states at the same energy E=6E0=2.26 eVE=6E_0=\mathbf{2.26\ eV}, a three-fold degeneracy from the cubic symmetry. Ground 1.13 eV (single), first excited 2.26 eV (triply degenerate); the 1.13 eV gap sits in the optical range — which is why dots of this size fluoresce visible light.

2 · Transient cooling of a copper rod (fully worked)

A copper rod of length L=0.10L=0.10 m starts at a uniform T0=100 ∘T_0=100\ ^\circC and at t=0t=0 its ends are clamped to 0 ∘0\ ^\circC. Copper has thermal diffusivity α=1.11×10−4 m2/s\alpha=1.11\times10^{-4}\ \mathrm{m^2/s}. Find the Fourier coefficients, the long-time cooling law, and the mid-rod temperature after 1010 s.

Step 1. Coefficients. From equation (6) with f(x)=T0f(x)=T_0 constant, bn=2T0L∫0Lsin⁡nπxL dx=2T0nπ(1−cos⁡nπ)b_n=\dfrac{2T_0}{L}\displaystyle\int_0^L\sin\frac{n\pi x}{L}\,\mathrm{d}x=\dfrac{2T_0}{n\pi}\bigl(1-\cos n\pi\bigr). Even modes vanish; odd modes give bn=4T0nπb_n=\dfrac{4T_0}{n\pi}, so b1=4(100)π=127.3 ∘Cb_1=\dfrac{4(100)}{\pi}=\mathbf{127.3\ ^\circ C}, b3=b1/3b_3=b_1/3, ... A flat profile is dominated by its lowest odd mode.

Step 2. Time constants. Mode nn decays as e−t/τne^{-t/\tau_n} with τn=L2α(nπ)2\tau_n=\dfrac{L^2}{\alpha(n\pi)^2}; the slowest is τ1=(0.10)2(1.11×10−4)π2=9.13 s\tau_1=\dfrac{(0.10)^2}{(1.11\times10^{-4})\pi^2}=\mathbf{9.13\ s}, and n=3n=3 decays 9×9\times faster (τ3=1.01\tau_3=1.01 s). Since τn∝n−2\tau_n\propto n^{-2}, after a few seconds only the fundamental survives.

Step 3. Long-time law. For t≳τ3t\gtrsim\tau_3 only one term survives: u(x,t)≈4T0πsin⁡πxL e−t/τ1u(x,t)\approx\dfrac{4T_0}{\pi}\sin\dfrac{\pi x}{L}\,e^{-t/\tau_1}. The whole rod then cools as a single exponential with the 9.139.13 s constant, whatever the initial shape — the spectral gap in action, the system relaxing on its slowest mode.

Step 4. Mid-rod temperature at t=10t=10 s. At x=L/2x=L/2, sin⁡(π/2)=1\sin(\pi/2)=1, and e−10/9.13=e−1.095=0.334e^{-10/9.13}=e^{-1.095}=0.334, so u(L/2,10 s)≈127.3×0.334=42.5 ∘Cu(L/2,10\,\mathrm{s})\approx127.3\times0.334=\mathbf{42.5\ ^\circ C}. The rod's centre has fallen from 100 °C to about 42.5 °C in ten seconds, and thereafter halves every τ1ln⁡2≈6.3\tau_1\ln 2\approx6.3 s.

Physics of the portrait

Separation of variables is inseparable from the man who turned it from a trick into a theory. Daniel Bernoulli guessed in 1753 that a vibrating string's motion is a sum of sinusoidal modes, but it was Joseph Fourier, studying heat in a metal bar, who forced the issue and won it.

Origins · 1 minJoseph Fourier and how this was discovered
JF
Joseph Fourier
1768–1830 · analytic theory of heat and trigonometric expansions

Jean-Baptiste Joseph Fourier was an orphan, a revolutionary, and briefly Napoleon's governor of Egypt before he became the mathematician whose name is attached to half of applied analysis. Working in stolen hours on the flow of heat, in an 1807 memoir to the Paris Academy he made a claim that scandalized the referees — Lagrange among them — that an arbitrary function could be written as a sum of sines and cosines. The committee refused to publish it, objecting that he could not prove convergence (Dirichlet's proof lay two decades away). Fourier pressed on and in 1822 published the Théorie analytique de la chaleur, whose method is exactly separation of variables: he sought product solutions of the heat equation, found the sine eigenfunctions selected by the boundary conditions, and fixed the coefficients by the orthogonality integrals now bearing his name — the first systematic complete eigenfunction expansion. The physics was almost incidental to the mathematics it forced into being: that a differential operator has a spectrum, that functions live in an inner-product space, and that boundary data are matched by projection. Every separation calculation here descends from Fourier's obstinate memoir.

History
1753
— Daniel Bernoulli proposes building a vibrating string's motion from a superposition of sinusoidal modes
1807
— Fourier submits his memoir on heat diffusion, asserting arbitrary functions expand in trigonometric series
1822
— Fourier publishes Théorie analytique de la chaleur, systematizing separation of variables and the coefficient integrals
1829
— Dirichlet gives the first rigorous convergence proof for Fourier series
1836
— Sturm and Liouville generalize the eigenvalue theory to variable-coefficient operators

Going further

Texts. Stone & Goldbart, Mathematics for Physics, ch. 8–9 · Arfken, Weber & Harris, Mathematical Methods for Physicists, 7th ed., ch. 9 · Hassani, Mathematical Physics, 2nd ed., ch. 22 · Byron & Fuller, Mathematics of Classical and Quantum Physics, ch. 7 · Riley, Hobson & Bence, Mathematical Methods for Physics and Engineering, 3rd ed., ch. 21 · Morse & Feshbach, Methods of Theoretical Physics, vol. 1, ch. 5. The key numerical results collected here are: E0=ℏ2π2/2meL2=0.376E_0=\hbar^2\pi^2/2m_eL^2=0.376 eV for L=1L=1 nm (ground state 1.131.13 eV, first excited 2.262.26 eV, degeneracy 33); copper-rod τ1=L2/απ2=9.13\tau_1=L^2/\alpha\pi^2=9.13 s and mid-rod 42.5 ∘42.5\ ^\circC at t=10t=10 s; square-drum f11=235.7f_{11}=235.7, f21=372.7f_{21}=372.7, f22=471.4f_{22}=471.4 Hz with f21/f11=5/2=1.58f_{21}/f_{11}=\sqrt{5/2}=1.58.

Prerequisites. Classification of Second-Order Linear PDEs · Boundary Conditions and Well-Posedness · Sturm–Liouville Theory and Eigenfunction Expansions. Leads to. Separation of Variables in Cylindrical Coordinates · Separation of Variables in Spherical Coordinates · The Helmholtz Equation · Green's Functions for PDEs.

Ask the tutor: Want to see this method turn a real boundary-value problem into a series — heat, potential, or a vibrating plate — worked line by line with the sign rule applied? Ask and we will build one together.

What is the difference between a separable operator and a separable solution?

Two sides of one condition. A separable operator splits into a sum of pieces each acting on a single coordinate, as the Cartesian Laplacian ∂x2+∂y2+∂z2\partial_x^2+\partial_y^2+\partial_z^2 does. A separable solution is the product ansatz u=X(x)Y(y)⋯u=X(x)Y(y)\cdots you try. The method works only when the operator is separable and the domain is a coordinate surface; then completeness supplies enough product solutions to build the general answer, whereas a non-coordinate boundary or non-separable operator admits none.

How many separation constants are there and how are they related?

Count the coordinates: a PDE in dd independent variables gives dd separated ODEs and d−1d-1 independent separation constants, linked by one constraint from the PDE. For Laplace in three dimensions the constraint is kx2+ky2=κ2k_x^2+k_y^2=\kappa^2 (the three sum to zero), leaving two free; for the heat equation there is a single λ\lambda tying the spatial eigenvalue to the decay rate. That constraint forbids choosing all signs independently, and is why at least one direction must behave oppositely to the others.

Why does the same ODE give sines in one direction and hyperbolic functions in another?

Because the sign of the separation constant, not the ODE's form, changes — and the boundary data set that sign. The equation X′′=cXX''=cX gives oscillatory sin⁡/cos⁡\sin/\cos when c<0c<0 and sinh⁡/cosh⁡\sinh/\cosh when c>0c>0. A direction with two homogeneous faces is forced to oscillate (only sines vanish at two points); the direction carrying the inhomogeneous datum goes hyperbolic (it must reach a prescribed value on one face). So "sines here, sinh there" is dictated by which faces carry zero data.

What happens to the k = 0 mode and why is it easy to miss?

The k=0k=0 mode solves X′′=0X''=0, giving the straight line X=A+BxX=A+Bx — not a sine — so it is invisible to the discrete ladder and easy to forget. Under Dirichlet data X(0)=X(L)=0X(0)=X(L)=0 it dies; under Neumann data it survives as a constant carrying the field's average, the steady mean that never decays. When the two ends sit at different fixed values, the ramp A+BxA+Bx supplies the linear steady state about which the sine series describes the transient. Omit it and you silently drop the mean or steady state.

Is separation of variables the same thing as a Fourier series?

Related but not identical. Separation of variables is the method — the product ansatz reducing a PDE to ODE eigenvalue problems. A Fourier series is the particular expansion you get when the eigenfunctions come out as sines and cosines, exactly the Cartesian constant-coefficient case; the same method in cylindrical coordinates yields a Fourier–Bessel series, and in spherical coordinates spherical harmonics. So Fourier series is what Cartesian separation produces; the unifying concept is expansion in the complete orthogonal eigenfunctions of a Sturm–Liouville operator.

Can separation handle inhomogeneous data on several faces at once?

Yes, by superposition. Pure separation wants one inhomogeneous face; when several carry data, split into sub-problems each with a single live face and the rest homogeneous, solve each, and add. Linearity guarantees the sum satisfies the PDE and reassembles all the data. If the PDE has a source term, first subtract a particular steady solution or expand the source in eigenfunctions, reducing it again to homogeneous separable pieces. The rule is always: decompose until every piece has a single live face.

Before this

Where this leads