Mathematical Methods Handbook

Calculus of several variables

Differentiation, extrema and integration in several variables.

In this chapter 7

Tick a unit to add it to your PDF basket.

  1. Differentiation and extrema
  2. Integration

Differentiation and extrema

4

Method

Partial derivatives and the chain rule

Adapted

Defines partial derivatives and the total derivative of a map between Euclidean spaces, identifies the total derivative with the Jacobian matrix, and gives the chain rule as a matrix product together with the C2C^2 condition under which mixed partials commute.

Definition(Partial derivative)AdaptedAdapted from Lee (2013), App. C, p. 644; Riley, Hobson & Bence (2006), §5.1, Eqs. (5.1)–(5.2) and p. 152; do Carmo (2016), Appendix, p. 127

Let U⊆RnU \subseteq \mathbb{R}^n be open, let f:U→Rf : U \to \mathbb{R}, let a∈Ua \in U and let eje_j be the jjth standard basis vector. The jjth partial derivative of ff at aa is

∂f∂xj(a)  =  lim⁡h→0f(a+hej)−f(a)h∈R,\frac{\partial f}{\partial x_j}(a) \;=\; \lim_{h \to 0} \frac{f(a + h e_j) - f(a)}{h} \in \mathbb{R},

whenever that limit exists, hh ranging over the real numbers with a+hej∈Ua + he_j \in U. It is also written ∂jf(a)\partial_j f(a) or fxj(a)f_{x_j}(a). For a map F=(F1,…,Fm):U→RmF = (F_1,\dots,F_m) : U \to \mathbb{R}^m, the partial derivatives of FF are those of its components, ∂Fi/∂xj\partial F_i/\partial x_j.

Higher partial derivatives are the partial derivatives of partial derivatives, with

∂2f∂xj∂xk(a)=∂∂xj ⁣(∂f∂xk) ⁣(a):\frac{\partial^2 f}{\partial x_j \partial x_k}(a) = \frac{\partial}{\partial x_j}\!\left(\frac{\partial f}{\partial x_k}\right)\!(a) :

the rightmost index is differentiated first. We read the subscript notation the same way round, fxjxk=∂2f/∂xj∂xkf_{x_j x_k} = \partial^2 f/\partial x_j \partial x_k, which is the convention of Riley, Hobson and Bence (p. 152) and of do Carmo (p. 127): both write fxy=∂2f/∂x ∂y=∂x(∂yf)f_{xy} = \partial^2 f/\partial x\,\partial y = \partial_x(\partial_y f). Other texts read the subscripts in the order of differentiation instead, so that fxyf_{xy} means ∂y(∂xf)=∂2f/∂y ∂x\partial_y(\partial_x f) = \partial^2 f/\partial y\, \partial x. The two readings agree whenever ff is C2C^2, which is why the difference is usually passed over; for a function that is not C2C^2 they can disagree (see the remark).

FF is of class CkC^k on UU (k≥1k \ge 1) if every partial derivative of FF of order at most kk exists at every point of UU and is continuous on UU; C0C^0 means continuous, and C∞C^\infty (smooth) means CkC^k for every kk.

Definition(Differentiability and the total derivative)AdaptedAdapted from Lee (2013), App. C, Eqs. (C.1)–(C.2) and Exercise C.1, p. 642

With U⊆RnU \subseteq \mathbb{R}^n open and a∈Ua \in U, a map F:U→RmF : U \to \mathbb{R}^m is differentiable at aa if there is a linear map L:Rn→RmL : \mathbb{R}^n \to \mathbb{R}^m with

lim⁡v→0∣F(a+v)−F(a)−Lv∣∣v∣=0,\lim_{v \to 0} \frac{\lvert F(a + v) - F(a) - Lv \rvert}{\lvert v \rvert} = 0 ,

the norms being Euclidean and vv ranging over Rn∖{0}\mathbb{R}^n \setminus \{0\} with a+v∈Ua + v \in U. Such an LL is unique; it is written DF(a)DF(a) and called the total derivative of FF at aa. Equivalently F(a+v)=F(a)+DF(a)v+R(v)F(a+v) = F(a) + DF(a)v + R(v) with ∣R(v)∣/∣v∣→0\lvert R(v)\rvert / \lvert v \rvert \to 0 as v→0v \to 0, so DF(a)DF(a) is the linear map that approximates the increment of FF to first order.

Definition(Jacobian matrix, total differential, directional derivative)AdaptedAdapted from Lee (2013), App. C, p. 644 and Eq. (C.6), p. 647; Riley, Hobson & Bence (2006), §5.2, Eqs. (5.5)–(5.6), p. 154 and §6.4.3, p. 205

Let U⊆RnU \subseteq \mathbb{R}^n be open and F:U→RmF : U \to \mathbb{R}^m.

  • The Jacobian matrix of FF at a∈Ua \in U is the m×nm \times n matrix JF(a)=(∂Fi/∂xj(a))i≤m, j≤nJ_F(a) = \bigl(\partial F_i/\partial x_j (a)\bigr)_{i \le m,\ j \le n}, whenever these partial derivatives exist. If m=nm = n, its determinant is the Jacobian determinant, also written ∂(F1,…,Fn)/∂(x1,…,xn)\partial(F_1,\dots,F_n)/\partial(x_1,\dots,x_n).
  • For real-valued ff differentiable at aa, the linear form Df(a)Df(a) written in the coordinate differentials dxjdx_j (the linear forms v↦vjv \mapsto v_j) is the total differential df=∑j=1n(∂f/∂xj) dxjdf = \sum_{j=1}^{n} (\partial f/\partial x_j)\, dx_j.
  • For v∈Rnv \in \mathbb{R}^n, the directional derivative of ff at aa along vv is Dvf(a)=ddtf(a+tv)∣t=0D_v f(a) = \frac{d}{dt} f(a + tv)\big|_{t=0}, when that one-variable derivative exists. No normalisation of vv is assumed.
Method(Partial derivatives, continuity and the total derivative)AdaptedAdapted from Lee (2013), App. C, Exercise C.1 (p. 642), Exercise C.2(a) (p. 643), Prop. C.8 and Exercise C.9 (p. 646), Prop. C.10 and the display after Eq. (C.6) (p. 647)

Let U⊆RnU \subseteq \mathbb{R}^n be open, F:U→RmF : U \to \mathbb{R}^m and a∈Ua \in U.

  1. If FF is differentiable at aa, then DF(a)DF(a) is unique, FF is continuous at aa, every partial derivative ∂Fi/∂xj(a)\partial F_i/\partial x_j(a) exists, and the matrix of DF(a)DF(a) in the standard bases is the Jacobian matrix: DF(a) v=JF(a) vDF(a)\,v = J_F(a)\,v for all v∈Rnv \in \mathbb{R}^n. In particular Dvf(a)=∑jvj ∂f/∂xj(a)D_v f(a) = \sum_{j} v_j\, \partial f/\partial x_j (a) for real-valued ff differentiable at aa.
  2. If FF is of class C1C^1 on UU — every ∂Fi/∂xj\partial F_i/\partial x_j exists at every point of UU and is continuous on UU — then FF is differentiable at every point of UU.
  3. FF is differentiable at aa if and only if each component F1,…,FmF_1, \dots, F_m is differentiable at aa, and then the rows of JF(a)J_F(a) are the JFi(a)J_{F_i}(a).

Neither of the following converses holds: existence of all partial derivatives at aa does not give differentiability at aa, and differentiability at every point of UU does not give C1C^1 (see the remark).

Idea of the proofAdaptedAdapted from Lee (2013), App. C, Prop. C.8, p. 646

Everything in part 1 comes from testing the definition of differentiability along a single direction: put v=tejv = te_j, divide by tt, and the remainder term dies because it is small compared with ∣v∣=∣t∣\lvert v\rvert = \lvert t\rvert. That one substitution gives uniqueness, the existence of the partials and the identification of the matrix at once. Part 2 goes the other way and is the only part that needs work: the increment is split into nn steps, each changing one coordinate, so that the one-variable mean value theorem applies to each; continuity of the partials at aa is then exactly what makes the nn intermediate values collapse onto their values at aa.

ProofAdaptedAdapted from Lee (2013), App. C, Prop. C.8, p. 646

Part 1. Let FF be differentiable at aa with F(a+v)=F(a)+Lv+R(v)F(a+v) = F(a) + Lv + R(v), ∣R(v)∣/∣v∣→0\lvert R(v)\rvert/\lvert v\rvert \to 0.

Uniqueness. Suppose LL and L′L' both satisfy the definition. Fix u∈Rnu \in \mathbb{R}^n with ∣u∣=1\lvert u \rvert = 1 and put v=tuv = tu with t→0t \to 0. Subtracting the two expansions, ∣(L−L′)(tu)∣/∣tu∣→0\lvert (L - L')(tu)\rvert/\lvert tu\rvert \to 0; but by linearity that quotient equals ∣(L−L′)u∣\lvert (L-L')u \rvert, a number independent of tt. So (L−L′)u=0(L - L')u = 0 for every unit uu, hence L=L′L = L'.

Continuity. A linear map between Euclidean spaces satisfies ∣Lv∣≤C∣v∣\lvert Lv\rvert \le C\lvert v\rvert for some constant CC (take CC to be the square root of the sum of the squares of the matrix entries, by the Cauchy-Schwarz inequality). Then ∣F(a+v)−F(a)∣≤C∣v∣+∣R(v)∣→0\lvert F(a+v) - F(a)\rvert \le C\lvert v\rvert + \lvert R(v)\rvert \to 0 as v→0v \to 0, which is continuity at aa.

The partial derivatives and the matrix. Put v=hejv = he_j with hh real and small, so that ∣v∣=∣h∣\lvert v\rvert = \lvert h\rvert. Then

F(a+hej)−F(a)h=Lej+R(hej)h,∣R(hej)h∣=∣R(hej)∣∣hej∣⟶0.\frac{F(a + he_j) - F(a)}{h} = Le_j + \frac{R(he_j)}{h}, \qquad \left\lvert \frac{R(he_j)}{h}\right\rvert = \frac{\lvert R(he_j)\rvert}{\lvert he_j\rvert} \longrightarrow 0 .

So the difference quotient converges, which means each component limit exists: ∂Fi/∂xj(a)\partial F_i/\partial x_j(a) exists and equals the iith component of LejLe_j. Since LejLe_j is the jjth column of the matrix of LL in the standard bases, that matrix is (∂Fi/∂xj(a))=JF(a)\bigl(\partial F_i/\partial x_j(a)\bigr) = J_F(a).

The directional derivative. For real-valued ff differentiable at aa and v≠0v \ne 0, the same substitution with vv in place of eje_j gives (f(a+tv)−f(a))/t=Df(a)v+R(tv)/t\bigl(f(a+tv) - f(a)\bigr)/t = Df(a)v + R(tv)/t, and ∣R(tv)/t∣=∣v∣ ∣R(tv)∣/∣tv∣→0\lvert R(tv)/t\rvert = \lvert v\rvert\,\lvert R(tv)\rvert/\lvert tv\rvert \to 0. Hence Dvf(a)D_vf(a) exists and equals Df(a)v=∑jvj ∂f/∂xj(a)Df(a)v = \sum_j v_j\,\partial f/\partial x_j(a), the last step by the matrix identification. For v=0v = 0 both sides are 00.

Part 2. By part 3, proved below, it is enough to treat a real-valued ff of class C1C^1. Fix a∈Ua \in U and r>0r > 0 with the closed ball ∣v∣≤r\lvert v\rvert \le r contained in UU. For ∣v∣<r\lvert v \rvert < r set v(0)=0v^{(0)} = 0 and v(k)=(v1,…,vk,0,…,0)v^{(k)} = (v_1,\dots,v_k,0,\dots,0), and telescope the increment one coordinate at a time:

f(a+v)−f(a)=∑k=1n[f(a+v(k))−f(a+v(k−1))].f(a+v) - f(a) = \sum_{k=1}^{n}\Bigl[ f\bigl(a + v^{(k)}\bigr) - f\bigl(a + v^{(k-1)}\bigr) \Bigr].

The kkth bracket changes only the kkth coordinate, so it is the increment of the one-variable function t↦f(a+v(k−1)+tek)t \mapsto f\bigl(a + v^{(k-1)} + te_k\bigr) over 0≤t≤vk0 \le t \le v_k (or vk≤t≤0v_k \le t \le 0). That function is differentiable, because ∂f/∂xk\partial f/\partial x_k exists at every point of UU — this is where the existence half of the C1C^1 hypothesis is used — so the mean value theorem gives a point ckc_k on the segment from a+v(k−1)a + v^{(k-1)} to a+v(k)a + v^{(k)} with

f(a+v(k))−f(a+v(k−1))=vk ∂f∂xk(ck).f\bigl(a+v^{(k)}\bigr) - f\bigl(a+v^{(k-1)}\bigr) = v_k\,\frac{\partial f}{\partial x_k}(c_k) .

Every point of that segment has the form a+(v1,…,vk−1,s,0,…,0)a + (v_1,\dots,v_{k-1},s,0,\dots,0) with ∣s∣≤∣vk∣\lvert s\rvert \le \lvert v_k\rvert, so ∣ck−a∣≤∣v∣\lvert c_k - a\rvert \le \lvert v\rvert and ckc_k lies in the ball. Subtracting the candidate linear map,

∣f(a+v)−f(a)−∑k=1nvk∂f∂xk(a)∣=∣∑k=1nvk(∂f∂xk(ck)−∂f∂xk(a))∣≤∣v∣∑k=1n∣∂f∂xk(ck)−∂f∂xk(a)∣,\Bigl\lvert f(a+v) - f(a) - \sum_{k=1}^{n} v_k \frac{\partial f}{\partial x_k}(a)\Bigr\rvert = \Bigl\lvert \sum_{k=1}^{n} v_k\Bigl(\frac{\partial f}{\partial x_k}(c_k) - \frac{\partial f}{\partial x_k}(a)\Bigr)\Bigr\rvert \le \lvert v\rvert \sum_{k=1}^{n}\Bigl\lvert \frac{\partial f}{\partial x_k}(c_k) - \frac{\partial f}{\partial x_k}(a)\Bigr\rvert ,

using ∣vk∣≤∣v∣\lvert v_k\rvert \le \lvert v\rvert. Divide by ∣v∣\lvert v\rvert and let v→0v \to 0: each ck→ac_k \to a because ∣ck−a∣≤∣v∣\lvert c_k - a\rvert \le \lvert v\rvert, and each ∂f/∂xk\partial f/\partial x_k is continuous at aa — this is where continuity, as opposed to mere existence, is used, and it is the only place — so the sum tends to 00. Hence ff is differentiable at aa with Df(a)v=∑kvk ∂f/∂xk(a)Df(a)v = \sum_k v_k\,\partial f/\partial x_k(a).

Part 3. The Euclidean norm of a vector dominates the modulus of each of its components and is dominated by their sum. So if FF is differentiable at aa with remainder RR, then each component remainder satisfies ∣Ri(v)∣≤∣R(v)∣=o(∣v∣)\lvert R_i(v)\rvert \le \lvert R(v)\rvert = o(\lvert v\rvert), and FiF_i is differentiable with DFi(a)DF_i(a) the iith row. Conversely, if each FiF_i is differentiable at aa with linear map LiL_i and remainder RiR_i, let LL be the linear map whose iith row is the matrix of LiL_i; then ∣R(v)∣≤∑i∣Ri(v)∣\lvert R(v)\rvert \le \sum_i \lvert R_i(v)\rvert, a sum of mm terms each o(∣v∣)o(\lvert v\rvert), so FF is differentiable at aa with DF(a)=LDF(a) = L. In either direction the rows of JF(a)J_F(a) are the JFi(a)J_{F_i}(a), by the matrix identification in part 1. □\square

Method(Chain rule)AdaptedAdapted from Lee (2013), App. C, Prop. C.3, p. 643; Lee (2013), App. C, Cor. C.11, p. 647

Let V⊆RnV \subseteq \mathbb{R}^n and W⊆RmW \subseteq \mathbb{R}^m be open, F:V→WF : V \to W and G:W→RpG : W \to \mathbb{R}^p.

  1. Total-derivative form. If FF is differentiable at a∈Va \in V and GG is differentiable at F(a)F(a), then G∘FG \circ F is differentiable at aa and D(G∘F)(a)=DG(F(a))∘DF(a)D(G \circ F)(a) = DG(F(a)) \circ DF(a), which in matrices is the product of a p×mp \times m with an m×nm \times n matrix, JG∘F(a)=JG(F(a)) JF(a).J_{G \circ F}(a) = J_G\bigl(F(a)\bigr)\, J_F(a).
  2. Partial-derivative form. If FF is of class C1C^1 on VV and GG is of class C1C^1 on WW, then G∘FG \circ F is of class C1C^1 on VV and, writing y=F(x)y = F(x) for the intermediate variables, ∂(Gi∘F)∂xj(x)=∑k=1m∂Gi∂yk(F(x)) ∂Fk∂xj(x)(1≤i≤p, 1≤j≤n).\frac{\partial (G_i \circ F)}{\partial x_j}(x) = \sum_{k=1}^{m} \frac{\partial G_i}{\partial y_k}\bigl(F(x)\bigr)\, \frac{\partial F_k}{\partial x_j}(x) \qquad (1 \le i \le p,\ 1 \le j \le n). If FF and GG are both of class CkC^k for some k≥1k \ge 1, or both smooth, so is G∘FG \circ F. (Lee's Cor. C.11 states the two ends of this, parts (a) and (b): the cases k=1k = 1 and smooth. The paragraph after it, p. 647, goes no further than to observe that, where there is differentiability enough to support it, induction on the chain rule yields whatever second- and higher-order formulas one needs; it does not assert that a composite of CkC^k maps is again CkC^k. The intermediate kk is therefore ours, and the proof below establishes it.)
Idea of the proofAdaptedAdapted from Lee (2013), App. C, Prop. C.3, pp. 643-644

Composing the two first-order expansions is almost the whole proof: substituting the increment of FF into the expansion of GG produces the wanted linear term DG(F(a)) DF(a) vDG(F(a))\,DF(a)\,v plus two errors. One is the linear map DG(F(a))DG(F(a)) applied to the error of FF, which is small because a linear map cannot inflate a vector by more than a fixed factor. The other is the error of GG evaluated at an increment that is itself at most a constant times ∣v∣\lvert v\rvert, so it too is small compared with ∣v∣\lvert v\rvert. The partial-derivative form is then the matrix product written out entry by entry.

ProofAdaptedAdapted from Lee (2013), App. C, Prop. C.3, pp. 643-644; Lee (2013), App. C, Cor. C.11, p. 647

Part 1. Put b=F(a)b = F(a), A=DF(a)A = DF(a) and B=DG(b)B = DG(b), and name the two remainders:

F(a+v)=b+Av+r(v),G(b+w)=G(b)+Bw+s(w),F(a+v) = b + Av + r(v), \qquad G(b+w) = G(b) + Bw + s(w),

with ∣r(v)∣/∣v∣→0\lvert r(v)\rvert/\lvert v\rvert \to 0 and ∣s(w)∣/∣w∣→0\lvert s(w)\rvert/\lvert w\rvert \to 0; set s(0)=0s(0) = 0, consistent with the definition. Let w(v)=F(a+v)−b=Av+r(v)w(v) = F(a+v) - b = Av + r(v), which is the increment at which GG is evaluated. Substituting,

G(F(a+v))−G(F(a))−BAv  =  B r(v)  +  s(w(v)).G\bigl(F(a+v)\bigr) - G\bigl(F(a)\bigr) - BAv \;=\; B\,r(v) \; + \; s\bigl(w(v)\bigr) .

The first error. As in part 1 of the previous statement, ∣By∣≤C′∣y∣\lvert By\rvert \le C'\lvert y\rvert for a constant C′C', so ∣B r(v)∣≤C′∣r(v)∣\lvert B\,r(v)\rvert \le C'\lvert r(v)\rvert, which is o(∣v∣)o(\lvert v\rvert) because FF is differentiable at aa — the first hypothesis.

The second error. Likewise ∣Av∣≤C∣v∣\lvert Av\rvert \le C\lvert v\rvert, and ∣r(v)∣≤∣v∣\lvert r(v)\rvert \le \lvert v\rvert once ∣v∣\lvert v\rvert is small enough, so ∣w(v)∣≤(C+1)∣v∣\lvert w(v)\rvert \le (C+1)\lvert v\rvert for small ∣v∣\lvert v\rvert. Let ε>0\varepsilon > 0. Because GG is differentiable at bb — the second hypothesis — there is δ>0\delta > 0 with ∣s(w)∣≤ε∣w∣\lvert s(w)\rvert \le \varepsilon\lvert w\rvert whenever ∣w∣≤δ\lvert w\rvert \le \delta. For ∣v∣\lvert v\rvert small enough that ∣w(v)∣≤δ\lvert w(v)\rvert \le \delta we then have ∣s(w(v))∣≤ε(C+1)∣v∣\lvert s(w(v))\rvert \le \varepsilon(C+1)\lvert v\rvert. Since ε\varepsilon was arbitrary, ∣s(w(v))∣/∣v∣→0\lvert s(w(v))\rvert/\lvert v\rvert \to 0.

Conclusion. The right-hand side of the display is therefore o(∣v∣)o(\lvert v\rvert), so G∘FG \circ F is differentiable at aa with total derivative the composite linear map BA=DG(F(a))∘DF(a)BA = DG(F(a)) \circ DF(a). Passing to matrices in the standard bases, where composition of linear maps is matrix multiplication, gives JG∘F(a)=JG(F(a)) JF(a)J_{G\circ F}(a) = J_G(F(a))\,J_F(a), a p×mp \times m matrix times an m×nm \times n one.

Part 2. If FF and GG are C1C^1, then by part 2 of the previous statement each is differentiable at every point, so part 1 applies at every x∈Vx \in V. Reading off the (i,j)(i,j) entry of the matrix product, and using part 1 of the previous statement to identify entries of a Jacobian with partial derivatives,

∂(Gi∘F)∂xj(x)=∑k=1m∂Gi∂yk(F(x)) ∂Fk∂xj(x).\frac{\partial (G_i\circ F)}{\partial x_j}(x) = \sum_{k=1}^{m}\frac{\partial G_i}{\partial y_k}\bigl(F(x)\bigr)\,\frac{\partial F_k}{\partial x_j}(x) .

Each summand is a product of ∂Gi/∂yk∘F\partial G_i/\partial y_k \circ F, continuous as a composite of continuous maps, with ∂Fk/∂xj\partial F_k/\partial x_j, continuous by hypothesis; a finite sum of products of continuous functions is continuous, so every first partial derivative of G∘FG \circ F is continuous and G∘FG\circ F is C1C^1.

For higher orders, argue by induction on the order kk, writing the summation index over the intermediate variables as ℓ\ell to keep the two uses of the letter apart. The displayed formula writes each first partial derivative of G∘FG\circ F as a sum of products of (i) first partial derivatives ∂Gi/∂yℓ\partial G_i/\partial y_\ell of GG composed with FF and (ii) first partial derivatives ∂Fℓ/∂xj\partial F_\ell/\partial x_j of FF. If FF and GG are CkC^k with k≥2k \ge 2, those factors are Ck−1C^{k-1} maps — the composite (∂Gi/∂yℓ)∘F(\partial G_i/\partial y_\ell)\circ F by the induction hypothesis, applied to the Ck−1C^{k-1} maps ∂Gi/∂yℓ\partial G_i/\partial y_\ell and FF — and sums and products of Ck−1C^{k-1} functions are Ck−1C^{k-1}. So the first partial derivatives of G∘FG\circ F are Ck−1C^{k-1}, which says that G∘FG\circ F is CkC^k. The smooth case is the case of every kk. □\square

Method(Equality of mixed partial derivatives)AdaptedAdapted from Lee (2013), App. C, Prop. C.6 and Cor. C.7, p. 646

Let U⊆RnU \subseteq \mathbb{R}^n be open and let F:U→RmF : U \to \mathbb{R}^m be of class C2C^2. Then

∂2Fi∂xj ∂xk(x)=∂2Fi∂xk ∂xj(x)(i≤m, j,k≤n, x∈U).\frac{\partial^2 F_i}{\partial x_j \, \partial x_k}(x) = \frac{\partial^2 F_i}{\partial x_k \, \partial x_j}(x) \qquad (i \le m,\ j, k \le n,\ x \in U).

Lee's Cor. C.7 draws the consequence for smooth FF. By the same argument a function of class CrC^r has all its mixed partial derivatives of order at most rr independent of the order of differentiation, and a smooth function has this at every order; the extension to finite rr is ours, and the proof below gives it. For n=2n = 2 this leaves three independent second derivatives: fxxf_{xx}, fyyf_{yy} and the common value fxy=fyxf_{xy} = f_{yx}.

Idea of the proofOriginal

The two mixed partials are two ways of evaluating one object: the second difference of FF over a small coordinate rectangle, Δ=F(a+sej+tek)−F(a+sej)−F(a+tek)+F(a)\Delta = F(a + se_j + te_k) - F(a+se_j) - F(a+te_k) + F(a). Applying the one-variable mean value theorem first in one direction and then in the other turns Δ/st\Delta/st into a second partial derivative at some interior point of the rectangle, and doing the two directions in the opposite order turns it into the other second partial derivative at another interior point. Shrinking the rectangle sends both interior points to aa, and continuity of the second partials — the C2C^2 hypothesis — forces the two limits to agree.

ProofOriginal

It is enough to prove the identity for a real-valued function of two variables. The assertion involves only the component FiF_i and only the two coordinates xjx_j, xkx_k, so fix ii and fix the remaining n−2n-2 coordinates at their values at the point xx; write ff for the resulting function of the two free coordinates, which is C2C^2 on an open set because FF is, and write ∂1\partial_1, ∂2\partial_2 for the two partial derivatives, with ∂2∂1f\partial_2\partial_1 f meaning ∂2(∂1f)\partial_2(\partial_1 f), so that no convention about the order of the indices is needed. The claim is ∂1∂2f=∂2∂1f\partial_1\partial_2 f = \partial_2\partial_1 f at the point in question, which we take to be aa.

Fix r>0r > 0 with the square ∣s∣,∣t∣≤r\lvert s\rvert, \lvert t\rvert \le r about aa inside the open set, and for 0<∣s∣,∣t∣≤r0 < \lvert s\rvert, \lvert t\rvert \le r define the second difference

Δ(s,t)=f(a+se1+te2)−f(a+se1)−f(a+te2)+f(a).\Delta(s,t) = f(a + se_1 + te_2) - f(a + se_1) - f(a + te_2) + f(a) .

First order of differentiation. Put φ(u)=f(a+ue1+te2)−f(a+ue1)\varphi(u) = f(a + ue_1 + te_2) - f(a + ue_1), so that Δ(s,t)=φ(s)−φ(0)\Delta(s,t) = \varphi(s) - \varphi(0). Since ∂1f\partial_1 f exists on the square, φ\varphi is differentiable with φ′(u)=∂1f(a+ue1+te2)−∂1f(a+ue1)\varphi'(u) = \partial_1 f(a+ue_1+te_2) - \partial_1 f(a+ue_1), and the mean value theorem gives a σ\sigma between 00 and ss with Δ(s,t)=s φ′(σ)\Delta(s,t) = s\,\varphi'(\sigma). Now apply the mean value theorem again, to the function τ↦∂1f(a+σe1+τe2)\tau \mapsto \partial_1 f(a + \sigma e_1 + \tau e_2), which is differentiable because ∂2∂1f\partial_2\partial_1 f exists on the square: there is a τ\tau between 00 and tt with φ′(σ)=t ∂2∂1f(a+σe1+τe2)\varphi'(\sigma) = t\,\partial_2\partial_1 f(a + \sigma e_1 + \tau e_2). Hence

Δ(s,t)st=∂2∂1f(a+σe1+τe2),∣σ∣≤∣s∣, ∣τ∣≤∣t∣.\frac{\Delta(s,t)}{st} = \partial_2\partial_1 f(a + \sigma e_1 + \tau e_2), \qquad \lvert \sigma\rvert \le \lvert s\rvert,\ \lvert\tau\rvert \le \lvert t\rvert .

The other order. Δ(s,t)\Delta(s,t) is symmetric under exchanging the roles of the two coordinates together with ss and tt: grouping its four terms the other way, Δ(s,t)=ψ(t)−ψ(0)\Delta(s,t) = \psi(t) - \psi(0) with ψ(u)=f(a+se1+ue2)−f(a+ue2)\psi(u) = f(a + se_1 + ue_2) - f(a + ue_2). The same two applications of the mean value theorem, in the reverse order, give points σ′\sigma' between 00 and ss and τ′\tau' between 00 and tt with

Δ(s,t)st=∂1∂2f(a+σ′e1+τ′e2).\frac{\Delta(s,t)}{st} = \partial_1\partial_2 f(a + \sigma' e_1 + \tau' e_2) .

Let the rectangle shrink. Equating the two expressions and letting (s,t)→(0,0)(s,t) \to (0,0): both arguments converge to aa, since ∣σ∣,∣σ′∣≤∣s∣\lvert\sigma\rvert,\lvert\sigma'\rvert \le \lvert s\rvert and ∣τ∣,∣τ′∣≤∣t∣\lvert\tau\rvert,\lvert\tau'\rvert \le \lvert t\rvert, and both ∂2∂1f\partial_2\partial_1 f and ∂1∂2f\partial_1\partial_2 f are continuous at aa by the C2C^2 hypothesis. Therefore ∂2∂1f(a)=∂1∂2f(a)\partial_2\partial_1 f(a) = \partial_1\partial_2 f(a). This is the only step that uses continuity, and the remark below shows that the conclusion fails without it.

Higher orders for a CrC^r function. Let FF be CrC^r and consider a mixed partial derivative of order m≤rm \le r, taken in some order of the indices. Any permutation of mm symbols is a product of transpositions of adjacent symbols, so it suffices to show that exchanging two consecutive differentiations leaves the result unchanged. Those two act on a partial derivative of FF of order m−2≤r−2m - 2 \le r-2, which is a C2C^2 function because FF is CrC^r; the case already proved applies to it, and the exchange is legitimate. The smooth case is the case of every rr. □\square

NoteOriginal

What it means. Differentiability in several variables is the existence of a linear approximation, not the existence of the partial derivatives, which record only what FF does along the nn coordinate directions. Class C1C^1 is the practical bridge between the two, and it is the hypothesis almost every later theorem uses. Once FF is differentiable, everything first-order about it sits in one matrix, and the chain rule is matrix multiplication in the order "outer map first, evaluated at the image point".

Method(Differentiating a composite map)AdaptedAdapted from Lee (2013), App. C, Cor. C.11, p. 647; Riley, Hobson & Bence (2006), §5.2, Eq. (5.8), p. 154

To differentiate x↦G(F(x))x \mapsto G(F(x)):

  1. Name the stages: y=F(x)y = F(x) with x∈V⊆Rnx \in V \subseteq \mathbb{R}^n, y∈W⊆Rmy \in W \subseteq \mathbb{R}^m, and z=G(y)∈Rpz = G(y) \in \mathbb{R}^p, recording which letters are independent at each stage.
  2. Check that FF is C1C^1 near xx and GG is C1C^1 near F(x)F(x), or at least that each is differentiable at the relevant point.
  3. Multiply in the right order and at the right point: JG∘F(x)=JG(F(x)) JF(x)J_{G\circ F}(x) = J_G(F(x))\,J_F(x), the outer factor evaluated at y=F(x)y = F(x). The (i,j)(i,j) entry is the sum over intermediate variables of part 2 of the chain rule, one term per path from xjx_j to ziz_i.
  4. Specialise if the chain is a curve. With F=γF = \gamma a differentiable curve, ddtG(γ(t))=JG(γ(t)) γ′(t)\frac{d}{dt}G(\gamma(t)) = J_G(\gamma(t))\,\gamma'(t), and γ(t)=a+tv\gamma(t) = a + tv recovers DvG(a)D_v G(a).
  5. Iterate for higher derivatives, applying step 3 to each first-order expression together with the product rule; once both maps are C2C^2 the order of differentiation does not matter.

When it fails. Step 3 needs differentiability, not just the existence of partial derivatives (see the remark). It also fails silently if the outer Jacobian is evaluated at the wrong point, or if a variable is held fixed at one stage and varied at another.

RemarkOriginal

Where the hypotheses are used, and what fails without them.

  • Partial derivatives alone do not give continuity. Put f(x,y)=xy/(x2+y2)f(x,y) = xy/(x^2+y^2) for (x,y)≠(0,0)(x,y) \ne (0,0) and f(0,0)=0f(0,0) = 0. Then f(x,0)=f(0,y)=0f(x,0) = f(0,y) = 0, so fx(0,0)=fy(0,0)=0f_x(0,0) = f_y(0,0) = 0 exist; but f=12f = \tfrac12 on the line y=xy = x away from the origin, so ff is not continuous there, hence not differentiable, and any first-order formula built from the two partials alone — the chain rule included — is false for it at the origin.
  • Continuity of the partials in part 2 is sufficient, not necessary. Let f(x,y)=(x2+y2)sin⁡(1/(x2+y2))f(x,y) = (x^2+y^2)\sin(1/(x^2+y^2)) with f(0,0)=0f(0,0) = 0. Since ∣f(v)∣≤∣v∣2\lvert f(v)\rvert \le \lvert v\rvert^2, ff is differentiable at the origin with Df(0,0)=0Df(0,0) = 0; but fxf_x contains −2xcos⁡(1/(x2+y2))/(x2+y2)-2x\cos(1/(x^2+y^2))/(x^2+y^2), unbounded near the origin, so ff is differentiable everywhere without being C1C^1.
  • C2C^2 cannot be weakened to mere existence of the mixed partials. Let f(x,y)=xy(x2−y2)/(x2+y2)f(x,y) = xy(x^2-y^2)/(x^2+y^2) away from the origin, f(0,0)=0f(0,0) = 0. From the definition fx(0,y)=−yf_x(0,y) = -y and fy(x,0)=xf_y(x,0) = x, so both mixed second partials exist at the origin yet ∂2f/∂y ∂x(0,0)=−1≠1=∂2f/∂x ∂y(0,0)\partial^2 f/\partial y\,\partial x(0,0) = -1 \ne 1 = \partial^2 f/\partial x\,\partial y(0,0); what fails is their continuity. For such an ff the two readings of fxyf_{xy} named in the first definition also disagree.
  • A weaker hypothesis in one source. Riley, Hobson and Bence (p. 153) assert the equality of mixed partials under a weaker condition than the C2C^2 hypothesis of Lee's Prop. C.6 used above: they ask only for continuity of the second partials at the point concerned. The statement here follows Lee.
  • Notation that differs between fields. Physics and thermodynamics texts write (∂f/∂x)y(\partial f/\partial x)_y, listing the held variables as subscripts (Riley, Hobson and Bence, §5.1, p. 152), because one symbol often denotes different functions of different variable sets. Those books call df=∑j(∂f/∂xj)dxjdf = \sum_j (\partial f/\partial x_j)dx_j the total differential and df/dx1df/dx_1 along a curve the total derivative; here these are Df(a)Df(a) in coordinate differentials and the case n=1n=1 of the chain rule. The symbol ∂(x,y,z)/∂(u,v,w)\partial(x,y,z)/\partial(u,v,w) is standard in both fields and returns in the change-of-variables formula. A reader turning to Riley, Hobson and Bence (p. 205) should note that they write that determinant with the array transposed relative to the Jacobian matrix defined above: their rows are indexed by uu, vv, ww and their columns by xx, yy, zz, so their first row is ∂x/∂u\partial x/\partial u, ∂y/∂u\partial y/\partial u, ∂z/∂u\partial z/\partial u, whereas the first row of JFJ_F here is ∂x/∂u\partial x/\partial u, ∂x/∂v\partial x/\partial v, ∂x/∂w\partial x/\partial w. Transposition leaves the determinant unchanged but not the matrix.
  • Smoothness assumed by the source. Lee's Eq. (C.6) defines the directional derivative for smooth ff, and the identity Dvf(a)=∑jvj∂f/∂xj(a)=Df(a)vD_v f(a) = \sum_j v_j \partial f/\partial x_j(a) = Df(a)v is the display just after it (p. 647). Differentiability of ff at the single point aa already implies it, by the chain rule applied to t↦f(a+tv)t \mapsto f(a+tv), which is the form stated in part 1; the implication does not reverse, since all directional derivatives at aa can exist without ff being differentiable there.
Example(A chain rule computed both ways)Original

Take

F:R2→R3,F(u,v)=(u+v2,  uv,  e u−v),G:R3→R2,G(x,y,z)=(x2y,  y+xz),F : \mathbb{R}^2 \to \mathbb{R}^3, \quad F(u,v) = \bigl(u + v^2,\; uv,\; e^{\,u-v}\bigr), \qquad G : \mathbb{R}^3 \to \mathbb{R}^2, \quad G(x,y,z) = \bigl(x^2y,\; y + xz\bigr),

and compute JG∘FJ_{G\circ F} at (u,v)=(1,2)(u,v) = (1,2), following the method.

  1. Stages. (u,v)↦(x,y,z)=F(u,v)↦G(x,y,z)(u,v) \mapsto (x,y,z) = F(u,v) \mapsto G(x,y,z), with n=2n = 2, m=3m = 3, p=2p = 2. At the point, F(1,2)=(1+4,  2,  e−1)=(5, 2, e−1)F(1,2) = (1 + 4,\; 2,\; e^{-1}) = (5,\, 2,\, e^{-1}), so the outer factor must be evaluated at (x,y,z)=(5,2,e−1)(x,y,z) = (5, 2, e^{-1}) and nowhere else.

  2. Hypotheses. Every component of FF and of GG is a polynomial in the coordinates and the exponential, so all partial derivatives of all orders exist and are continuous: both maps are smooth, hence C1C^1, hence differentiable, and part 2 of the chain rule applies.

  3. The two Jacobians.

    JF(u,v)=(12vvue u−v−e u−v) →(1,2) (1421e−1−e−1),JG(x,y,z)=(2xyx20z1x) →(5,2,e−1) (20250e−115).J_F(u,v) = \begin{pmatrix} 1 & 2v \\ v & u \\ e^{\,u-v} & -e^{\,u-v}\end{pmatrix} \ \xrightarrow{(1,2)}\ \begin{pmatrix} 1 & 4 \\ 2 & 1 \\ e^{-1} & -e^{-1}\end{pmatrix}, \qquad J_G(x,y,z) = \begin{pmatrix} 2xy & x^2 & 0 \\ z & 1 & x \end{pmatrix} \ \xrightarrow{(5,2,e^{-1})}\ \begin{pmatrix} 20 & 25 & 0 \\ e^{-1} & 1 & 5\end{pmatrix}.
  4. Multiply, outer factor first.

    JG∘F(1,2)=(20250e−115)(1421e−1−e−1)=(701052+6e−11−e−1)=(701054.2072770.632121).J_{G\circ F}(1,2) = \begin{pmatrix} 20 & 25 & 0 \\ e^{-1} & 1 & 5\end{pmatrix} \begin{pmatrix} 1 & 4 \\ 2 & 1 \\ e^{-1} & -e^{-1}\end{pmatrix} = \begin{pmatrix} 70 & 105 \\ 2 + 6e^{-1} & 1 - e^{-1} \end{pmatrix} = \begin{pmatrix} 70 & 105 \\ 4.207277 & 0.632121\end{pmatrix}.

    For instance the (1,1)(1,1) entry is 20⋅1+25⋅2+0⋅e−1=7020\cdot1 + 25\cdot2 + 0\cdot e^{-1} = 70: one term for each intermediate variable, and the term through zz drops out because ∂G1/∂z=0\partial G_1/\partial z = 0.

  5. Check by composing first. Writing H=G∘FH = G \circ F out,

    H1(u,v)=(u+v2)2 uv,H2(u,v)=uv+(u+v2) e u−v,H_1(u,v) = (u+v^2)^2\,uv, \qquad H_2(u,v) = uv + (u+v^2)\,e^{\,u-v},

    and differentiating directly: ∂H1/∂u=2(u+v2)uv+(u+v2)2v\partial H_1/\partial u = 2(u+v^2)uv + (u+v^2)^2v, which at (1,2)(1,2) is 2⋅5⋅2+25⋅2=702\cdot5\cdot2 + 25\cdot2 = 70; ∂H1/∂v=4v(u+v2)uv+(u+v2)2u=4⋅2⋅5⋅2+25=105\partial H_1/\partial v = 4v(u+v^2)uv + (u+v^2)^2u = 4\cdot2\cdot5\cdot2 + 25 = 105; ∂H2/∂u=v+(1+u+v2)eu−v=2+6e−1\partial H_2/\partial u = v + (1 + u + v^2)e^{u-v} = 2 + 6e^{-1}; and ∂H2/∂v=u+(2v−u−v2)eu−v=1+(4−5)e−1=1−e−1\partial H_2/\partial v = u + (2v - u - v^2)e^{u-v} = 1 + (4-5)e^{-1} = 1 - e^{-1}. All four entries agree.

  6. A directional derivative. By part 1 of the first statement, the derivative of H1H_1 at (1,2)(1,2) along w=(1,−1)w = (1,-1) is JH1(1,2) w=70−105=−35J_{H_1}(1,2)\,w = 70 - 105 = -35. Equivalently ddtH1(1+t,2−t)∣t=0=−35\frac{d}{dt}H_1(1+t, 2-t)\big|_{t=0} = -35, which is step 4 of the method with the curve γ(t)=(1,2)+t(1,−1)\gamma(t) = (1,2) + t(1,-1).

  7. Mixed partials. H2H_2 is smooth, so the equality of mixed partials applies. Differentiating the expressions in step 5 once more, ∂2H2/∂u ∂v=∂u(u+(2v−u−v2)eu−v)=1+(2v−u−v2−1)eu−v\partial^2H_2/\partial u\,\partial v = \partial_u\bigl(u + (2v-u-v^2)e^{u-v}\bigr) = 1 + (2v - u - v^2 - 1)e^{u-v}, which is 1−2e−1=0.2642411 - 2e^{-1} = 0.264241 at (1,2)(1,2); and ∂2H2/∂v ∂u=∂v(v+(1+u+v2)eu−v)=1+(2v−1−u−v2)eu−v\partial^2H_2/\partial v\,\partial u = \partial_v\bigl(v + (1+u+v^2)e^{u-v}\bigr) = 1 + (2v - 1 - u - v^2)e^{u-v}, the same expression and the same value 1−2e−11 - 2e^{-1}. For a function that is not C2C^2 this agreement fails, as the third bullet of the remark shows.

ApplicationOriginal

Maxwell relations in thermodynamics. The equality of mixed partials is the whole content of the Maxwell relations. The Helmholtz free energy A(T,V)A(T,V) satisfies dA=−S dT−p dVdA = -S\,dT - p\,dV, so ∂A/∂T=−S\partial A/\partial T = -S and ∂A/∂V=−p\partial A/\partial V = -p as functions of (T,V)(T,V). If AA is C2C^2 on the region of the phase diagram concerned, then ∂2A/∂T ∂V=∂2A/∂V ∂T\partial^2A/\partial T\,\partial V = \partial^2A/\partial V\,\partial T, that is

(∂S∂V)T=(∂p∂T)V,\left(\frac{\partial S}{\partial V}\right)_T = \left(\frac{\partial p}{\partial T}\right)_V ,

which converts a quantity that cannot be measured directly (the volume dependence of the entropy) into one that can (the pressure rise at fixed volume). Each thermodynamic potential gives one such relation the same way. The C2C^2 hypothesis is not idle: it fails at a phase boundary, where second derivatives of the potential jump or diverge, and the classification of transitions into first and second order is precisely a statement about which derivative of the potential first misbehaves.

Changing coordinates. Every curvilinear calculation is the chain rule with FF the coordinate map. For plane polars, F(r,θ)=(rcos⁡θ,rsin⁡θ)F(r,\theta) = (r\cos\theta, r\sin\theta) has JF=(cos⁡θ−rsin⁡θsin⁡θrcos⁡θ)J_F = \begin{pmatrix} \cos\theta & -r\sin\theta\\ \sin\theta & r\cos\theta\end{pmatrix} with determinant rr; the chain rule then expresses ∂/∂r\partial/\partial r and ∂/∂θ\partial/\partial\theta in terms of ∂/∂x\partial/\partial x and ∂/∂y\partial/\partial y, and inverting that relation (possible exactly where the Jacobian determinant is non-zero, so not at the origin) is how the Laplacian is transformed. The determinant rr reappears as the area element, which is the subject of the change-of-variables formula.

Material derivatives in continuum mechanics. A quantity ϕ\phi carried by a moving fluid is observed along a particle path t↦x(t)t \mapsto x(t), so the rate of change seen by the particle is the chain rule applied to t↦ϕ(x(t),t)t \mapsto \phi(x(t), t): DϕDt=∂ϕ/∂t+∑jx˙j ∂ϕ/∂xj=ϕt+v⋅∇ϕ\frac{D\phi}{Dt} = \partial\phi/\partial t + \sum_j \dot x_j\,\partial\phi/\partial x_j = \phi_t + v\cdot\nabla\phi. Step 4 of the method, the case of a curve, is exactly this computation, and the warning in the method about which variables are held fixed at which stage is the reason the convective term is so often dropped by mistake: ∂ϕ/∂t\partial\phi/\partial t at fixed position and Dϕ/DtD\phi/Dt following the fluid are different functions written with similar symbols.

Theorem

Taylor expansion and critical points in several variables

Adapted

Gives the second-order Taylor expansion of a C2C^2 function of nn variables in Peano and mean-value form, and classifies a critical point as a strict local minimum, a strict local maximum or a saddle according as the Hessian there is positive definite, negative definite or indefinite, with no conclusion when it is singular and semidefinite.

Prerequisites: Partial derivatives and the chain rule, Taylor's theorem, Quadratic forms and the Rayleigh quotient

Definition(Gradient, Hessian, critical point, definiteness)AdaptedAdapted from Riley, Hobson & Bence (2006), §5.8, pp. 162–163 and pp. 166–167; Lee (2013), App. C, Prop. C.6, p. 646

Let U⊆RnU \subseteq \mathbb{R}^n be open and f:U→Rf : U \to \mathbb{R}.

  • If ff is differentiable at a∈Ua \in U, its gradient there is the column vector ∇f(a)=(∂f/∂x1(a),…,∂f/∂xn(a))T\nabla f(a) = \bigl(\partial f/\partial x_1(a), \dots, \partial f/\partial x_n(a)\bigr)^{\mathsf T}, so that Df(a)h=∇f(a)⋅hDf(a)h = \nabla f(a) \cdot h.
  • If ff is of class C2C^2 on UU, its Hessian at aa is the n×nn \times n matrix Hf(a)=(∂2f∂xi ∂xj(a))i,j≤n,H_f(a) = \left( \frac{\partial^2 f}{\partial x_i \, \partial x_j}(a) \right)_{i,j \le n}, the entry in row ii and column jj being ∂i(∂jf)(a)\partial_i\bigl(\partial_j f\bigr)(a) — the rightmost index differentiated first, the convention fixed in the unit on partial derivatives. That unit's equality of mixed partials makes Hf(a)H_f(a) symmetric because ff is C2C^2, so which index is read first makes no difference here.
  • a∈Ua \in U is a critical point (or stationary point) of ff if ff is differentiable at aa and ∇f(a)=0\nabla f(a) = 0.
  • aa is a local minimum of ff if f(x)≥f(a)f(x) \ge f(a) for all xx in some ball Br(a)⊆UB_r(a) \subseteq U, and a strict local minimum if f(x)>f(a)f(x) > f(a) for all x∈Br(a)x \in B_r(a) with x≠ax \neq a; local maxima are defined with the inequalities reversed. A saddle point is a critical point that is neither a local minimum nor a local maximum.
  • A real symmetric n×nn \times n matrix HH is positive definite if hTHh>0h^{\mathsf T} H h > 0 for every h≠0h \ne 0, positive semidefinite if hTHh≥0h^{\mathsf T} H h \ge 0 for every hh, negative (semi)definite if −H-H is positive (semi)definite, and indefinite if uTHu>0u^{\mathsf T} H u > 0 and wTHw<0w^{\mathsf T} H w < 0 for some u,w∈Rnu, w \in \mathbb{R}^n. Its eigenvalues are real, and the eigenvalue test of quadratic forms makes HH positive definite exactly when all of them are positive and positive semidefinite exactly when none of them is negative. Applied to −H-H, whose eigenvalues are −λ-\lambda for each eigenvalue λ\lambda of HH, the same test makes HH negative definite exactly when all are negative and negative semidefinite exactly when none is positive. The indefinite case is not among the ones that unit states, but it follows from those two: being indefinite is exactly failing both semidefiniteness conditions, so HH is indefinite exactly when some eigenvalue is positive and some is negative.
Theorem(Second-order Taylor expansion)AdaptedAdapted from Riley, Hobson & Bence (2006), §5.7, Eqs. (5.18) and (5.20), pp. 160–162; Lee (2013), App. C, Thm C.15, p. 648

Let U⊆RnU \subseteq \mathbb{R}^n be open, let f:U→Rf : U \to \mathbb{R} be of class C2C^2 on UU and let a∈Ua \in U. Then, as h→0h \to 0,

f(a+h)=f(a)+∑j=1n∂f∂xj(a) hj+12∑j=1n∑k=1n∂2f∂xj ∂xk(a) hjhk+o(∣h∣2),f(a + h) = f(a) + \sum_{j=1}^{n} \frac{\partial f}{\partial x_j}(a)\, h_j + \frac{1}{2} \sum_{j=1}^{n} \sum_{k=1}^{n} \frac{\partial^2 f}{\partial x_j \, \partial x_k}(a)\, h_j h_k + o\bigl(\lvert h \rvert^2\bigr),

that is, the difference between f(a+h)f(a+h) and the quadratic polynomial written here, divided by ∣h∣2\lvert h \rvert^2, tends to 00. The single sum is ∇f(a)⋅h\nabla f(a)\cdot h and the double sum is hTHf(a) hh^{\mathsf T} H_f(a)\, h.

If ff is of class Ck+1C^{k+1} on UU and W⊆UW \subseteq U is convex with a∈Wa \in W, the expansion continues to order kk for every x∈Wx \in W: f(x)f(x) equals its kkth Taylor polynomial at aa plus a remainder given by an explicit integral of the (k+1)(k+1)st partial derivatives along the segment from aa to xx.

Neither cited source states the o(∣h∣2)o(\lvert h\rvert^2) remainder; what each of them does state, and how the display follows, is set out in the remark on provenance below.

Theorem(Mean-value form of the second-order expansion)Original

Let U⊆RnU \subseteq \mathbb{R}^n be open, let f:U→Rf : U \to \mathbb{R} be of class C2C^2 on UU, let a∈Ua \in U and let h∈Rnh \in \mathbb{R}^n be such that the closed segment {a+th:0≤t≤1}\{a + th : 0 \le t \le 1\} lies in UU. Then there is some θ∈(0,1)\theta \in (0,1), depending on aa and hh, with

f(a+h)=f(a)+∇f(a)⋅h+12 hTHf(a+θh) h.f(a + h) = f(a) + \nabla f(a) \cdot h + \tfrac{1}{2}\, h^{\mathsf T} H_f(a + \theta h)\, h .

Neither cited source states this form; see the remark on provenance below.

Idea of the proof(Both expansions, from one variable)Original

Restrict ff to the segment through aa in the direction hh. The function g(t)=f(a+th)g(t) = f(a+th) of the single variable tt has g′(t)=∇f(a+th)⋅hg'(t) = \nabla f(a+th)\cdot h and g′′(t)=hTHf(a+th) hg''(t) = h^{\mathsf T} H_f(a+th)\,h, by the chain rule, so one-variable Taylor's theorem with the Lagrange remainder applied to gg on [0,1][0,1] is the mean-value form. The o(∣h∣2)o(\lvert h\rvert^2) form follows from it by replacing Hf(a+θh)H_f(a+\theta h) with Hf(a)H_f(a): what that costs is at most ∣h∣2\lvert h \rvert^2 times the amount by which the second partial derivatives vary on the ball of radius ∣h∣\lvert h\rvert about aa, and that amount tends to 00 as h→0h \to 0 precisely because ff is C2C^2.

Proof(Mean-value form)AdaptedAdapted from Lee (2013), App. C, Thm C.15 and its proof, p. 648

Let UU, ff, aa and hh be as in the statement. If h=0h = 0 every θ\theta works, so assume h≠0h \neq 0.

  • The one-variable function is defined on an open set containing [0,1][0,1]. The set T={t∈R:a+th∈U}T = \{t \in \mathbb{R} : a + th \in U\} is the preimage of the open set UU under the continuous map t↦a+tht \mapsto a+th, hence open, and it contains [0,1][0,1] because the closed segment lies in UU — the hypothesis on hh. Every t∈[0,1]t \in [0,1], the end points included, therefore has an open interval about it inside TT, so derivatives taken below at t=0t = 0 and t=1t = 1 are two-sided ones, exactly like those at interior points. No other property of TT is used.
  • Its derivatives are the directional derivatives of ff. On TT put g(t)=f(a+th)g(t) = f(a+th). The map t↦a+tht \mapsto a+th is affine, so the chain rule applies and gives g′(t)=∑j=1n∂f∂xj(a+th) hj=∇f(a+th)⋅h,g'(t) = \sum_{j=1}^{n} \frac{\partial f}{\partial x_j}(a+th)\, h_j = \nabla f(a+th)\cdot h , and applying it once more to each term, g′′(t)=∑j=1n∑k=1n∂2f∂xk ∂xj(a+th) hjhk=hTHf(a+th) h.g''(t) = \sum_{j=1}^{n}\sum_{k=1}^{n} \frac{\partial^2 f}{\partial x_k \,\partial x_j}(a+th)\, h_j h_k = h^{\mathsf T} H_f(a+th)\, h . Because ff is C2C^2 on UU, all the first and second partial derivatives appearing here are continuous, so g′′g'' is continuous on TT and in particular on [0,1][0,1].
  • Apply the one-variable theorem. Taylor's theorem with N=1N = 1, expansion point 00 and evaluation point 11 requires exactly that g′′g'' exist and be continuous on [0,1][0,1], which the previous step supplies. Its Lagrange remainder gives a point θ\theta between 00 and 11 with g(1)=g(0)+g′(0)+12g′′(θ).g(1) = g(0) + g'(0) + \tfrac{1}{2} g''(\theta) . As that unit states the conclusion, θ\theta lies in the closed interval [0,1][0,1], and that is all the rest of this unit uses: every later appeal to the mean-value form needs only ∣θh∣≤∣h∣\lvert \theta h\rvert \le \lvert h\rvert. The strict inclusion θ∈(0,1)\theta \in (0,1) asserted in the statement comes from the sharper version recorded in that unit's remark on its hypotheses, where it is enough that g′g' be continuous on [0,1][0,1] and g′′g'' exist at every interior point, and θ\theta may then be taken strictly between the end points. Both conditions hold here, since gg is C2C^2 on the open set T⊇[0,1]T \supseteq [0,1].
  • Read the terms back. g(1)=f(a+h)g(1) = f(a+h), g(0)=f(a)g(0) = f(a), g′(0)=∇f(a)⋅hg'(0) = \nabla f(a)\cdot h and g′′(θ)=hTHf(a+θh)hg''(\theta) = h^{\mathsf T}H_f(a+\theta h)h, which is the display of the statement. □\square

The reduction to the single variable tt along the segment is the route of Lee's Thm C.15; he carries it to order kk and keeps an integral remainder, whereas the Lagrange remainder of our one-variable unit is what produces the intermediate point θ\theta.

Proof(The o(∣h∣2)o(\lvert h \rvert^2) form)Original

Write H=Hf(a)H = H_f(a) and let P(h)=f(a)+∇f(a)⋅h+12hTHhP(h) = f(a) + \nabla f(a)\cdot h + \tfrac12 h^{\mathsf T}Hh be the quadratic polynomial of the statement, whose two sums are the ones displayed there.

  • A ball on which the mean-value form is available. UU is open, so fix r>0r > 0 with Br(a)⊆UB_r(a) \subseteq U. For 0<∣h∣<r0 < \lvert h\rvert < r the closed segment from aa to a+ha+h lies in the convex set Br(a)⊆UB_r(a) \subseteq U, so the mean-value form applies and yields a θ=θ(h)∈(0,1)\theta = \theta(h) \in (0,1) with f(a+h)−P(h)=12 hT[Hf(a+θh)−H]h.f(a+h) - P(h) = \tfrac12\, h^{\mathsf T}\bigl[ H_f(a+\theta h) - H \bigr] h .
  • A crude bound for a quadratic form. For any real n×nn \times n matrix AA, ∣hTAh∣≤∑j,k∣Ajk∣∣hj∣∣hk∣≤(max⁡j,k∣Ajk∣)(∑j∣hj∣)2≤n(max⁡j,k∣Ajk∣)∣h∣2,\bigl\lvert h^{\mathsf T} A h \bigr\rvert \le \sum_{j,k} \lvert A_{jk}\rvert \lvert h_j\rvert \lvert h_k \rvert \le \Bigl(\max_{j,k} \lvert A_{jk}\rvert\Bigr) \Bigl( \sum_{j} \lvert h_j \rvert \Bigr)^{2} \le n \Bigl(\max_{j,k}\lvert A_{jk}\rvert\Bigr) \lvert h \rvert^2 , the last step by the Cauchy–Schwarz inequality (∑j∣hj∣)2≤n∑jhj2\bigl(\sum_j \lvert h_j\rvert\bigr)^2 \le n \sum_j h_j^2.
  • The matrix in question is small. For 0≤s<r0 \le s < r put ω(s)=max⁡j,k  sup⁡∣u∣≤s∣∂2f∂xj ∂xk(a+u)−∂2f∂xj ∂xk(a)∣.\omega(s) = \max_{j,k} \; \sup_{\lvert u \rvert \le s} \left\lvert \frac{\partial^2 f}{\partial x_j\,\partial x_k}(a+u) - \frac{\partial^2 f}{\partial x_j \,\partial x_k}(a) \right\rvert . Each second partial derivative is continuous at aa, because ff is C2C^2; there are finitely many of them, so ω(s)→0\omega(s) \to 0 as s→0+s \to 0^+. Since ∣θh∣≤∣h∣\lvert \theta h\rvert \le \lvert h \rvert, the entries of Hf(a+θh)−HH_f(a+\theta h) - H are bounded in modulus by ω(∣h∣)\omega(\lvert h\rvert).
  • Conclude. Combining the three previous steps, ∣f(a+h)−P(h)∣≤12n ω(∣h∣) ∣h∣2\lvert f(a+h) - P(h)\rvert \le \tfrac12 n\, \omega(\lvert h\rvert)\, \lvert h\rvert^2 for 0<∣h∣<r0 < \lvert h \rvert < r, so ∣f(a+h)−P(h)∣∣h∣2≤12n ω(∣h∣)→h→00,\frac{\lvert f(a+h) - P(h)\rvert}{\lvert h\rvert^{2}} \le \tfrac12 n\, \omega(\lvert h\rvert) \xrightarrow[h \to 0]{} 0 , which is the assertion f(a+h)=P(h)+o(∣h∣2)f(a+h) = P(h) + o(\lvert h\rvert^2). □\square

Only a ball about aa was used, so this form needs no convexity hypothesis on UU, as the statement records.

RemarkAdaptedAdapted from Riley, Hobson & Bence (2006), §5.7, Eqs. (5.18) and (5.20), pp. 160–162, and §5.8, pp. 164 and 167; Lee (2013), App. C, Thm C.15 and Eqs. (C.7)–(C.9), p. 648

What the sources state, and what is ours.

  • The o(∣h∣2)o(\lvert h\rvert^2) remainder. Riley, Hobson and Bence write Eqs. (5.18) and (5.20) as a formal series ending in "+⋯+\cdots", with no remainder estimate at all. Lee's Thm C.15 does give an exact remainder, but it is not the one displayed above: taking k=1k = 1 there — the case whose hypothesis is exactly f∈C2f \in C^2 — produces the first-order Taylor polynomial, with f(a+h)=f(a)+∇f(a)⋅h+R1(h),R1(h)=∑j=1n∑k=1nhjhk∫01(1−t) ∂2f∂xj ∂xk(a+th) dt,f(a+h) = f(a) + \nabla f(a)\cdot h + R_1(h), \qquad R_1(h) = \sum_{j=1}^{n}\sum_{k=1}^{n} h_j h_k \int_0^1 (1-t)\, \frac{\partial^2 f}{\partial x_j \, \partial x_k}(a+th)\, dt , valid whenever the segment from aa to a+ha+h lies in a convex subset of UU, so for all small ∣h∣\lvert h\rvert. This R1(h)R_1(h) is not o(∣h∣2)o(\lvert h\rvert^2): it carries the quadratic term itself. (For n=1n = 1, f(x)=x2f(x) = x^2 and a=0a = 0 the first-order polynomial is 00 while R1(h)=h2R_1(h) = h^2.)
  • How the display follows from it, which is ours. R1R_1 splits. Since ∫01(1−t) dt=12\int_0^1 (1-t)\,dt = \tfrac12, subtracting and adding the value of each second partial derivative at aa gives R1(h)=12 hTHf(a) h  +  ∑j=1n∑k=1nhjhk∫01(1−t)[∂2f∂xj ∂xk(a+th)−∂2f∂xj ∂xk(a)]dt,R_1(h) = \tfrac12\, h^{\mathsf T} H_f(a)\, h \;+\; \sum_{j=1}^{n}\sum_{k=1}^{n} h_j h_k \int_0^1 (1-t)\left[ \frac{\partial^2 f}{\partial x_j\,\partial x_k}(a+th) - \frac{\partial^2 f}{\partial x_j\,\partial x_k}(a) \right] dt , and it is the second piece alone that is o(∣h∣2)o(\lvert h\rvert^2), because the second partial derivatives are continuous at aa and so the brackets tend to 00 uniformly in t∈[0,1]t \in [0,1] as h→0h \to 0. The displayed expansion is therefore a consequence of Lee's case k=1k = 1 and not that case itself. The splitting is ours, and so is the route actually taken in the two proofs above, which reaches the same o(∣h∣2)o(\lvert h\rvert^2) statement from the mean-value form instead of from the integral remainder.
  • The mean-value form. Neither source states it. It is Taylor's theorem with the Lagrange remainder, applied to the one-variable function t↦f(a+th)t \mapsto f(a+th) on [0,1][0,1], and the reduction to that one variable is the only thing it shares with Lee's Thm C.15.
  • The word "strict" in the classification. Riley, Hobson and Bence give the two-variable criteria on p. 164 and the eigenvalue criteria on p. 167, and both are phrased with "minima" and "maxima"; neither says strict. The strengthening to strict local extrema in parts 1 and 2 of the next statement goes beyond those pages and is ours. What supplies it is the remainder estimate in the proof below: it bounds ∣R(h)∣\lvert R(h)\rvert by a fraction of λ1∣h∣2\lambda_1\lvert h\rvert^2, which gives a sign of f(a+h)−f(a)f(a+h) - f(a) at every h≠0h \ne 0 in a punctured ball, not merely a weak inequality.
Theorem(Classification of a critical point by the Hessian)AdaptedAdapted from Riley, Hobson & Bence (2006), §5.8, pp. 164 and 167

Let U⊆RnU \subseteq \mathbb{R}^n be open, let f:U→Rf : U \to \mathbb{R} be of class C2C^2 on UU, let a∈Ua \in U satisfy ∇f(a)=0\nabla f(a) = 0, and put H=Hf(a)H = H_f(a).

  1. If HH is positive definite, aa is a strict local minimum of ff.
  2. If HH is negative definite, aa is a strict local maximum of ff.
  3. If HH is indefinite, aa is a saddle point; more precisely, every ball Br(a)⊆UB_r(a) \subseteq U contains points where f>f(a)f > f(a) and points where f<f(a)f < f(a).

In two variables, with D=det⁡H=fxxfyy−fxy2D = \det H = f_{xx}f_{yy} - f_{xy}^2 evaluated at aa:

  • D>0D > 0 and fxx>0f_{xx} > 0: strict local minimum (then fyy>0f_{yy} > 0 automatically);
  • D>0D > 0 and fxx<0f_{xx} < 0: strict local maximum (then fyy<0f_{yy} < 0 automatically);
  • D<0D < 0: saddle point;
  • D=0D = 0: the test does not classify the point. (It is not quite silent: the next statement says what is still excluded and what is not.)
Idea of the proof(Why the Hessian decides)AdaptedAdapted from Riley, Hobson & Bence (2006), §5.8, pp. 166–167

At a critical point the linear term of the expansion is absent, so f(a+h)−f(a)f(a+h) - f(a) is the quadratic form 12hTHh\tfrac12 h^{\mathsf T}Hh plus an error small compared with ∣h∣2\lvert h\rvert^2. In an orthonormal eigenbasis of HH the form becomes 12∑rλrar2\tfrac12\sum_r \lambda_r a_r^2, so the signs of the eigenvalues say which signs the form takes. A definite form does more: on the unit sphere it is bounded away from zero, by the extreme eigenvalue, and that margin is a fixed multiple of ∣h∣2\lvert h \rvert^2, which the error cannot overcome. When the form takes both signs one need only walk along the two directions that witness this.

Proof(Classification of a critical point)AdaptedAdapted from Riley, Hobson & Bence (2006), §5.8, pp. 164, 166–167

Throughout, ∇f(a)=0\nabla f(a) = 0 and H=Hf(a)H = H_f(a), which is symmetric because ff is C2C^2. The second-order expansion proved above then reads

f(a+h)−f(a)=12 hTHh+R(h),R(h)∣h∣2→0 as h→0.f(a+h) - f(a) = \tfrac12\, h^{\mathsf T}Hh + R(h), \qquad \frac{R(h)}{\lvert h\rvert^2} \to 0 \text{ as } h \to 0 .

The five numbered items below are the steps of the argument, not the parts of the statement: items 1 and 2 together prove part 1, item 3 proves part 2, item 4 proves part 3, and item 5 is the two-variable specialisation. Each item names the part it serves.

  1. Part 1, the quadratic form has a margin. The eigenvalues λ1≤⋯≤λn\lambda_1 \le \cdots \le \lambda_n of HH are real and, by the eigenvalue test for definiteness, all positive, so λ1>0\lambda_1 > 0. The Rayleigh bound of quadratic forms gives hTHh≥λ1∣h∣2h^{\mathsf T}Hh \ge \lambda_1 \lvert h\rvert^2 for every hh.
  2. Part 1 concluded: positive definite gives a strict local minimum. Because R(h)=o(∣h∣2)R(h) = o(\lvert h\rvert^2) and UU is open, there is r>0r > 0 with Br(a)⊆UB_r(a) \subseteq U and ∣R(h)∣≤14λ1∣h∣2\lvert R(h)\rvert \le \tfrac14 \lambda_1 \lvert h\rvert^2 whenever ∣h∣<r\lvert h \rvert < r — this is the definition of the limit in the display, with 14λ1\tfrac14\lambda_1 as the tolerance, and it is here that positive definiteness, not mere semidefiniteness, is used: the tolerance has to be a positive multiple of ∣h∣2\lvert h\rvert^2. Hence for 0<∣h∣<r0 < \lvert h \rvert < r f(a+h)−f(a)≥12λ1∣h∣2−14λ1∣h∣2=14λ1∣h∣2>0,f(a+h) - f(a) \ge \tfrac12\lambda_1\lvert h\rvert^2 - \tfrac14\lambda_1\lvert h\rvert^2 = \tfrac14 \lambda_1 \lvert h \rvert^2 > 0 , so aa is a strict local minimum.
  3. Part 2: negative definite. Apply part 1 to −f-f, which is C2C^2, has ∇(−f)(a)=0\nabla(-f)(a) = 0 and H−f(a)=−HH_{-f}(a) = -H positive definite; a strict local minimum of −f-f at aa is a strict local maximum of ff.
  4. Part 3: indefinite gives a saddle. Choose uu with uTHu>0u^{\mathsf T}Hu > 0; then u≠0u \neq 0. For t≠0t \neq 0 with a+tu∈Ua + tu \in U, f(a+tu)−f(a)=t2(12uTHu+R(tu)t2),R(tu)t2=∣u∣2 R(tu)∣tu∣2→t→00,f(a+tu) - f(a) = t^2\left( \tfrac12 u^{\mathsf T}Hu + \frac{R(tu)}{t^2} \right), \qquad \frac{R(tu)}{t^{2}} = \lvert u\rvert^{2}\,\frac{R(tu)}{\lvert tu\rvert^{2}} \xrightarrow[t \to 0]{} 0 , so the bracket is positive for all small enough ∣t∣≠0\lvert t\rvert \neq 0 and f(a+tu)>f(a)f(a+tu) > f(a) there. The same argument with ww, for which wTHw<0w^{\mathsf T}Hw < 0, gives points with f<f(a)f < f(a). Every ball Bρ(a)⊆UB_\rho(a) \subseteq U contains a+tua + tu and a+twa+tw for all small ∣t∣≠0\lvert t \rvert \ne 0, so each contains points of both kinds; in particular aa is neither a local minimum nor a local maximum, that is, a saddle point.
  5. The two-variable criteria, from parts 1–3. Here HH has eigenvalues λ1,λ2\lambda_1, \lambda_2 with λ1λ2=det⁡H=D\lambda_1\lambda_2 = \det H = D and λ1+λ2=tr⁡H=fxx+fyy\lambda_1 + \lambda_2 = \operatorname{tr} H = f_{xx} + f_{yy}, and fxx=e1THe1f_{xx} = e_1^{\mathsf T}He_1 with e1=(1,0)Te_1 = (1,0)^{\mathsf T}.
    • If D>0D > 0 the two eigenvalues share a sign. Were both negative, HH would be negative definite and fxx=e1THe1f_{xx} = e_1^{\mathsf T}He_1 would be negative; so if also fxx>0f_{xx} > 0, both are positive, HH is positive definite and part 1 applies. Moreover fyy=(D+fxy2)/fxx>0f_{yy} = (D + f_{xy}^2)/f_{xx} > 0, which is the parenthetical claim.
    • If D>0D > 0 and fxx<0f_{xx} < 0, apply the previous case to −f-f, whose determinant is again DD and whose (1,1)(1,1) entry is −fxx>0-f_{xx} > 0.
    • If D<0D < 0 the eigenvalues have opposite signs, so HH is indefinite and part 3 applies.
    • If D=0D = 0 then 00 is an eigenvalue. If tr⁡H≠0\operatorname{tr}H \neq 0 the eigenvalues are 00 and tr⁡H\operatorname{tr}H, of one sign only, so HH is semidefinite; if tr⁡H=0\operatorname{tr}H = 0 both eigenvalues vanish and H=0H = 0, since a symmetric matrix is orthogonally diagonalisable. Either way HH is singular and semidefinite, so none of parts 1–3 applies, and the next statement shows that the three-way classification cannot be completed from HH alone — although, when H≠0H \neq 0, it still excludes one of the two kinds of extremum. □\square

Reading the signs of the quadratic form off the eigenvalues of HH, after expanding the displacement in an orthonormal eigenbasis, is the route of Riley, Hobson and Bence (pp. 166–167, with the two-variable criteria on p. 164). Step 1 reaches the one consequence of that expansion it needs — the lower bound λ1∣h∣2\lambda_1\lvert h\rvert^2 — by quoting the Rayleigh bound of quadratic forms instead of expanding; step 5 uses the eigenvalue signs directly, as they do. They argue with the quadratic approximation itself; the remainder estimates in steps 2 and 4, which are what turn a sign of the form into a sign of f(a+h)−f(a)f(a+h)-f(a), are ours.

Theorem(The converse, and the cases the Hessian does not decide)Original

Let U⊆RnU \subseteq \mathbb{R}^n be open, let f:U→Rf : U \to \mathbb{R} be of class C2C^2 on UU, let a∈Ua \in U satisfy ∇f(a)=0\nabla f(a) = 0 and put H=Hf(a)H = H_f(a), as in the previous statement.

  1. If aa is a local minimum of ff, then HH is positive semidefinite; if aa is a local maximum, HH is negative semidefinite.
  2. Suppose HH is semidefinite and singular, so that none of parts 1–3 applies (part 4 may still apply). Then:
    • if HH is positive semidefinite and H≠0H \neq 0, aa is not a local maximum, by part 4; but each of the three remaining possibilities occurs — a strict local minimum, a local minimum that is not strict, and no local extremum at all — and HH does not distinguish them, since all three occur among functions with the same ∇f(a)=0\nabla f(a) = 0 and the same Hf(a)H_f(a);
    • if HH is negative semidefinite and H≠0H \neq 0, symmetrically, aa is not a local minimum, and the three mirror-image possibilities — a strict local maximum, a non-strict local maximum, and no local extremum — all occur;
    • if H=0H = 0, nothing is excluded: aa may be a strict local minimum, a strict local maximum, a non-strict local extremum, or no local extremum at all.

So in the singular semidefinite case the Hessian fixes at most the sign of the extremum that is still possible, never whether there is one.

Idea of the proof(The converse, and why the degenerate cases are undecidable)Original

Part 4 is the expansion read along a single ray: if ff does not fall below f(a)f(a) nearby, then the quadratic term, which dominates for small tt, cannot be negative in any direction. Part 5 asks for the opposite of a theorem — functions that the Hessian cannot tell apart — so it has to be settled by constructing them, and the eigenbasis of HH hands them over. Split the coordinates into the directions where the form is positive and the directions where it vanishes; adding a quartic in the vanishing directions changes neither the gradient nor the Hessian at aa, and its sign, or its absence, decides what happens there.

Proof(The converse, and the cases the Hessian does not decide)Original

Write H=Hf(a)H = H_f(a), symmetric since ff is C2C^2, and keep the expansion f(a+h)−f(a)=12hTHh+R(h)f(a+h) - f(a) = \tfrac12 h^{\mathsf T}Hh + R(h) with R(h)=o(∣h∣2)R(h) = o(\lvert h\rvert^2), as in the previous proof.

Part 4. Let aa be a local minimum, so f(a+h)≥f(a)f(a+h) \ge f(a) for ∣h∣<ρ\lvert h\rvert < \rho, some ρ>0\rho > 0. Fix h≠0h \ne 0. For 0<t<ρ/∣h∣0 < t < \rho/\lvert h\rvert the point a+tha + th lies in that ball, so

0≤f(a+th)−f(a)=t2(12hTHh+∣h∣2R(th)∣th∣2).0 \le f(a+th) - f(a) = t^2\left( \tfrac12 h^{\mathsf T}Hh + \lvert h\rvert^2 \frac{R(th)}{\lvert th\rvert^2} \right).

Dividing by t2>0t^2 > 0 and letting t→0+t \to 0^+, the last term vanishes and hTHh≥0h^{\mathsf T}Hh \ge 0 remains. As hh was arbitrary, HH is positive semidefinite. If aa is a local maximum, apply this to −f-f to get −H-H positive semidefinite, that is HH negative semidefinite.

Part 5, the constructions. Let HH be positive semidefinite and singular. By the principal-axes theorem (quadratic forms) choose an orthonormal basis q1,…,qnq_1, \dots, q_n of eigenvectors, with eigenvalues λ1,…,λn\lambda_1, \dots, \lambda_n; none is negative, by semidefiniteness, and at least one is 00, by singularity, so we may order them as λ1,…,λp>0\lambda_1, \dots, \lambda_p > 0 and λp+1=⋯=λn=0\lambda_{p+1} = \cdots = \lambda_n = 0 with 0≤p≤n−10 \le p \le n-1. Put yj(x)=qj⋅(x−a)y_j(x) = q_j \cdot (x - a), so that y=(y1,…,yn)y = (y_1, \dots, y_n) are orthonormal coordinates centred at aa, and let

q(y)=12∑j≤pλjyj2,q(y) = \tfrac12\sum_{j \le p} \lambda_j y_j^{2},

which is the quadratic form of HH in these coordinates: q(y(x))=12(x−a)TH(x−a)q(y(x)) = \tfrac12 (x-a)^{\mathsf T}H(x-a).

Each yjy_j is an affine function of xx with ∇yj=qj\nabla y_j = q_j, so for a polynomial φ\varphi in yy with no constant and no linear term, the function x↦f(a)+φ(y(x))x \mapsto f(a) + \varphi(y(x)) has gradient 00 at aa, and its Hessian at aa is ∑j,k∂2φ/∂yj∂yk(0) qjqkT\sum_{j,k}\partial^2\varphi/\partial y_j\partial y_k(0)\, q_jq_k^{\mathsf T}. In particular each of

Φ1=f(a)+q(y)+∑j>pyj4,Φ2=f(a)+q(y),Φ3=f(a)+q(y)−yn4\Phi_1 = f(a) + q(y) + \sum_{j>p} y_j^{4}, \qquad \Phi_2 = f(a) + q(y), \qquad \Phi_3 = f(a) + q(y) - y_n^{4}

is a polynomial in xx of class C∞C^\infty with gradient 00 and Hessian exactly HH at aa: the quartic terms contribute nothing to either, and qq contributes ∑j≤pλjqjqjT=H\sum_{j\le p}\lambda_j q_jq_j^{\mathsf T} = H.

Now suppose in addition H≠0H \neq 0, that is p≥1p \ge 1.

  • Φ1\Phi_1 has a strict local minimum at aa — indeed a strict global one. For y≠0y \neq 0 both q(y)≥0q(y) \ge 0 and ∑j>pyj4≥0\sum_{j>p}y_j^4 \ge 0, and they vanish together only if yj=0y_j = 0 for j≤pj \le p (as λj>0\lambda_j > 0 there) and for j>pj > p, that is only if y=0y = 0.
  • Φ2\Phi_2 has a local minimum at aa that is not strict: q≥0q \ge 0 always, while Φ2=f(a)\Phi_2 = f(a) on the whole subspace {y1=⋯=yp=0}\{y_1 = \cdots = y_p = 0\}, of dimension n−p≥1n - p \ge 1.
  • Φ3\Phi_3 has no local extremum at aa. Along x=a+sqnx = a + s q_n (a direction with λn=0\lambda_n = 0, available because p<np < n) it equals f(a)−s4<f(a)f(a) - s^4 < f(a) for s≠0s \neq 0, so aa is not a local minimum; along x=a+sq1x = a + sq_1 it equals f(a)+12λ1s2>f(a)f(a) + \tfrac12\lambda_1 s^2 > f(a) for s≠0s \ne 0, so aa is not a local maximum either.

All three have the same gradient 00 and the same Hessian HH at aa, which proves that no criterion depending on those two can separate them; and by part 4 none of them has a local maximum at aa, since HH has the positive eigenvalue λ1\lambda_1 and so is not negative semidefinite. The negative semidefinite case is this one applied to −f-f.

Part 5, the case H=0H = 0. Then p=0p = 0 and q≡0q \equiv 0. The four functions

f(a)+∣x−a∣4,f(a)−∣x−a∣4,f(a),f(a)+y1(x)3f(a) + \lvert x - a\rvert^{4}, \qquad f(a) - \lvert x-a\rvert^{4}, \qquad f(a), \qquad f(a) + y_1(x)^{3}

are all C∞C^\infty with gradient 00 and Hessian 00 at aa, and have there, respectively, a strict local minimum, a strict local maximum, a local extremum that is both a non-strict minimum and a non-strict maximum, and no local extremum at all — the last because y1(x)3y_1(x)^3 takes both signs arbitrarily close to aa. So nothing is excluded. □\square

NoteOriginal

What it means. Near a critical point a C2C^2 function looks, to the accuracy that matters, like the constant f(a)f(a) plus the quadratic form 12hTHh\tfrac12 h^{\mathsf T} H h: the first-order term has been switched off, so the second-order term decides the local shape. Classifying the critical point is then nothing but asking what signs that quadratic form takes, a question about the eigenvalues of a symmetric matrix. The test is silent exactly when HH is semidefinite and singular — the form vanishes along some direction without ever changing sign — because the quadratic approximation is then too coarse along those null directions and the higher-order terms take over. A form that does change sign still decides, however degenerate it is.

RemarkOriginal

Where the hypotheses are used, and what fails without them.

  • The segment must lie in UU. The mean-value form is the one-variable theorem applied to g(t)=f(a+th)g(t) = f(a+th) on [0,1][0,1], and gg is defined only where a+th∈Ua + th \in U; on a domain that is not convex there may be no intermediate point at which to evaluate the Hessian. The o(∣h∣2)o(\lvert h\rvert^2) form is local and needs only a ball around aa.
  • C2C^2 is used twice. It makes HH symmetric — without it "definiteness" could refer only to the symmetric part, since hTHh=hT(12(H+HT))hh^{\mathsf T} H h = h^{\mathsf T}\bigl(\tfrac12(H + H^{\mathsf T})\bigr)h for every hh — and it is what gives the second-order expansion a remainder small compared with ∣h∣2\lvert h \rvert^2, which is what turns a sign of the quadratic form into a sign of f(a+h)−f(a)f(a+h) - f(a) in parts 1–3.
  • Singular and semidefinite really is undecidable. Both f(x,y)=x2+y4f(x,y) = x^2 + y^4 and g(x,y)=x2−y4g(x,y) = x^2 - y^4 have a critical point at the origin with Hessian diag⁡(2,0)\operatorname{diag}(2,0), positive semidefinite and singular. The origin is a strict local minimum of ff, whereas g(0,y)=−y4<0g(0,y) = -y^4 < 0 for y≠0y \ne 0 and g(x,0)=x2>0g(x,0) = x^2 > 0 for x≠0x \neq 0, so it is a saddle point of gg. Neither can be a local maximum, which is part 5. The third possibility is realised by p(x,y)=x2p(x,y) = x^2, with the same gradient and the same Hessian at the origin again: there pp has a local minimum that is not strict, since p=0p = 0 along the whole yy-axis. For H=0H = 0 take u(x,y)=(x2+y2)2u(x,y) = (x^2+y^2)^2, with a strict local minimum at the origin, −u-u, with a strict local maximum, and v(x,y)=x3−3xy2v(x,y) = x^3 - 3xy^2, whose value on the line y=0y = 0 is x3x^3 and so changes sign at the origin.
  • The test classifies, it does not locate. Points where ff fails to be differentiable, and boundary points of the region of interest, are not critical points and are not covered; on a compact set the maximum and minimum may well be attained there.
  • The same criteria in other books. Riley, Hobson and Bence (p. 164) give the minimum test as "fxxf_{xx} and fyyf_{yy} both positive and fxy2<fxxfyyf_{xy}^2 < f_{xx}f_{yy}", equivalent to the determinant form above because fxx>0f_{xx} > 0 with fxxfyy>fxy2≥0f_{xx}f_{yy} > f_{xy}^2 \ge 0 forces fyy>0f_{yy} > 0; p. 167 gives the nn-variable test by the signs of the eigenvalues of the Hessian and notes that it may fail when some eigenvalues vanish and the non-zero ones share a sign, which is the case of part 5.
  • Constrained problems are different. Parts 1–5 describe a critical point of ff on an open set. If the variables are tied by equations, the first-order condition is not ∇f=0\nabla f = 0 but a multiplier condition. That is the subject of Lagrange multipliers, a later unit which takes this one as a prerequisite; the pointer is forward, and nothing in the present unit uses it.
Example(Two critical-point problems, in two and in three variables)Original

(a) f(x,y)=x4+y4−4xyf(x,y) = x^4 + y^4 - 4xy on R2\mathbb{R}^2.

Critical points. ∂f/∂x=4x3−4y\partial f/\partial x = 4x^3 - 4y and ∂f/∂y=4y3−4x\partial f/\partial y = 4y^3 - 4x, so ∇f=0\nabla f = 0 means y=x3y = x^3 and x=y3=x9x = y^3 = x^9, that is x(x8−1)=0x(x^8-1) = 0. Over the reals x∈{0,1,−1}x \in \{0, 1, -1\}, giving the three critical points (0,0)(0,0), (1,1)(1,1), (−1,−1)(-1,-1).

Hessian. fxx=12x2f_{xx} = 12x^2, fyy=12y2f_{yy} = 12y^2, fxy=−4f_{xy} = -4, so

Hf(x,y)=(12x2−4−412y2).H_f(x,y) = \begin{pmatrix} 12x^2 & -4 \\ -4 & 12y^2\end{pmatrix}.

Classification. At (0,0)(0,0): H=(0−4−40)H = \begin{pmatrix} 0 & -4\\ -4 & 0\end{pmatrix} and D=det⁡H=−16<0D = \det H = -16 < 0, so by the two-variable criteria (0,0)(0,0) is a saddle point; f(0,0)=0f(0,0) = 0. At (±1,±1)(\pm1,\pm1) (both signs together): H=(12−4−412)H = \begin{pmatrix}12 & -4\\ -4 & 12\end{pmatrix}, D=144−16=128>0D = 144 - 16 = 128 > 0 and fxx=12>0f_{xx} = 12 > 0, so both are strict local minima, with the common value

f(1,1)=f(−1,−1)=1+1−4=−2.f(1,1) = f(-1,-1) = 1 + 1 - 4 = -2 .

The eigenvalues of that HH are 12∓412 \mp 4, namely 88 and 1616, both positive, as part 1 requires.

Check that −2-2 is the global minimum. From 4xy≤2(x2+y2)4xy \le 2(x^2+y^2) (which is 2(x−y)2≥02(x-y)^2 \ge 0),

f(x,y)≥x4+y4−2x2−2y2=(x2−1)2+(y2−1)2−2≥−2,f(x,y) \ge x^4 + y^4 - 2x^2 - 2y^2 = (x^2-1)^2 + (y^2-1)^2 - 2 \ge -2 ,

with equality only if x2=y2=1x^2 = y^2 = 1 and x=yx = y, that is at the two minima just found. So min⁡R2f=−2\min_{\mathbb{R}^2} f = -2.

(b) f(x,y,z)=x2+y2+z2−2xyzf(x,y,z) = x^2+y^2+z^2-2xyz on R3\mathbb{R}^3, where the two-variable determinant test has nothing to say and the eigenvalues must be used.

Critical points. ∇f=2(x−yz,  y−xz,  z−xy)\nabla f = 2(x - yz,\; y - xz,\; z - xy), so we need x=yzx = yz, y=xzy = xz, z=xyz = xy. Multiplying the first two gives xy=xyz2xy = xyz^2, so xy(1−z2)=0xy(1-z^2) = 0; with z=xyz = xy this reads z(1−z2)=0z(1-z^2) = 0, so z∈{0,1,−1}z \in \{0,1,-1\}, and the symmetric argument applies to xx and yy. If one coordinate is 00 then all three are, by the equations; otherwise each is ±1\pm 1 and x=yzx = yz forces the product xyz=1xyz = 1. The critical points are therefore the origin and the four points (1,1,1)(1,1,1), (1,−1,−1)(1,-1,-1), (−1,1,−1)(-1,1,-1), (−1,−1,1)(-1,-1,1).

Hessian.

Hf(x,y,z)=2(1−z−y−z1−x−y−x1).H_f(x,y,z) = 2\begin{pmatrix} 1 & -z & -y \\ -z & 1 & -x \\ -y & -x & 1 \end{pmatrix}.

At the origin H=2IH = 2I, positive definite, so the origin is a strict local minimum, with f=0f = 0. (It is not a global minimum: f(t,t,t)=3t2−2t3→−∞f(t,t,t) = 3t^2 - 2t^3 \to -\infty.)

At (1,1,1)(1,1,1),

H=(2−2−2−22−2−2−22)=4I−2J,J=(111111111).H = \begin{pmatrix} 2 & -2 & -2 \\ -2 & 2 & -2 \\ -2 & -2 & 2\end{pmatrix} = 4I - 2J, \qquad J = \begin{pmatrix}1&1&1\\1&1&1\\1&1&1\end{pmatrix}.

JJ has eigenvalue 33 on (1,1,1)T(1,1,1)^{\mathsf T} and eigenvalue 00 on the plane x+y+z=0x+y+z=0, so HH has eigenvalues 4−2⋅3=−24 - 2\cdot 3 = -2 (once) and 4−2⋅0=44 - 2\cdot 0 = 4 (twice). These have both signs, so HH is indefinite and (1,1,1)(1,1,1) is a saddle point, with f(1,1,1)=3−2=1f(1,1,1) = 3 - 2 = 1. The other three points are the same by the symmetry (x,y,z)↦(−x,−y,z)(x,y,z)\mapsto(-x,-y,z) and its relatives, which fix ff.

Note that det⁡H=(−2)(4)(4)=−32<0\det H = (-2)(4)(4) = -32 < 0 here while det⁡(2I)=8>0\det(2I) = 8 > 0 at the origin: in three variables a negative determinant only says the eigenvalues' product is negative, which it also would be for a negative definite 3×33\times 3 matrix. The sign of the determinant is a test only when n=2n = 2.

Application(Stable equilibria and transition states on a potential-energy surface)Original

A mechanical or molecular system with coordinates x=(x1,…,xn)x = (x_1,\dots,x_n) and potential energy V(x)V(x) is in equilibrium exactly where ∇V(x)=0\nabla V(x) = 0, since the generalised forces are −∂V/∂xj-\partial V/\partial x_j. Which kind of equilibrium it is, is the question this unit answers with H=HV(x∗)H = H_V(x_*):

  • HH positive definite: a strict local minimum of the energy, a stable equilibrium. Expanding VV to second order, V≈V(x∗)+12hTHhV \approx V(x_*) + \tfrac12 h^{\mathsf T}Hh, is exactly the harmonic approximation, and the squared frequencies of the small oscillations are the eigenvalues of the mass-weighted Hessian M−1/2HM−1/2M^{-1/2}HM^{-1/2} (normal modes); positive definiteness of HH is what makes them positive, so that the motion oscillates rather than runs away.
  • HH indefinite with exactly one negative eigenvalue and all the others positive: an index-1 saddle, the transition state of chemical kinetics. The system is stable against all displacements except along the eigenvector of the negative eigenvalue, which is the reaction coordinate; the corresponding "frequency" is imaginary, and that is the quantity transition-state theory removes from the partition function of the saddle.
  • HH singular and semidefinite: the harmonic approximation fails along the null directions. Genuine instances are the rigid translations and rotations of an isolated molecule of NN atoms, in the n=3Nn = 3N nuclear coordinates: they leave VV unchanged, so they are exactly zero eigenvalues of HH at every stationary point. The three translations always count; of the rotations, three are independent if the molecule is nonlinear, but only two if it is linear, because a rotation about the molecular axis moves no nucleus. The number of zero eigenvalues is therefore 66 for a nonlinear molecule, 55 for a linear one — every diatomic, and CO2\mathrm{CO_2} — and 33 for a single atom, which has no rotations at all. The remaining eigenvalues are the vibrations, which is the familiar count of 3N−63N - 6 normal modes, or 3N−53N - 5 for a linear molecule. These zero modes are projected out before the vibrational analysis rather than classified.

As a two-coordinate model, take V(x,y)=(x2−1)2+2y2V(x,y) = (x^2-1)^2 + 2y^2 (energies in units of some ϵ\epsilon, lengths in units of some aa). Then ∇V=(4x(x2−1), 4y)\nabla V = (4x(x^2-1),\, 4y), so the stationary points are (±1,0)(\pm1, 0) and (0,0)(0,0), and HV=diag⁡(12x2−4, 4)H_V = \operatorname{diag}(12x^2-4,\,4).

  • At (±1,0)(\pm 1, 0): HV=diag⁡(8,4)H_V = \operatorname{diag}(8, 4), positive definite — two stable equilibria, of equal energy V=0V = 0, with harmonic frequencies 8ϵ/(ma2)\sqrt{8\epsilon/(ma^2)} and 4ϵ/(ma2)\sqrt{4\epsilon/(ma^2)} for a particle of mass mm.
  • At (0,0)(0,0): HV=diag⁡(−4,4)H_V = \operatorname{diag}(-4, 4), eigenvalues −4-4 and 44 — an index-1 saddle, the transition state between the two wells, at energy V=1V = 1. The barrier is ΔV=1−0=1\Delta V = 1 - 0 = 1 (that is, ϵ\epsilon), the reaction coordinate is the xx direction, and the yy direction remains a stable vibration of the transition state with frequency 4ϵ/(ma2)\sqrt{4\epsilon/(ma^2)}.

An Arrhenius rate ∝e−ΔV/kBT\propto e^{-\Delta V/k_BT} needs only the barrier, a number obtained from the critical points; the Hessian supplies the prefactor.

Theorem

Implicit and inverse function theorems

Adapted

A map of class CkC^k between open subsets of Rn\mathbb{R}^n whose Jacobian determinant is non-zero at a point is a CkC^k diffeomorphism of some neighbourhood of that point onto an open set, and an equation Φ(x,y)=c\Phi(x,y) = c whose partial Jacobian in yy is invertible at a solution determines yy locally as a CkC^k function gg of xx, with Dg(x)=−(∂Φ/∂y)−1(∂Φ/∂x)Dg(x) = -(\partial\Phi/\partial y)^{-1}(\partial\Phi/\partial x) evaluated at (x,g(x))(x, g(x)).

Prerequisites: Partial derivatives and the chain rule, Limits of sequences and completeness, Connectedness and simple connectivity

Definition(Diffeomorphism and regular point)AdaptedAdapted from Folland (1999), §2.6, p. 74; Lee (2013), App. C, p. 645

Let Ω,Ω′⊆Rn\Omega, \Omega' \subseteq \mathbb{R}^n be open and let k∈{1,2,… }∪{∞}k \in \{1, 2, \dots\} \cup \{\infty\}.

  • A map F:Ω→Ω′F : \Omega \to \Omega' is a CkC^k diffeomorphism if FF is bijective, FF is of class CkC^k on Ω\Omega, and F−1F^{-1} is of class CkC^k on Ω′\Omega'. For k=∞k = \infty this is simply a diffeomorphism.
  • A point a∈Ωa \in \Omega is a regular point of a C1C^1 map F:Ω→RnF : \Omega \to \mathbb{R}^n if DF(a)DF(a) is invertible, equivalently if the Jacobian determinant det⁡JF(a)\det J_F(a) is non-zero.
  • Following Folland, a C1C^1 map GG on an open Ω⊆Rn\Omega \subseteq \mathbb{R}^n is called a C1C^1 diffeomorphism when GG is injective on Ω\Omega and DxGD_xG is invertible at every x∈Ωx \in \Omega; by the second statement below this agrees with the definition above, with Ω′=G(Ω)\Omega' = G(\Omega).
Theorem(Inverse function theorem)AdaptedAdapted from Lee (2013), App. C, Thm C.34, p. 657 and Prop. C.4, p. 645; Folland (1999), §2.6, p. 74

Let Ω⊆Rn\Omega \subseteq \mathbb{R}^n be open, let F:Ω→RnF : \Omega \to \mathbb{R}^n be of class CkC^k for some kk with 1≤k≤∞1 \le k \le \infty, and let a∈Ωa \in \Omega be a regular point of FF, that is det⁡JF(a)≠0\det J_F(a) \neq 0. Then there exist open sets Ω0\Omega_0 and V0V_0 with a∈Ω0⊆Ωa \in \Omega_0 \subseteq \Omega and F(a)∈V0F(a) \in V_0 such that

  1. FF restricted to Ω0\Omega_0 is a bijection onto V0V_0 whose inverse G=(F∣Ω0)−1:V0→Ω0G = (F|_{\Omega_0})^{-1} : V_0 \to \Omega_0 is of class CkC^k; that is, F∣Ω0:Ω0→V0F|_{\Omega_0} : \Omega_0 \to V_0 is a CkC^k diffeomorphism, and Ω0\Omega_0 may be taken connected;
  2. for every y∈V0y \in V_0, writing x=G(y)x = G(y), DG(y)=[DF(x)]−1,sodet⁡JG(y)=1det⁡JF(x).DG(y) = \bigl[DF(x)\bigr]^{-1}, \qquad\text{so}\qquad \det J_{G}(y) = \frac{1}{\det J_F(x)} .

The map FF need not be injective on the whole of Ω\Omega, and Ω0\Omega_0 cannot in general be taken to be Ω\Omega (see the remark).

Idea of the proof(Inverse function theorem)AdaptedAdapted from Lee (2013), App. C, proof of Thm C.34, pp. 657–659

Normalise so that the point is the origin and the derivative there is the identity. Then FF differs from the identity by a map φ\varphi whose derivative vanishes at the origin, so φ\varphi moves points by at most half their separation on a small ball. Solving F(x)=yF(x) = y is the same as finding a fixed point of x↦y+φ(x)x \mapsto y + \varphi(x), which that bound makes a contraction of a closed ball into itself, so the contraction mapping theorem supplies exactly one solution for each small yy — existence and uniqueness of the inverse at one stroke. The same bound shows that FF can shrink a distance by no more than a factor of two, ∣F(x′)−F(x)∣≥12∣x′−x∣\lvert F(x') - F(x)\rvert \ge \tfrac12\lvert x' - x\rvert, which makes the inverse Lipschitz with constant 22; the derivative of the inverse is then read off the difference quotient, and its smoothness class follows from DG=(DF∘G)−1DG = (DF\circ G)^{-1}, matrix inversion being smooth.

Proof(Inverse function theorem)AdaptedAdapted from Lee (2013), App. C, Lemma C.35 and the proof of Thm C.34, pp. 657–660

Normalisation. Let A=DF(a)A = DF(a), invertible by hypothesis, and set

F~(v)=A−1(F(a+v)−F(a)),v∈Ω~={v∈Rn:a+v∈Ω}.\tilde F(v) = A^{-1}\bigl(F(a+v) - F(a)\bigr), \qquad v \in \tilde\Omega = \{v \in \mathbb{R}^n : a + v \in \Omega\} .

Ω~\tilde\Omega is open and contains 00; F~\tilde F is CkC^k on it, being FF composed on both sides with affine maps; F~(0)=0\tilde F(0) = 0; and DF~(0)=A−1A=ID\tilde F(0) = A^{-1}A = I by the chain rule. The maps v↦a+vv \mapsto a+v and w↦F(a)+Aww \mapsto F(a) + Aw are C∞C^\infty bijections of Rn\mathbb{R}^n with C∞C^\infty inverses, so if F~\tilde F restricted to an open connected Ω~0∋0\tilde\Omega_0 \ni 0 is a CkC^k diffeomorphism onto an open V~0∋0\tilde V_0 \ni 0, then FF restricted to Ω0=a+Ω~0\Omega_0 = a + \tilde\Omega_0 is a CkC^k diffeomorphism onto V0=F(a)+AV~0V_0 = F(a) + A\tilde V_0, and Ω0\Omega_0, V0V_0 are open with Ω0\Omega_0 connected. Part 1 for FF therefore follows from part 1 for F~\tilde F, and we may assume a=0a = 0, F(0)=0F(0) = 0, DF(0)=IDF(0) = I.

Step 1: FF differs from the identity by a 12\tfrac12-contraction. Put φ(x)=x−F(x)\varphi(x) = x - F(x) on Ω\Omega, so that φ\varphi is CkC^k with Dφ(0)=I−I=0D\varphi(0) = I - I = 0. Because FF is of class C1C^1 — this is where continuity of the derivative, and not merely its existence, is used — the partial derivatives of φ\varphi are continuous, so there is r>0r > 0 with Br(0)‾⊆Ω\overline{B_r(0)} \subseteq \Omega and

∣∂φj∂xk(x)∣≤12nfor all j,k and all ∣x∣≤r.\Bigl\lvert \frac{\partial \varphi_j}{\partial x_k}(x) \Bigr\rvert \le \frac{1}{2n} \quad \text{for all } j,k \text{ and all } \lvert x \rvert \le r .

The closed ball is convex, so for x,x′∈Br(0)‾x, x' \in \overline{B_r(0)} the fundamental theorem of calculus along the segment between them gives, for each component,

φj(x′)−φj(x)=∫01∑k=1n∂φj∂xk(x+t(x′−x)) (xk′−xk) dt,\varphi_j(x') - \varphi_j(x) = \int_0^1 \sum_{k=1}^n \frac{\partial \varphi_j}{\partial x_k}\bigl(x + t(x'-x)\bigr)\,(x'_k - x_k)\, dt ,

whence ∣φj(x′)−φj(x)∣≤12n∑k∣xk′−xk∣≤12n∣x′−x∣\lvert \varphi_j(x') - \varphi_j(x)\rvert \le \frac{1}{2n}\sum_k \lvert x'_k - x_k\rvert \le \frac{1}{2\sqrt n}\lvert x' - x\rvert by the Cauchy–Schwarz inequality. Squaring and summing over the nn components,

∣φ(x′)−φ(x)∣≤12∣x′−x∣(x,x′∈Br(0)‾).(1)\lvert \varphi(x') - \varphi(x) \rvert \le \tfrac12 \lvert x' - x\rvert \qquad (x, x' \in \overline{B_r(0)}). \tag{1}

Step 2: FF expands distances, so it is injective there. For x,x′∈Br(0)‾x, x' \in \overline{B_r(0)} write x′−x=(F(x′)−F(x))+(φ(x′)−φ(x))x' - x = \bigl(F(x') - F(x)\bigr) + \bigl(\varphi(x') - \varphi(x)\bigr). The triangle inequality and (1)(1) give ∣x′−x∣≤∣F(x′)−F(x)∣+12∣x′−x∣\lvert x'-x\rvert \le \lvert F(x')-F(x)\rvert + \tfrac12\lvert x'-x\rvert, that is

∣F(x′)−F(x)∣≥12∣x′−x∣.(2)\lvert F(x') - F(x)\rvert \ge \tfrac12 \lvert x' - x\rvert . \tag{2}

In particular F(x′)=F(x)F(x') = F(x) forces x′=xx' = x.

Step 3: each yy with ∣y∣<r/2\lvert y \rvert < r/2 has exactly one preimage. Fix such a yy and put Ty(x)=y+φ(x)T_y(x) = y + \varphi(x) on K=Br(0)‾K = \overline{B_r(0)}; then Ty(x)=xT_y(x) = x if and only if F(x)=yF(x) = y. Taking x=0x = 0 in (1)(1) and using φ(0)=0\varphi(0) = 0 gives ∣φ(x)∣≤12∣x∣\lvert \varphi(x)\rvert \le \tfrac12\lvert x\rvert, so for x∈Kx \in K

∣Ty(x)∣≤∣y∣+12∣x∣<r2+r2=r,\lvert T_y(x) \rvert \le \lvert y \rvert + \tfrac12\lvert x \rvert < \tfrac{r}{2} + \tfrac{r}{2} = r ,

and TyT_y maps KK into Br(0)⊆KB_r(0) \subseteq K. By (1)(1), ∣Ty(x′)−Ty(x)∣=∣φ(x′)−φ(x)∣≤12∣x′−x∣\lvert T_y(x') - T_y(x)\rvert = \lvert \varphi(x') - \varphi(x)\rvert \le \tfrac12 \lvert x' - x\rvert for x,x′∈Kx, x' \in K, so TyT_y is a contraction of constant 12\tfrac12 on the non-empty closed bounded set KK. That such a map has exactly one fixed point is the contraction mapping theorem; since that unit comes later in the handbook, here is the one instance needed. Set x0=0x_0 = 0 and xm+1=Ty(xm)x_{m+1} = T_y(x_m), all in KK. The contraction bound gives ∣xm+1−xm∣≤2−m∣x1−x0∣\lvert x_{m+1} - x_m \rvert \le 2^{-m}\lvert x_1 - x_0\rvert by induction on mm, so ∑m≥0∣xm+1−xm∣\sum_{m \ge 0}\lvert x_{m+1}-x_m\rvert converges and the sequence is Cauchy. It therefore converges in Rn\mathbb{R}^n, one coordinate at a time: ∣(xm)j−(xm′)j∣≤∣xm−xm′∣\lvert (x_m)_j - (x_{m'})_j\rvert \le \lvert x_m - x_{m'}\rvert makes each coordinate sequence Cauchy in R\mathbb{R}, hence convergent by the Cauchy criterion of limits of sequences, and if xx is the vector of the nn limits then ∣xm−x∣≤∑j∣(xm)j−xj∣→0\lvert x_m - x\rvert \le \sum_{j}\lvert (x_m)_j - x_j\rvert \to 0. The limit lies in KK because KK is closed; boundedness of KK plays no part in this step. Letting m→∞m \to \infty in xm+1=Ty(xm)x_{m+1} = T_y(x_m), with TyT_y continuous by the same bound, gives Ty(x)=xT_y(x) = x. If x′∈Kx' \in K also satisfies Ty(x′)=x′T_y(x') = x' then ∣x−x′∣≤12∣x−x′∣\lvert x - x'\rvert \le \tfrac12\lvert x - x'\rvert, forcing x=x′x = x'. Finally the displayed inequality shows ∣x∣=∣Ty(x)∣<r\lvert x \rvert = \lvert T_y(x)\rvert < r, so x∈Br(0)x \in B_r(0).

Step 4: the neighbourhoods, and continuity of the inverse. Put

V0=Br/2(0),Ω0=Br(0)∩F−1(V0),V_0 = B_{r/2}(0), \qquad \Omega_0 = B_r(0) \cap F^{-1}(V_0),

the latter open because FF is continuous, and both containing 00 because F(0)=0F(0) = 0. By step 3, FF maps Ω0\Omega_0 onto V0V_0 (every y∈V0y \in V_0 has a preimage in Br(0)B_r(0), which then lies in Ω0\Omega_0), and by step 2 it does so injectively. Let G:V0→Ω0G : V_0 \to \Omega_0 be the inverse. Substituting x=G(y)x = G(y) and x′=G(y′)x' = G(y') in (2)(2),

∣G(y′)−G(y)∣≤2∣y′−y∣,(3)\lvert G(y') - G(y) \rvert \le 2 \lvert y' - y \rvert , \tag{3}

so GG is continuous and F∣Ω0F|_{\Omega_0} is a homeomorphism onto V0V_0. Finally Ω0\Omega_0 is connected. The ball V0V_0 is: it is the union of the segments joining its centre to its points; each such segment is the image of an interval under a continuous map, so it is connected by items 1 and 2 of "Properties of connected spaces" in connectedness and simple connectivity; and they all contain the centre, so item 4 of that statement glues them into one connected set. Item 2 of the same statement — connectedness transported through a continuous map — then makes the image Ω0=G(V0)\Omega_0 = G(V_0) connected.

Step 5: GG is differentiable, with DG(y)=[DF(G(y))]−1DG(y) = [DF(G(y))]^{-1}. First, DF(x)DF(x) is invertible at every x∈Br(0)‾x \in \overline{B_r(0)}: if DF(x)v=0DF(x)v = 0 then v=Dφ(x)vv = D\varphi(x)v, and the bound of step 1 with the same two inequalities as in (1)(1) gives ∣Dφ(x)v∣≤12∣v∣\lvert D\varphi(x)v\rvert \le \tfrac12 \lvert v\rvert, so ∣v∣≤12∣v∣\lvert v \rvert \le \tfrac12\lvert v\rvert and v=0v = 0. Now fix y∈V0y \in V_0, put x=G(y)x = G(y) and L=DF(x)L = DF(x). For y′∈V0y' \in V_0 with y′≠yy' \neq y, put x′=G(y′)x' = G(y'), which differs from xx because GG is injective; using y′−y=F(x′)−F(x)y' - y = F(x') - F(x),

G(y′)−G(y)−L−1(y′−y)∣y′−y∣=−L−1 ⁣(F(x′)−F(x)−L(x′−x)∣x′−x∣)∣x′−x∣∣y′−y∣.\frac{G(y') - G(y) - L^{-1}(y'-y)}{\lvert y' - y\rvert} = - L^{-1}\!\left( \frac{F(x') - F(x) - L(x'-x)}{\lvert x' - x\rvert} \right) \frac{\lvert x' - x\rvert}{\lvert y' - y\rvert} .

The last factor is at most 22, by (3)(3). The vector in brackets tends to 00 as x′→xx' \to x, because FF is differentiable at xx with derivative LL; and x′→xx' \to x as y′→yy' \to y, again by (3)(3). Since the linear map L−1L^{-1} is bounded, the whole right-hand side tends to 00 as y′→yy' \to y. So GG is differentiable at yy with DG(y)=L−1DG(y) = L^{-1}.

Step 6: GG is of class CkC^k. By step 5, DG=ι∘DF∘GDG = \iota \circ DF \circ G, where ι(B)=B−1\iota(B) = B^{-1} on the open set of invertible matrices. Cramer's rule expresses each entry of B−1B^{-1} as a polynomial in the entries of BB divided by det⁡B≠0\det B \neq 0, so ι\iota is C∞C^\infty. Now induct on the order. GG is continuous (step 4) and DFDF is continuous (FF is C1C^1), so DGDG is continuous, that is GG is C1C^1. Suppose GG is CjC^j with 1≤j≤k−11 \le j \le k-1; then DFDF is Ck−1C^{k-1} and hence CjC^j, so the composition DG=ι∘DF∘GDG = \iota\circ DF\circ G is CjC^j, which says that GG is Cj+1C^{j+1}. For finite kk this ends at G∈CkG \in C^k; for k=∞k = \infty it gives G∈CjG \in C^j for every finite jj, that is G∈C∞G \in C^\infty. This proves part 1.

Part 2. On Ω0\Omega_0 we have G∘F=id⁡G \circ F = \operatorname{id} with both maps differentiable, so the chain rule gives DG(F(x)) DF(x)=IDG(F(x))\,DF(x) = I for every x∈Ω0x \in \Omega_0. Hence DF(x)DF(x) is invertible and DG(y)=[DF(x)]−1DG(y) = [DF(x)]^{-1} at y=F(x)y = F(x); taking determinants, det⁡JG(y) det⁡JF(x)=1\det J_G(y)\,\det J_F(x) = 1. □\square

Lee's proof is the model for steps 1–6. He states the theorem for smooth maps, normalises in two stages and quotes a general Lipschitz estimate for the bound (1)(1); here the normalisation is a single composition, (1)(1) is derived on the spot, the one instance of his contraction lemma (Lemma C.35) that is needed is proved in place rather than quoted, and step 6 keeps track of a finite differentiability class.

Theorem(Local diffeomorphism and openness)AdaptedAdapted from Lee (2013), App. C, Cor. C.36, p. 660

Let Ω⊆Rn\Omega \subseteq \mathbb{R}^n be open and let F:Ω→RnF : \Omega \to \mathbb{R}^n be of class CkC^k, 1≤k≤∞1 \le k \le \infty, with det⁡JF(x)≠0\det J_F(x) \neq 0 for every x∈Ωx \in \Omega. Then

  1. FF is an open map: F(W)F(W) is open in Rn\mathbb{R}^n for every open W⊆ΩW \subseteq \Omega; in particular F(Ω)F(\Omega) is open;
  2. if in addition FF is injective on Ω\Omega, then F:Ω→F(Ω)F : \Omega \to F(\Omega) is a CkC^k diffeomorphism.
Idea of the proof(Local diffeomorphism and openness)Original

The hypothesis is the one of the inverse function theorem, holding at every point at once. So around the image of each point there is a whole open set of image points, which is openness; and smoothness of an inverse is a local property, so once injectivity makes the local inverses fit together into one map, that map inherits their smoothness.

Proof(Local diffeomorphism and openness)AdaptedAdapted from Lee (2013), App. C, Cor. C.36 and its proof, p. 660
  1. Openness. Let W⊆ΩW \subseteq \Omega be open and let y∈F(W)y \in F(W), say y=F(x)y = F(x) with x∈Wx \in W. The restriction F∣WF|_W is CkC^k on the open set WW and det⁡JF(x)≠0\det J_F(x) \ne 0, so the inverse function theorem applied to F∣WF|_W at xx produces open sets Ω0⊆W\Omega_0 \subseteq W containing xx and V0V_0 containing yy with F(Ω0)=V0F(\Omega_0) = V_0. Then y∈V0⊆F(W)y \in V_0 \subseteq F(W) with V0V_0 open, and as yy was arbitrary, F(W)F(W) is open. Taking W=ΩW = \Omega gives the last clause.
  2. Global inverse. Suppose FF is also injective on Ω\Omega. Then F:Ω→F(Ω)F : \Omega \to F(\Omega) is a bijection, so a map G:F(Ω)→ΩG : F(\Omega) \to \Omega inverting it exists for set-theoretic reasons, and F(Ω)F(\Omega) is open by part 1. Fix y=F(x)∈F(Ω)y = F(x) \in F(\Omega) and take Ω0∋x\Omega_0 \ni x, V0∋yV_0 \ni y from the inverse function theorem at xx, with (F∣Ω0)−1:V0→Ω0(F|_{\Omega_0})^{-1} : V_0 \to \Omega_0 of class CkC^k. For z∈V0z \in V_0, both G(z)G(z) and (F∣Ω0)−1(z)(F|_{\Omega_0})^{-1}(z) are preimages of zz under FF, and FF is injective on all of Ω\Omega, so the two agree. Hence GG coincides with a CkC^k map on a neighbourhood of each point of F(Ω)F(\Omega), so GG is CkC^k, and F:Ω→F(Ω)F : \Omega \to F(\Omega) is a CkC^k diffeomorphism. □\square

Injectivity is used only in part 2, and only to identify the local inverses with each other; nothing in part 1 needs it.

Theorem(Implicit function theorem)AdaptedAdapted from Lee (2013), App. C, Thm C.40, pp. 661–662

Write points of Rn×Rp\mathbb{R}^n \times \mathbb{R}^p as (x,y)(x,y) with x=(x1,…,xn)x = (x_1, \dots, x_n) and y=(y1,…,yp)y = (y_1, \dots, y_p). Let U⊆Rn×RpU \subseteq \mathbb{R}^n \times \mathbb{R}^p be open, let Φ:U→Rp\Phi : U \to \mathbb{R}^p be of class CkC^k for some kk with 1≤k≤∞1 \le k \le \infty, let (a,b)∈U(a,b) \in U and put c=Φ(a,b)c = \Phi(a,b). Suppose the p×pp \times p partial Jacobian in the yy variables,

∂Φ∂y(a,b)=(∂Φi∂yj(a,b))i,j≤p,\frac{\partial \Phi}{\partial y}(a,b) = \left( \frac{\partial \Phi_i}{\partial y_j}(a,b) \right)_{i,j \le p},

is invertible. Then there exist open sets V0⊆RnV_0 \subseteq \mathbb{R}^n with a∈V0a \in V_0 and W0⊆RpW_0 \subseteq \mathbb{R}^p with b∈W0b \in W_0, with V0×W0⊆UV_0 \times W_0 \subseteq U, and a map g:V0→W0g : V_0 \to W_0 of class CkC^k, such that

{(x,y)∈V0×W0  :  Φ(x,y)=c}={(x,g(x))  :  x∈V0};\bigl\{ (x,y) \in V_0 \times W_0 \;:\; \Phi(x,y) = c \bigr\} = \bigl\{ (x, g(x)) \;:\; x \in V_0 \bigr\} ;

that is, for (x,y)∈V0×W0(x,y) \in V_0 \times W_0 one has Φ(x,y)=c\Phi(x,y) = c if and only if y=g(x)y = g(x). In particular g(a)=bg(a) = b, and gg is the only map V0→W0V_0 \to W_0 with this property.

Moreover V0V_0 may be taken small enough that ∂Φ/∂y(x,g(x))\partial\Phi/\partial y\bigl(x, g(x)\bigr) is invertible at every x∈V0x \in V_0 — replacing V0V_0 by a smaller open set containing aa leaves the displayed equality of sets intact, since it merely restricts both sides. With V0V_0 so chosen, for every x∈V0x \in V_0

∂Φ∂x(x,g(x))+∂Φ∂y(x,g(x)) Dg(x)=0,Dg(x)=−[∂Φ∂y(x,g(x))]−1∂Φ∂x(x,g(x)),\frac{\partial \Phi}{\partial x}\bigl(x, g(x)\bigr) + \frac{\partial \Phi}{\partial y}\bigl(x, g(x)\bigr)\, Dg(x) = 0, \qquad Dg(x) = - \left[ \frac{\partial \Phi}{\partial y}\bigl(x, g(x)\bigr) \right]^{-1} \frac{\partial \Phi}{\partial x}\bigl(x, g(x)\bigr),

where ∂Φ/∂x\partial \Phi/\partial x is the p×np \times n block of derivatives in the xx variables. For n=p=1n = p = 1 this is the familiar g′(x)=−Φx/Φyg'(x) = -\Phi_x/\Phi_y, both evaluated at (x,g(x))(x, g(x)). What is asserted is invertibility along the graph of gg, which is all that is used; invertibility throughout V0×W0V_0 \times W_0 is not claimed.

Of this, Lee's Thm C.40 supplies the two neighbourhoods, the CkC^k map gg and the equality of the level set with its graph. The uniqueness of gg, the refinement of V0V_0 just described and the derivative formula are ours, obtained from the chain rule in steps 6–8 of the proof below.

Idea of the proof(Implicit function theorem)AdaptedAdapted from Lee (2013), App. C, proof of Thm C.40, pp. 661–662

Make the equation part of a change of variables. The map Ψ(x,y)=(x,Φ(x,y))\Psi(x,y) = (x, \Phi(x,y)) leaves the xx coordinates untouched and replaces yy by the value of Φ\Phi, so its derivative is block triangular with diagonal blocks InI_n and ∂Φ/∂y\partial\Phi/\partial y — invertible exactly under the hypothesis. The inverse function theorem then makes Ψ\Psi a CkC^k diffeomorphism of a neighbourhood of (a,b)(a,b). Its inverse must return xx in the first slot, so it has the form (x,z)↦(x,β(x,z))(x,z) \mapsto (x, \beta(x,z)); freezing the second argument at the level cc turns β\beta into the wanted function gg, and the level set becomes its graph.

Proof(Implicit function theorem)AdaptedAdapted from Lee (2013), App. C, proof of Thm C.40, pp. 661–662
  1. A map with invertible derivative. Define Ψ:U→Rn×Rp\Psi : U \to \mathbb{R}^n\times\mathbb{R}^p by Ψ(x,y)=(x,Φ(x,y))\Psi(x,y) = \bigl(x, \Phi(x,y)\bigr). It is of class CkC^k, since Φ\Phi is and the first block is the identity, and in the splitting of the coordinates its derivative is DΨ(x,y)=(In0∂Φ/∂x∂Φ/∂y),D\Psi(x,y) = \begin{pmatrix} I_n & 0 \\ \partial\Phi/\partial x & \partial\Phi/\partial y \end{pmatrix} , block lower triangular, so det⁡DΨ(x,y)=det⁡(∂Φ/∂y (x,y))\det D\Psi(x,y) = \det\bigl(\partial\Phi/\partial y\,(x,y)\bigr). At (a,b)(a,b) that determinant is non-zero: this is the hypothesis, and it is the only place it is used.
  2. Invert it locally, on a product. By the inverse function theorem there are open sets Ω1⊆U\Omega_1 \subseteq U containing (a,b)(a,b) and Y1Y_1 containing Ψ(a,b)=(a,c)\Psi(a,b) = (a,c) with Ψ∣Ω1:Ω1→Y1\Psi|_{\Omega_1} : \Omega_1 \to Y_1 a CkC^k diffeomorphism. Choose open V∋aV \ni a in Rn\mathbb{R}^n and W0∋bW_0 \ni b in Rp\mathbb{R}^p with V×W0⊆Ω1V\times W_0 \subseteq \Omega_1, and set Ω0=V×W0\Omega_0 = V\times W_0 and Y0=Ψ(Ω0)Y_0 = \Psi(\Omega_0). Since Ψ∣Ω1\Psi|_{\Omega_1} is a homeomorphism onto the open set Y1Y_1, the set Y0Y_0 is open, it contains (a,c)(a,c), and Ψ∣Ω0:Ω0→Y0\Psi|_{\Omega_0} : \Omega_0 \to Y_0 is a CkC^k diffeomorphism. Write its inverse as (Ψ∣Ω0)−1(x,z)=(α(x,z), β(x,z)),(x,z)∈Y0,\bigl(\Psi|_{\Omega_0}\bigr)^{-1}(x,z) = \bigl(\alpha(x,z),\, \beta(x,z)\bigr), \qquad (x,z) \in Y_0, with α\alpha and β\beta of class CkC^k (they are the two blocks of components of a CkC^k map).
  3. The inverse returns xx unchanged. For (x,z)∈Y0(x,z) \in Y_0, (x,z)=Ψ(α(x,z),β(x,z))=(α(x,z), Φ(α(x,z),β(x,z))).(x,z) = \Psi\bigl(\alpha(x,z), \beta(x,z)\bigr) = \bigl(\alpha(x,z),\, \Phi(\alpha(x,z), \beta(x,z))\bigr) . Comparing first components gives α(x,z)=x\alpha(x,z) = x; substituting that and comparing second components gives Φ(x,β(x,z))=zfor all (x,z)∈Y0.(∗)\Phi\bigl(x, \beta(x,z)\bigr) = z \qquad \text{for all } (x,z) \in Y_0. \tag{$*$}
  4. Definition of gg. Put V0={x∈V:(x,c)∈Y0}V_0 = \{x \in V : (x,c) \in Y_0\}, which is open because x↦(x,c)x \mapsto (x,c) is continuous and Y0Y_0 is open, and which contains aa because (a,c)∈Y0(a,c) \in Y_0. Define g:V0→Rpg : V_0 \to \mathbb{R}^p by g(x)=β(x,c)g(x) = \beta(x,c); it is CkC^k, being β\beta composed with an affine map. For x∈V0x \in V_0 the point (x,g(x))(x, g(x)) is (Ψ∣Ω0)−1(x,c)∈Ω0=V×W0(\Psi|_{\Omega_0})^{-1}(x,c) \in \Omega_0 = V\times W_0, so g(x)∈W0g(x) \in W_0: thus gg maps V0V_0 into W0W_0, as claimed. Also V0×W0⊆V×W0⊆UV_0\times W_0 \subseteq V\times W_0 \subseteq U, and g(a)=bg(a) = b because (Ψ∣Ω0)−1(a,c)=(a,b)(\Psi|_{\Omega_0})^{-1}(a,c) = (a,b).
  5. The level set is the graph of gg. Let (x,y)∈V0×W0(x,y) \in V_0\times W_0. If y=g(x)y = g(x) then Φ(x,y)=Φ(x,β(x,c))=c\Phi(x,y) = \Phi(x,\beta(x,c)) = c by (∗)(*). Conversely, suppose Φ(x,y)=c\Phi(x,y) = c. Then Ψ(x,y)=(x,c)\Psi(x,y) = (x,c), and (x,y)∈Ω0(x,y) \in \Omega_0, so applying (Ψ∣Ω0)−1(\Psi|_{\Omega_0})^{-1} to both sides gives (x,y)=(x,β(x,c))=(x,g(x))(x,y) = (x, \beta(x,c)) = (x, g(x)), that is y=g(x)y = g(x). The two sets displayed in the statement are therefore equal.
  6. Uniqueness. Any g~:V0→W0\tilde g : V_0 \to W_0 whose graph is that same set has g~(x)=g(x)\tilde g(x) = g(x) for every x∈V0x \in V_0, since the set meets each {x}×W0\{x\}\times W_0 in the single point (x,g(x))(x,g(x)).
  7. Shrinking V0V_0 to make ∂Φ/∂y\partial\Phi/\partial y invertible along the graph. Consider d(x)=det⁡(∂Φ/∂y(x,g(x)))d(x) = \det\bigl(\partial\Phi/\partial y(x, g(x))\bigr) on V0V_0. Each entry of ∂Φ/∂y\partial\Phi/\partial y is continuous, because Φ\Phi is of class CkC^k with k≥1k \ge 1; gg is continuous by step 4; and the determinant is a polynomial in the entries. So dd is continuous. Its value at x=ax = a is det⁡(∂Φ/∂y(a,b))≠0\det\bigl(\partial\Phi/\partial y(a,b)\bigr) \neq 0 — the hypothesis again. Hence V0′={x∈V0:d(x)≠0}=d−1(R∖{0})V_0' = \{x \in V_0 : d(x) \neq 0\} = d^{-1}\bigl(\mathbb{R}\setminus\{0\}\bigr) is open and contains aa. Replace V0V_0 by V0′V_0': the set equality of step 5 restricts to both sides, gg restricted to V0′V_0' is still CkC^k with values in W0W_0, and step 6 applies verbatim. This secures invertibility only along the graph; to have it at every point of a product neighbourhood one would have to shrink W0W_0 as well and then re-shrink V0V_0 to keep gg inside the smaller W0W_0, and nothing below needs that.
  8. The derivative of gg. On V0V_0 the identity Φ(x,g(x))=c\Phi\bigl(x, g(x)\bigr) = c holds, by step 5, with Φ\Phi and gg both of class CkC^k, k≥1k \ge 1. The map x↦(x,g(x))x \mapsto (x, g(x)) has for derivative the (n+p)×n(n+p)\times n matrix whose top block is InI_n and whose bottom block is Dg(x)Dg(x). The composite x↦Φ(x,g(x))x \mapsto \Phi(x, g(x)) is constant, so its derivative vanishes, and the chain rule computes that derivative as ∂Φ/∂x\partial\Phi/\partial x times the top block plus ∂Φ/∂y\partial\Phi/\partial y times the bottom block: ∂Φ∂x(x,g(x))+∂Φ∂y(x,g(x)) Dg(x)=0.\frac{\partial \Phi}{\partial x}\bigl(x, g(x)\bigr) + \frac{\partial \Phi}{\partial y}\bigl(x, g(x)\bigr)\, Dg(x) = 0 . By step 7 the p×pp \times p matrix ∂Φ/∂y(x,g(x))\partial\Phi/\partial y(x,g(x)) is invertible for every x∈V0x \in V_0, so multiplying on the left by its inverse and rearranging gives Dg(x)=−[∂Φ/∂y(x,g(x))]−1 ∂Φ/∂x(x,g(x))Dg(x) = -\bigl[\partial\Phi/\partial y(x,g(x))\bigr]^{-1}\,\partial\Phi/\partial x(x,g(x)), the formula of the statement. □\square

Steps 1–5 are Lee's route: the map Ψ\Psi, its block-triangular derivative, the local inverse and the identification of the level set with a graph. Steps 6–8 are ours; Thm C.40 states none of the uniqueness of gg, the refinement of V0V_0, or the derivative formula.

NoteOriginal

What it means. Both theorems say the same thing twice: where the linear approximation of a map is invertible, the map itself behaves like that linear approximation — but only nearby. The inverse function theorem reads this as "FF can be undone locally"; the implicit function theorem reads it as "the equation Φ(x,y)=c\Phi(x,y) = c can be solved locally for yy, and the solution inherits the smoothness of Φ\Phi". Neither gives a formula for the solution, only its existence, its uniqueness in a box, and its derivative. Each follows from the other: Lee's route to the implicit function theorem applies the inverse function theorem to (x,y)↦(x,Φ(x,y))(x,y) \mapsto (x, \Phi(x,y)), whose Jacobian is block triangular with diagonal blocks InI_n and ∂Φ/∂y\partial \Phi/\partial y, and the inverse function theorem itself is usually proved by a contraction-mapping argument.

RemarkOriginal

Where the hypotheses are used, and what fails without them.

  • Local, never global. Let F(x,y)=(excos⁡y,  exsin⁡y)F(x,y) = (e^x \cos y,\; e^x \sin y) on Ω=R2\Omega = \mathbb{R}^2. Its Jacobian determinant is e2xe^{2x}, non-zero everywhere, so FF is a local diffeomorphism at every point and an open map; but F(x,y+2π)=F(x,y)F(x, y + 2\pi) = F(x,y), so FF is not injective. A non-vanishing Jacobian determinant on a connected open set therefore does not give global invertibility; injectivity is an extra hypothesis, as in part 2 of the local-diffeomorphism statement.
  • Class C1C^1 cannot be weakened to differentiability. Let f(0)=0f(0) = 0 and f(x)=x+2x2sin⁡(1/x)f(x) = x + 2x^2 \sin(1/x) for x≠0x \neq 0. Then ff is differentiable on R\mathbb{R} with f′(0)=lim⁡h→0(1+2hsin⁡(1/h))=1≠0f'(0) = \lim_{h\to 0}(1 + 2h\sin(1/h)) = 1 \ne 0, while for x≠0x \neq 0 f′(x)=1+4xsin⁡(1/x)−2cos⁡(1/x),f'(x) = 1 + 4x \sin(1/x) - 2 \cos(1/x), which equals −1-1 at every x=1/(2πj)x = 1/(2\pi j) and 33 at every x=1/((2j+1)π)x = 1/((2j+1)\pi), j∈Nj \in \mathbb{N}. So f′f' takes both signs in every neighbourhood of 00. That destroys injectivity near 00, by the following argument. Given a neighbourhood of 00, choose jj so large that it contains the interval I=[l,r]I = [l, r] with l=1/((2j+1)π)l = 1/((2j+1)\pi) and r=1/(2πj)r = 1/(2\pi j), where indeed l<rl < r because 2j+1>2j2j+1 > 2j. Then f′(l)=3>0f'(l) = 3 > 0 and f′(r)=−1<0f'(r) = -1 < 0, so ff exceeds f(l)f(l) just to the right of ll and exceeds f(r)f(r) just to the left of rr: neither endpoint is where ff attains its maximum over the compact interval II. That maximum is therefore attained at an interior point ξ\xi, with f(ξ)>f(l)f(\xi) > f(l) and f(ξ)>f(r)f(\xi) > f(r). Pick vv with max⁡{f(l),f(r)}<v<f(ξ)\max\{f(l), f(r)\} < v < f(\xi). The intermediate value theorem, applied to the continuous ff on [l,ξ][l,\xi] and then on [ξ,r][\xi, r], produces one point of each interval at which f=vf = v; neither of them is ξ\xi, since f(ξ)>vf(\xi) > v, so one lies strictly left of ξ\xi and the other strictly right of it, and the two are distinct. So ff is injective on no neighbourhood of 00: the conclusion fails although Df(0)Df(0) is invertible. What is missing is the continuity of f′f' at 00.
  • The invertible block decides which variables are solved for. For Φ(x,y)=x2+y2−1\Phi(x,y) = x^2 + y^2 - 1 on R2\mathbb{R}^2, ∂Φ/∂y=2y\partial \Phi/\partial y = 2y is invertible at every point of the unit circle except (±1,0)(\pm 1, 0); near those two points the circle is not the graph of a function of xx, but ∂Φ/∂x=2x\partial \Phi/\partial x = 2x is invertible there, so it is the graph of a function of yy. The hypothesis is on one block of the Jacobian, not on the whole of it.
  • Existence is not a formula. For Φ(x,y)=y5+y−x\Phi(x,y) = y^5 + y - x one has ∂Φ/∂y=5y4+1≥1\partial \Phi/\partial y = 5y^4 + 1 \ge 1 everywhere, so near each solution the theorem gives yy as a smooth function of xx, with g′(x)=1/(5g(x)4+1)g'(x) = 1/(5g(x)^4+1). That these local solutions are pieces of a single smooth function on the whole of R\mathbb{R} is a further, non-local fact, which the theorem cannot supply: it holds because y↦y5+yy \mapsto y^5+y has derivative ≥1\ge 1, so is strictly increasing, and tends to ±∞\pm\infty, so is a bijection of R\mathbb{R} onto R\mathbb{R} — whence every xx has exactly one solution g(x)g(x), and the local solutions, being solutions, agree with it. But gg is given by no formula in radicals, since y5+y−xy^5 + y - x has Galois group S5S_5 over Q(x)\mathbb{Q}(x) and so is not solvable by radicals. The derivative formula is still fully usable, which is the normal way these theorems are applied.
  • Smoothness class in the sources. Lee states both theorems for smooth maps; Folland uses and states the C1C^1 version, since that is what the change-of-variables theorem needs. The versions above are for CkC^k with 1≤k≤∞1 \le k \le \infty, covering both: the inverse is obtained first as a continuous map, then shown differentiable, and its derivative is a composition of F−1F^{-1}, x↦DF(x)x \mapsto DF(x) and matrix inversion, so each extra degree of smoothness of FF gives one more for F−1F^{-1}.
  • Why the Jacobian determinant. The hypothesis is the invertibility of the linear map DF(a)DF(a), which exists as a total derivative because FF is C1C^1 (partial derivatives and the chain rule). Arfken's reciprocal relation ∂(x1,x2,… )/∂(u1,u2,… )=[∂(u1,u2,… )/∂(x1,x2,… )]−1\partial(x_1,x_2,\dots)/\partial(u_1,u_2,\dots) = [\partial(u_1,u_2,\dots)/\partial(x_1,x_2,\dots)]^{-1} between the Jacobian of a change of variables and that of its inverse (Eq. (4.75), p. 230) is exactly the determinant identity of part 2 of the inverse function theorem.
Example(Solving a system implicitly, and inverting a map locally)Original

(a) Two equations, two unknowns, one parameter. Take n=1n = 1, p=2p = 2 and

Φ(x,y1,y2)=(y13+y2−2x,    y1+y22−2x)\Phi(x, y_1, y_2) = \bigl( y_1^3 + y_2 - 2x, \;\; y_1 + y_2^2 - 2x \bigr)

on U=R3U = \mathbb{R}^3, a polynomial map and so of class C∞C^\infty. At (a,b)=(1,(1,1))(a,b) = \bigl(1,(1,1)\bigr) both components vanish: 1+1−2=01 + 1 - 2 = 0 twice. So c=Φ(a,b)=(0,0)c = \Phi(a,b) = (0,0).

Check the hypothesis.

∂Φ∂y=(3y12112y2)⟹∂Φ∂y(a,b)=(3112),det⁡=6−1=5≠0.\frac{\partial\Phi}{\partial y} = \begin{pmatrix} 3y_1^2 & 1 \\ 1 & 2y_2 \end{pmatrix} \quad\Longrightarrow\quad \frac{\partial\Phi}{\partial y}(a,b) = \begin{pmatrix} 3 & 1 \\ 1 & 2\end{pmatrix}, \qquad \det = 6 - 1 = 5 \neq 0 .

The theorem therefore gives a neighbourhood V0V_0 of x=1x = 1 and a C∞C^\infty map g=(g1,g2)g = (g_1,g_2) on it with g(1)=(1,1)g(1) = (1,1), such that for (x,y)(x,y) in a box about (1,(1,1))\bigl(1,(1,1)\bigr) the system y13+y2=2xy_1^3 + y_2 = 2x, y1+y22=2xy_1 + y_2^2 = 2x holds exactly when y=g(x)y = g(x).

Its derivative. With ∂Φ/∂x=(−2,−2)T\partial\Phi/\partial x = (-2,-2)^{\mathsf T} and

(3112)−1=15(2−1−13),\begin{pmatrix} 3 & 1\\ 1 & 2\end{pmatrix}^{-1} = \frac{1}{5}\begin{pmatrix} 2 & -1 \\ -1 & 3\end{pmatrix},

the formula Dg=−[∂Φ/∂y]−1 [∂Φ/∂x]Dg = -[\partial\Phi/\partial y]^{-1}\,[\partial\Phi/\partial x] gives

Dg(1)=−15(2−1−13)(−2−2)=15(24)=(2/54/5),Dg(1) = -\frac{1}{5}\begin{pmatrix} 2 & -1\\ -1 & 3\end{pmatrix}\begin{pmatrix}-2\\-2\end{pmatrix} = \frac{1}{5}\begin{pmatrix}2\\4\end{pmatrix} = \begin{pmatrix} 2/5 \\ 4/5\end{pmatrix},

so g1′(1)=0.4g_1'(1) = 0.4 and g2′(1)=0.8g_2'(1) = 0.8.

Numerical check. Solving the system at x=1.01x = 1.01 by Newton's method from (1,1)(1,1) gives y≈(1.0039935,1.0079715)y \approx (1.0039935, 1.0079715), and the difference quotients (yi−1)/0.01(y_i - 1)/0.01 are 0.399350.39935 and 0.797150.79715 — the predicted slopes 0.40.4 and 0.80.8 to the accuracy expected of a first-order approximation over a step of 0.010.01.

(b) A map that is locally but not globally invertible. Let

F(x,y)=(x2−y2,  xy),JF(x,y)=(2x−2yyx),det⁡JF=2x2+2y2.F(x,y) = \bigl(x^2 - y^2,\; xy\bigr), \qquad J_F(x,y) = \begin{pmatrix} 2x & -2y \\ y & x\end{pmatrix}, \qquad \det J_F = 2x^2 + 2y^2 .

The determinant is non-zero except at the origin, so on Ω=R2∖{(0,0)}\Omega = \mathbb{R}^2\setminus\{(0,0)\} the local-diffeomorphism statement applies: FF is an open map there and a C∞C^\infty diffeomorphism of any open set on which it happens to be injective. It is not injective on Ω\Omega, because F(−x,−y)=F(x,y)F(-x,-y) = F(x,y).

At (2,1)(2,1): F(2,1)=(3,2)F(2,1) = (3,2) and det⁡JF=10\det J_F = 10, so there are neighbourhoods Ω0∋(2,1)\Omega_0 \ni (2,1) and V0∋(3,2)V_0 \ni (3,2) with F∣Ω0F|_{\Omega_0} a diffeomorphism onto V0V_0, and its inverse GG has

DG(3,2)=(4−212)−1=110(22−14)=(0.20.2−0.10.4),DG(3,2) = \begin{pmatrix} 4 & -2 \\ 1 & 2\end{pmatrix}^{-1} = \frac{1}{10}\begin{pmatrix}2 & 2\\ -1 & 4\end{pmatrix} = \begin{pmatrix} 0.2 & 0.2 \\ -0.1 & 0.4 \end{pmatrix},

and det⁡JG(3,2)=1/10\det J_G(3,2) = 1/10. Solving F(x,y)=(3.1,2)F(x,y) = (3.1, 2) numerically from (2,1)(2,1) gives (2.019979,0.990109)(2.019979, 0.990109): the increments divided by 0.10.1 are 0.199790.19979 and −0.09891-0.09891, against the first column (0.2,−0.1)(0.2, -0.1) of DG(3,2)DG(3,2).

Application(Thermodynamic derivatives and the cyclic relation)Original

An equation of state ties the state variables of a fluid together by one equation, Φ(p,V,T)=0\Phi(p, V, T) = 0 — for one mole of a van der Waals gas,

Φ(p,V,T)=(p+aV2)(V−b)−RT.\Phi(p,V,T) = \Bigl(p + \frac{a}{V^2}\Bigr)(V - b) - RT .

Thermodynamics then treats any two of p,V,Tp, V, T as independent and the third as a function of them, and writes partial derivatives such as (∂p/∂V)T(\partial p/\partial V)_T. The implicit function theorem is what licenses this: wherever Φ\Phi is C1C^1 and ∂Φ/∂p≠0\partial\Phi/\partial p \neq 0, the equation determines pp locally as a C1C^1 function of (V,T)(V,T), and

(∂p∂V)T=−ΦVΦp,(∂V∂T)p=−ΦTΦV,(∂T∂p)V=−ΦpΦT,\Bigl(\frac{\partial p}{\partial V}\Bigr)_T = -\frac{\Phi_V}{\Phi_p}, \qquad \Bigl(\frac{\partial V}{\partial T}\Bigr)_p = -\frac{\Phi_T}{\Phi_V}, \qquad \Bigl(\frac{\partial T}{\partial p}\Bigr)_V = -\frac{\Phi_p}{\Phi_T},

each from the one-dimensional derivative formula with the other two variables playing the role of parameters. Two consequences used constantly in the subject come out at once. Solving instead for VV as a function of (p,T)(p,T) gives (∂V/∂p)T=−Φp/ΦV(\partial V/\partial p)_T = -\Phi_p/\Phi_V, the reciprocal of the first expression above: this is the reciprocal relation (∂p/∂V)T=1/(∂V/∂p)T(\partial p/\partial V)_T = 1/(\partial V/\partial p)_T, the one-dimensional case of the determinant identity of the inverse function theorem. Multiplying the three displayed expressions, every factor cancels against another while all three minus signs survive, giving the cyclic relation

(∂p∂V)T(∂V∂T)p(∂T∂p)V=−1.\Bigl(\frac{\partial p}{\partial V}\Bigr)_T \Bigl(\frac{\partial V}{\partial T}\Bigr)_p \Bigl(\frac{\partial T}{\partial p}\Bigr)_V = -1 .

It holds for any equation of state whose three partial derivatives are non-zero at the state in question; the minus sign, which surprises people who expect the three factors to cancel to +1+1, is simply the product of the three minus signs in the derivative formula.

For the van der Waals gas, Φp=V−b\Phi_p = V - b, ΦT=−R\Phi_T = -R and ΦV=p−a/V2+2ab/V3\Phi_V = p - a/V^2 + 2ab/V^3, so for instance

(∂p∂T)V=−ΦTΦp=RV−b,\Bigl(\frac{\partial p}{\partial T}\Bigr)_V = -\frac{\Phi_T}{\Phi_p} = \frac{R}{V-b} ,

with no need to solve the equation of state for anything. Where the hypothesis fails, the physics changes. Since Φp=V−b≠0\Phi_p = V - b \neq 0, the first of the two conditions that fix the critical point, (∂p/∂V)T=−ΦV/Φp=0(\partial p/\partial V)_T = -\Phi_V/\Phi_p = 0, says exactly that ΦV=0\Phi_V = 0; and that is the failure of the hypothesis under which VV is a function of pp at fixed TT. So wherever ΦV=0\Phi_V = 0 the isotherm is flat and the isothermal compressibility −V−1(∂V/∂p)T-V^{-1}(\partial V/\partial p)_T is infinite: the single-phase description has lost its local mechanical stability. That locus is the spinodal, and it is not where the two-phase region begins. The boundary of the two-phase region is the binodal, fixed by the Maxwell equal-area construction — a global condition on the isotherm, which no derivative of Φ\Phi and no local theorem can deliver. For every T<TcT < T_c the spinodal lies strictly inside the binodal; between the two the homogeneous states are metastable rather than absent, with (∂p/∂V)T<0(\partial p/\partial V)_T < 0 and so ΦV>0\Phi_V > 0, and the phases have in fact already separated there. The two loci meet only at the critical point, which is why ΦV=0\Phi_V = 0 is nevertheless exactly the right condition for the computation that follows. The second condition, (∂2p/∂V2)T=0(\partial^2 p/\partial V^2)_T = 0, is a genuinely further one, not a restatement of the first; both are needed, and solving the pair for the van der Waals gas gives the familiar

Vc=3b,Tc=8a27Rb,pc=a27b2,pcVcRTc=38,V_c = 3b, \qquad T_c = \frac{8a}{27Rb}, \qquad p_c = \frac{a}{27b^2}, \qquad \frac{p_cV_c}{RT_c} = \frac{3}{8},

the last number being the same for every van der Waals fluid, which is why it is a test of the model.

Method

Lagrange multipliers

Adapted

If a C1C^1 function has a local extremum, among the points of the common zero set of m<nm < n constraints, at a point where the mm constraint gradients are linearly independent, then its gradient there is a unique linear combination of them; this gives the standard recipe for constrained extrema together with the points at which the recipe can miss them.

Prerequisites: Implicit and inverse function theorems, Taylor expansion and critical points in several variables, Compactness

Definition(Constraint set, regular point, Lagrangian)AdaptedAdapted from Lee (2013), §5, p. 107 and Problem 11-11, p. 301; Riley, Hobson & Bence (2006), §5.9, pp. 168–169

Let U⊆RnU \subseteq \mathbb{R}^n be open, let 1≤m<n1 \le m < n, and let g=(g1,…,gm):U→Rmg = (g_1, \dots, g_m) : U \to \mathbb{R}^m be of class C1C^1.

  • The constraint set is the level set M={x∈U:g(x)=0}M = \{x \in U : g(x) = 0\}. (A constraint written gi(x)=cig_i(x) = c_i is brought to this form by replacing gig_i with gi−cig_i - c_i, which changes no derivative.)
  • A point x∗∈Mx_* \in M is a regular point of the constraint if the m×nm \times n Jacobian matrix Jg(x∗)J_g(x_*) has rank mm; equivalently, if the gradients ∇g1(x∗),…,∇gm(x∗)\nabla g_1(x_*), \dots, \nabla g_m(x_*) are linearly independent. If every point of MM is regular, MM is a regular level set of gg and gg is a defining function for it.
  • The tangent space to MM at a regular point x∗x_* is Tx∗M=ker⁡Jg(x∗)={v∈Rn:∇gi(x∗)⋅v=0 for i=1,…,m},T_{x_*}M = \ker J_g(x_*) = \bigl\{ v \in \mathbb{R}^n : \nabla g_i(x_*) \cdot v = 0 \text{ for } i = 1, \dots, m \bigr\}, a subspace of dimension n−mn - m; its orthogonal complement, the normal space, is spanned by the ∇gi(x∗)\nabla g_i(x_*).
  • f:U→Rf : U \to \mathbb{R} has a local minimum on MM at x∗∈Mx_* \in M if there is r>0r > 0 with f(x)≥f(x∗)f(x) \ge f(x_*) for every x∈M∩Br(x∗)x \in M \cap B_r(x_*); a local maximum on MM reverses the inequality, and a local extremum on MM is either. Only the values of ff on MM are compared, so x∗x_* need not be a critical point of ff on UU.
  • The Lagrangian of the problem is the function on U×RmU \times \mathbb{R}^m L(x,λ)=f(x)−∑i=1mλi gi(x),L(x, \lambda) = f(x) - \sum_{i=1}^{m} \lambda_i\, g_i(x), and λ1,…,λm\lambda_1, \dots, \lambda_m are its Lagrange multipliers (also called undetermined multipliers).
Method(First-order necessary condition)AdaptedAdapted from Lee (2013), Problem 11-11, p. 301; Riley, Hobson & Bence (2006), §5.9, Eqs. (5.27)–(5.28), p. 168 and Eq. (5.31), p. 169; Arfken, Weber & Harris (2013), §22.3, Eq. (22.67), p. 1109

Let U⊆RnU \subseteq \mathbb{R}^n be open, let 1≤m<n1 \le m < n, let f:U→Rf : U \to \mathbb{R} and g=(g1,…,gm):U→Rmg = (g_1, \dots, g_m) : U \to \mathbb{R}^m be of class C1C^1, and let M={x∈U:g(x)=0}M = \{x \in U : g(x) = 0\}.

Suppose ff has a local extremum on MM at a point x∗∈Mx_* \in M which is a regular point of the constraint, that is rank⁡Jg(x∗)=m\operatorname{rank} J_g(x_*) = m. Then there is exactly one λ=(λ1,…,λm)∈Rm\lambda = (\lambda_1, \dots, \lambda_m) \in \mathbb{R}^m with

∇f(x∗)=∑i=1mλi ∇gi(x∗),\nabla f(x_*) = \sum_{i=1}^{m} \lambda_i\, \nabla g_i(x_*),

equivalently ∇xL(x∗,λ)=0\nabla_x L(x_*, \lambda) = 0. Since ∇λL(x∗,λ)=−g(x∗)=0\nabla_\lambda L(x_*,\lambda) = -g(x_*) = 0 holds automatically for x∗∈Mx_* \in M, the pair (x∗,λ)(x_*, \lambda) is a critical point of LL on U×RmU \times \mathbb{R}^m, and the n+mn + m equations

∂f∂xj(x)−∑i=1mλi∂gi∂xj(x)=0(j=1,…,n),gi(x)=0(i=1,…,m)\frac{\partial f}{\partial x_j}(x) - \sum_{i=1}^{m} \lambda_i \frac{\partial g_i}{\partial x_j}(x) = 0 \quad (j = 1, \dots, n), \qquad g_i(x) = 0 \quad (i = 1, \dots, m)

in the n+mn + m unknowns (x,λ)(x, \lambda) hold at (x∗,λ)(x_*, \lambda). Geometrically, ∇f(x∗)\nabla f(x_*) lies in the normal space of MM at x∗x_*, that is ∇f(x∗)⋅v=0\nabla f(x_*) \cdot v = 0 for every v∈Tx∗Mv \in T_{x_*}M: the derivative of ff vanishes in every direction tangent to the constraint set. The condition is necessary only: a solution of the displayed system need be neither a maximum nor a minimum of ff on MM.

Idea of the proof(First-order necessary condition)AdaptedAdapted from Arfken, Weber & Harris (2013), §22.3, Eqs. (22.63)–(22.66), p. 1108

Regularity says that mm of the nn coordinates can be eliminated. Call those mm coordinates yy and the remaining n−mn-m of them uu, chosen so that ∂g/∂y\partial g/\partial y is invertible; the implicit function theorem then presents MM near x∗x_* as the graph y=h(u)y = h(u) of a C1C^1 map, and ff restricted to MM becomes an ordinary unconstrained function F(u)=f(u,h(u))F(u) = f(u,h(u)) of the free variables, whose gradient must vanish. The chain rule turns that into one relation between the uu- and the yy-derivatives of ff and of gg. Define λ\lambda from the yy-block alone, which is where ∂g/∂y\partial g/\partial y can be inverted; the relation then says precisely that the uu-block matches as well, and the two blocks together are ∇f(x∗)=∑iλi∇gi(x∗)\nabla f(x_*) = \sum_i\lambda_i\nabla g_i(x_*).

Proof(First-order necessary condition)AdaptedAdapted from Arfken, Weber & Harris (2013), §22.3, Eqs. (22.63)–(22.66), p. 1108; Evans (2010), §8.4.1, proof of Thm 2, pp. 460–462
  1. Split the coordinates. Jg(x∗)J_g(x_*) is m×nm\times n of rank mm, so mm of its columns are linearly independent. Relabel the coordinates of Rn\mathbb{R}^n so that these are the last mm, writing x=(u,y)x = (u,y) with u∈Rn−mu\in\mathbb{R}^{n-m} and y∈Rmy\in\mathbb{R}^m, and x∗=(u∗,y∗)x_* = (u_*,y_*). A relabelling permutes the entries of every gradient in the same way, so a conclusion of the form ∇f=∑iλi∇gi\nabla f = \sum_i\lambda_i\nabla g_i is unaffected by it. By construction ∂g/∂y (x∗)\partial g/\partial y\,(x_*) is an invertible m×mm\times m matrix.
  2. Eliminate yy. Apply the implicit function theorem to gg at (u∗,y∗)(u_*,y_*) with level c=0c = 0: there are open sets V0∋u∗V_0\ni u_* and W0∋y∗W_0 \ni y_* with V0×W0⊆UV_0\times W_0\subseteq U, and a C1C^1 map h:V0→W0h : V_0\to W_0 with h(u∗)=y∗h(u_*) = y_*, such that for (u,y)∈V0×W0(u,y)\in V_0\times W_0 g(u,y)=0  ⟺  y=h(u).g(u,y) = 0 \iff y = h(u) .
  3. The restricted problem is unconstrained. Put F(u)=f(u,h(u))F(u) = f\bigl(u, h(u)\bigr), a C1C^1 function on V0V_0. Let r>0r>0 be the radius in the hypothesis that x∗x_* is a local extremum of ff on MM, and shrink V0V_0 so that (u,h(u))∈Br(x∗)(u,h(u)) \in B_r(x_*) for every u∈V0u\in V_0, which is possible because u↦(u,h(u))u\mapsto (u,h(u)) is continuous and maps u∗u_* to x∗x_*. Each such point lies in MM by step 2, so F(u)≥F(u∗)F(u)\ge F(u_*) for all u∈V0u\in V_0 in the minimum case and F(u)≤F(u∗)F(u)\le F(u_*) in the maximum case. Hence u∗u_* is an unconstrained local extremum of FF at an interior point of its domain, so ∇F(u∗)=0\nabla F(u_*) = 0: each partial derivative is the derivative of a one-variable differentiable function with an interior local extremum, and so vanishes.
  4. What the chain rule makes of that. Differentiating F=f∘(u↦(u,h(u)))F = f\circ(u\mapsto(u,h(u))) at u∗u_* with the chain rule gives, as an identity between 1×(n−m)1\times(n-m) row vectors, 0  =  ∂f∂u(x∗)+∂f∂y(x∗) Dh(u∗).0 \;=\; \frac{\partial f}{\partial u}(x_*) + \frac{\partial f}{\partial y}(x_*)\, Dh(u_*) .
  5. What the implicit function theorem gives for DhDh. Its derivative formula, applied to gg, reads Dh(u∗)=−[∂g∂y(x∗)]−1∂g∂u(x∗).Dh(u_*) = -\left[\frac{\partial g}{\partial y}(x_*)\right]^{-1}\frac{\partial g}{\partial u}(x_*) .
  6. Define the multipliers, then check both blocks. Put λT  =  ∂f∂y(x∗)[∂g∂y(x∗)]−1  ∈  R1×m,\lambda^{\mathsf T} \;=\; \frac{\partial f}{\partial y}(x_*)\left[\frac{\partial g}{\partial y}(x_*)\right]^{-1} \;\in\; \mathbb{R}^{1\times m}, which is Arfken's λ=(∂f/∂z)/(∂g/∂z)\lambda = (\partial f/\partial z)\big/(\partial g/\partial z) with a matrix inverse in place of the division. The yy-block then holds by construction, ∂f∂y(x∗)=λT∂g∂y(x∗),\frac{\partial f}{\partial y}(x_*) = \lambda^{\mathsf T}\frac{\partial g}{\partial y}(x_*) , and substituting step 5 into step 4 gives the uu-block: ∂f∂u(x∗)=−∂f∂y(x∗)Dh(u∗)=∂f∂y(x∗)[∂g∂y(x∗)]−1∂g∂u(x∗)=λT∂g∂u(x∗).\frac{\partial f}{\partial u}(x_*) = -\frac{\partial f}{\partial y}(x_*)Dh(u_*) = \frac{\partial f}{\partial y}(x_*)\left[\frac{\partial g}{\partial y}(x_*)\right]^{-1}\frac{\partial g}{\partial u}(x_*) = \lambda^{\mathsf T}\frac{\partial g}{\partial u}(x_*) . Together the two blocks say Df(x∗)=λTJg(x∗)Df(x_*) = \lambda^{\mathsf T}J_g(x_*), that is ∇f(x∗)=∑i=1mλi∇gi(x∗)\nabla f(x_*) = \sum_{i=1}^m \lambda_i\nabla g_i(x_*); undoing the relabelling of step 1 states it in the original coordinates.
  7. Uniqueness, and the other forms of the conclusion. If ∑iλi∇gi(x∗)=∑iμi∇gi(x∗)\sum_i \lambda_i\nabla g_i(x_*) = \sum_i\mu_i\nabla g_i(x_*) then ∑i(λi−μi)∇gi(x∗)=0\sum_i(\lambda_i-\mu_i)\nabla g_i(x_*) = 0, and the rank hypothesis makes those gradients linearly independent, so μ=λ\mu = \lambda: the multiplier is unique. For v∈Tx∗M=ker⁡Jg(x∗)v\in T_{x_*}M = \ker J_g(x_*) we get ∇f(x∗)⋅v=λTJg(x∗)v=0\nabla f(x_*)\cdot v = \lambda^{\mathsf T}J_g(x_*)v = 0, the geometric form. And ∇xL(x∗,λ)=∇f(x∗)−∑iλi∇gi(x∗)=0\nabla_xL(x_*,\lambda) = \nabla f(x_*) - \sum_i\lambda_i\nabla g_i(x_*) = 0 while ∇λL(x∗,λ)=−g(x∗)=0\nabla_\lambda L(x_*,\lambda) = -g(x_*) = 0 because x∗∈Mx_* \in M, so (x∗,λ)(x_*,\lambda) is a critical point of LL on U×RmU\times\mathbb{R}^m. □\square

Arfken carries out exactly this elimination for n=3n = 3, m=1m = 1, and his Eq. (22.65) is step 6 in that case; Evans's Thm 2 follows the same implicit-function route in a function space. The mm-constraint bookkeeping and the relabelling of step 1 are ours.

NoteOriginal

What it means. On the constraint set only n−mn - m of the nn coordinates can be moved freely, so the right first-order condition is not that ∇f\nabla f vanish but that it have no component along the directions one is still allowed to move in — and those are exactly the directions perpendicular to all the constraint gradients. The multipliers are the coefficients that express the leftover, normal part of ∇f\nabla f. The reason the regularity hypothesis is needed, and the reason the result is true, is the implicit function theorem: where the constraint gradients are independent, mm of the variables can be eliminated as C1C^1 functions of the other n−mn-m, turning the problem into an unconstrained one in n−mn-m free variables.

Method(Constrained extrema by multipliers)AdaptedAdapted from Riley, Hobson & Bence (2006), §5.9, pp. 168–171; Arfken, Weber & Harris (2013), §22.3, pp. 1107–1109

To find the extrema of a C1C^1 function ff on M={x∈U:g(x)=0}M = \{x \in U : g(x) = 0\}, with gg of class C1C^1 and m<nm < n constraints:

  1. Write the constraints as equalities with zero on the right, gi(x)=0g_i(x) = 0, and count: nn variables, mm constraints, m<nm < n.
  2. Form the Lagrangian L(x,λ)=f(x)−∑iλigi(x)L(x,\lambda) = f(x) - \sum_i \lambda_i g_i(x).
  3. Solve the n+mn+m stationarity equations ∂L/∂xj=0\partial L/\partial x_j = 0 for j≤nj \le n together with gi(x)=0g_i(x) = 0 for i≤mi \le m, in the n+mn+m unknowns x1,…,xn,λ1,…,λmx_1, \dots, x_n, \lambda_1, \dots, \lambda_m. Keep every branch: never divide by a quantity that could vanish without treating that case separately — the step at which Riley, Hobson and Bence's worked sphere problem would lose solutions.
  4. List separately every point of MM where rank⁡Jg<m\operatorname{rank} J_g < m. The theorem says nothing at such points, so they are extra candidates and must be examined on their own.

How it fails. Step 3 finds only regular candidates, so skipping step 4 can miss the answer outright (see the remark). The equations locate maxima, minima and saddle points alike — Arfken makes this point on p. 1109 — so they only produce candidates; and on a non-compact MM, or when ff is unbounded on MM, there may be no extremum at all although step 3 has solutions. The alternative of substituting the constraint to eliminate a variable, which Arfken contrasts the method with, is equally valid whenever the elimination can actually be carried out; multipliers are preferred when it cannot be, or when the symmetry of the variables should be kept.

Method(Deciding which candidates are extrema)Original

The multiplier equations do not say which candidates are extrema. Let C⊆MC \subseteq M be the set of candidates produced by steps 3 and 4 above.

  1. If MM is compact (closed and bounded) and ff is continuous on MM, then ff attains a maximum and a minimum on MM, and by the theorem each is attained at a point of CC. So the largest and the smallest value of ff on CC are the maximum and the minimum of ff on MM; when CC is finite this is a comparison of finitely many numbers, and when it is not, it is the easier problem of extremising ff on CC. No second-order test is needed. The multipliers may be discarded once x∗x_* is known.
  2. Otherwise test a candidate directly. With ff and gg of class C2C^2, x∗x_* a regular point, λ\lambda the multiplier belonging to x∗x_*, and H  =  Hf(x∗)−∑i=1mλi Hgi(x∗)H \;=\; H_f(x_*) - \sum_{i=1}^{m} \lambda_i\, H_{g_i}(x_*) the Hessian of x↦L(x,λ)x \mapsto L(x,\lambda) at x∗x_*: if hTHh>0h^{\mathsf T} H h > 0 for every non-zero h∈Tx∗Mh \in T_{x_*}M then x∗x_* is a strict local minimum of ff on MM, and if hTHh<0h^{\mathsf T} H h < 0 for every such hh then a strict local maximum. HH need only be definite on the tangent space, not on all of Rn\mathbb{R}^n; if it is indefinite on the tangent space, x∗x_* is neither.
Idea of the proof(Why steps 5 and 6 work)Original

Step 5 needs no calculus. On a compact constraint set a continuous ff attains its largest and smallest values somewhere, and wherever that is, either the theorem applies there or the rank condition fails there — so the point is already on the candidate list, and comparing values on the list is the whole of the matter. Step 6 is the unconstrained second-derivative test in disguise: parametrise MM near x∗x_* by the free variables, and the Hessian of ff pulled back to those parameters turns out to be exactly HH restricted to the tangent space, because the first-order condition annihilates the terms that involve the curvature of the parametrisation. That is what the Hessian of the Lagrangian, rather than of ff, is for.

Proof(The tests of steps 5 and 6)Original

Step 5. Let MM be compact and ff continuous on MM. If M=∅M = \varnothing there is nothing to extremise, so assume M≠∅M \neq \varnothing. By the extreme value theorem (compactness), which is stated there for a non-empty compact space, ff attains a maximum at some x^∈M\hat x\in M and a minimum at some xˇ∈M\check x\in M. Now x^\hat x is in particular a local maximum of ff on MM, so:

  • if rank⁡Jg(x^)=m\operatorname{rank}J_g(\hat x) = m, the first-order condition applies at x^\hat x and produces a λ\lambda solving the n+mn+m equations, so x^\hat x is among the solutions found in step 3;
  • otherwise rank⁡Jg(x^)<m\operatorname{rank}J_g(\hat x) < m and x^\hat x is listed by step 4.

Either way x^∈C\hat x \in C, and the same for xˇ\check x. Hence max⁡Mf=max⁡Cf\max_M f = \max_C f and min⁡Mf=min⁡Cf\min_M f = \min_C f, and these are attained at points of CC — which is what step 5 asserts, with no second-order information used. □\square

Step 6. Let f,gf, g be of class C2C^2, let x∗∈Mx_*\in M be a regular point with multiplier λ\lambda, and let H=Hf(x∗)−∑iλiHgi(x∗)H = H_f(x_*) - \sum_i\lambda_iH_{g_i}(x_*).

  1. A C2C^2 parametrisation of MM near x∗x_*. Repeat steps 1 and 2 of the previous proof; since gg is now C2C^2, the implicit function theorem returns an hh of class C2C^2. Put ϕ(u)=(u,h(u))\phi(u) = (u, h(u)) for u∈V0u\in V_0: a C2C^2 map whose image is M∩(V0×W0)M\cap(V_0\times W_0), and a homeomorphism onto that set, its inverse being the restriction of the projection (u,y)↦u(u,y)\mapsto u. Write P=Dϕ(u∗)P = D\phi(u_*), an n×(n−m)n\times(n-m) matrix whose top block is In−mI_{n-m}, so rank⁡P=n−m\operatorname{rank}P = n-m.
  2. Its image is the tangent space. Differentiating g(ϕ(u))=0g(\phi(u)) = 0 at u∗u_* gives Jg(x∗)P=0J_g(x_*)P = 0, so the image of PP lies in Tx∗M=ker⁡Jg(x∗)T_{x_*}M = \ker J_g(x_*); both spaces have dimension n−mn-m, so they coincide.
  3. The pulled-back Hessian is HH on the tangent space. Put F=f∘ϕF = f\circ\phi and Gi=gi∘ϕG_i = g_i\circ\phi, all of class C2C^2 on V0V_0. Two applications of the chain rule give, for α,β≤n−m\alpha,\beta \le n-m, ∂2F∂uα∂uβ(u∗)=(PTHf(x∗)P)αβ+∑j=1n∂f∂xj(x∗) ∂2ϕj∂uα∂uβ(u∗),\frac{\partial^2 F}{\partial u_\alpha \partial u_\beta}(u_*) = \bigl(P^{\mathsf T}H_f(x_*)P\bigr)_{\alpha\beta} + \sum_{j=1}^{n}\frac{\partial f}{\partial x_j}(x_*)\,\frac{\partial^2\phi_j}{\partial u_\alpha\partial u_\beta}(u_*), and the same formula with each gig_i in place of ff — whose left-hand side is 00, because GiG_i vanishes identically on V0V_0. Multiplying the gig_i identity by λi\lambda_i, summing over ii and subtracting from the ff identity, HF(u∗)=PTHP+∑j=1n(∂f∂xj(x∗)−∑i=1mλi∂gi∂xj(x∗))Hϕj(u∗)=PTHP,H_F(u_*) = P^{\mathsf T}HP + \sum_{j=1}^{n}\left(\frac{\partial f}{\partial x_j}(x_*) - \sum_{i=1}^{m}\lambda_i\frac{\partial g_i}{\partial x_j}(x_*)\right)H_{\phi_j}(u_*) = P^{\mathsf T}HP , since each bracket is a component of ∇f(x∗)−∑iλi∇gi(x∗)\nabla f(x_*) - \sum_i\lambda_i\nabla g_i(x_*), which vanishes by the first-order condition. This is where the multiplier earns its keep: it is exactly what makes the second derivatives of the parametrisation drop out.
  4. And u∗u_* is a critical point of FF. ∇F(u∗)=PT∇f(x∗)=0\nabla F(u_*) = P^{\mathsf T}\nabla f(x_*) = 0, because the columns of PP lie in Tx∗MT_{x_*}M and ∇f(x∗)\nabla f(x_*) is orthogonal to that space, by the geometric form of the first-order condition.
  5. Conclude. Suppose hTHh>0h^{\mathsf T}Hh>0 for every non-zero h∈Tx∗Mh\in T_{x_*}M. For w≠0w \ne 0 in Rn−m\mathbb{R}^{n-m} we have Pw≠0Pw\ne0 and Pw∈Tx∗MPw\in T_{x_*}M, so wTHF(u∗)w=(Pw)TH(Pw)>0w^{\mathsf T}H_F(u_*)w = (Pw)^{\mathsf T}H(Pw)>0: the matrix HF(u∗)H_F(u_*) is positive definite. By part 1 of the classification in Taylor expansion and critical points in several variables, u∗u_* is a strict local minimum of FF: there is ρ>0\rho>0 with F(u)>F(u∗)F(u)>F(u_*) for 0<∣u−u∗∣<ρ0<\lvert u-u_*\rvert<\rho. Because ϕ\phi is a homeomorphism onto M∩(V0×W0)M\cap(V_0\times W_0), every point of MM close enough to x∗x_* is ϕ(u)\phi(u) for exactly one uu with ∣u−u∗∣<ρ\lvert u - u_*\rvert<\rho, and x≠x∗x\ne x_* corresponds to u≠u∗u\ne u_*; hence f(x)>f(x∗)f(x)>f(x_*) for all such x≠x∗x\ne x_*, which is a strict local minimum of ff on MM. The maximum case is this one applied to −f-f, whose multiplier is −λ-\lambda and whose matrix is −H-H. Finally, if HH is indefinite on Tx∗MT_{x_*}M then HF(u∗)H_F(u_*) is indefinite, so by part 3 of the same classification every neighbourhood of u∗u_* contains points where FF exceeds F(u∗)F(u_*) and points where it is smaller; transporting these through ϕ\phi shows x∗x_* is neither a local minimum nor a local maximum of ff on MM. □\square
RemarkOriginal

Where the hypotheses are used, and what fails without them.

  • The rank condition cannot be dropped. Minimise f(x,y)=xf(x,y) = x subject to g(x,y)=y2−x3=0g(x,y) = y^2 - x^3 = 0 on U=R2U = \mathbb{R}^2. The constraint set is the cuspidal curve y2=x3y^2 = x^3, which forces x≥0x \ge 0, so the minimum of ff on MM is at the origin. But ∇g(0,0)=(−3x2,2y)∣(0,0)=(0,0)\nabla g(0,0) = (-3x^2,2y)\big|_{(0,0)} = (0,0) has rank 00, and ∇f(0,0)=(1,0)≠λ(0,0)\nabla f(0,0) = (1,0) \ne \lambda(0,0) for any λ\lambda: the multiplier equation has no solution at the true minimiser, which step 3 misses and only step 4 finds.
  • Uniqueness of λ\lambda comes from the same hypothesis: linear independence of the ∇gi(x∗)\nabla g_i(x_*) is exactly what makes the coefficients in ∇f(x∗)=∑iλi∇gi(x∗)\nabla f(x_*) = \sum_i \lambda_i \nabla g_i(x_*) unique.
  • Necessary, not sufficient. For f(x,y)=yf(x,y) = y with g(x,y)=y−x3=0g(x,y) = y - x^3 = 0, ∇g=(−3x2,1)\nabla g = (-3x^2,1) never vanishes, so every point of MM is regular, and (0,1)=λ(−3x2,1)(0,1) = \lambda(-3x^2,1) gives λ=1\lambda = 1, x=0x = 0. But ff on MM is x↦x3x \mapsto x^3, with no local extremum at x=0x = 0. The system cannot tell maxima, minima and neither apart; that is what steps 5 and 6 are for.
  • m<nm < n is needed for the problem to be non-trivial. With m=nm = n and the rank condition, gg is a local diffeomorphism near x∗x_* by the inverse function theorem, so MM is locally the single point x∗x_*; with m>nm > n the rank condition is unsatisfiable.
  • Equality constraints only. For inequality constraints gi(x)≤0g_i(x) \le 0 the first-order conditions carry sign restrictions on the multipliers and a complementarity condition, and are not covered here.
  • Sign conventions. We write L=f−∑iλigiL = f - \sum_i \lambda_i g_i, which is Arfken's convention: his Eqs. (22.66)–(22.67), pp. 1108–1109, read ∂f/∂xi−∑jλj ∂gj/∂xi=0\partial f/\partial x_i - \sum_j \lambda_j\,\partial g_j/\partial x_i = 0. Riley, Hobson and Bence use the opposite sign — f+λgf + \lambda g in Eqs. (5.27)–(5.28), f+λg+μhf + \lambda g + \mu h in (5.31) — which replaces each λi\lambda_i by −λi-\lambda_i and changes nothing about the solutions x∗x_*. The sign matters when the multiplier itself is interpreted, as a sensitivity or as a physical quantity such as a force or a chemical potential: with our convention, and under hypotheses making the optimal point and multiplier differentiable in the constraint levels cc, λi\lambda_i is ∂/∂ci\partial/\partial c_i of the constrained optimal value of ff.
  • The analogous hypothesis in the variational setting. Gelfand and Fomin's isoperimetric theorem (Thm 1, §12.1, p. 43) assumes that the extremal of JJ is not an extremal of the constraint functional KK before producing λ\lambda; their footnote names the analogy with the finite-dimensional method, and that hypothesis is the infinite-dimensional counterpart of rank⁡Jg(x∗)=m\operatorname{rank}J_g(x_*) = m. Evans's Theorem 2 (§8.4.1, p. 460) carries no such hypothesis: it assumes only that uu minimises II over the admissible class. Non-degeneracy of the constraint enters there only inside the proof, as the case assumption (13) under which the implicit function theorem is applied, and step 3 (p. 462) treats the opposite case and finds the conclusion holds trivially, for any λ\lambda. In our finite-dimensional statement the regularity hypothesis cannot be dispensed with that way, as the cuspidal curve above shows.
  • Smoothness class in the sources. Lee's Problem 11-11 states the result for a smooth function on a smooth manifold with a smooth local defining function — his name for a map whose zero set is the constraint set and whose differential is surjective there, so his regularity hypothesis contains ours. The version above is for C1C^1 data on an open subset of Rn\mathbb{R}^n, which is what the implicit function theorem route needs and the generality the physics texts use.
Example(Two constraints on a sphere, and a non-compact constraint set)Original

(a) The highest point of a tilted great circle. Maximise and minimise f(x,y,z)=zf(x,y,z) = z on

M={(x,y,z):g1=x2+y2+z2−1=0,    g2=x+y+z=0},M = \bigl\{ (x,y,z) : g_1 = x^2+y^2+z^2-1 = 0, \;\; g_2 = x+y+z = 0 \bigr\},

the great circle cut from the unit sphere by a plane through the origin. Here n=3n = 3, m=2m = 2.

Step 4 first: every point is regular. ∇g1=2(x,y,z)\nabla g_1 = 2(x,y,z) and ∇g2=(1,1,1)\nabla g_2 = (1,1,1) are linearly dependent only if (x,y,z)(x,y,z) is a multiple of (1,1,1)(1,1,1); on MM the plane equation then forces 3x=03x = 0, hence (x,y,z)=(0,0,0)(x,y,z) = (0,0,0), which is not on the sphere. So rank⁡Jg=2\operatorname{rank}J_g = 2 at every point of MM and step 4 contributes no candidates.

Step 3. With L=z−λ1(x2+y2+z2−1)−λ2(x+y+z)L = z - \lambda_1(x^2+y^2+z^2-1) - \lambda_2(x+y+z) the stationarity equations are

0=2λ1x+λ2,0=2λ1y+λ2,1=2λ1z+λ2,0 = 2\lambda_1 x + \lambda_2, \qquad 0 = 2\lambda_1 y + \lambda_2, \qquad 1 = 2\lambda_1 z + \lambda_2 ,

together with the two constraints. Subtracting the first two gives 2λ1(x−y)=02\lambda_1(x-y) = 0. If λ1=0\lambda_1 = 0 the first equation gives λ2=0\lambda_2 = 0 and the third then reads 1=01 = 0; so λ1≠0\lambda_1 \ne 0 and x=yx = y. The plane gives z=−2xz = -2x, and the sphere 2x2+4x2=12x^2 + 4x^2 = 1, so x=±1/6x = \pm 1/\sqrt6. The two candidates are

(16,16,−26)and(−16,−16,26).\Bigl(\tfrac{1}{\sqrt6}, \tfrac{1}{\sqrt6}, -\tfrac{2}{\sqrt6}\Bigr) \quad\text{and}\quad \Bigl(-\tfrac{1}{\sqrt6},-\tfrac{1}{\sqrt6}, \tfrac{2}{\sqrt6}\Bigr).

Their multipliers follow from the first and third equations: 1=2λ1(z−x)1 = 2\lambda_1(z-x), and for the second point z−x=3/6z - x = 3/\sqrt6, so λ1=1/6\lambda_1 = 1/\sqrt6 and λ2=−2λ1x=1/3\lambda_2 = -2\lambda_1x = 1/3.

Step 5. MM is closed (an intersection of two level sets of continuous functions) and bounded (it lies on the unit sphere), hence compact, and ff is continuous, so the maximum and the minimum of ff on MM are attained and lie among the two candidates. Comparing the two values of zz,

max⁡Mz=26=23≈0.8165,min⁡Mz=−26≈−0.8165,\max_M z = \frac{2}{\sqrt6} = \sqrt{\tfrac23} \approx 0.8165, \qquad \min_M z = -\frac{2}{\sqrt6} \approx -0.8165 ,

with no second-order test needed. Independent check: on MM, x+y=−zx + y = -z and x2+y2=1−z2x^2+y^2 = 1-z^2, while x2+y2≥(x+y)2/2x^2+y^2 \ge (x+y)^2/2 always; so 1−z2≥z2/21 - z^2 \ge z^2/2, that is z2≤2/3z^2 \le 2/3, with equality when x=yx = y — exactly the bound just found.

(b) A non-compact constraint set, where step 6 is needed. Minimise f(x,y)=x+yf(x,y) = x+y on M={xy=1,  x>0}M = \{xy = 1,\; x>0\}, taking U={(x,y):x>0}U = \{(x,y) : x > 0\} and g=xy−1g = xy - 1. Then ∇g=(y,x)\nabla g = (y,x), which is non-zero on MM, so every point is regular and step 4 is empty. Step 3: (1,1)=λ(y,x)(1,1) = \lambda(y,x) gives y=x=1/λy = x = 1/\lambda, and xy=1xy = 1 with x>0x>0 gives x=y=1x = y = 1, λ=1\lambda = 1; the single candidate is (1,1)(1,1) with f=2f = 2. MM is closed but unbounded, so step 5 does not apply. Step 6:

H=Hf(1,1)−λHg(1,1)=(0000)−1⋅(0110)=(0−1−10),H = H_f(1,1) - \lambda H_g(1,1) = \begin{pmatrix}0&0\\0&0\end{pmatrix} - 1\cdot\begin{pmatrix}0&1\\1&0\end{pmatrix} = \begin{pmatrix}0&-1\\-1&0\end{pmatrix},

and T(1,1)M=ker⁡(11)=span⁡{(1,−1)T}T_{(1,1)}M = \ker\begin{pmatrix}1&1\end{pmatrix} = \operatorname{span}\{(1,-1)^{\mathsf T}\}. For h=t(1,−1)Th = t(1,-1)^{\mathsf T} with t≠0t \ne 0,

hTHh=t2 (1,−1)(0−1−10)(1−1)=t2 (1,−1)(1−1)=2t2>0,h^{\mathsf T}Hh = t^2\,(1,-1)\begin{pmatrix}0&-1\\-1&0\end{pmatrix}\begin{pmatrix}1\\-1\end{pmatrix} = t^2\,(1,-1)\begin{pmatrix}1\\-1\end{pmatrix} = 2t^2 > 0,

so (1,1)(1,1) is a strict local minimum of ff on MM. Note that HH itself is indefinite on R2\mathbb{R}^2 (its eigenvalues are ±1\pm1): definiteness on the tangent line is all that is required, and all that holds. Check: for x>0x>0, x+1/x≥2x + 1/x \ge 2 by (x−1/x)2≥0(\sqrt x - 1/\sqrt x)^2 \ge 0, with equality only at x=1x=1, so (1,1)(1,1) is in fact the global minimiser and min⁡Mf=2\min_M f = 2.

Application(The Boltzmann distribution as a constrained maximum of entropy)Original

A system with n≥3n \ge 3 accessible microstates of energies E1,…,EnE_1,\dots,E_n, not all equal, is described by probabilities p=(p1,…,pn)p = (p_1,\dots,p_n). Gibbs's variational principle takes the equilibrium distribution to be the one maximising the entropy

S(p)=−k∑i=1npiln⁡piS(p) = -k\sum_{i=1}^{n} p_i\ln p_i

on the open set U={p:pi>0 for all i}U = \{p : p_i>0 \text{ for all } i\}, subject to the two constraints

g1(p)=∑ipi−1=0,g2(p)=∑ipiEi−Uˉ=0,g_1(p) = \sum_i p_i - 1 = 0, \qquad g_2(p) = \sum_i p_iE_i - \bar U = 0 ,

normalisation and a prescribed mean energy Uˉ\bar U. Here m=2<nm = 2 < n.

Regularity. ∇g1=(1,…,1)\nabla g_1 = (1,\dots,1) and ∇g2=(E1,…,En)\nabla g_2 = (E_1,\dots,E_n) are linearly independent precisely because the energies are not all equal, so every point of MM is a regular point and the first-order condition applies at any maximiser.

The multiplier equations. ∂S/∂pi=−k(ln⁡pi+1)\partial S/\partial p_i = -k(\ln p_i + 1), so ∇S=λ1∇g1+λ2∇g2\nabla S = \lambda_1\nabla g_1 + \lambda_2\nabla g_2 reads

−k(ln⁡pi+1)=λ1+λ2Ei(i=1,…,n),-k(\ln p_i + 1) = \lambda_1 + \lambda_2 E_i \qquad (i = 1,\dots,n),

that is pi=e−1−λ1/k e−βEip_i = e^{-1-\lambda_1/k}\,e^{-\beta E_i} with β=λ2/k\beta = \lambda_2/k. The factor in front is the same for every ii, so imposing g1=0g_1 = 0 fixes it and gives the Boltzmann distribution

pi=e−βEiZ,Z=∑j=1ne−βEj,p_i = \frac{e^{-\beta E_i}}{Z}, \qquad Z = \sum_{j=1}^{n} e^{-\beta E_j} ,

with β\beta then determined by g2=0g_2 = 0, that is by −∂(ln⁡Z)/∂β=Uˉ-\partial(\ln Z)/\partial\beta = \bar U. Two features of the method are doing real work here. The multipliers are not nuisances to be eliminated but the answer: λ2=kβ\lambda_2 = k\beta is, by the sensitivity reading of the multiplier noted in the remark above, the derivative of the maximal entropy with respect to the mean energy, which thermodynamics calls 1/T1/T — so β=1/(kT)\beta = 1/(kT), and the temperature is the multiplier conjugate to the energy constraint. And the single candidate produced is the maximiser: SS is strictly concave on UU (each −pln⁡p-p\ln p is), while MM is the intersection of UU with an affine subspace and so convex, and a critical point of a strictly concave function on a convex set is its unique maximiser.

A worked instance. Take three equally spaced levels Ei=(i−1)ϵE_i = (i-1)\epsilon for i=1,2,3i = 1,2,3 and Uˉ=0.8 ϵ\bar U = 0.8\,\epsilon. With w=e−βϵw = e^{-\beta\epsilon} the constraint g2=0g_2 = 0 becomes

w+2w21+w+w2=45  ⟺  6w2+w−4=0  ⟹  w=97−112≈0.7374048,\frac{w + 2w^2}{1 + w + w^2} = \frac45 \;\Longleftrightarrow\; 6w^2 + w - 4 = 0 \;\Longrightarrow\; w = \frac{\sqrt{97}-1}{12} \approx 0.7374048 ,

taking the positive root. Then βϵ=−ln⁡w≈0.3046183\beta\epsilon = -\ln w \approx 0.3046183, so kT≈3.2828 ϵkT \approx 3.2828\,\epsilon; Z=1+w+w2≈2.2811707Z = 1+w+w^2 \approx 2.2811707 and

p≈(0.4383714,  0.3232572,  0.2383714),S/k≈1.0683834.p \approx (0.4383714,\; 0.3232572,\; 0.2383714), \qquad S/k \approx 1.0683834 .

The mean energy checks: 0.3232572+2(0.2383714)=0.80000000.3232572 + 2(0.2383714) = 0.8000000. And S/kS/k sits just below ln⁡3≈1.0986123\ln 3 \approx 1.0986123, the entropy of the uniform distribution, which is the unconstrained maximum — the energy constraint costs a little entropy, as it must.

Integration

3

Method

Multiple integrals and change of variables

Adapted

States when a multiple integral may be computed as an iterated integral and gives the change-of-variables formula for a C1C^1 diffeomorphism, with the absolute Jacobian determinant as the local volume factor, specialised to plane polar, cylindrical and spherical coordinates.

Prerequisites: Partial derivatives and the chain rule, Implicit and inverse function theorems, The Lebesgue integral, Fubini and Tonelli theorems

Definition(Iterated integral, Jacobian factor, admissible coordinate map)AdaptedAdapted from Riley, Hobson & Bence (2006), §6.1, Eqs. (6.3)–(6.4), pp. 188–190; Folland (1999), §2.6, p. 74
  • An iterated integral of ff over a region described by a≤x≤ba \le x \le b, y1(x)≤y≤y2(x)y_1(x) \le y \le y_2(x) is ∫ab(∫y1(x)y2(x)f(x,y) dy)dx,\int_a^b \left( \int_{y_1(x)}^{y_2(x)} f(x,y)\, dy \right) dx , the inner integral being computed with xx held fixed. The limits of the inner integral may depend on the outer variable; those of the outer integral may not. The convention extends to any number of variables.
  • Let Ω⊆Rn\Omega \subseteq \mathbb{R}^n be open. A map G:Ω→RnG : \Omega \to \mathbb{R}^n is a C1C^1 diffeomorphism (Folland's usage) if GG is of class C1C^1, injective on Ω\Omega, and det⁡DuG≠0\det D_uG \neq 0 for every u∈Ωu \in \Omega. Then G(Ω)G(\Omega) is open and G−1G^{-1} is C1C^1 (inverse function theorem).
  • For such a GG the Jacobian factor at u∈Ωu \in \Omega is ∣det⁡DuG∣\lvert \det D_uG \rvert, written ∣∂(x1,…,xn)/∂(u1,…,un)∣\bigl\lvert \partial(x_1,\dots,x_n)/\partial(u_1,\dots,u_n) \bigr\rvert when x=G(u)x = G(u). The absolute value is taken: the sign of the determinant records only the orientation of the coordinate ordering.
Method(When a multiple integral is an iterated integral)AdaptedAdapted from Folland (1999), Thm 2.37, p. 67 and Thm 2.39, p. 68; Riley, Hobson & Bence (2006), §6.1, Eqs. (6.3)–(6.4), pp. 188–190
  1. Box, continuous integrand. If ff is continuous on the closed bounded box R=[a1,b1]×⋯×[an,bn]⊆RnR = [a_1,b_1]\times\cdots\times[a_n,b_n] \subseteq \mathbb{R}^n, then ∫Rf dnx\int_R f\, d^n x equals the iterated integral in each of the n!n! orders of the variables.
  2. Region with variable limits. Let y1≤y2y_1 \le y_2 be continuous on [a,b][a,b], let R={(x,y):a≤x≤b, y1(x)≤y≤y2(x)},R = \bigl\{ (x,y) : a \le x \le b,\ y_1(x) \le y \le y_2(x) \bigr\}, and let ff be continuous on RR. Then ∫Rf dA=∫ab(∫y1(x)y2(x)f(x,y) dy)dx.\int_R f \, dA = \int_a^b \left( \int_{y_1(x)}^{y_2(x)} f(x,y)\, dy \right) dx . If the same RR can also be written as {(x,y):c≤y≤d, x1(y)≤x≤x2(y)}\{(x,y) : c \le y \le d,\ x_1(y) \le x \le x_2(y)\} with x1≤x2x_1 \le x_2 continuous, the iterated integral in the other order has the same value. The same holds in nn variables, with the innermost limits depending on all the outer variables.
  3. The general condition. Let ff be Lebesgue measurable on Rp×Rq\mathbb{R}^p \times \mathbb{R}^q. If f≥0f \ge 0, or if ∫∣f∣<∞\int \lvert f \rvert < \infty, then both iterated integrals and the multiple integral agree (for f≥0f \ge 0 all three may be +∞+\infty); the inner integrals are then defined for almost every value of the outer variable, and are measurable functions of it. This is Folland's Thm 2.39, the form of Fubini–Tonelli for the completed product measure, which is the one that applies to Lebesgue measurable integrands. If neither hypothesis holds, the two iterated integrals can both exist and be different; see Fubini and Tonelli, where these hypotheses and a counterexample belong. Parts 1 and 2 are the cases in which ff is bounded on a bounded region, so that ∫∣f∣<∞\int \lvert f \rvert < \infty automatically.
Idea of the proof(Parts 1 and 2 are part 3 with the hypothesis checked)Original

Part 3 asks for absolute integrability; parts 1 and 2 are the situations in which that comes free, because a continuous function on a compact set is bounded and a bounded function on a bounded region has a finite integral of its modulus. So the only work is bookkeeping: extend the integrand by zero outside the region, so that it is defined on the whole of Rn\mathbb{R}^n and part 3 can be quoted, and then split off one variable at a time.

Proof(Parts 1 and 2, from part 3)AdaptedAdapted from Folland (1999), Thm 2.37, p. 67 and Thm 2.39, p. 68

Part 1. ff is continuous on the compact box RR, hence bounded, say ∣f∣≤C\lvert f\rvert \le C. Let f~=f\tilde f = f on RR and f~=0\tilde f = 0 elsewhere. Then f~\tilde f is Lebesgue measurable — for c≥0c \ge 0 the set {f~>c}\{\tilde f > c\} is {x∈R:f(x)>c}\{x \in R: f(x) > c\}, the intersection of RR with an open set because ff is continuous on RR, and for c<0c < 0 it is that set together with the open complement of RR — and

∫Rn∣f~∣ dnx≤Cvol⁡(R)<∞.\int_{\mathbb{R}^n} \lvert \tilde f\rvert \, d^nx \le C \operatorname{vol}(R) < \infty .

So part 3 applies to f~\tilde f with the splitting Rn=Rn−1×R\mathbb{R}^n = \mathbb{R}^{n-1}\times\mathbb{R} and gives

∫Rf dnx=∫Rnf~ dnx=∫Rn−1(∫Rf~(x′,xn) dxn)dn−1x′,\int_R f\,d^nx = \int_{\mathbb{R}^n}\tilde f \,d^nx = \int_{\mathbb{R}^{n-1}}\left( \int_{\mathbb{R}} \tilde f(x', x_n)\, dx_n\right) d^{n-1}x' ,

where the inner integral is ∫anbnf(x′,xn) dxn\int_{a_n}^{b_n} f(x',x_n)\,dx_n for x′x' in the box R′=[a1,b1]×⋯×[an−1,bn−1]R' = [a_1,b_1]\times\cdots\times[a_{n-1},b_{n-1}] and 00 for x′x' outside it. Repeating the step on R′R', and n−1n-1 times in all, produces the iterated integral with the variables peeled off in the order xn,xn−1,…,x1x_n, x_{n-1}, \dots, x_1. Lebesgue measure on Rn\mathbb{R}^n is unchanged by a permutation of the coordinates — the case T=T = a permutation matrix, ∣det⁡T∣=1\lvert\det T\rvert = 1, of the change-of-variables statement below — so relabelling the variables first and then repeating the argument gives each of the n!n! orders, all equal to ∫Rf\int_R f.

Part 2. The region

R={(x,y)∈[a,b]×R  :  y1(x)≤y≤y2(x)}R = \bigl\{(x,y) \in [a,b]\times\mathbb{R} \;:\; y_1(x) \le y \le y_2(x)\bigr\}

is closed, being cut out of the closed set [a,b]×R[a,b]\times\mathbb{R} by the two non-strict inequalities y−y2(x)≤0y - y_2(x) \le 0 and y1(x)−y≤0y_1(x) - y \le 0 whose left sides are continuous there; and it is bounded, because y1y_1 and y2y_2 are continuous on a compact interval and so bounded. Hence RR is compact, and the extension f~\tilde f of ff by zero is measurable with ∫∣f~∣<∞\int\lvert\tilde f\rvert < \infty, exactly as in part 1. Part 3 with p=q=1p = q = 1 then gives

∫Rf dA=∫R2f~ dA=∫R(∫Rf~(x,y) dy)dx,\int_R f\, dA = \int_{\mathbb{R}^2}\tilde f \,dA = \int_{\mathbb{R}}\left(\int_{\mathbb{R}} \tilde f(x,y)\,dy\right) dx ,

and for fixed x∈[a,b]x \in [a,b] the function f~(x,⋅)\tilde f(x,\cdot) is f(x,⋅)f(x,\cdot) on [y1(x),y2(x)][y_1(x), y_2(x)] and 00 off it, while for x∉[a,b]x \notin [a,b] it vanishes identically. So the right-hand side is ∫ab(∫y1(x)y2(x)f(x,y) dy)dx\int_a^b \bigl(\int_{y_1(x)}^{y_2(x)} f(x,y)\,dy\bigr)dx, which is the claim. If RR has the second description as well, the same computation with the two variables exchanged — part 3 gives both iterated integrals, with the same value — yields the other order. In nn variables the argument is the same, applied once for each variable, the innermost limits being allowed to depend on all the outer variables because nothing above required the limits to be constants. □\square

NoteOriginal

Part 3 is the Fubini–Tonelli theorem, in the form Folland states for the completed product measure (his Thm 2.39, p. 68), which is the form that applies to Lebesgue measurable integrands. It is not proved in this unit: it belongs to Fubini and Tonelli, along with the construction of the product measure and the counterexample showing that the hypothesis cannot be dropped. Everything here that needs it quotes it.

Method(Change of variables)AdaptedAdapted from Folland (1999), §2.6, Thm 2.47(a)–(b), p. 74

Let Ω⊆Rn\Omega \subseteq \mathbb{R}^n be open and let G:Ω→RnG : \Omega \to \mathbb{R}^n be a C1C^1 diffeomorphism, so that GG is C1C^1, injective, and det⁡DuG≠0\det D_uG \neq 0 for every u∈Ωu \in \Omega. Let ff be a Lebesgue measurable function on G(Ω)G(\Omega). If f≥0f \ge 0, or if ff is integrable on G(Ω)G(\Omega), then f∘Gf \circ G is measurable on Ω\Omega and

∫G(Ω)f(x) dnx  =  ∫Ωf(G(u)) ∣det⁡DuG∣ dnu.\int_{G(\Omega)} f(x)\, d^{n}x \;=\; \int_{\Omega} f\bigl(G(u)\bigr)\, \bigl\lvert \det D_uG \bigr\rvert \, d^{n}u .

Part (b) of the same theorem is the volume rule: for Lebesgue measurable E⊆ΩE \subseteq \Omega, the image G(E)G(E) is measurable and

vol⁡(G(E))=∫E∣det⁡DuG∣ dnu\operatorname{vol}\bigl(G(E)\bigr) = \int_E \lvert \det D_uG \rvert \, d^n u

— equivalently, the displayed formula applied to f=χG(E)f = \chi_{G(E)}, which is the indicator function on G(Ω)G(\Omega) that the hypotheses admit. The Jacobian factor is thus the local ratio by which GG stretches nn-dimensional volume.

Algebra of Jacobian determinants. For composable C1C^1 changes of variables x=x(y)x = x(y), y=y(z)y = y(z), the chain rule and the multiplicativity of determinants give

∂(x1,…,xn)∂(z1,…,zn)=∂(x1,…,xn)∂(y1,…,yn)  ∂(y1,…,yn)∂(z1,…,zn),∂(x1,…,xn)∂(y1,…,yn)=[∂(y1,…,yn)∂(x1,…,xn)]−1,\frac{\partial(x_1,\dots,x_n)}{\partial(z_1,\dots,z_n)} = \frac{\partial(x_1,\dots,x_n)}{\partial(y_1,\dots,y_n)}\; \frac{\partial(y_1,\dots,y_n)}{\partial(z_1,\dots,z_n)}, \qquad \frac{\partial(x_1,\dots,x_n)}{\partial(y_1,\dots,y_n)} = \left[ \frac{\partial(y_1,\dots,y_n)}{\partial(x_1,\dots,x_n)} \right]^{-1},

the second with both sides evaluated at corresponding points. These help when one of the two sets of partial derivatives is much easier to compute than the other.

Idea of the proof(Why the Jacobian factor is the local volume ratio)AdaptedAdapted from Folland (1999), §2.6, proof of Thm 2.47, pp. 75–76

Near a point u0u_0 the map GG agrees, to higher order, with the affine map u↦G(u0)+Du0G (u−u0)u \mapsto G(u_0) + D_{u_0}G\,(u - u_0), and an affine map multiplies the volume of every set by ∣det⁡∣\lvert\det\rvert of its linear part — the linear case of the theorem, which follows from Fubini–Tonelli and the one-variable scaling and translation rules. So on a cube small enough that DuGD_uG hardly varies, GG multiplies volume by nearly ∣det⁡DuG∣\lvert\det D_uG\rvert. Subdividing a cube into many such pieces and adding up gives a sum that is a Riemann-type approximation to ∫∣det⁡DuG∣\int\lvert\det D_uG\rvert, and the mesh can be sent to zero because DuGD_uG is continuous. That gives the volume rule, and the formula for integrals then follows by approximating ff by simple functions.

Proof(The volume rule and the algebra of Jacobian determinants)AdaptedAdapted from Folland (1999), §2.6, Thm 2.47(b), p. 74; Arfken, Weber & Harris (2013), §4.4, Eq. (4.75), p. 230; Riley, Hobson & Bence (2006), §6.4.4, Eqs. (6.16)–(6.17), pp. 206–207

The volume rule, given the integral formula. Let E⊆ΩE \subseteq \Omega be Lebesgue measurable; that G(E)G(E) is again measurable is part of Folland's statement and is not re-proved here. The function f=χG(E)f = \chi_{G(E)} is measurable and non-negative on G(Ω)G(\Omega), so the hypotheses of the displayed formula are met, and its left-hand side is ∫G(Ω)χG(E) dnx=vol⁡(G(E))\int_{G(\Omega)}\chi_{G(E)}\,d^nx = \operatorname{vol}(G(E)). On the right, χG(E)(G(u))=1\chi_{G(E)}(G(u)) = 1 exactly when G(u)∈G(E)G(u) \in G(E), which by the injectivity of GG happens exactly when u∈Eu \in E; so χG(E)∘G=χE\chi_{G(E)}\circ G = \chi_E and the right-hand side is ∫E∣det⁡DuG∣ dnu\int_E\lvert\det D_uG\rvert\,d^nu. This is the volume rule, and it is why injectivity, and not merely the non-vanishing of the determinant, is needed: a map that covered part of G(Ω)G(\Omega) twice would make χG(E)∘G\chi_{G(E)}\circ G larger than χE\chi_E.

The composition rule. Let x=x(y)x = x(y) and y=y(z)y = y(z) be C1C^1 with the composite defined. The chain rule gives Dzx=(Dyx)(Dzy)D_z x = (D_yx)(D_zy) at corresponding points, and the determinant of a product of square matrices is the product of the determinants, which is the first display.

The reciprocal rule. Apply the composition rule with z=xz = x, so that the composite is the identity map, whose derivative is II with determinant 11:

∂(x1,…,xn)∂(y1,…,yn)  ∂(y1,…,yn)∂(x1,…,xn)=1,\frac{\partial(x_1,\dots,x_n)}{\partial(y_1,\dots,y_n)}\;\frac{\partial(y_1,\dots,y_n)}{\partial(x_1,\dots,x_n)} = 1 ,

both factors evaluated at corresponding points. This is the second display, and it is part 2 of the inverse function theorem read as an identity between determinants — the relation Arfken writes as J−1=∂(u)/∂(x)J^{-1} = \partial(u)/\partial(x). In particular neither determinant can vanish where the other is defined. □\square

NoteOriginal

The change-of-variables formula itself — the first display of the statement — is not proved in this handbook. Folland's proof (§2.6, pp. 75–76) runs along the lines of the idea above: it settles the linear case first, then bounds the measure of the image of a cube by that of the image of its affine approximation, sums over a fine subdivision and passes to the limit, and finally extends from indicator functions to simple and then to measurable functions by monotone convergence. It needs his decomposition of an open set into cubes with disjoint interiors and the regularity of Lebesgue measure, neither of which is developed here; he also notes (p. 74) that he proves a more general result by different methods in his §11.2. Everything else in this unit is proved from the formula, not alongside it.

Method(The three standard coordinate maps)AdaptedAdapted from Riley, Hobson & Bence (2006), §6.4.3, p. 205; Lee (2013), App. C, Examples C.37–C.38, pp. 660–661; Arfken, Weber & Harris (2013), §1.10, p. 73

Each map below is a C∞C^\infty diffeomorphism from the stated open set onto its image, whose complement in Rn\mathbb{R}^n is a Lebesgue null set; so by the change-of-variables theorem the resulting formula computes the integral over all of Rn\mathbb{R}^n.

  1. Plane polar. G(r,φ)=(rcos⁡φ,  rsin⁡φ)G(r,\varphi) = (r\cos\varphi,\; r\sin\varphi) on (0,∞)×(−π,π)(0,\infty) \times (-\pi,\pi), with image R2\mathbb{R}^2 minus the closed half-line {(x,0):x≤0}\{(x,0) : x \le 0\}: det⁡DG=r,dA=r dr dφ.\det DG = r, \qquad dA = r\, dr\, d\varphi .
  2. Cylindrical polar. G(ρ,φ,z)=(ρcos⁡φ,  ρsin⁡φ,  z)G(\rho,\varphi,z) = (\rho\cos\varphi,\; \rho\sin\varphi,\; z) on (0,∞)×(−π,π)×R(0,\infty) \times (-\pi,\pi) \times \mathbb{R}, with image R3\mathbb{R}^3 minus the closed half-plane {(x,0,z):x≤0}\{(x,0,z) : x \le 0\}: det⁡DG=ρ,dV=ρ dρ dφ dz.\det DG = \rho, \qquad dV = \rho\, d\rho\, d\varphi\, dz .
  3. Spherical polar (physics convention: θ\theta the polar angle from the positive zz-axis, φ\varphi the azimuth). G(r,θ,φ)=(rsin⁡θcos⁡φ,  rsin⁡θsin⁡φ,  rcos⁡θ)G(r,\theta,\varphi) = (r\sin\theta\cos\varphi,\; r\sin\theta\sin\varphi,\; r\cos\theta) on (0,∞)×(0,π)×(−π,π)(0,\infty) \times (0,\pi) \times (-\pi,\pi), with the same image as in 2: det⁡DG=r2sin⁡θ,dV=r2sin⁡θ dr dθ dφ.\det DG = r^2 \sin\theta, \qquad dV = r^2 \sin\theta\, dr\, d\theta\, d\varphi . Since 0<θ<π0 < \theta < \pi, sin⁡θ>0\sin\theta > 0 and the absolute value may be dropped.
Idea of the proof(The three coordinate maps)Original

Each determinant is a direct computation. The real content is set-theoretic: the map is injective on the stated box because it can be inverted by hand — the radius is the norm of the point, the polar angle comes from the last coordinate, the azimuth from the first two — and the injectivity of the azimuth is just the fact that two angles in an interval of length 2π2\pi with the same sine and cosine are equal. What the box leaves out is a piece of a hyperplane, which is null because each of its one-dimensional sections is a single point, and Tonelli turns that into a statement about nn-dimensional measure.

Proof(The three coordinate maps)AdaptedAdapted from Riley, Hobson & Bence (2006), §6.4.3, p. 205; Lee (2013), App. C, Examples C.37–C.38, pp. 660–661
  1. The determinants. For plane polar, DG(r,φ)=(cos⁡φ−rsin⁡φsin⁡φrcos⁡φ),det⁡DG=rcos⁡2φ+rsin⁡2φ=r.DG(r,\varphi) = \begin{pmatrix} \cos\varphi & -r\sin\varphi \\ \sin\varphi & r\cos\varphi\end{pmatrix}, \qquad \det DG = r\cos^2\varphi + r\sin^2\varphi = r . For cylindrical polar the matrix is DG(ρ,φ,z)=(cos⁡φ−ρsin⁡φ0sin⁡φρcos⁡φ0001),DG(\rho,\varphi,z) = \begin{pmatrix} \cos\varphi & -\rho\sin\varphi & 0 \\ \sin\varphi & \rho\cos\varphi & 0 \\ 0 & 0 & 1\end{pmatrix}, and expanding along the last row gives det⁡DG=ρ\det DG = \rho, the previous determinant. For spherical polar, DG(r,θ,φ)=(sin⁡θcos⁡φrcos⁡θcos⁡φ−rsin⁡θsin⁡φsin⁡θsin⁡φrcos⁡θsin⁡φrsin⁡θcos⁡φcos⁡θ−rsin⁡θ0);DG(r,\theta,\varphi) = \begin{pmatrix} \sin\theta\cos\varphi & r\cos\theta\cos\varphi & -r\sin\theta\sin\varphi \\ \sin\theta\sin\varphi & r\cos\theta\sin\varphi & r\sin\theta\cos\varphi \\ \cos\theta & -r\sin\theta & 0\end{pmatrix} ; expanding along the last row, the cofactor of the (3,1)(3,1) entry is r2cos⁡θsin⁡θcos⁡2φ+r2sin⁡θcos⁡θsin⁡2φ=r2sin⁡θcos⁡θ,r^2\cos\theta\sin\theta\cos^2\varphi + r^2\sin\theta\cos\theta\sin^2\varphi = r^2\sin\theta\cos\theta , and that of the (3,2)(3,2) entry is −(rsin⁡2θcos⁡2φ+rsin⁡2θsin⁡2φ)=−rsin⁡2θ-\bigl(r\sin^2\theta\cos^2\varphi + r\sin^2\theta\sin^2\varphi\bigr) = -r\sin^2\theta, so det⁡DG=cos⁡θ⋅r2sin⁡θcos⁡θ+(−rsin⁡θ)⋅(−rsin⁡2θ)=r2sin⁡θ (cos⁡2θ+sin⁡2θ)=r2sin⁡θ.\det DG = \cos\theta\cdot r^2\sin\theta\cos\theta + (-r\sin\theta)\cdot(-r\sin^2\theta) = r^2\sin\theta\,(\cos^2\theta + \sin^2\theta) = r^2\sin\theta . On each box the determinant is positive, since r,ρ>0r, \rho > 0 and sin⁡θ>0\sin\theta > 0 for 0<θ<π0 < \theta < \pi.
  2. Injectivity, and the image, for plane polar. Let x=G(r,φ)x = G(r,\varphi) with (r,φ)∈(0,∞)×(−π,π)(r,\varphi) \in (0,\infty)\times(-\pi,\pi). Then ∣x∣=r\lvert x\rvert = r, so rr is determined by xx; and x/r=(cos⁡φ,sin⁡φ)x/r = (\cos\varphi,\sin\varphi), so φ\varphi is determined too, because if cos⁡φ=cos⁡φ′\cos\varphi = \cos\varphi' and sin⁡φ=sin⁡φ′\sin\varphi = \sin\varphi' then φ−φ′∈2πZ\varphi - \varphi' \in 2\pi\mathbb{Z}, and the only member of 2πZ2\pi\mathbb{Z} in (−2π,2π)(-2\pi,2\pi) is 00. So GG is injective. Its image omits the origin (r>0r > 0) and omits the points with x/∣x∣=(−1,0)x/\lvert x\rvert = (-1,0), which is the case φ=±π\varphi = \pm\pi, excluded from the box; everything else is attained, by taking r=∣x∣r = \lvert x\rvert and φ\varphi the unique angle in (−π,π)(-\pi,\pi) with (cos⁡φ,sin⁡φ)=x/∣x∣(\cos\varphi,\sin\varphi) = x/\lvert x\rvert. The image is therefore R2\mathbb{R}^2 minus the closed half-line {(x,0):x≤0}\{(x,0) : x \le 0\}.
  3. Cylindrical polar. The first two coordinates are the plane polar map and the third is the identity, so injectivity and the image follow from step 2 applied in each horizontal plane: the complement of the image is the closed half-plane {(x,0,z):x≤0}\{(x,0,z) : x \le 0\}.
  4. Spherical polar. Let x=G(r,θ,φ)x = G(r,\theta,\varphi) on the stated box. Then ∣x∣2=r2sin⁡2θ(cos⁡2φ+sin⁡2φ)+r2cos⁡2θ=r2\lvert x\rvert^2 = r^2\sin^2\theta(\cos^2\varphi+\sin^2\varphi) + r^2\cos^2\theta = r^2, so r=∣x∣r = \lvert x\rvert is determined. Next x3/r=cos⁡θx_3/r = \cos\theta, and cos⁡\cos is injective on (0,π)(0,\pi), so θ\theta is determined. Then sin⁡θ>0\sin\theta > 0 and rsin⁡θ=r2−x32=∣(x1,x2)∣r\sin\theta = \sqrt{r^2 - x_3^2} = \lvert(x_1,x_2)\rvert, so (x1,x2)/(rsin⁡θ)(x_1,x_2)/(r\sin\theta) is a unit vector equal to (cos⁡φ,sin⁡φ)(\cos\varphi,\sin\varphi), and φ\varphi is determined as in step 2. So GG is injective. Conversely, let xx be outside the closed half-plane {(x,0,z):x≤0}\{(x,0,z) : x\le 0\}; then (x1,x2)≠(0,0)(x_1,x_2) \neq (0,0) and (x1,x2)/∣(x1,x2)∣≠(−1,0)(x_1,x_2)/\lvert(x_1,x_2)\rvert \ne (-1,0), so putting r=∣x∣>0r = \lvert x\rvert > 0, θ=arccos⁡(x3/r)∈(0,π)\theta = \arccos(x_3/r) \in (0,\pi) and φ\varphi the unique angle in (−π,π)(-\pi,\pi) with (cos⁡φ,sin⁡φ)=(x1,x2)/∣(x1,x2)∣(\cos\varphi,\sin\varphi) = (x_1,x_2)/\lvert(x_1,x_2)\rvert recovers x=G(r,θ,φ)x = G(r,\theta,\varphi). Points of that half-plane are not attained: r>0r>0 excludes the origin, 0<θ<π0<\theta<\pi excludes the rest of the zz-axis, and ∣φ∣<π\lvert\varphi\rvert < \pi excludes the open half-plane {(x,0,z):x<0}\{(x,0,z): x<0\}. So the image is the same as in step 3.
  5. The omitted sets are null. In R2\mathbb{R}^2 the complement of the image lies in the line L={(x,y):y=0}L = \{(x,y) : y = 0\}, which is closed and hence measurable, and by part 3 of the first statement, applied to the non-negative function χL\chi_L, vol⁡(L)=∫R(∫RχL(x,y) dy)dx=∫R0 dx=0,\operatorname{vol}(L) = \int_{\mathbb{R}}\left(\int_{\mathbb{R}} \chi_L(x,y)\, dy\right) dx = \int_{\mathbb{R}} 0 \, dx = 0 , because for each fixed xx the inner integrand is the indicator of the single point y=0y = 0. The same computation in R3\mathbb{R}^3, integrating in yy first, gives measure 00 for the plane {y=0}\{y = 0\} and hence for the closed half-plane inside it. A subset of a null set is null.
  6. The formulas. Each GG is C∞C^\infty, injective, and has non-vanishing Jacobian determinant on its box, so it is a C1C^1 diffeomorphism in the sense used here and the change-of-variables theorem applies with ∣det⁡DG∣\lvert \det DG\rvert equal to rr, ρ\rho and r2sin⁡θr^2\sin\theta respectively. Since Rn∖G(Ω)\mathbb{R}^n \setminus G(\Omega) is null, ∫Rnf=∫G(Ω)f\int_{\mathbb{R}^n} f = \int_{G(\Omega)}f for every ff that is non-negative or integrable, which is the clause at the head of the statement. □\square
NoteOriginal

What it means. Two different reductions are in play. An iterated integral turns one nn-dimensional integral into nn one-dimensional ones; what must be checked is absolute integrability, and what is gained is that each stage is one-variable calculus. A change of variables replaces the region by an easier one; what must be checked is that the new coordinates label each point of the region once, and the price is the Jacobian factor, the local volume distortion of the coordinate map. In practice: choose coordinates that make the region a box, then iterate.

Method(Computing a multiple integral)AdaptedAdapted from Riley, Hobson & Bence (2006), §6.1, pp. 188–190 and §6.4.3, p. 205; Arfken, Weber & Harris (2013), §1.10, p. 73
  1. Describe the region RR by inequalities, and sketch it if n≤3n \le 3. The limits are a property of RR, not of the integrand.
  2. Choose coordinates. Pick a map GG making RR the image of a box or of a region with simple limits: polar or cylindrical for symmetry about an axis, spherical for symmetry about a point, a linear map for an ellipsoid or a parallelepiped.
  3. Check the map on the open set you will integrate over: GG must be C1C^1, injective and have non-vanishing Jacobian determinant there. Excluding a null set — the origin, a half-plane cut, an axis — to achieve this does not change the integral.
  4. Compute the Jacobian factor ∣det⁡DuG∣\lvert \det D_uG \rvert; if the inverse map is the one given to you, compute ∂(u)/∂(x)\partial(u)/\partial(x) and take the reciprocal.
  5. Substitute: f(x)↦f(G(u))f(x) \mapsto f(G(u)), dnx↦∣det⁡DuG∣ dnud^nx \mapsto \lvert \det D_uG\rvert\,d^nu, and R↦G−1(R)R \mapsto G^{-1}(R).
  6. Justify iterating, then iterate. Check that the integrand is non-negative, or that the integral of its absolute value is finite — Tonelli applied to ∣f∣\lvert f\rvert is the usual way — then iterate in whichever order makes the limits simplest. Under the same condition the order may be exchanged, which often turns variable limits into constants.

How it fails. Step 3 is where most errors occur: a map that covers part of the region twice doubles that part's contribution, and one whose Jacobian determinant vanishes on a set of positive measure is not a diffeomorphism there at all. Step 6 cannot be skipped when ff changes sign and the region is unbounded, or when ff is unbounded: both iterated integrals can then exist and differ. For a region with part of its boundary at infinity the integral is a limit over an increasing family of bounded regions, and arguments that "neglect" the corners of that family are not valid — Arfken's warning on p. 73.

RemarkOriginal

Where the hypotheses are used, and conventions that differ.

  • Injectivity. The polar map on (0,∞)×(0,4π)(0,\infty)\times(0,4\pi) has Jacobian determinant r≠0r \ne 0 throughout but wraps the punctured plane twice, and the formula applied to it returns exactly twice the correct answer. Non-vanishing of the determinant is local and does not give injectivity; both are hypotheses.
  • Null sets removed to get a diffeomorphism. The polar map is not injective on (0,∞)×[−π,π](0,\infty)\times[-\pi,\pi], since the ends of the φ\varphi-interval give the same points; on [0,∞)×[−π,π][0,\infty)\times[-\pi,\pi] the determinant also vanishes, along r=0r = 0. The spherical map degenerates likewise at θ∈{0,π}\theta \in \{0,\pi\}. Deleting these sets costs nothing, because their images — a half-line in R2\mathbb{R}^2, a half-plane and an axis in R3\mathbb{R}^3 — are Lebesgue null.
  • The integrability hypothesis in Fubini. Both iterated integrals can exist and disagree when ∫∣f∣=∞\int\lvert f\rvert = \infty; Folland's remarks after Thm 2.37 record this and send the reader to his Exercises 47 and 48 (pp. 68–69) for the examples, and Riley, Hobson and Bence warn about unbounded regions and discontinuous integrands for the same reason. For non-negative integrands no such hypothesis is needed.
  • Which matrix, and whether it is transposed. Arfken (Eq. (4.74)) and Riley, Hobson and Bence (p. 205) lay the Jacobian matrix out with ∂xj/∂ui\partial x_j/\partial u_i in row ii, the transpose of the convention used here. Transposition does not change a determinant, so every formula above is the same either way; the layout matters only if the matrix itself is wanted.
  • Spherical angle names. We use the physics convention, θ\theta the polar angle and φ\varphi the azimuth, giving r2sin⁡θr^2\sin\theta, as do Riley, Hobson and Bence (p. 205). Lee's Example C.38 writes the same map as (ρ,φ,θ)(\rho,\varphi,\theta) with φ\varphi from the positive zz-axis and θ\theta the azimuth, and so records the determinant as ρ2sin⁡φ\rho^2\sin\varphi. Only the names differ, but mixing them silently exchanges the two angles.
  • Relation to the elementary statement. The theorem above is Folland's, for Lebesgue measurable ff; for continuous ff on a bounded region with null boundary it reduces to the Riemann-integral version of calculus texts. Riley, Hobson and Bence state the nn-dimensional rule without proof (§6.4.4) and derive the volume element geometrically from a parallelepiped.
Example(A region that becomes a box, and an integral over a ball)Original

(a) Hyperbolic coordinates. Let DD be the part of the open first quadrant between the hyperbolas xy=1xy = 1 and xy=4xy = 4 and between the lines y=xy = x and y=4xy = 4x. Compute the area of DD and ∬Dxy dA\iint_D xy \, dA.

Step 1, the region. D={(x,y):x>0, y>0, 1≤xy≤4, 1≤y/x≤4}D = \{(x,y) : x>0,\ y>0,\ 1 \le xy \le 4,\ 1 \le y/x \le 4\}, a curvilinear quadrilateral with no description by simple limits in xx and yy: the roles of the two hyperbolas and the two lines change as xx increases.

Step 2, the coordinates. The two pairs of boundary curves are level sets of u=xyu = xy and v=y/xv = y/x, so take these as the new variables. On the open first quadrant Q=(0,∞)2Q = (0,\infty)^2 the map Ψ(x,y)=(xy, y/x)\Psi(x,y) = (xy,\, y/x) has the explicit inverse

G(u,v)=(u/v,  uv),(u,v)∈(0,∞)2,G(u,v) = \Bigl( \sqrt{u/v},\; \sqrt{uv} \Bigr), \qquad (u,v) \in (0,\infty)^2 ,

as one checks by composing both ways, and D=G([1,4]×[1,4])D = G\bigl([1,4]\times[1,4]\bigr): a box.

Step 3, the map is admissible. GG is C∞C^\infty on (0,∞)2(0,\infty)^2 and injective, having the inverse Ψ\Psi. The boundary of the box is a null set, so we may work on the open box B=(1,4)×(1,4)B = (1,4)\times(1,4) and integrate over G(B)G(B): it differs from DD by the image of that boundary, which is null by the volume rule, vol⁡(G(N))=∫N∣det⁡DG∣=0\operatorname{vol}(G(N)) = \int_N\lvert\det D G\rvert = 0 for a null NN.

Step 4, the Jacobian factor, by the reciprocal rule. It is easier to differentiate Ψ\Psi:

∂(u,v)∂(x,y)=det⁡(yx−y/x21/x)=yx+xyx2=2yx=2v,\frac{\partial(u,v)}{\partial(x,y)} = \det\begin{pmatrix} y & x \\ -y/x^2 & 1/x\end{pmatrix} = \frac{y}{x} + \frac{xy}{x^2} = \frac{2y}{x} = 2v ,

so by the reciprocal rule det⁡D(u,v)G=1/(2v)\det D_{(u,v)}G = 1/(2v), which is positive, and the Jacobian factor is 1/(2v)1/(2v).

Steps 5 and 6, substitute and iterate. Both integrands below are non-negative, so Tonelli licenses the iteration in either order. For the area,

area⁡(D)=∬Bdu dv2v=(∫14du)(∫14dv2v)=3⋅12ln⁡4=3ln⁡2≈2.079442.\operatorname{area}(D) = \iint_B \frac{du\,dv}{2v} = \left(\int_1^4 du\right)\left(\int_1^4 \frac{dv}{2v}\right) = 3 \cdot \tfrac12\ln 4 = 3\ln 2 \approx 2.079442 .

For the second integral, xy=uxy = u in the new variables, so

∬Dxy dA=∬Bu2v du dv=(∫14u du)(∫14dv2v)=152ln⁡2≈5.198604.\iint_D xy\, dA = \iint_B \frac{u}{2v}\,du\,dv = \left(\int_1^4 u\,du\right)\left(\int_1^4\frac{dv}{2v}\right) = \frac{15}{2}\ln 2 \approx 5.198604 .

Check. Integrating numerically in the original variables, over xx from 1/21/2 to 22 with yy between max⁡(1/x,x)\max(1/x, x) and min⁡(4/x,4x)\min(4/x, 4x), gives 2.07944152.0794415 and 5.19860395.1986039 — the closed forms to seven figures.

(b) Spherical coordinates. Compute I=∫BR(x2+y2) dVI = \int_{B_R}(x^2+y^2)\,dV over the ball ∣x∣≤R\lvert x\rvert \le R. In spherical polars x2+y2=r2sin⁡2θx^2+y^2 = r^2\sin^2\theta and dV=r2sin⁡θ dr dθ dφdV = r^2\sin\theta\,dr\,d\theta\,d\varphi, and the ball minus a null set is the image of the box (0,R)×(0,π)×(−π,π)(0,R)\times(0,\pi)\times(-\pi,\pi), so

I=∫−ππ ⁣ ⁣∫0π ⁣ ⁣∫0Rr4sin⁡3θ dr dθ dφ=2π⋅R55⋅∫0πsin⁡3θ dθ=2π⋅R55⋅43=8πR515,I = \int_{-\pi}^{\pi}\!\!\int_0^{\pi}\!\!\int_0^{R} r^4\sin^3\theta \, dr\, d\theta\, d\varphi = 2\pi \cdot \frac{R^5}{5}\cdot \int_0^\pi \sin^3\theta\,d\theta = 2\pi\cdot\frac{R^5}{5}\cdot\frac43 = \frac{8\pi R^5}{15},

using ∫0πsin⁡3θ dθ=∫−11(1−c2) dc=4/3\int_0^\pi\sin^3\theta\,d\theta = \int_{-1}^{1}(1-c^2)\,dc = 4/3 with c=cos⁡θc = \cos\theta. For R=1R = 1 this is 8π/15≈1.6755168\pi/15 \approx 1.675516. The three integrals separated because the integrand factorised and the limits were constants — which is the whole point of choosing coordinates that turn the region into a box.

Application(Moments of inertia, and the Maxwell speed distribution)Original

A uniform solid ellipsoid. Let E={x2/a2+y2/b2+z2/c2≤1}E = \{x^2/a^2 + y^2/b^2 + z^2/c^2 \le 1\} carry total mass MM at constant density ρ=M/vol⁡(E)\rho = M/\operatorname{vol}(E). Its moment of inertia about the zz-axis is Iz=ρ∫E(x2+y2) dVI_z = \rho\int_E (x^2+y^2)\,dV. Two changes of variables do the whole computation.

First the linear map G(u)=(au1,bu2,cu3)G(u) = (au_1, bu_2, cu_3), with constant det⁡DG=abc\det DG = abc, which carries the closed unit ball BB onto EE; the volume rule gives vol⁡(E)=abcvol⁡(B)=43πabc\operatorname{vol}(E) = abc\operatorname{vol}(B) = \tfrac43\pi abc, and

∫E(x2+y2) dV=abc∫B(a2u12+b2u22) dV.\int_E (x^2+y^2)\,dV = abc\int_B \bigl(a^2u_1^2 + b^2u_2^2\bigr)\,dV .

Then spherical polars on BB: ∫B∣u∣2dV=∫01r2⋅4πr2 dr=4π/5\int_B \lvert u\rvert^2 dV = \int_0^1 r^2\cdot 4\pi r^2\,dr = 4\pi/5, and since ∫Bu12=∫Bu22=∫Bu32\int_Bu_1^2 = \int_Bu_2^2 = \int_Bu_3^2 by the symmetry of BB under permuting coordinates, each equals 13⋅4π/5=4π/15\tfrac13\cdot4\pi/5 = 4\pi/15. Hence

Iz=3M4πabc⋅abc (a2+b2) 4π15=M (a2+b2)5,I_z = \frac{3M}{4\pi abc}\cdot abc\,(a^2+b^2)\,\frac{4\pi}{15} = \frac{M\,(a^2+b^2)}{5},

which for a=b=c=Ra=b=c=R is the familiar 25MR2\tfrac25 MR^2 of a uniform sphere. Nothing but the Jacobian factors abcabc and r2sin⁡θr^2\sin\theta was needed; attempting the same integral in Cartesian coordinates means three nested square-root limits.

The Maxwell speed distribution. In the kinetic theory of gases the velocity v∈R3v \in \mathbb{R}^3 of a molecule of mass mm at temperature TT has probability density

f(v)=(m2πkT)3/2e−m∣v∣2/(2kT),f(v) = \left(\frac{m}{2\pi kT}\right)^{3/2} e^{-m\lvert v\rvert^2/(2kT)} ,

which is largest at v=0v = 0. The distribution of the speed ∣v∣\lvert v\rvert is obtained by changing to spherical coordinates in velocity space, where d3v=v2sin⁡θ dv dθ dφd^3v = v^2\sin\theta\,dv\,d\theta\,d\varphi: since ff depends only on v=∣v∣v = \lvert v\rvert, the two angular integrations give the factor ∫−ππ∫0πsin⁡θ dθ dφ=4π\int_{-\pi}^{\pi}\int_0^\pi \sin\theta\,d\theta\,d\varphi = 4\pi and

F(v)=4πv2(m2πkT)3/2e−mv2/(2kT).F(v) = 4\pi v^2\left(\frac{m}{2\pi kT}\right)^{3/2} e^{-mv^2/(2kT)} .

The famous v2v^2 in front is precisely the Jacobian factor, with the surface of the sphere of radius vv folded into it. It is also what makes F(0)=0F(0) = 0 and puts the most probable speed at

dFdv=0  ⟹  2v=mv2kT v  ⟹  vmp=2kTm,\frac{dF}{dv} = 0 \;\Longrightarrow\; 2v = \frac{mv^2}{kT}\,v \;\Longrightarrow\; v_{\mathrm{mp}} = \sqrt{\frac{2kT}{m}} ,

strictly positive, even though the most probable velocity vector is zero. The apparent paradox is entirely a matter of the volume element: few molecules have small speed because there is little room in velocity space at small ∣v∣\lvert v\rvert.

Theorem

Differentiation under the integral sign

Adapted

If ff and all its first partial derivatives in the parameters x∈U⊆Rnx \in U \subseteq \mathbb{R}^n are continuous on U×[a,b]U \times [a,b], then F(x)=∫abf(x,t) dtF(x) = \int_a^b f(x,t)\,dt is of class C1C^1 with ∂F/∂xi=∫ab∂f/∂xi dt\partial F/\partial x_i = \int_a^b \partial f/\partial x_i\,dt; with differentiable limits of integration the derivative acquires the two boundary terms of the Leibniz rule.

Prerequisites: Uniform convergence, Partial derivatives and the chain rule, Compactness

Theorem(Fixed limits of integration)AdaptedAdapted from Lee (2013), App. C, Thm C.14, p. 648

Let U⊆RnU \subseteq \mathbb{R}^n be open, let a<ba < b be real, and let f:U×[a,b]→Rf : U \times [a,b] \to \mathbb{R} be continuous. Suppose that for each i=1,…,ni = 1,\dots,n the partial derivative ∂f/∂xi\partial f/\partial x_i exists at every point of U×[a,b]U \times [a,b] and is continuous on U×[a,b]U \times [a,b]. Define

F(x)=∫abf(x,t) dt(x∈U).F(x) = \int_a^b f(x,t)\, dt \qquad (x \in U).

Then FF is of class C1C^1 on UU and, for every x∈Ux \in U and every ii,

∂F∂xi(x)=∫ab∂f∂xi(x,t) dt.\frac{\partial F}{\partial x_i}(x) = \int_a^b \frac{\partial f}{\partial x_i}(x,t)\, dt .

For n=1n = 1 this reads F′(x)=∫ab∂f/∂x (x,t) dtF'(x) = \int_a^b \partial f/\partial x\,(x,t)\, dt.

The following corollary is ours, not part of Lee's theorem, which concludes only C1C^1; it is proved in Step 7 below. Iteration. If ff and all its partial derivatives in xx up to order kk are continuous on U×[a,b]U \times [a,b], then FF is of class CkC^k and each such derivative may be taken inside the integral.

Theorem(Leibniz rule with variable limits)AdaptedAdapted from Stakgold & Holst (2011), §1.2, Eq. (1.2.11), p. 64; Lee (2013), App. C, Thm C.14, p. 648

Let I,J⊆RI, J \subseteq \mathbb{R} be open intervals, let f:I×J→Rf : I \times J \to \mathbb{R} be continuous with ∂f/∂x\partial f/\partial x existing and continuous on I×JI \times J, and let α,β:I→J\alpha, \beta : I \to J be differentiable. Define

F(x)=∫α(x)β(x)f(x,t) dt(x∈I).F(x) = \int_{\alpha(x)}^{\beta(x)} f(x,t)\, dt \qquad (x \in I).

Then FF is differentiable on II and

F′(x)=f(x,β(x)) β′(x)  −  f(x,α(x)) α′(x)  +  ∫α(x)β(x)∂f∂x(x,t) dt.F'(x) = f\bigl(x, \beta(x)\bigr)\, \beta'(x) \;-\; f\bigl(x, \alpha(x)\bigr)\, \alpha'(x) \;+\; \int_{\alpha(x)}^{\beta(x)} \frac{\partial f}{\partial x}(x,t)\, dt .

If in addition α\alpha and β\beta are of class C1C^1, then FF is of class C1C^1. The two boundary terms are the rate at which the interval of integration sweeps across the integrand at each end; the integral term is the previous statement with the limits frozen.

NoteOriginal

What it means. The question answered here is when a limit (the derivative in xx) may be moved through an integral (over tt). Continuity of ∂f/∂x\partial f/\partial x on the closed strip makes the difference quotients in xx converge uniformly in t∈[a,b]t \in [a,b], which is one sufficient condition for a limit to pass under a sign of integration (uniform convergence); that is the whole content of the fixed-limit theorem. The variable-limit version is then the chain rule applied to (x,u,v)↦∫uvf(x,t) dt(x,u,v) \mapsto \int_u^v f(x,t)\,dt, whose three partial derivatives are, by the fundamental theorem of calculus and the fixed-limit theorem, ∫uv∂f/∂x dt\int_u^v \partial f/\partial x\,dt, −f(x,u)-f(x,u) and f(x,v)f(x,v). On an unbounded interval of integration, or with an unbounded integrand, continuity is not enough and the hypothesis has to be a domination condition instead; see dominated convergence.

Idea of the proof(Fixed limits)Original

The derivative of FF at xx is a limit of averages of difference quotients of ff, and the integral of ∂f/∂x\partial f/\partial x is the average of a limit. So the whole question is whether one limit, taken in xx, may be exchanged with an average taken in tt — and the one hypothesis that always licenses such an exchange over a bounded interval is that the convergence be uniform in tt.

That uniformity is bought by compactness. The mean value theorem rewrites each difference quotient in xx as a value of ∂f/∂x\partial f/\partial x at an unknown nearby point; continuity of ∂f/∂x\partial f/\partial x on a compact strip around the segment {x}×[a,b]\{x\}\times[a,b] makes that value close to ∂f/∂x(x,t)\partial f/\partial x(x,t) by an amount that does not depend on tt. Integrating an error smaller than ε\varepsilon over an interval of length b−ab-a costs at most (b−a)ε(b-a)\varepsilon, which is the whole estimate. The same compactness argument, used once more, shows the resulting partial derivatives are continuous, which is what upgrades "differentiable" to C1C^1.

Proof(Fixed limits)Original

Lee states the theorem on p. 648 without proving it: the paragraph that introduces it, at the foot of p. 647, says only that a proof may be found in [Apo74], [Rud76] or [Str00]. So the argument below is ours; it is the standard compactness route sketched in the remark.

Step 0 (FF is defined). For each fixed x∈Ux \in U the map t↦f(x,t)t \mapsto f(x,t) is continuous on [a,b][a,b], hence Riemann integrable, so F(x)F(x) is a well-defined real number.

Step 1 (localise). Fix x0∈Ux_0 \in U and an index ii. Since UU is open there is r>0r > 0 with the closed ball K={x∈Rn:∣x−x0∣≤r}K = \{x \in \mathbb{R}^n : \lvert x - x_0\rvert \le r\} contained in UU. The set K×[a,b]⊆Rn+1K \times [a,b] \subseteq \mathbb{R}^{n+1} is closed and bounded, hence compact by Heine-Borel.

Step 2 (uniform continuity of the derivative). By hypothesis ∂f/∂xi\partial f/\partial x_i is continuous on U×[a,b]U \times [a,b], hence on the compact set K×[a,b]K \times [a,b], hence uniformly continuous there (compactness, "what continuity gains on a compact space", part 2). So, given ε>0\varepsilon > 0, there is δ\delta with 0<δ≤r0 < \delta \le r such that

∣∂f∂xi(y,s)−∂f∂xi(y′,s)∣<εwhenever y,y′∈K, ∣y−y′∣<δ, s∈[a,b].\left\lvert \frac{\partial f}{\partial x_i}(y,s) - \frac{\partial f}{\partial x_i}(y',s) \right\rvert < \varepsilon \qquad\text{whenever } y, y' \in K,\ \lvert y - y'\rvert < \delta,\ s \in [a,b] .

This is the only place the continuity of ∂f/∂xi\partial f/\partial x_i is used; its mere existence at every point of U×[a,b]U \times [a,b] is used again in Step 3, to apply the mean value theorem. Existence alone would not give the display.

Step 3 (mean value theorem in the ii-th variable). Let 0<∣h∣<δ0 < \lvert h \rvert < \delta, so that x0+hei∈K⊆Ux_0 + h e_i \in K \subseteq U, and fix t∈[a,b]t \in [a,b]. The one-variable function s↦f(x0+sei,t)s \mapsto f(x_0 + s e_i, t) is defined for ∣s∣≤r\lvert s \rvert \le r, is continuous there (as ff is continuous) and is differentiable with derivative ∂f/∂xi(x0+sei,t)\partial f/\partial x_i (x_0 + s e_i, t), because that partial derivative exists at every point of U×[a,b]U \times [a,b]. The mean value theorem therefore supplies a number θ∈(0,1)\theta \in (0,1), depending on tt and hh, with

f(x0+hei,t)−f(x0,t)h=∂f∂xi(x0+θhei,t).\frac{f(x_0 + h e_i, t) - f(x_0, t)}{h} = \frac{\partial f}{\partial x_i}\bigl(x_0 + \theta h e_i, t\bigr) .

Step 4 (the difference quotients converge uniformly in tt). The point x0+θheix_0 + \theta h e_i lies in KK and is at distance ∣θh∣<δ\lvert \theta h\rvert < \delta from x0x_0, so Step 2 applied to y=x0+θheiy = x_0 + \theta h e_i and y′=x0y' = x_0 turns Step 3 into

∣f(x0+hei,t)−f(x0,t)h−∂f∂xi(x0,t)∣<εfor every t∈[a,b] and every 0<∣h∣<δ.\left\lvert \frac{f(x_0 + h e_i, t) - f(x_0, t)}{h} - \frac{\partial f}{\partial x_i}(x_0, t) \right\rvert < \varepsilon \qquad\text{for every } t \in [a,b] \text{ and every } 0 < \lvert h\rvert < \delta .

The bound is independent of tt: the difference quotients converge to ∂f/∂xi(x0,⋅)\partial f/\partial x_i(x_0, \cdot) uniformly on [a,b][a,b] (uniform convergence).

Step 5 (integrate the estimate). By linearity of the integral and the elementary bound ∣∫abg∣≤(b−a)sup⁡[a,b]∣g∣\lvert\int_a^b g\rvert \le (b-a)\sup_{[a,b]}\lvert g\rvert, Step 4 gives, for every 0<∣h∣<δ0 < \lvert h \rvert < \delta,

∣F(x0+hei)−F(x0)h−∫ab∂f∂xi(x0,t) dt∣≤(b−a) ε.\left\lvert \frac{F(x_0 + h e_i) - F(x_0)}{h} - \int_a^b \frac{\partial f}{\partial x_i}(x_0,t)\,dt \right\rvert \le (b-a)\,\varepsilon .

As ε>0\varepsilon > 0 was arbitrary, the limit of the left-hand difference quotient as h→0h \to 0 exists and equals the integral: ∂F/∂xi(x0)\partial F/\partial x_i(x_0) exists and is ∫ab∂f/∂xi(x0,t) dt\int_a^b \partial f/\partial x_i (x_0,t)\,dt. This is the displayed formula.

Nothing in Steps 1 to 5 singled out the point x0x_0 or the index ii: the hypotheses hold at every point of UU and for every ii, so the argument may be run again at any x∈Ux \in U. Hence every first partial derivative of FF exists at every point of UU and is given there by the displayed formula. That is what makes Step 6 legitimate as stated.

Step 6 (the partial derivatives are continuous). Fix again a point x0∈Ux_0 \in U and the ball K⊆UK \subseteq U, ε\varepsilon and δ\delta of Steps 1 and 2. By the paragraph just above, ∂F/∂xi\partial F/\partial x_i exists at every point of KK and is the integral of ∂f/∂xi\partial f/\partial x_i there. So for x,x′∈Kx, x' \in K with ∣x−x′∣<δ\lvert x - x'\rvert < \delta, Step 2 bounds the integrands and the same elementary estimate gives

∣∂F∂xi(x)−∂F∂xi(x′)∣≤∫ab∣∂f∂xi(x,t)−∂f∂xi(x′,t)∣dt≤(b−a) ε.\left\lvert \frac{\partial F}{\partial x_i}(x) - \frac{\partial F}{\partial x_i}(x') \right\rvert \le \int_a^b \left\lvert \frac{\partial f}{\partial x_i}(x,t) - \frac{\partial f}{\partial x_i}(x',t) \right\rvert dt \le (b-a)\,\varepsilon .

Since ε\varepsilon was arbitrary and δ\delta depends only on ε\varepsilon, this says ∂F/∂xi\partial F/\partial x_i is continuous at x0x_0; and x0∈Ux_0 \in U was arbitrary. Every first partial derivative of FF therefore exists on UU and is continuous on UU, which is exactly the statement that FF is of class C1C^1 (partial derivatives and the chain rule).

Step 7 (iteration). Suppose ff and all its xx-partials up to order kk are continuous on U×[a,b]U \times [a,b]. Steps 1 to 6 apply to ff and give ∂F/∂xi=∫ab∂f/∂xi dt\partial F/\partial x_i = \int_a^b \partial f/\partial x_i\,dt; the integrand is a function to which the hypotheses again apply, with kk replaced by k−1k-1. Induction on kk therefore gives F∈CkF \in C^k and the interchange for every derivative of order at most kk. □\square

Idea of the proof(Variable limits)Original

There is nothing new to prove. Freeze the two limits of integration as independent variables, so that the single function Φ(x,u,v)=∫uvf(x,t) dt\Phi(x,u,v) = \int_u^v f(x,t)\,dt contains all the information, and note that FF is the composite of Φ\Phi with the curve x↦(x,α(x),β(x))x \mapsto (x, \alpha(x), \beta(x)).

The three partial derivatives of Φ\Phi are known separately: the derivative in xx is the fixed-limit theorem just proved, and the derivatives in uu and in vv are the fundamental theorem of calculus, with a minus sign at the lower end. The chain rule then assembles them, and the three terms of the Leibniz formula are just those three partial derivatives weighted by 11, α′(x)\alpha'(x) and β′(x)\beta'(x).

Proof(Variable limits)Original

Write Φ(x,u,v)=∫uvf(x,t) dt\Phi(x,u,v) = \int_u^v f(x,t)\,dt for (x,u,v)∈I×J×J(x,u,v) \in I \times J \times J, with the usual orientation convention ∫uv=−∫vu\int_u^v = -\int_v^u. Because JJ is an interval, the closed segment between uu and vv lies in JJ, so the integrand is defined and continuous there and Φ\Phi is well defined. By construction F(x)=Φ(x,α(x),β(x))F(x) = \Phi\bigl(x, \alpha(x), \beta(x)\bigr), the composition being legitimate because α\alpha and β\beta take values in JJ.

Step 1 (the two derivatives in the limits). Fix xx and uu. The map v↦∫uvf(x,t) dtv \mapsto \int_u^v f(x,t)\,dt is an indefinite integral of the continuous function t↦f(x,t)t \mapsto f(x,t), so by the fundamental theorem of calculus ∂Φ/∂v=f(x,v)\partial \Phi/\partial v = f(x,v). Exchanging the roles of the endpoints and using the orientation convention, ∂Φ/∂u=−f(x,u)\partial \Phi/\partial u = -f(x,u).

Step 2 (the derivative in the parameter). Fix u,v∈Ju, v \in J and choose a closed interval [c,d]⊆J[c,d] \subseteq J containing both uu and vv, and an open interval I′⊆II' \subseteq I containing the point xx of interest. Then ff and ∂f/∂x\partial f/\partial x are continuous on I′×[c,d]I' \times [c,d], so the fixed-limit statement applies with [c,d][c,d] in place of [a,b][a,b] and gives

∂Φ∂x(x,u,v)=∫uv∂f∂x(x,t) dt,\frac{\partial \Phi}{\partial x}(x,u,v) = \int_u^v \frac{\partial f}{\partial x}(x,t)\,dt ,

the sign convention carrying over from ∫uv\int_u^v to ∫uv∂f/∂x\int_u^v \partial f/\partial x unchanged.

Step 3 (Φ\Phi is of class C1C^1). The two derivatives of Step 1 are continuous in (x,u,v)(x,u,v) because ff is continuous. For the third, let (x,u,v)(x,u,v) and (x′,u′,v′)(x',u',v') both lie in I′×[c,d]2I' \times [c,d]^2 with I′I' and [c,d][c,d] as in Step 2, and let M=max⁡∣∂f/∂x∣M = \max \lvert \partial f/\partial x\rvert over the compact set I′′‾×[c,d]\overline{I''} \times [c,d] for a compact subinterval I′′‾⊆I′\overline{I''} \subseteq I' containing xx and x′x'. Then

∣∂Φ∂x(x,u,v)−∂Φ∂x(x′,u′,v′)∣≤∣∫uv(∂f∂x(x,t)−∂f∂x(x′,t))dt∣+M(∣u−u′∣+∣v−v′∣),\left\lvert \frac{\partial \Phi}{\partial x}(x,u,v) - \frac{\partial \Phi}{\partial x}(x',u',v') \right\rvert \le \left\lvert \int_u^v \Bigl( \frac{\partial f}{\partial x}(x,t) - \frac{\partial f}{\partial x}(x',t) \Bigr) dt \right\rvert + M\bigl( \lvert u - u'\rvert + \lvert v - v'\rvert \bigr) ,

because changing the endpoints alters the integral only over two intervals of lengths ∣u−u′∣\lvert u - u'\rvert and ∣v−v′∣\lvert v-v'\rvert. The first term tends to 00 as x′→xx' \to x by Step 6 of the previous proof, and the second tends to 00 as (u′,v′)→(u,v)(u',v') \to (u,v). So all three partial derivatives of Φ\Phi exist and are continuous on I×J×JI \times J \times J, that is, Φ\Phi is of class C1C^1, and in particular differentiable at every point (partial derivatives and the chain rule).

Step 4 (chain rule). The curve γ(x)=(x,α(x),β(x))\gamma(x) = \bigl(x, \alpha(x), \beta(x)\bigr) is differentiable on II, since α\alpha and β\beta are differentiable by hypothesis, with γ′(x)=(1,α′(x),β′(x))\gamma'(x) = \bigl(1, \alpha'(x), \beta'(x)\bigr). As Φ\Phi is differentiable, the chain rule applies to F=Φ∘γF = \Phi \circ \gamma and gives, at every x∈Ix \in I,

F′(x)=∂Φ∂x⋅1+∂Φ∂u α′(x)+∂Φ∂v β′(x),F'(x) = \frac{\partial \Phi}{\partial x} \cdot 1 + \frac{\partial \Phi}{\partial u}\,\alpha'(x) + \frac{\partial \Phi}{\partial v}\,\beta'(x) ,

all three partials evaluated at γ(x)\gamma(x). Substituting Steps 1 and 2 produces

F′(x)=∫α(x)β(x)∂f∂x(x,t) dt−f(x,α(x))α′(x)+f(x,β(x))β′(x),F'(x) = \int_{\alpha(x)}^{\beta(x)} \frac{\partial f}{\partial x}(x,t)\,dt - f\bigl(x,\alpha(x)\bigr)\alpha'(x) + f\bigl(x,\beta(x)\bigr)\beta'(x) ,

which is the Leibniz formula.

Step 5 (the C1C^1 refinement). If in addition α,β∈C1\alpha, \beta \in C^1, then γ\gamma is continuous with continuous derivative, and the right-hand side above is a continuous function of xx: the three partials of Φ\Phi are continuous by Step 3 and γ\gamma, α′\alpha', β′\beta' are continuous. A differentiable function with continuous derivative is of class C1C^1, so F∈C1(I)F \in C^1(I). □\square

Method(Evaluating an integral by introducing a parameter)Original

A definite integral with no visible parameter can often be computed by creating one and differentiating.

  1. Embed the integral in a family. Write the wanted number as F(x0)F(x_0) for some F(x)=∫abf(x,t) dtF(x) = \int_a^b f(x,t)\,dt, choosing the parameter xx so that ∂f/∂x\partial f/\partial x is simpler than ff — typically by inserting a factor e−xte^{-xt}, txt^{x} or cos⁡(xt)\cos(xt), or by promoting a constant already present to a variable.
  2. Check the hypotheses on a region containing x0x_0. Find an open I∋x0I \ni x_0 on which ff and ∂f/∂x\partial f/\partial x are continuous on I×[a,b]I \times [a,b], endpoints included. If the tt-interval is infinite or ff is unbounded, this step must instead produce a function gg, integrable over the tt-range, with ∣∂f/∂x(x,t)∣≤g(t)\lvert \partial f/\partial x (x,t)\rvert \le g(t) for every x∈Ix \in I and every tt, so that dominated convergence applies.
  3. Differentiate under the sign to get F′(x)=∫ab∂f/∂x (x,t) dtF'(x) = \int_a^b \partial f/\partial x\,(x,t)\,dt, and evaluate that integral in closed form. If it is still hard, differentiate again, or combine with a reversal of the order of integration, the companion technique for a double integral (Arfken, Weber & Harris (2013), §1.10, Example 1.10.6, pp. 70–71).
  4. Solve the resulting equation for FF. Usually F′=φ(x)F' = \varphi(x) is integrated directly; sometimes step 3 yields a first-order differential equation for FF, for example F′=c(x)FF' = c(x)F.
  5. Fix the constant of integration from a value of xx at which FF is known, often an endpoint or a limit x→∞x \to \infty; frequently it is a value at which the integrand vanishes identically in tt, so that FF there is 00. The constant cannot be recovered from the differentiated equation alone, and this step is where the answer is pinned down.
  6. Evaluate at x0x_0, checking that x0x_0 lies in the interval II on which steps 2–5 were justified.

How it fails. Omitting step 2 is the usual error: on a strip that is not closed, or with an infinite interval of integration, continuity of ff and ∂f/∂x\partial f/\partial x does not justify step 3, and the identity can be false (see the remark). Omitting step 5 produces an answer right up to an additive constant. If ff or ∂f/∂x\partial f/\partial x is discontinuous at some t=t0t = t_0 in [a,b][a,b], split the integral at t0t_0 first and use the Leibniz rule on each piece, as Stakgold and Holst do for a Green's function whose tt-derivative jumps at t=xt = x.

RemarkOriginal

Where the hypotheses are used, and what fails without them.

  • The continuity must hold on a closed strip U×[a,b]U \times [a,b]. Let f(x,t)=2x3(x2+t2)2,f(x,t) = \frac{2x^3}{(x^2+t^2)^2} , which is continuous, together with ∂f/∂x\partial f/\partial x, on R×(0,∞)\mathbb{R}\times(0,\infty) — but on no strip U×[0,b]U \times [0,b] with 0∈U0 \in U, since f(x,0)=2/xf(x,0) = 2/x has no limit as x→0x \to 0. With the full range t∈(0,∞)t \in (0,\infty), ∫0∞dt/(x2+t2)2=π/(4x3)\int_0^\infty dt/(x^2+t^2)^2 = \pi/(4x^3) for x>0x > 0, so F(x)=∫0∞f(x,t) dt=π2 (x>0),F(0)=0,F(x)=−π2 (x<0),F(x) = \int_0^\infty f(x,t)\, dt = \frac{\pi}{2}\ (x>0), \qquad F(0) = 0, \qquad F(x) = -\frac{\pi}{2}\ (x<0), and FF is not even continuous at 00, let alone differentiable; meanwhile f(x,t)f(x,t) vanishes to third order in xx for each fixed t>0t > 0, so ∂f/∂x(0,t)=0\partial f/\partial x(0,t) = 0 and the differentiated integral exists and equals 00. One side of the formula does not exist at all.
  • It is the open end at t=0t = 0, not the length of the tt-interval, that fails here. Shortening the range to (0,1](0,1] changes nothing: ∫01f(x,t) dt=x/(x2+1)+arctan⁡(1/x)\int_0^1 f(x,t)\,dt = x/(x^2+1) + \arctan(1/x), with one-sided limits ±π/2\pm\pi/2 at 00 while the value there is 00. Keeping the range infinite but closing it at the bad end repairs the identity: on R×[1,∞)\mathbb{R}\times[1,\infty) one finds ∫1∞f(x,t) dt=arctan⁡x−x/(1+x2)=23x3+O(x5)\int_1^\infty f(x,t)\,dt = \arctan x - x/(1+x^2) = \tfrac23 x^3 + O(x^5), whose derivative at 00 is 0=∫1∞∂f/∂x(0,t) dt0 = \int_1^\infty \partial f/\partial x(0,t)\,dt. What goes wrong in the first bullet is that the mass of ∂f/∂x\partial f/\partial x escapes to t=0t = 0 as x→0x \to 0: no function of tt integrable near 00 dominates ∂f/∂x(x,t)\partial f/\partial x(x,t) for all small xx.
  • Existence of ∂f/∂x\partial f/\partial x is not enough; its continuity is what is used. The fixed-limit statement is proved by controlling (f(x+h,t)−f(x,t))/h(f(x+h,t)-f(x,t))/h uniformly in t∈[a,b]t \in [a,b], via the mean value theorem and the continuity of ∂f/∂x\partial f/\partial x on the compact strip K×[a,b]K \times [a,b] for a compact K∋xK \ni x. Drop that continuity and the difference quotients need not converge uniformly.
  • The boundary terms need only differentiability of the limits. In the Leibniz rule α\alpha and β\beta are required to be differentiable, not C1C^1; FF is then differentiable but perhaps not C1C^1. They must also take values in JJ, so that f(x,α(x))f(x,\alpha(x)) and f(x,β(x))f(x,\beta(x)) are defined, and JJ must be an interval, so that the whole segment between α(x)\alpha(x) and β(x)\beta(x) lies in it.
  • A jump in the integrand across the diagonal. Stakgold and Holst apply the rule to a Green's-function integral ∫01g(x,ξ) q(ξ) dξ\int_0^1 g(x,\xi)\,q(\xi)\,d\xi — they call the source term ff, which we rename qq here to keep ff for the integrand of the statements above — where ∂g/∂x\partial g/\partial x jumps at ξ=x\xi = x. The integral must first be split at ξ=x\xi = x, after which each piece has a continuous xx-derivative and a variable limit. The boundary terms from the two pieces cancel on the first differentiation precisely because gg is continuous across ξ=x\xi = x, and fail to cancel on the second, which is what produces the delta-like source term.
  • Conventions. Some texts call the fixed-limit identity "Leibniz's rule" and others reserve that name for the variable-limit formula with its two boundary terms, which is the usage here. The same name is also attached, in an unrelated context, to the formula for the nnth derivative of a product.
  • The general hypothesis. For an infinite interval or an unbounded integrand the right statement replaces continuity of ∂f/∂x\partial f/\partial x by a bound ∣∂f/∂x(x,t)∣≤g(t)\lvert \partial f/\partial x(x,t)\rvert \le g(t) valid for all xx in a neighbourhood, with gg integrable over the tt-range; that belongs to dominated convergence. Domination is what replaces the compactness of [a,b][a,b] used in the proof above.
Example(A parameter inserted where there was none)Original

Evaluate

N=∫01ln⁡(1+t)1+t2 dt.N = \int_0^1 \frac{\ln(1+t)}{1+t^2}\, dt .

There is no parameter in sight, so we create one.

  1. Embed in a family. Put f(x,t)=ln⁡(1+xt)/(1+t2)f(x,t) = \ln(1+xt)/(1+t^2) and F(x)=∫01f(x,t) dtF(x) = \int_0^1 f(x,t)\,dt, so that N=F(1)N = F(1) and F(0)=0F(0) = 0. The point of this choice is that differentiating in xx removes the logarithm.
  2. Check the hypotheses. Take I=(−1,∞)I = (-1,\infty). For x∈Ix \in I and t∈[0,1]t \in [0,1] we have 1+xt≥min⁡{1,1+x}>01 + xt \ge \min\{1, 1+x\} > 0, so ff is continuous on I×[0,1]I \times [0,1], and so is ∂f∂x(x,t)=t(1+xt)(1+t2).\frac{\partial f}{\partial x}(x,t) = \frac{t}{(1+xt)(1+t^2)} . The tt-interval is closed and bounded, so the fixed-limit theorem applies on the whole of II and F∈C1(I)F \in C^1(I).
  3. Differentiate under the sign and split the integrand. Partial fractions in tt give t(1+xt)(1+t2)=11+x2(−x1+xt+t+x1+t2),\frac{t}{(1+xt)(1+t^2)} = \frac{1}{1+x^2}\left( \frac{-x}{1+xt} + \frac{t+x}{1+t^2} \right), which is checked by clearing denominators: −x(1+t2)+(t+x)(1+xt)=t+x2t=t(1+x2)-x(1+t^2) + (t+x)(1+xt) = t + x^2 t = t(1+x^2).
  4. Evaluate the three pieces. For x≠0x \neq 0, ∫01dt/(1+xt)=ln⁡(1+x)/x\int_0^1 dt/(1+xt) = \ln(1+x)/x, while ∫01t dt/(1+t2)=12ln⁡2\int_0^1 t\,dt/(1+t^2) = \tfrac12 \ln 2 and ∫01dt/(1+t2)=π/4\int_0^1 dt/(1+t^2) = \pi/4. Hence F′(x)=11+x2(−ln⁡(1+x)+12ln⁡2+πx4),F'(x) = \frac{1}{1+x^2}\left( -\ln(1+x) + \tfrac12 \ln 2 + \frac{\pi x}{4} \right), and this also holds at x=0x = 0, where both sides equal 12ln⁡2\tfrac12\ln 2.
  5. Integrate from 00 to 11. FF is C1C^1 on I⊇[0,1]I \supseteq [0,1], so F(1)=F(0)+∫01F′(x) dxF(1) = F(0) + \int_0^1 F'(x)\,dx with F(0)=0F(0) = 0: F(1)=−∫01ln⁡(1+x)1+x2 dx+ln⁡22∫01dx1+x2+π4∫01x dx1+x2.F(1) = -\int_0^1 \frac{\ln(1+x)}{1+x^2}\,dx + \frac{\ln 2}{2}\int_0^1 \frac{dx}{1+x^2} + \frac{\pi}{4}\int_0^1 \frac{x\,dx}{1+x^2} .
  6. Recognise the integral on the right. The first integral is N=F(1)N = F(1) again — only the name of the variable has changed. The other two are π/4\pi/4 and 12ln⁡2\tfrac12\ln 2, so F(1)=−F(1)+ln⁡22⋅π4+π4⋅ln⁡22=−F(1)+πln⁡24.F(1) = -F(1) + \frac{\ln 2}{2}\cdot\frac{\pi}{4} + \frac{\pi}{4}\cdot\frac{\ln 2}{2} = -F(1) + \frac{\pi \ln 2}{4} .
  7. Solve. 2F(1)=πln⁡2/42F(1) = \pi \ln 2/4, so N=πln⁡28=0.2721982613…N = \frac{\pi \ln 2}{8} = 0.2721982613\ldots Numerical quadrature of the original integral gives 0.27219826130.2721982613, which is the check. Note that step 5, fixing the value of FF at a point where it is known, is what pins the answer down; step 4 alone determines NN only up to a constant.
Example(Variable limits: a Volterra integral and the equation it solves)Original

Let q:R→Rq : \mathbb{R} \to \mathbb{R} be continuous and set

u(x)=∫0xsin⁡(x−s) q(s) ds.u(x) = \int_0^x \sin(x - s)\, q(s)\, ds .

We show that uu solves u′′+u=qu'' + u = q with u(0)=u′(0)=0u(0) = u'(0) = 0, and then compute it for q(s)=sq(s) = s.

  1. Hypotheses. Here f(x,s)=sin⁡(x−s)q(s)f(x,s) = \sin(x-s)q(s) is continuous on R2\mathbb{R}^2, and ∂f/∂x=cos⁡(x−s)q(s)\partial f/\partial x = \cos(x-s)q(s) is too; the limits α(x)=0\alpha(x) = 0 and β(x)=x\beta(x) = x are of class C1C^1 with α′=0\alpha' = 0, β′=1\beta' = 1. The Leibniz rule applies, with I=J=RI = J = \mathbb{R}.
  2. First differentiation. The boundary term at the lower limit carries the factor α′=0\alpha' = 0, and the one at the upper limit is f(x,x)⋅1=sin⁡(0)q(x)=0f(x,x)\cdot 1 = \sin(0)q(x) = 0. So only the integral term survives: u′(x)=∫0xcos⁡(x−s) q(s) ds.u'(x) = \int_0^x \cos(x-s)\, q(s)\, ds . In particular u(0)=u′(0)=0u(0) = u'(0) = 0, both integrals being over an interval of zero length.
  3. Second differentiation. Apply the rule again, now to the integrand cos⁡(x−s)q(s)\cos(x-s)q(s), whose xx-derivative is −sin⁡(x−s)q(s)-\sin(x-s)q(s). This time the upper boundary term is cos⁡(0)q(x)=q(x)\cos(0)q(x) = q(x) and does not vanish: u′′(x)=q(x)−∫0xsin⁡(x−s) q(s) ds=q(x)−u(x).u''(x) = q(x) - \int_0^x \sin(x-s)\,q(s)\,ds = q(x) - u(x) . Hence u′′+u=qu'' + u = q. The whole content of the computation is that the boundary term is invisible at the first differentiation and decisive at the second.
  4. A closed form. Take q(s)=sq(s) = s. Substituting σ=x−s\sigma = x - s, u(x)=∫0x(x−σ)sin⁡σ dσ=x(1−cos⁡x)−(sin⁡x−xcos⁡x)=x−sin⁡x.u(x) = \int_0^x (x - \sigma)\sin\sigma\, d\sigma = x\bigl(1 - \cos x\bigr) - \bigl(\sin x - x\cos x\bigr) = x - \sin x .
  5. Check. u′′=sin⁡xu'' = \sin x, so u′′+u=sin⁡x+(x−sin⁡x)=x=q(x)u'' + u = \sin x + (x - \sin x) = x = q(x), and u(0)=u′(0)=0u(0) = u'(0) = 0. The value at x=1x = 1 is u(1)=1−sin⁡1=0.1585290152…,u(1) = 1 - \sin 1 = 0.1585290152\ldots, and numerical quadrature of ∫01sin⁡(1−s) s ds\int_0^1 \sin(1-s)\,s\,ds returns 0.15852901520.1585290152.
ApplicationOriginal

Differentiating an integral in a parameter, and in its limits, is one of the standard moves of theoretical physics.

  • Impulse response and Duhamel's formula. For a mass on a spring driven from rest, mx¨+kx=f(t)m\ddot{x} + kx = f(t) with x(0)=x˙(0)=0x(0) = \dot{x}(0) = 0 and ω=k/m\omega = \sqrt{k/m}, the solution is x(t)=1mω∫0tsin⁡(ω(t−s))f(s) ds,x(t) = \frac{1}{m\omega}\int_0^t \sin\bigl(\omega(t-s)\bigr) f(s)\,ds , and the verification is Example 2 word for word, with the factor 1/(mω)1/(m\omega) and ω\omega inserted: the first differentiation loses its boundary term because the impulse response sin⁡(ωτ)/(mω)\sin(\omega\tau)/(m\omega) vanishes at τ=0\tau = 0 (the system starts at rest), and the second keeps it because the derivative of that response is 1/m1/m at τ=0\tau = 0 (an impulse delivers momentum). That surviving boundary term is the force at the present instant. For m=1m = 1, ω=2\omega = 2 and a step force f≡1f \equiv 1 the formula gives x(t)=(1−cos⁡2t)/4x(t) = (1 - \cos 2t)/4, which oscillates about the static displacement f/k=1/4f/k = 1/4; at t=1t = 1 it equals 0.35403670910.3540367091.
  • Green's functions with a kink. The same rule, applied twice, is how one checks that u(x)=∫01g(x,ξ) q(ξ) dξu(x) = \int_0^1 g(x,\xi)\,q(\xi)\,d\xi solves −u′′=q-u'' = q on (0,1)(0,1) with u(0)=u(1)=0u(0) = u(1) = 0. Because ∂g/∂x\partial g/\partial x jumps across ξ=x\xi = x, the integral must first be split at ξ=x\xi = x, which turns a fixed-limit integral into two variable-limit ones. Stakgold and Holst carry this out (Stakgold & Holst (2011), §1.2, pp. 63–64): the boundary terms of the two pieces cancel on the first differentiation, because gg is continuous across the diagonal, and fail to cancel on the second, where their difference is exactly the unit jump of ∂g/∂x\partial g/\partial x and delivers −q(x)-q(x). Every delta-function source in a Green's-function calculation appears in this way.
  • Generating functions in statistical mechanics and quantum theory. Thermodynamic averages are parameter derivatives of integrals: from Z(β)=∫e−βH dΓZ(\beta) = \int e^{-\beta H}\,d\Gamma one gets ⟨H⟩=−∂(ln⁡Z)/∂β\langle H \rangle = -\partial(\ln Z)/\partial\beta, and differentiating again gives the energy variance, hence the heat capacity. Moments of any distribution come the same way from its moment generating function, and the Hellmann-Feynman theorem ∂E/∂λ=⟨ψ∣∂H/∂λ∣ψ⟩\partial E/\partial\lambda = \langle \psi \vert \partial H/\partial\lambda \vert \psi\rangle is the same interchange applied to E(λ)=∫ψ‾ HλψE(\lambda) = \int \overline{\psi}\,H_\lambda \psi. In each case the hypothesis that has to be checked is the one of step 2 of the method: on an infinite range of integration continuity is not enough, and one needs a dominating integrable bound valid throughout a neighbourhood of the parameter value.

Method

Gaussian integrals

Adapted

Collects the one-dimensional Gaussian integral and its moments, the effect of completing the square in the exponent, and the nn-dimensional formula ∫exp⁡(−12xTAx+bTx) dnx=(2π)n/2(det⁡A)−1/2exp⁡(12bTA−1b)\int \exp(-\tfrac12 x^{\mathsf T}Ax + b^{\mathsf T}x)\,d^n x = (2\pi)^{n/2}(\det A)^{-1/2}\exp(\tfrac12 b^{\mathsf T}A^{-1}b) for symmetric positive definite AA, with the recipe for reducing an exponent to that form.

Prerequisites: Multiple integrals and change of variables, Differentiation under the integral sign, Quadratic forms and the Rayleigh quotient, Spectral theorem for Hermitian matrices, Fubini and Tonelli theorems, Cauchy's theorem

Definition(Notation)AdaptedAdapted from Arfken, Weber & Harris (2013), §13.1, Eq. (13.5), p. 600 and Eq. (13.8), p. 601

Throughout, α>0\alpha > 0 and n∈Nn \in \mathbb{N}.

  • The gamma function is defined for Re⁡z>0\operatorname{Re} z > 0 by the Euler integral Γ(z)=∫0∞e−ttz−1 dt\Gamma(z) = \int_0^\infty e^{-t} t^{z-1}\,dt, which converges there; it satisfies Γ(z+1)=zΓ(z)\Gamma(z+1) = z\Gamma(z), Γ(k)=(k−1)!\Gamma(k) = (k-1)! for k∈Nk \in \mathbb{N}, and Γ(1/2)=π\Gamma(1/2) = \sqrt{\pi}. Only these facts are used below; for the full theory see the Gamma function.
  • The double factorial of an odd number is (2m−1)!!=1⋅3⋅5⋯(2m−1)(2m-1)!! = 1 \cdot 3 \cdot 5 \cdots (2m-1) for m≥1m \ge 1, with the convention (−1)!!=1(-1)!! = 1 so that the formulas below hold at m=0m = 0. It is related to the gamma function by Γ(m+12)=(2m−1)!! π/2m\Gamma(m + \tfrac12) = (2m-1)!!\,\sqrt{\pi}/2^{m}.
  • A real symmetric n×nn \times n matrix AA is positive definite if xTAx>0x^{\mathsf T} A x > 0 for every x∈Rn∖{0}x \in \mathbb{R}^n \setminus \{0\}, equivalently if all its eigenvalues are positive (quadratic forms).
  • dnxd^n x denotes Lebesgue measure on Rn\mathbb{R}^n, and an integral written ∫Rn\int_{\mathbb{R}^n} is over all of Rn\mathbb{R}^n. Only the symmetric part of a matrix in a quadratic exponent is ever visible, since xTAx=xT(12(A+AT))xx^{\mathsf T} A x = x^{\mathsf T}\bigl(\tfrac12(A + A^{\mathsf T})\bigr)x for every xx, so AA may be assumed symmetric without loss.
Method(The one-dimensional Gaussian integral and its moments)AdaptedAdapted from Riley, Hobson & Bence (2006), §6.4.2, pp. 202–204; Arfken, Weber & Harris (2013), §13.1, Eq. (13.8), p. 601 and Exercise 13.1.10, p. 608

Let α>0\alpha > 0.

  1. The integral. ∫−∞∞e−αx2 dx=πα,equivalently∫−∞∞e−x2/(2σ2) dx=σ2π(σ>0).\int_{-\infty}^{\infty} e^{-\alpha x^2}\, dx = \sqrt{\frac{\pi}{\alpha}} , \qquad\text{equivalently}\qquad \int_{-\infty}^{\infty} e^{-x^2/(2\sigma^2)}\, dx = \sigma\sqrt{2\pi} \quad (\sigma > 0). In gamma-function form the same statement is Γ(1/2)=π\Gamma(1/2) = \sqrt{\pi}.
  2. Even moments. For every integer m≥0m \ge 0, ∫0∞x2me−αx2 dx=Γ ⁣(m+12)2 α m+1/2=(2m−1)!!2 m+1αmπα,\int_{0}^{\infty} x^{2m} e^{-\alpha x^2}\, dx = \frac{\Gamma\!\left(m + \tfrac12\right)}{2\,\alpha^{\,m+1/2}} = \frac{(2m-1)!!}{2^{\,m+1}\alpha^{m}}\sqrt{\frac{\pi}{\alpha}}, and, the integrand being even, twice that over the whole line: ∫−∞∞x2me−αx2 dx=Γ ⁣(m+12)α m+1/2=(2m−1)!!(2α)mπα.\int_{-\infty}^{\infty} x^{2m} e^{-\alpha x^2}\, dx = \frac{\Gamma\!\left(m + \tfrac12\right)}{\alpha^{\,m+1/2}} = \frac{(2m-1)!!}{(2\alpha)^{m}}\sqrt{\frac{\pi}{\alpha}} .
  3. Odd moments. For every integer m≥0m \ge 0, ∫0∞x2m+1e−αx2 dx=m!2 α m+1,∫−∞∞x2m+1e−αx2 dx=0,\int_{0}^{\infty} x^{2m+1} e^{-\alpha x^2}\, dx = \frac{m!}{2\,\alpha^{\,m+1}}, \qquad \int_{-\infty}^{\infty} x^{2m+1} e^{-\alpha x^2}\, dx = 0 , the second because the integrand is odd and absolutely integrable. The half-line formula here is part (a) of Arfken's Exercise 13.1.10; part (b) of that exercise is the half-line even moment of part 2 above. The full-line values in parts 2 and 3 are obtained from those two by the parity of the integrand.
  4. Completing the square. For α>0\alpha > 0 and any β∈C\beta \in \mathbb{C}, ∫−∞∞e−αx2+βx dx=πα  eβ2/(4α),\int_{-\infty}^{\infty} e^{-\alpha x^2 + \beta x}\, dx = \sqrt{\frac{\pi}{\alpha}}\; e^{\beta^2/(4\alpha)} , the integral converging absolutely for every complex β\beta. In particular, with β=ib\beta = i b for real bb, ∫−∞∞e−αx2eibx dx=πα  e−b2/(4α):\int_{-\infty}^{\infty} e^{-\alpha x^2} e^{i b x}\, dx = \sqrt{\frac{\pi}{\alpha}}\; e^{-b^2/(4\alpha)} : the Fourier transform of a Gaussian is a Gaussian.
Method(The multidimensional Gaussian integral)AdaptedAdapted from Riley, Hobson & Bence (2006), §30.13, Eqs. (30.144)–(30.145), p. 1206 and §30.15.2, Eq. (30.149), pp. 1209–1210

Let AA be a real symmetric positive definite n×nn \times n matrix and let b∈Rnb \in \mathbb{R}^n. Then the integral below converges absolutely and

∫Rnexp⁡ ⁣(−12 xTAx+bTx)dnx=(2π)n/2det⁡A  exp⁡ ⁣(12 bTA−1b).\int_{\mathbb{R}^n} \exp\!\left( -\tfrac12\, x^{\mathsf T} A x + b^{\mathsf T} x \right) d^n x = \frac{(2\pi)^{n/2}}{\sqrt{\det A}}\; \exp\!\left( \tfrac12\, b^{\mathsf T} A^{-1} b \right).

Special cases and equivalent forms:

  1. With b=0b = 0: ∫Rne−12xTAx dnx=(2π)n/2(det⁡A)−1/2\displaystyle \int_{\mathbb{R}^n} e^{-\frac12 x^{\mathsf T} A x}\, d^n x = (2\pi)^{n/2} (\det A)^{-1/2}.
  2. Writing V=A−1V = A^{-1}, which is also symmetric positive definite, and shifting by μ∈Rn\mu \in \mathbb{R}^n: ∫Rnexp⁡ ⁣(−12(x−μ)TV−1(x−μ))dnx=(2π)n/2(det⁡V)1/2,\int_{\mathbb{R}^n} \exp\!\left( -\tfrac12 (x-\mu)^{\mathsf T} V^{-1} (x-\mu) \right) d^n x = (2\pi)^{n/2} (\det V)^{1/2}, the normalisation of the multivariate Gaussian density with covariance VV.
  3. Without the factor 12\tfrac12: ∫Rne−xTAx dnx=πn/2(det⁡A)−1/2\displaystyle \int_{\mathbb{R}^n} e^{- x^{\mathsf T} A x}\, d^n x = \pi^{n/2}(\det A)^{-1/2}, from case 1 with AA replaced by 2A2A.

If AA is symmetric but not positive definite, the integral diverges for every bb: writing A=QΛQTA = Q\Lambda Q^{\mathsf T} with QQ orthogonal and substituting x=Qyx = Qy, with c=QTbc = Q^{\mathsf T}b, the integrand factorises and

∫Rnexp⁡ ⁣(−12xTAx+bTx)dnx=∏i=1n∫−∞∞e−λiyi2/2+ciyi dyi,\int_{\mathbb{R}^n} \exp\!\left( -\tfrac12 x^{\mathsf T}Ax + b^{\mathsf T}x \right) d^n x = \prod_{i=1}^{n} \int_{-\infty}^{\infty} e^{-\lambda_i y_i^2/2 + c_i y_i}\, dy_i ,

in which every factor is positive and any factor with λi≤0\lambda_i \le 0 is +∞+\infty.

NoteOriginal

What it means. Everything here comes from two facts: the single number ∫e−x2dx=π\int e^{-x^2}dx = \sqrt{\pi}, which is not obtainable by antidifferentiation and is got instead by squaring the integral and passing to plane polar coordinates (hence this unit's place after change of variables); and the fact that a positive definite quadratic form becomes a sum of squares in suitable coordinates, which turns the nn-dimensional integral into a product of nn copies of the first fact. Every other formula is bookkeeping: completing the square removes a linear term at the cost of a constant, and differentiating the answer with respect to α\alpha or bb generates the moments.

Idea of the proof(One dimension)Original

The single value ∫Re−x2dx=π\int_{\mathbb{R}} e^{-x^2}dx = \sqrt{\pi} cannot be reached by antidifferentiation, so it is reached sideways: the square of the integral is an integral over the plane, and in polar coordinates the radial factor ρ\rho supplied by the area element is exactly what makes e−ρ2ρe^{-\rho^2}\rho elementary to integrate. Because the plane is unbounded, the squeeze between the disc inscribed in a large square and the disc circumscribing it does the work of a convergence argument.

Everything else in the statement is a change of variable away. The substitution u=αx2u = \alpha x^2 turns a half-line moment into the Euler integral for Γ\Gamma, so the moments are gamma values; the odd full-line moments vanish by symmetry, which is legitimate only because the integrals converge absolutely. And a linear term in the exponent is removed by completing the square, which shifts the variable — by a real amount when β\beta is real, and by a complex one when it is not, in which case the shift is a deformation of the contour that costs nothing because e−αz2e^{-\alpha z^2} is entire.

Proof(One dimension)AdaptedAdapted from Riley, Hobson & Bence (2006), §6.4.2, pp. 202–204; Hassani (2013), Example 11.3.8, pp. 352–353

Part 1.

Convergence. The integrand is continuous and positive, and e−αx2≤e−α∣x∣e^{-\alpha x^2} \le e^{-\alpha \lvert x\rvert} for ∣x∣≥1\lvert x\rvert \ge 1, whose integral over ∣x∣≥1\lvert x \rvert \ge 1 is finite. So the integral converges absolutely for every α>0\alpha > 0.

Reduction to α=1\alpha = 1. The substitution x=t/αx = t/\sqrt{\alpha} is a linear bijection of R\mathbb{R} with dx=α−1/2dtdx = \alpha^{-1/2}dt, so ∫Re−αx2dx=α−1/2I\int_{\mathbb{R}} e^{-\alpha x^2}dx = \alpha^{-1/2} I with I=∫Re−t2dtI = \int_{\mathbb{R}} e^{-t^2}dt. Only II has to be found.

Truncate and square. Put I(a)=∫−aae−t2dtI(a) = \int_{-a}^{a} e^{-t^2}dt for a>0a > 0; then I(a)→II(a) \to I as a→∞a \to \infty. Since e−x2e−y2=e−(x2+y2)e^{-x^2}e^{-y^2} = e^{-(x^2+y^2)} and the square Qa=[−a,a]2Q_a = [-a,a]^2 is a product of intervals,

I(a)2=∫Qae−(x2+y2) dx dy,I(a)^2 = \int_{Q_a} e^{-(x^2+y^2)}\, dx\, dy ,

the double integral of a continuous function over a compact rectangle being the iterated one (iterated integrals).

Squeeze between two discs. Write DRD_R for the closed disc of radius RR about the origin. The square QaQ_a contains DaD_a and is contained in Da2D_{a\sqrt2}, because its inradius is aa and its circumradius is a2a\sqrt2. The integrand is positive, so

J(a)≤I(a)2≤J(a2),J(R)=∫DRe−(x2+y2) dx dy.J(a) \le I(a)^2 \le J\bigl(a\sqrt2\bigr), \qquad J(R) = \int_{D_R} e^{-(x^2+y^2)}\,dx\,dy .

This is the step that needs care, and it is why Riley, Hobson and Bence treat the unbounded region explicitly (pp. 203–204).

Evaluate on a disc. In plane polar coordinates the area element is ρ dρ dφ\rho\,d\rho\,d\varphi (change of variables), so

J(R)=∫02π ⁣ ⁣∫0Re−ρ2ρ dρ dφ=2π[−12e−ρ2]0R=π(1−e−R2).J(R) = \int_0^{2\pi}\!\!\int_0^{R} e^{-\rho^2}\rho\, d\rho\, d\varphi = 2\pi \left[ -\tfrac12 e^{-\rho^2} \right]_0^{R} = \pi\bigl(1 - e^{-R^2}\bigr) .

Conclude. Hence π(1−e−a2)≤I(a)2≤π(1−e−2a2)\pi(1 - e^{-a^2}) \le I(a)^2 \le \pi(1 - e^{-2a^2}). Both bounds tend to π\pi as a→∞a \to \infty, so I2=πI^2 = \pi, and I>0I > 0 because the integrand is positive; therefore I=πI = \sqrt{\pi} and ∫Re−αx2dx=π/α\int_{\mathbb{R}}e^{-\alpha x^2}dx = \sqrt{\pi/\alpha}. Taking α=1/(2σ2)\alpha = 1/(2\sigma^2) gives the second form, 2πσ2=σ2π\sqrt{2\pi\sigma^2} = \sigma\sqrt{2\pi}.

The gamma form. In Γ(1/2)=∫0∞e−tt−1/2dt\Gamma(1/2) = \int_0^\infty e^{-t}t^{-1/2}dt substitute t=x2t = x^2 with x>0x > 0: then dt=2x dxdt = 2x\,dx and t−1/2=1/xt^{-1/2} = 1/x, so Γ(1/2)=2∫0∞e−x2dx=I=π\Gamma(1/2) = 2\int_0^\infty e^{-x^2}dx = I = \sqrt{\pi}, the last equality because the integrand is even.

Part 2 (even moments). On (0,∞)(0,\infty) substitute u=αx2u = \alpha x^2, an increasing C1C^1 bijection of (0,∞)(0,\infty) onto itself, with x=(u/α)1/2x = (u/\alpha)^{1/2} and dx=12α−1/2u−1/2dudx = \tfrac12 \alpha^{-1/2}u^{-1/2}du. Then

∫0∞x2me−αx2dx=∫0∞(uα)me−u 12α−1/2u−1/2 du=12 α m+1/2∫0∞um−1/2e−u du=Γ(m+12)2 α m+1/2,\int_0^\infty x^{2m}e^{-\alpha x^2}dx = \int_0^\infty \Bigl(\frac{u}{\alpha}\Bigr)^{m} e^{-u}\,\tfrac12 \alpha^{-1/2}u^{-1/2}\,du = \frac{1}{2\,\alpha^{\,m+1/2}} \int_0^\infty u^{m-1/2}e^{-u}\,du = \frac{\Gamma(m+\tfrac12)}{2\,\alpha^{\,m+1/2}} ,

the last integral being the Euler integral for Γ(m+12)\Gamma(m+\tfrac12), convergent because m−12>−1m - \tfrac12 > -1.

The double-factorial form follows from Γ(z+1)=zΓ(z)\Gamma(z+1) = z\Gamma(z) applied mm times:

Γ(m+12)=(m−12)(m−32)⋯12 Γ(12)=(2m−1)(2m−3)⋯12mπ=(2m−1)!!2mπ,\Gamma\bigl(m+\tfrac12\bigr) = \bigl(m-\tfrac12\bigr)\bigl(m-\tfrac32\bigr)\cdots\tfrac12\,\Gamma\bigl(\tfrac12\bigr) = \frac{(2m-1)(2m-3)\cdots 1}{2^{m}}\sqrt{\pi} = \frac{(2m-1)!!}{2^{m}}\sqrt{\pi} ,

which at m=0m = 0 reads Γ(1/2)=π\Gamma(1/2) = \sqrt{\pi} because the product is empty and (−1)!!=1(-1)!! = 1. Substituting and separating one factor α−1/2\alpha^{-1/2},

Γ(m+12)2α m+1/2=(2m−1)!!2 m+1αmπα.\frac{\Gamma(m+\tfrac12)}{2\alpha^{\,m+1/2}} = \frac{(2m-1)!!}{2^{\,m+1}\alpha^{m}}\sqrt{\frac{\pi}{\alpha}} .

The integrand x2me−αx2x^{2m}e^{-\alpha x^2} is even and, by the computation just made, absolutely integrable over (0,∞)(0,\infty); hence the full-line integral is twice the half-line one, which gives (2m−1)!! (2α)−mπ/α=Γ(m+12)α−(m+1/2)(2m-1)!!\,(2\alpha)^{-m}\sqrt{\pi/\alpha} = \Gamma(m+\tfrac12)\alpha^{-(m+1/2)}.

Part 3 (odd moments). On (0,∞)(0,\infty) the same substitution u=αx2u = \alpha x^2, now in the form du=2αx dxdu = 2\alpha x\,dx, absorbs one power of xx:

∫0∞x2m+1e−αx2dx=∫0∞(uα)me−u du2α=Γ(m+1)2 α m+1=m!2 α m+1,\int_0^\infty x^{2m+1}e^{-\alpha x^2}dx = \int_0^\infty \Bigl(\frac{u}{\alpha}\Bigr)^{m}e^{-u}\,\frac{du}{2\alpha} = \frac{\Gamma(m+1)}{2\,\alpha^{\,m+1}} = \frac{m!}{2\,\alpha^{\,m+1}} ,

using Γ(k)=(k−1)!\Gamma(k) = (k-1)! for positive integers. Over the whole line the integrand is odd, and it is absolutely integrable because ∫R∣x∣2m+1e−αx2dx=2 m!/(2αm+1)<∞\int_{\mathbb{R}}\lvert x\rvert^{2m+1}e^{-\alpha x^2}dx = 2\,m!/(2\alpha^{m+1}) < \infty by what has just been computed; so the contributions of (0,∞)(0,\infty) and (−∞,0)(-\infty,0) are negatives of one another and may be added, giving 00.

Part 4 (completing the square). Set γ=β/(2α)∈C\gamma = \beta/(2\alpha) \in \mathbb{C}. Expanding, −α(x−γ)2+αγ2=−αx2+2αγx=−αx2+βx-\alpha(x-\gamma)^2 + \alpha\gamma^2 = -\alpha x^2 + 2\alpha\gamma x = -\alpha x^2 + \beta x, and αγ2=β2/(4α)\alpha\gamma^2 = \beta^2/(4\alpha). The integral converges absolutely for every β∈C\beta \in \mathbb{C}, since ∣e−αx2+βx∣=e−αx2+(Re⁡β)x\lvert e^{-\alpha x^2 + \beta x}\rvert = e^{-\alpha x^2 + (\operatorname{Re}\beta)x} and the exponent tends to −∞-\infty quadratically. So

∫−∞∞e−αx2+βxdx=eβ2/(4α)∫−∞∞e−α(x−γ)2 dx,\int_{-\infty}^{\infty} e^{-\alpha x^2 + \beta x}dx = e^{\beta^2/(4\alpha)} \int_{-\infty}^{\infty} e^{-\alpha (x-\gamma)^2}\,dx ,

and it remains to show the last integral is π/α\sqrt{\pi/\alpha} for every complex γ\gamma.

Write γ=p+iq\gamma = p + iq with p,qp, q real. Translating the real variable by pp leaves the integral unchanged, so we may take γ=iq\gamma = iq, and the claim becomes that e−αz2e^{-\alpha z^2} has the same integral along the line Im⁡z=−q\operatorname{Im}z = -q as along the real axis. Integrate e−αz2e^{-\alpha z^2}, an entire function, around the boundary of the rectangle with vertices ±R\pm R and ±R−iq\pm R - iq: the closed contour integral is zero by Cauchy's theorem. On the vertical side z=R+isz = R + is, with ss between 00 and −q-q, we have Re⁡(z2)=R2−s2≥R2−q2\operatorname{Re}(z^2) = R^2 - s^2 \ge R^2 - q^2, so ∣e−αz2∣≤e−α(R2−q2)\lvert e^{-\alpha z^2}\rvert \le e^{-\alpha(R^2 - q^2)}; the side has length ∣q∣\lvert q\rvert, so its contribution is at most ∣q∣e−α(R2−q2)\lvert q\rvert e^{-\alpha(R^2-q^2)}, which tends to 00 as R→∞R \to \infty, and the same bound holds on the side at −R-R. Letting R→∞R \to \infty, the two horizontal sides therefore contribute equal and opposite amounts, which is the claim. This is the contour of Hassani's Example 11.3.8, used here for a general complex γ\gamma rather than only a purely imaginary one. Finally, β=ib\beta = ib with bb real gives β2/(4α)=−b2/(4α)\beta^2/(4\alpha) = -b^2/(4\alpha). □\square

Idea of the proof(Several dimensions)Original

A positive definite quadratic form is a sum of squares in the right coordinates, and the right coordinates are reached by two volume-preserving moves: a translation that kills the linear term, and a rotation that diagonalises the matrix. After them the integrand is a product of nn one-variable Gaussians, so the integral is a product of nn copies of part 1, and the only trace of the matrix that survives is λ1⋯λn=det⁡A\lambda_1\cdots\lambda_n = \det A under the square root. No new analysis is involved; this is why the nn-dimensional formula is as cheap as the one-dimensional one.

Proof(Several dimensions)AdaptedAdapted from Riley, Hobson & Bence (2006), §30.13, Eqs. (30.144)–(30.145), p. 1206 and §30.15.2, Eq. (30.149), pp. 1209–1210

Step 1 (diagonalise). AA is real symmetric, so A=QΛQTA = Q\Lambda Q^{\mathsf T} with QQ orthogonal and Λ=diag⁡(λ1,…,λn)\Lambda = \operatorname{diag}(\lambda_1,\dots,\lambda_n) real (spectral theorem). Positive definiteness of AA says exactly that every λi>0\lambda_i > 0 (eigenvalue test). Hence det⁡A=λ1⋯λn>0\det A = \lambda_1\cdots\lambda_n > 0 and AA is invertible.

Step 2 (complete the square). Put c=A−1bc = A^{-1}b, so that Ac=bAc = b. Expanding and using AT=AA^{\mathsf T} = A,

−12(x−c)TA(x−c)=−12xTAx+12xTAc+12cTAx−12cTAc.-\tfrac12 (x-c)^{\mathsf T}A(x-c) = -\tfrac12 x^{\mathsf T}Ax + \tfrac12 x^{\mathsf T}Ac + \tfrac12 c^{\mathsf T}Ax - \tfrac12 c^{\mathsf T}Ac .

Now xTAc=xTb=bTxx^{\mathsf T}Ac = x^{\mathsf T}b = b^{\mathsf T}x and cTAx=(Ac)Tx=bTxc^{\mathsf T}Ax = (Ac)^{\mathsf T}x = b^{\mathsf T}x, the second using the symmetry of AA, so the two middle terms add to bTxb^{\mathsf T}x; and cTAc=cTb=bTA−1bc^{\mathsf T}Ac = c^{\mathsf T}b = b^{\mathsf T}A^{-1}b. Rearranging,

−12xTAx+bTx=−12(x−c)TA(x−c)+12 bTA−1b.-\tfrac12 x^{\mathsf T}Ax + b^{\mathsf T}x = -\tfrac12(x-c)^{\mathsf T}A(x-c) + \tfrac12\, b^{\mathsf T}A^{-1}b .

Step 3 (two volume-preserving substitutions). Substitute y=x−cy = x - c: a translation of Rn\mathbb{R}^n onto itself with Jacobian determinant 11. Then substitute y=Qzy = Qz: a linear bijection with ∣det⁡Q∣=1\lvert \det Q\rvert = 1, since QTQ=IQ^{\mathsf T}Q = \mathrm{I} forces (det⁡Q)2=1(\det Q)^2 = 1. Both are covered by the change-of-variables theorem, and under the second

yTAy=zTQTAQz=zTΛz=∑i=1nλizi2.y^{\mathsf T}Ay = z^{\mathsf T}Q^{\mathsf T}AQz = z^{\mathsf T}\Lambda z = \sum_{i=1}^{n}\lambda_i z_i^2 .

Step 4 (factorise). The constant from Step 2 comes out of the integral, leaving

∫Rnexp⁡(−12∑iλizi2)dnz=∫Rn∏i=1ne−λizi2/2 dnz=∏i=1n∫−∞∞e−λizi2/2 dzi,\int_{\mathbb{R}^n}\exp\Bigl(-\tfrac12 \sum_i \lambda_i z_i^2\Bigr) d^n z = \int_{\mathbb{R}^n} \prod_{i=1}^{n} e^{-\lambda_i z_i^2/2}\, d^n z = \prod_{i=1}^{n}\int_{-\infty}^{\infty} e^{-\lambda_i z_i^2/2}\,dz_i ,

the exchange being legitimate for a non-negative measurable integrand (Tonelli) and each one-variable factor being finite because λi>0\lambda_i > 0. This also proves the absolute convergence asserted in the statement, the integrand being positive. By part 1 of the one-dimensional statement with α=λi/2\alpha = \lambda_i/2,

∏i=1n2πλi=(2π)n/2λ1⋯λn=(2π)n/2det⁡A.\prod_{i=1}^{n}\sqrt{\frac{2\pi}{\lambda_i}} = \frac{(2\pi)^{n/2}}{\sqrt{\lambda_1\cdots\lambda_n}} = \frac{(2\pi)^{n/2}}{\sqrt{\det A}} .

Step 5 (assemble). Multiplying by e12bTA−1be^{\frac12 b^{\mathsf T}A^{-1}b} from Step 2 gives the displayed formula.

Step 6 (the three special cases). Case 1 is b=0b = 0. For case 2, note that V=A−1V = A^{-1} is symmetric with eigenvalues 1/λi>01/\lambda_i > 0, hence symmetric positive definite, and det⁡V=1/det⁡A\det V = 1/\det A; applying case 1 to V−1V^{-1} after the translation x↦x−μx \mapsto x - \mu gives (2π)n/2(det⁡V−1)−1/2=(2π)n/2(det⁡V)1/2(2\pi)^{n/2}(\det V^{-1})^{-1/2} = (2\pi)^{n/2}(\det V)^{1/2}. For case 3, replace AA by 2A2A in case 1 and use det⁡(2A)=2ndet⁡A\det(2A) = 2^{n}\det A: the answer is (2π)n/22−n/2(det⁡A)−1/2=πn/2(det⁡A)−1/2(2\pi)^{n/2}2^{-n/2}(\det A)^{-1/2} = \pi^{n/2}(\det A)^{-1/2}.

Step 7 (divergence without positive definiteness). Steps 1 and 3 used only that AA is real symmetric, so for any such AA the integral equals ∏i∫Re−λiyi2/2+ciyidyi\prod_i \int_{\mathbb{R}} e^{-\lambda_i y_i^2/2 + c_i y_i}dy_i with c=QTbc = Q^{\mathsf T}b, as recorded in the statement. Each factor is positive, and the ii-th is finite only when λi>0\lambda_i > 0: it equals 2π/λi eci2/(2λi)\sqrt{2\pi/\lambda_i}\,e^{c_i^2/(2\lambda_i)} then, by part 4 of the one-dimensional statement; it is ∫Reciydy=+∞\int_{\mathbb{R}} e^{c_i y}dy = +\infty when λi=0\lambda_i = 0 (whatever cic_i is), and +∞+\infty when λi<0\lambda_i < 0, the exponent then tending to +∞+\infty at one end at least. Since all factors are positive, a single infinite factor makes the product infinite, so the integral diverges whenever some eigenvalue fails to be positive — that is, whenever AA is not positive definite. □\square

Method(Reducing a Gaussian integral to standard form)AdaptedAdapted from Riley, Hobson & Bence (2006), §30.13, p. 1206 and §30.15.2, pp. 1209–1210; Hassani (2013), Example 11.3.8, pp. 352–353

To evaluate ∫RnP(x) eQ(x) dnx\displaystyle \int_{\mathbb{R}^n} P(x)\, e^{Q(x)}\, d^n x, where QQ is a quadratic polynomial and PP a polynomial:

  1. Separate the exponent by degree. Write Q(x)=−12xTAx+bTx+cQ(x) = -\tfrac12 x^{\mathsf T} A x + b^{\mathsf T} x + c and replace AA by 12(A+AT)\tfrac12(A + A^{\mathsf T}), which changes nothing. Pull ece^{c} outside.
  2. Test positive definiteness of AA: all eigenvalues positive, or equivalently all nn leading principal minors of AA positive. If the test fails, stop; the integral diverges.
  3. Complete the square. Using AT=AA^{\mathsf T} = A, −12xTAx+bTx=−12(x−A−1b)TA (x−A−1b)+12 bTA−1b,-\tfrac12 x^{\mathsf T} A x + b^{\mathsf T} x = -\tfrac12 (x - A^{-1}b)^{\mathsf T} A\, (x - A^{-1}b) + \tfrac12\, b^{\mathsf T} A^{-1} b , and substitute y=x−A−1by = x - A^{-1}b: a translation, with Jacobian determinant 11, so dnx=dnyd^n x = d^n y and the domain is still Rn\mathbb{R}^n.
  4. Diagonalise. Write A=QΛQTA = Q \Lambda Q^{\mathsf T} with QQ orthogonal and Λ=diag⁡(λ1,…,λn)\Lambda = \operatorname{diag}(\lambda_1,\dots,\lambda_n) (spectral theorem) and substitute y=Qzy = Qz; since ∣det⁡Q∣=1\lvert\det Q\rvert = 1, dny=dnzd^n y = d^n z, and the integral factorises into ∏i∫e−λizi2/2 dzi=∏i2π/λi=(2π)n/2(det⁡A)−1/2\prod_i \int e^{-\lambda_i z_i^2/2}\,dz_i = \prod_i \sqrt{2\pi/\lambda_i} = (2\pi)^{n/2}(\det A)^{-1/2}.
  5. Handle a polynomial prefactor PP by differentiation. Each factor xjx_j in PP is produced by ∂/∂bj\partial/\partial b_j acting on ebTxe^{b^{\mathsf T}x}, so ∫Rnxj1⋯xjk e−12xTAx+bTx dnx=∂k∂bj1⋯∂bjk[(2π)n/2det⁡Ae12bTA−1b],\int_{\mathbb{R}^n} x_{j_1}\cdots x_{j_k}\, e^{-\frac12 x^{\mathsf T}Ax + b^{\mathsf T}x}\, d^n x = \frac{\partial^k}{\partial b_{j_1} \cdots \partial b_{j_k}} \left[ \frac{(2\pi)^{n/2}}{\sqrt{\det A}} e^{\frac12 b^{\mathsf T}A^{-1}b} \right], evaluated at the wanted bb (usually b=0b = 0). In one variable the same job is done by ∂/∂α\partial/\partial\alpha: differentiating ∫e−αx2dx=π/α\int e^{-\alpha x^2}dx = \sqrt{\pi/\alpha} mm times in α\alpha produces the even moment of order 2m2m with a factor (−1)m(-1)^m. Differentiation under the integral sign is justified because every derivative is dominated, on a neighbourhood of the parameter value, by an integrable Gaussian times a polynomial (differentiation under the integral sign).
  6. A linear term that is not real. The statement above assumes b∈Rnb \in \mathbb{R}^n, so a complex bb is outside it; the identity nevertheless persists, and the following justification is ours. With xx still real, ∣exp⁡(−12xTAx+bTx)∣=exp⁡(−12xTAx+(Re⁡b)Tx)\lvert \exp(-\tfrac12 x^{\mathsf T}Ax + b^{\mathsf T}x)\rvert = \exp(-\tfrac12 x^{\mathsf T}Ax + (\operatorname{Re}b)^{\mathsf T}x), which is the real case already settled, so the integral converges absolutely. Diagonalise as in step 4 — y=Qzy = Qz, with c=QTb∈Cnc = Q^{\mathsf T}b \in \mathbb{C}^n — and split the absolutely convergent integral into a product by Fubini's theorem (Fubini and Tonelli); each factor is ∫Re−λizi2/2+cizidzi=2π/λi eci2/(2λi)\int_{\mathbb{R}} e^{-\lambda_i z_i^2/2 + c_i z_i}dz_i = \sqrt{2\pi/\lambda_i}\,e^{c_i^2/(2\lambda_i)} by part 4 of the one-dimensional statement, which is proved there for every complex coefficient. Multiplying the factors and using ∑ici2/λi=cTΛ−1c=bTQΛ−1QTb=bTA−1b\sum_i c_i^2/\lambda_i = c^{\mathsf T}\Lambda^{-1}c = b^{\mathsf T}Q\Lambda^{-1}Q^{\mathsf T}b = b^{\mathsf T}A^{-1}b returns the same closed form. The one-dimensional ingredient is where the complex shift is paid for: there the real variable cannot simply be translated, and a rectangular contour is closed instead, using that e−αz2e^{-\alpha z^2} is entire — Hassani's route for ∫eiax−bx2dx\int e^{iax-bx^2}dx.

How it fails. Step 2 is not a formality: symmetry of AA alone does not give convergence. Step 4 needs AA real symmetric, so that QQ can be taken orthogonal; a matrix with complex entries is outside the statement above, and extending the formula to one requires a choice of branch for (det⁡A)−1/2(\det A)^{-1/2}. Purely imaginary exponents, ∫eixTAxdnx\int e^{i x^{\mathsf T}Ax}d^nx (Fresnel-type), are not covered at all: those integrals do not converge absolutely and need an oscillatory-integral argument.

RemarkOriginal

Where the hypotheses are used, and conventions that differ.

  • Positive definiteness, not just symmetry. Riley, Hobson and Bence's worked evaluation of ∫exp⁡(−12(x−μ)TV−1(x−μ)) dnx\int \exp(-\tfrac12 (x-\mu)^{\mathsf T} V^{-1}(x-\mu))\,d^n x (p. 1210) assumes only that VV is symmetric, and its orthogonal diagonalisation then gives (2π)n/2(λ1⋯λn)1/2(2\pi)^{n/2}(\lambda_1\cdots\lambda_n)^{1/2}. That step needs λi>0\lambda_i > 0 for every ii: each factor is ∫e−yi2/(2λi)dyi\int e^{-y_i^2/(2\lambda_i)}dy_i, which is +∞+\infty if λi<0\lambda_i < 0, while if some λi=0\lambda_i = 0 then VV is singular and V−1V^{-1} does not exist, so the integral is not defined; and (det⁡V)1/2(\det V)^{1/2} would not be real if an odd number of eigenvalues were negative. In the setting of that section VV is a covariance matrix, where positive definiteness is automatic for a non-degenerate distribution; the statement above makes the hypothesis explicit because the formula needs it.
  • Why the nn-dimensional case needs no new analysis. Convergence of the factorised integral is absolute, so Tonelli's theorem lets the nn-fold integral be written as a product (Fubini and Tonelli); the substitutions in steps 3 and 4 are linear changes of variables with ∣det⁡∣=1\lvert\det\rvert = 1, covered by the change-of-variables theorem.
  • The one-dimensional value is not an antiderivative. e−x2e^{-x^2} has no elementary antiderivative, which is why the standard route squares the integral, converts the resulting double integral to plane polar coordinates, and controls the unbounded region by squeezing the square [−a,a]2[-a,a]^2 between the discs of radius aa and a2a\sqrt{2} — the care Riley, Hobson and Bence take on pp. 203–204 precisely because the region is unbounded.
  • Normalisation conventions. Three conventions for the exponent are in common use: e−αx2e^{-\alpha x^2} (giving π/α\sqrt{\pi/\alpha}), e−x2/(2σ2)e^{-x^2/(2\sigma^2)} (giving σ2π\sigma\sqrt{2\pi}), and in nn dimensions e−12xTAxe^{-\frac12 x^{\mathsf T}Ax} versus e−xTAxe^{-x^{\mathsf T}Ax}, which differ by 2n/22^{n/2} as recorded in case 3 above. Statistics and quantum field theory keep the factor 12\tfrac12; many methods texts omit it. Check which is in force before quoting a result.
  • Double factorial, and ranges of integration. (2m−1)!!(2m-1)!! denotes the product of the odd numbers up to 2m−12m-1, with (−1)!!=1(-1)!! = 1; Arfken's Exercise 13.1.10 writes the even moment both with Γ(m+12)\Gamma(m+\tfrac12) and with the double factorial, and the two agree because Γ(m+12)=(2m−1)!!π/2m\Gamma(m+\tfrac12) = (2m-1)!!\sqrt{\pi}/2^{m}. Both of his formulas are over (0,∞)(0,\infty), which is why part 2 states the half-line value first and the full-line value as twice it. Some authors write (2m)!/(2mm!)(2m)!/(2^m m!) for the same number.
  • The odd moments on the half-line are not zero. Part 3 gives m!/(2αm+1)m!/(2\alpha^{m+1}) over (0,∞)(0,\infty) and 00 over R\mathbb{R}; the second follows from the first only because the integral converges absolutely, so the two halves may be added. The symmetry argument is not available for a Gaussian multiplied by a non-integrable factor.
Example(One dimension: a moment, a linear term, and both at once)Original

Take α=2\alpha = 2 throughout and compute three integrals.

  1. A pure moment. With m=2m = 2 and α=2\alpha = 2, part 2 of the one-dimensional statement gives ∫−∞∞x4e−2x2dx=(2⋅2−1)!!(2⋅2)2π2=316π2=32π32=0.2349964007…\int_{-\infty}^{\infty} x^{4}e^{-2x^2}dx = \frac{(2\cdot 2 - 1)!!}{(2\cdot 2)^{2}}\sqrt{\frac{\pi}{2}} = \frac{3}{16}\sqrt{\frac{\pi}{2}} = \frac{3\sqrt{2\pi}}{32} = 0.2349964007\ldots Independent check by the other route. Differentiating ∫Re−αx2dx=π α−1/2\int_{\mathbb{R}}e^{-\alpha x^2}dx = \sqrt{\pi}\,\alpha^{-1/2} twice in α\alpha (step 5 of the method) gives ∫Rx4e−αx2dx=34π α−5/2\int_{\mathbb{R}}x^4 e^{-\alpha x^2}dx = \tfrac34\sqrt{\pi}\,\alpha^{-5/2}, and at α=2\alpha = 2 that is 34π 2−5/2=0.2349964007\tfrac34\sqrt{\pi}\,2^{-5/2} = 0.2349964007. Numerical quadrature agrees to ten digits.
  2. A linear term. With β=3\beta = 3, part 4 gives ∫−∞∞e−2x2+3xdx=π2  e9/8=1.2533141373×3.0802168489=3.8604793227…\int_{-\infty}^{\infty} e^{-2x^2 + 3x}dx = \sqrt{\frac{\pi}{2}}\;e^{9/8} = 1.2533141373 \times 3.0802168489 = 3.8604793227\ldots The exponent is largest at x=β/(2α)=3/4x = \beta/(2\alpha) = 3/4, where −2x2+3x=9/8-2x^2+3x = 9/8, which is where the factor e9/8e^{9/8} comes from.
  3. Both. For the second moment with the linear term present, differentiate the answer to 2 twice in β\beta rather than inserting x2x^2 by hand. With G(β)=π/α eβ2/(4α)G(\beta) = \sqrt{\pi/\alpha}\,e^{\beta^2/(4\alpha)}, G′′(β)=πα  eβ2/(4α)[(β2α)2+12α],G''(\beta) = \sqrt{\frac{\pi}{\alpha}}\;e^{\beta^2/(4\alpha)}\left[ \left(\frac{\beta}{2\alpha}\right)^{2} + \frac{1}{2\alpha} \right], so at α=2\alpha = 2, β=3\beta = 3 the bracket is (3/4)2+1/4=13/16=0.8125(3/4)^2 + 1/4 = 13/16 = 0.8125 and ∫−∞∞x2e−2x2+3xdx=3.8604793227×0.8125=3.1366394497…\int_{-\infty}^{\infty} x^{2}e^{-2x^2+3x}dx = 3.8604793227 \times 0.8125 = 3.1366394497\ldots Quadrature returns 3.13663944973.1366394497. Sanity check on the bracket: it is ⟨x2⟩\langle x^2\rangle for the Gaussian with mean 3/43/4 and variance 1/(2α)=1/41/(2\alpha) = 1/4, namely (3/4)2+1/4(3/4)^2 + 1/4, as it should be.
Example(Three dimensions with a linear term)Original

Evaluate

I=∫R3exp⁡ ⁣(−x12−x22−x32+x1x2+x2x3+x1+x3)d3x.I = \int_{\mathbb{R}^3} \exp\!\left( -x_1^2 - x_2^2 - x_3^2 + x_1x_2 + x_2x_3 + x_1 + x_3 \right) d^3x .
  1. Read off AA and bb. The quadratic part is −12xTAx-\tfrac12 x^{\mathsf T}Ax and the linear part bTxb^{\mathsf T}x with A=(2−10−12−10−12),b=(101),A = \begin{pmatrix} 2 & -1 & 0 \\ -1 & 2 & -1 \\ 0 & -1 & 2 \end{pmatrix}, \qquad b = \begin{pmatrix} 1 \\ 0 \\ 1 \end{pmatrix}, since −12(2x12+2x22+2x32−2x1x2−2x2x3)-\tfrac12(2x_1^2+2x_2^2+2x_3^2 - 2x_1x_2 - 2x_2x_3) reproduces the quadratic terms. AA is already symmetric, so step 1 of the method changes nothing.
  2. Test positive definiteness. The leading principal minors are 22, det⁡(2−1−12)=3\det\begin{pmatrix}2&-1\\-1&2\end{pmatrix} = 3 and det⁡A=2(4−1)+1(−2−0)=4\det A = 2(4-1) + 1(-2-0) = 4, all positive, so AA is positive definite by Sylvester's criterion (quadratic forms). As a cross-check the eigenvalues are 2−22-\sqrt2, 22 and 2+22+\sqrt2, with product (4−2)⋅2=4=det⁡A(4-2)\cdot 2 = 4 = \det A.
  3. Invert AA. Cofactor expansion gives A−1=14(321242123),A^{-1} = \frac{1}{4}\begin{pmatrix} 3 & 2 & 1 \\ 2 & 4 & 2 \\ 1 & 2 & 3 \end{pmatrix}, which is verified by AA−1=IA A^{-1} = \mathrm{I}: the first column of the product is 14(2⋅3−1⋅2,  −3+4−1,  −2+2)T=(1,0,0)T\tfrac14(2\cdot 3 - 1\cdot 2,\; -3 + 4 - 1,\; -2 + 2)^{\mathsf T} = (1,0,0)^{\mathsf T}, and similarly for the others.
  4. Evaluate the exponent. A−1b=14(3+1, 2+2, 1+3)T=(1,1,1)TA^{-1}b = \tfrac14(3+1,\,2+2,\,1+3)^{\mathsf T} = (1,1,1)^{\mathsf T}, so bTA−1b=1+0+1=2b^{\mathsf T}A^{-1}b = 1 + 0 + 1 = 2 and 12bTA−1b=1\tfrac12 b^{\mathsf T}A^{-1}b = 1.
  5. Assemble. I=(2π)3/24 e1=(2π)3/2e2=2 e π3/2=21.4059392604…I = \frac{(2\pi)^{3/2}}{\sqrt{4}}\,e^{1} = \frac{(2\pi)^{3/2}e}{2} = \sqrt{2}\,e\,\pi^{3/2} = 21.4059392604\ldots Iterated numerical quadrature over [−12,12]3[-12,12]^3 gives 21.4059421.40594, which is the check.
  6. A moment of the same form. Setting b=0b = 0 and using step 5 of the method, ∫xixj e−12xTAxd3x\int x_i x_j\,e^{-\frac12 x^{\mathsf T}Ax}d^3x divided by ∫e−12xTAxd3x\int e^{-\frac12 x^{\mathsf T}Ax}d^3x equals (A−1)ij(A^{-1})_{ij}. So for the centred density proportional to e−12xTAxe^{-\frac12 x^{\mathsf T}Ax} the second moments are ⟨x12⟩=3/4\langle x_1^2\rangle = 3/4, ⟨x22⟩=1\langle x_2^2\rangle = 1 and ⟨x1x3⟩=1/4\langle x_1 x_3\rangle = 1/4. The pair x1,x3x_1, x_3 is the one pair that the exponent does not couple, yet its covariance is nonzero: correlations spread beyond the couplings, because it is A−1A^{-1} and not AA that gives the second moments. The end coordinates also fluctuate less than the middle one.
ApplicationOriginal

Gaussian integrals are the only multidimensional integrals that can be done in closed form in general, which is why so much of physics is arranged to look Gaussian.

  • Classical fluctuations of a harmonic system. Three equal masses on a line, joined to each other and to two fixed walls by identical springs of stiffness κ\kappa, have potential energy U=κ2[x12+(x2−x1)2+(x3−x2)2+x32]=12 xTKx,K=κA,U = \tfrac{\kappa}{2}\bigl[x_1^2 + (x_2-x_1)^2 + (x_3-x_2)^2 + x_3^2\bigr] = \tfrac12\, x^{\mathsf T}Kx , \qquad K = \kappa A , with AA the matrix of the three-dimensional example above. In the canonical ensemble at temperature TT the displacements have density proportional to e−U/kBTe^{-U/k_BT}, which is the Gaussian with Aeff=K/kBTA_{\text{eff}} = K/k_BT, so the configurational partition function is (2πkBT/κ)3/2(det⁡A)−1/2=12(2πkBT/κ)3/2(2\pi k_BT/\kappa)^{3/2}(\det A)^{-1/2} = \tfrac12 (2\pi k_BT/\kappa)^{3/2} and the second moments are ⟨xixj⟩=kBT (K−1)ij=kBTκ (A−1)ij,\langle x_i x_j \rangle = k_BT\,(K^{-1})_{ij} = \frac{k_BT}{\kappa}\,(A^{-1})_{ij} , so ⟨x12⟩=0.75 kBT/κ\langle x_1^2\rangle = 0.75\,k_BT/\kappa, ⟨x22⟩=kBT/κ\langle x_2^2\rangle = k_BT/\kappa and ⟨x1x3⟩=0.25 kBT/κ\langle x_1x_3\rangle = 0.25\,k_BT/\kappa: the middle mass, held by softer effective restoring forces, wanders furthest. Summing the same formula recovers equipartition, ⟨U⟩=12∑i,jKij⟨xixj⟩=12kBTtr⁡(KK−1)=32kBT,\langle U \rangle = \tfrac12\sum_{i,j}K_{ij}\langle x_ix_j\rangle = \tfrac12 k_BT\operatorname{tr}\bigl(KK^{-1}\bigr) = \tfrac32 k_BT , that is, 12kBT\tfrac12 k_BT per quadratic degree of freedom, for any positive definite KK whatever. The free energy −kBTln⁡Z-k_BT\ln Z contains the term 12kBTln⁡det⁡K\tfrac12 k_BT \ln \det K, which is how the determinant of a stiffness matrix becomes a measurable quantity.
  • Wave packets and propagators. Part 4 with β=ib\beta = ib says that the Fourier transform of a Gaussian is a Gaussian of reciprocal width: a wave packet of position spread σ\sigma has momentum spread ℏ/(2σ)\hbar/(2\sigma), and the product is the minimum allowed by the uncertainty relation. The same formula, with α\alpha taken to the imaginary axis, is the free-particle propagator ⟨x∣e−iHt/ℏ∣x0⟩\langle x\vert e^{-iHt/\hbar}\vert x_0\rangle; and the Gaussian path integral of a quadratic action is the infinite-dimensional version of the formula of the second statement, with (det⁡A)−1/2(\det A)^{-1/2} becoming a functional determinant.
  • Error estimates and least squares. A measurement with Gaussian errors of covariance VV has likelihood proportional to exp⁡(−12(x−μ)TV−1(x−μ))\exp(-\tfrac12 (x-\mu)^{\mathsf T}V^{-1}(x-\mu)), normalised by (2π)n/2(det⁡V)1/2(2\pi)^{n/2}(\det V)^{1/2} from case 2 of the second statement. Fitting parameters by maximising it is exactly minimising the quadratic form in the exponent, which is least squares; the confidence regions are its level sets, ellipsoids with axes along the eigenvectors of VV and semi-axes proportional to λi\sqrt{\lambda_i}, so the diagonalisation of step 4 of the method is also the statement that correlated errors can always be reported as independent ones in rotated variables.