The question the last guide left open
Two guides ago, separation of variables handed you a ladder of sine arches sin(n pi x / L) and told you the real solution is a superposition of them. The last guide sorted those arches into sine series and cosine series, matched to whether the boundary holds the ends fixed or insulated, and to the even or odd extension that goes with each. So the shapes are settled. What is still missing is the one number in front of each shape. We want to write a given starting profile f(x) as a sum f(x) = b_1 sin(pi x / L) + b_2 sin(2 pi x / L) + ..., and the entire job now is to pin down those amplitudes b_n.
At first this looks hopeless. There are infinitely many unknowns b_n, and they all sit tangled inside one equation. If you tried this with ordinary vectors you would set up a giant linear system and grind. But sine series come with a gift that ordinary tangled sums do not: the building blocks are mutually perpendicular in a precise integral sense. That single fact lets you reach in and pull out any one coefficient without touching the others. Matching the initial condition stops being a wall of simultaneous equations and becomes a sequence of independent, one-line integrals — that is the whole story of this guide.
Perpendicular functions, the same idea as perpendicular vectors
Remember how you pick a single component out of an ordinary vector. To find how much of v points along a unit axis e_k, you take the dot product v . e_k; every other axis contributes nothing because the axes are perpendicular. The clever leap is to treat functions on the interval [0, L] as vectors with infinitely many components, and to replace the dot product by an integral. The inner product of two functions f and g is defined as the integral of f(x) g(x) over [0, L]. Two functions are called orthogonal when that integral is zero — they are perpendicular in exactly the same sense, just with a sum-over-points turned into an integral.
Now the small miracle that makes everything run. The sine modes are orthogonal to one another: the integral of sin(m pi x / L) sin(n pi x / L) over [0, L] is zero whenever m and n are different, and equals L/2 when m and n are the same. This is the orthogonality of the trigonometric functions, and it is not luck — it falls out of a product-to-sum identity that turns sin times sin into cosines that integrate to zero over a whole number of half-periods. Geometrically, distinct sine arches wiggle so that wherever one is positive the other spends just as much time canceling it; their overlap averages to nothing.
The projection trick: extracting one coefficient
Here is the move that does everything. Start from f(x) = sum over k of b_k sin(k pi x / L), the equality we want to solve for the b's. To isolate the m-th coefficient, multiply both sides by the m-th mode sin(m pi x / L) and integrate over [0, L]. On the right, integration is linear, so it slides inside the sum and hits each term b_k times the integral of sin(k pi x / L) sin(m pi x / L). By orthogonality every one of those integrals is zero — except the single term where k equals m, which contributes b_m times L/2. The entire infinite sum collapses to one survivor.
Want: f(x) = b_1 sin(pi x/L) + b_2 sin(2 pi x/L) + b_3 sin(3 pi x/L) + ...
Step: multiply BOTH sides by sin(m pi x/L), then integrate over [0, L]
integral[ f(x) sin(m pi x/L) dx ]
= sum over k of b_k * integral[ sin(k pi x/L) sin(m pi x/L) dx ]
orthogonality: integral[ sin(k..) sin(m..) ] = 0 if k != m
= L/2 if k == m
so the whole sum collapses to the k = m term:
integral[ f(x) sin(m pi x/L) dx ] = b_m * (L/2)
=> b_m = (2/L) * integral_0^L f(x) sin(m pi x/L) dxSolving for the survivor gives the celebrated Fourier coefficient formula: b_m = (2/L) times the integral over [0, L] of f(x) sin(m pi x / L) dx. Read it as a projection. The integral measures how strongly the profile f overlaps with the m-th pure arch, and the 2/L simply renormalizes by the mode's own length L/2 — the same way you divide by a basis vector's squared length to get a true component. Every coefficient is computed by the same recipe, each one ignorant of the others, exactly as separate vector components are.
A tiny worked example
- Take a bar on [0, pi] (so L = pi) starting at the constant profile f(x) = 1, with both ends clamped to zero. Set up the sine-series coefficient: b_m = (2/pi) times the integral from 0 to pi of 1 . sin(m x) dx.
- Do the integral. The antiderivative of sin(m x) is -cos(m x)/m, so the definite integral is (1 - cos(m pi))/m. Since cos(m pi) is +1 for even m and -1 for odd m, the bracket is 0 for even m and 2 for odd m.
- Assemble. b_m = (2/pi) . (1 - cos(m pi))/m, which is 0 for even m and 4/(m pi) for odd m. The even modes vanish — a symmetry you could have guessed, since the flat profile is symmetric about the midpoint and the even-numbered arches are not.
- Read off the series. f(x) = 1 is rebuilt as (4/pi) [ sin(x) + sin(3x)/3 + sin(5x)/5 + ... ]. Three honest integrals, no linear system, and you have the exact amplitudes of every mode the heat or wave evolution will carry forward.
Why it pins down the answer, and where it generalizes
Be honest about what these coefficients do and do not promise. The formula always produces numbers — you can integrate f against any mode whether or not the series truly converges back to f. Orthogonality guarantees that if f can be expanded in these sines at all, these are the only weights that work; it does not by itself prove the rebuilt sum equals f at every point. That stronger claim is convergence, and it depends on how nice f is. In the mean-square sense the partial sums always close in on f for any reasonable profile, and the coefficients even minimize the squared error at each truncation — but pointwise agreement at a jump is a separate, more delicate matter saved for the next guide.
The deepest reward is that this projection trick is not special to sines. The same machine runs on any family of mutually orthogonal functions, and the eigenfunctions thrown up by a separated boundary-value problem are guaranteed to form one. That is the bridge to the next rung: cosines, Bessel functions on a disk, Legendre polynomials on a sphere, all obey their own orthogonality and all yield coefficients by the very same multiply-and-integrate recipe — a generalized Fourier series. The unifying frame is the Sturm-Liouville problem, which proves that a broad class of self-adjoint operators always delivers a complete orthogonal basis, sometimes orthogonal with respect to a weight r(x) that sits inside the integral. Master the sine case and you have, in miniature, the method for them all.