Calculus of Variations Raju K George, IIST
Lecture-1
In Calculus of Variations, we will study maximum and minimum of a certain class of functions. We first recall some maxima/minima results from the classical calculus. Maxima and Minima
Let X and Y be two arbitrary sets and f : X Y be a well-defined function having domain → X and range Y . The function values f(x) become comparable if Y is IR or a subset of IR. Thus, optimization problem is valid for real valued functions. Let f : X IR be a real valued → function having X as its domain. Now x X is said to be maximum point for the function f if 0 ∈ f(x ) f(x) x X. The value f(x ) is called the maximum value of f. Similarly, x X is 0 ≥ ∀ ∈ 0 0 ∈ said to be a minimum point for the function f if f(x ) f(x) x X and in this case f(x ) is 0 ≤ ∀ ∈ 0 the minimum value of f.
Sufficient condition for having maximum and minimum:
Theorem (Weierstrass Theorem)
Let S IR and f : S IR be a well defined function. Then f will have a maximum/minimum ⊆ → under the following sufficient conditions.
1. f : S IR is a continuous function. → 2. S IR is a bound and closed (compact) subset of IR. ⊂
Note that the above conditions are just sufficient conditions but not necessary.
Example 1:
Let f : [ 1, 1] IR defined by − → 1 x = 0 f(x)= − x x = 0 | | 6
1 −1 +1
−1
Obviously f(x) is not continuous at x = 0. However the f(x) has a minimum point x0 = 0 and maximum points at x = 1, x = 1. Continuity condition of the Weierstrass theorem is violated − but still the function has maximum and minimum.
Example 2:
Consider a function f : ( 1, 1) IR defined by − → 2 x< 0 f(x)= − 2 x 0 ≥
2
() −1 +1
−2
f(x) has a maximum value x = 2 and a minimum value x = 2 even though both the conditions − (a) and (b) of Weierstrass theorem are violated.
Example 3:
Let f : [ 1, 1] IR be defined by f(x)= x2. − →
2 −1 1
This function satisfies both the conditions of Weierstrass theorem. f(x) has a minimum value 0 at x = 0 and maximum value 1 at x = 1 and x = 1. −
Example 4:
Let f : ( 1, 1) IR defined by f(x)= x2, f has a minimum at x = 0. − →
−1 1
But f has no maximum point as x = 1 and x = 1 are outside the domain of the function. Here − the condition (b) is violated.
Necessary condition for Maximum/Minimum when f is differentiable.
Theorem
Let f : S IR be a differentiable function and let x be an interior point of S and let x is → 0 0 either a maximum point or minimum point of f. Then the first derivative of f vanishes at x0.
ie f ′(x0) = 0. This condition is just a necessary condition but not sufficient condition. An interior point x D IR is said to be a stationary point if f (x ) = 0. A stationary point 0 ∈ ⊆ ′ 0 x0 need not be maximum point/minimum point. However, if f ′′(x0) > 0 then x0 is a minimum point and if f ′′(x0) < 0 then x0 is a maximum point.
Example 5:
Let f : IR IR be defined by → f(x)= x3
3 2 f ′(x) = 3x =0 when x = 0
x3
However, x = 0 is neither a maximum point nor a minimum point of f(x)= x3.
Example 6:
Let f : IR IR be given by → f(x)= x2
Hence, f ′(x0) = 2x0 =0 when x0 = 0.
Obviously x0 = 0 is a stationary point and this stationary point is minimum point of f(x), as f ′′(x0) = 2 > 0.
Necessary conditions for Maxima/Minima functions of several variables
Multi-variable functions.
Let f : IRn IR be a real valued function of n - variables defined on IRn. If f has partial derivatives → at x IRn. If x is a maximum point/minimum point of the function f(x) then 0 ∈ 0 ∂f ∂f ∂f = 0, = 0, = 0 ∂x ∂y · · · ∂x 1 x=x0 2 x=x0 n 1 x=x0 −
4 A stationary point x0 is maximum point if the matrix ∂2f ∂2f ∂2f 2 ∂x ∂x1∂x2 · · · ∂x1∂xn 1
∂2f ∂2f ∂2f ∂x ∂x ∂x2 · · · ∂x ∂x M = 2 1 2 2 n ··· ··· ··· ··· ∂2f ∂2f ∂2f 2 ∂xn∂x1 ∂xn∂x2 · · · ∂xn x=x0 is negative definite and x0 is minimum point if M is positive definite.
Functionals:
Let S be a set of functions. Let f : S IR be a real valued function. Such functions are known → as a functionals. In otherwords, a functional is a real valued function whose domain is a set of functions.
Example 7:
Let C[0, 1] be the set of all continuous functions defined on [0, 1] Let I : C[0, 1] IR be a function defined by → 1 I(y)= y(x) dx Z0 Obviously I(y) is a functional on C[0, 1]. The following table gives the values of I(y) for different functions y(x), listed in the table.
y(x) I(y) x 0.5 x2 0.333 x3 0.25 sin x 0.4597 cos x 0.8415 ex 1.7183 1 1
We can find for which function y, the functional I(y) has a maximum value or minimum value. In the above example, I(y) will have minimum value for y(x) = x3 and I(y) will have maximum value for the function y(x)= ex out of the seven functions given here.
1 Let C [x1,x2] denote the set of continuously differentiable functions defined on [x1,x2]. Now x2 1 consider a functional I : C [x ,x ] IR defined by I(y) = F (x,y,y′)dx subject to the end 1 2 → Zx1 conditions y(x1)= y1 and y(x2)= y2.
5 In calculus of variations the basic problem is to find a function y for which the functional I(y) is maximum or minimum. We call such functions as extremizing functions and the value of the functional at the extremizing function as extremum. Consider the extremization problem x2 Extremize y I(y)= F (x,y,y′)dx Zx1 subject to the end conditions y(x1)= y1 and y(x2)= y2, where F is a twice continuously differen- tiable function.
Example
Find the shortest smooth plane curve joining two distinct points P (x1,y1) and Q(x2,y2).
y Q(x2,y2)
ds dy dx
y(x)
P(x1,y1)
x
There are infinitely many functions y passing through the given two points P (x1,y1) and Q(x2,y2). We are looking for a function which will have minimum arc length. Let ds be a small strip on the curve then we have. ds2 = dx2 + dy2 ds 2 dy 2 = 1+ dx dx dy 2 ds = 1+ dx dx s Q x2 dy 2 Total arc length I(y)= ds = 1+ dx 1 s dx ZP Zx Thus, the problem is to minimize I(y) subject to the end conditions y(x1)= y1 and y(x2)= y2.
Lecture-2
Lemma (Fundamental Lemma of Calculus of Variations)
b If f(x) is a continuous function defined on [a, b] and if f(x)g(x) dx = 0 for every function a g(x) C(a, b) such that g(a)= g(b) = 0 then f(x) 0 forZ all x [a, b]. ∈ ≡ ∈
6 Proof:
Let f(x) = 0 for some c (a, b). Without loss of generality let us assume that f(c) > 0. Now 6 ∈ because of continuity of f we have f(x) > 0 for some interval [x ,x ] [a, b] that contains the 1 2 ⊂ point c. (x x )(x x) for x [x ,x ] Let g(x)= − 1 2 − ∈ 1 2 0 outside [x ,x ] 1 2 Note that (x x )(x x) is positive for x (x ,x ). − 1 2 − ∈ 1 2 Now consider
b x1 ✘✘✿ 0 x2 b ✘✘✿ 0 ✘✘✘ ✘✘✘ f(x)g(x) dx = ✘f(✘x)g(x) dx + f(x)g(x) dx + ✘f(✘x)g(x) dx a a x1 x2 Z Z x2 Z Z = f(x)g(x) dx x1 Z x2 = f(x)(x x )(x x) dx > 0 − 1 2 − Zx1 Thus we get a contradiction to what is given in the Lemma. This implies that f(x) 0 on [a, b]. ≡
Euler-Lagrange Equation (Necessary Condition for Extremum)
Theorem: If y(x) is an extremizing function for the problem
x2 Minimize/Maximize I(y) = F (x,y,y′) dx (1) Zx1 with end conditions y(x1)= y1 and y(x2)= y2 then y(x) satisfies the BVP.
d ∂F ∂F = 0 (2) dx ∂y − ∂y ′ y(x1)= y1 and y(x2)= y2. (3)
Equation (2) is known as the Euler-Lagrange equation.
Proof:
Let y(x) be an extremizing function for the functional I(y) in (1).
7 Y y(x) + η (x) y2
y1 y(x)
η(x)
O x X 1 x2
Let Y = y(x)+ ǫ η(x) be a variation of y(x), where η(x) is a continuously differentiable function with η(x1)=0= η(x2) and ǫ is a small constant. Hence I along the path Y = y(x)+ ǫ η(x) is given by x2 x2 I(ǫ)= F (x, y(x)+ ǫ η(x), y′(x)+ ǫ η′(x)) dx = F (x,Y (x),Y ′(x)) dx Zx1 Zx1 Since y(x) is an extremizing function, I(ǫ) has extremum when ǫ = 0. Thus, by classical calculus, dI = 0 dǫ |ǫ=0 dI x2 ∂F ∂x ∂F ∂Y ∂F ∂Y = = + + ′ dx ⇒ dǫ ∂x ∂ǫ ∂Y ∂ǫ ∂Y ∂ǫ Zx1 ′ ∂x But =0 as x is independent of ǫ. ∂ǫ ∂Y = η(x) ∂ǫ ∂Y ′ = η′(x) ∂ǫ dI x2 ∂F ∂F ∴ = η(x)+ η′(x) dx dǫ ∂Y ∂Y Zx1 ′ Integration by parts we get ✟✯ 0 x2 x✟2 x2 ∂F ∂F ✟✟ d ∂F η′(x) dx = ✟η(x) η(x) dx ∂Y ∂Y✟ − dx ∂Y Zx1 ′ ✟ ′ x1 Zx1 ′ (using η(x1)= η(x2) = 0) x2 d ∂F = η(x) dx − dx ∂Y Zx1 ′ dI x2 ∂F d ∂F = η(x) dx = 0 dǫ ∂Y − dx ∂Y ǫ=0 Zx1 ′ ǫ=0 x2 ∂F d ∂F = η(x ) dx = 0 ∂y − dx ∂y Zx1 ′ as Y (x) = y(x) and Y ′(x) = y′(x) |ǫ=0 |ǫ=0
8 Since η(x) is arbitrary function, by applying the Fundamental Lemma of calculus of variations, we get d ∂F ∂F = 0 dx ∂y − ∂y ′
Different Forms of Euler Lagrange Equation
Suppose that y(x) is an extremizer of I(y).
Since F = F (x,y,y′) d ∂F dx ∂F dy ∂F dy (F ) = + + ′ dx ∂x dx ∂y dx ∂y′ dx ∂F ∂F ∂F = + y′ + y′′ (4) ∂x ∂y ∂y′ d ∂F d ∂F ∂F Consider y′ = y′ + y′′ (5) dx ∂y dx ∂y ∂y ′ ′ ′ Subtracting (4) - (5) we get,
dF d ∂F ∂F ∂F d ∂F y′ = + y′ y′ dx − dx ∂y ∂x ∂y − dx ∂y ′ ′ ✘✘✘✿ 0 d ∂F ∂F ∂F ✘d ✘✘∂F F y′ = y′ ✘✘ dx − ∂y − ∂x ✘✘∂y − dx ∂y ′ ′
As y(x) is an extremizer and by using Euler-Lagrange equation we get
d ∂F ∂F F y′ = 0 dx − ∂y − ∂x ′ which is another form of Euler-Lagrange Equation.
Special Cases
x2 Extremize I(y) = F (x,y,y′) dx y(x1)= y1 ; y(x2)= y2. Zx1
(i) When x does not appear in F explicitly
∂F = 0 ∂x d ∂F ∂F d ∂F ∂F Hence F y′ = 0 becomes F y′ =0or F y′ = const. This dx − ∂y′ − ∂x dx − ∂y′ − ∂y′ is known as Beltrami Identity.
9 (ii) When y does not appear in F explicitly ∂F = 0 ∂y
d ∂F ∂F d ∂F ∂F Hence, = 0 reduces to =0 or = const. dx ∂y − ∂y dx ∂y ∂y ′ ′ ′ (iii) When y′ does not appear in F explicitly ∂F = 0 ∂y′
d ∂F ∂F ∂F Then = 0 reduces to = 0. dx ∂y − ∂y ∂y ′
Example-1
Find the shortest smooth plane curve joining two distinct points (x1,y1) and (x2,y2). We are minimizing the arc length of the function y
x2 dy 2 Minimize I(y) = 1+ dx 1 s dx Zx 2 Here, F (x,y,y′) = 1+ y′ ∂F ∂F y =p 0 ; = ′ 2 ∂y ∂y′ 1+ y′ Euler-Lagrange equation p d ∂F y = = 0 ′ = const = c ⇒ dx ∂y 2 ′ 1+ y′ 2 y′ = c 1+p y′ 2 2 2 y′ = c p(1 + y′ ) 2 2 2 2 y′ c y′ = c − 2 2 2 (1 c )y′ = c − 2 2 c = y′ = ⇒ 1 c2 − c2 = y′ = = m ⇒ s1 c2 − y = mx + b y(x )= y = y = mx + b 1 1 ⇒ 1 1 y(x )= y = y = mx + b 2 2 ⇒ 2 2 y y y y 1 − 2 = m ; b = y 1 − 2 x x x 1 − x x 1 1 − 2 1 − 2 Thus the curve having minimum arc length passing through the given two fixed point is a straight line.
10 Exercise
Show that another form of Euler - Lagrange equation is F F ′ F ′ y F ′ ′ y = 0. y − y x − y y ′ − y y ′′
Example-2
x1 y 2 Find the extremals of the functional ′ dx. x3 Zx0 2 y′ ∂F ∂F 2y′ F (x,y,y′) = 3 ; = 0; = 3 x ∂y ∂y′ x Euler- Lagrange equation 3 2 d ∂F d 2y′ 2x y′′ 6y′x 2 = = − = xy′′ 3y′ = 0 dx ∂y dx x3 x6 x4 − ′ y′′ 3 Thus we have xy′′ 3y′ = 0 or = − y′ x y 1 Integrating ′′ = 3 dx + c y x Z ′ Z ln y′ = 3ln x + c
y′ 3 ln = c or y′ = C x x3 Cx4 y = + C 4 2 y = Ax4 + B
Example-3
x2 2 Extremize I(y) = 1+ y′ dx, y(x1)= y(x2) = 0 Zx1 2 ∂F F = 1+ y′ , = 2y′ ∂y′ d Euler Equation 2y′ =0 = 2y′′ = 0 dx ⇒ y′(x) = C, y(x)= Cx + D y y C = 1 − 2 ; x x 1 − 2
Example-4
1 2 Find the curve y on which the functional y′ + 12xy dx,y(0) = 0,y(1) = 1 is exrtremum. Z0
11 Solution:
2 Here F = y′ + 12xy
Euler Lagrange Equation: 12x 2y′′ = 0 or y′′ = 6x − 2 y′ = 3x + C 3 y = x + cx + c′ Applying the conditions we get y = x3
Lecture-3
Brachistochrone Problem (Shortest Time of Descent Problem)
Find the shortest path on which a particle in the absence of friction will slide from one point to another point in the shortest time under the action of gravity.
O
P(x,y) y
P1(x,y)
Solution:
Let the particle slide from o along the path OP1. Let at time t, the particle be at P (x,y). Let arc OP = s. By the principle of work and energy, we have KE at P KE at O = Work done in moving the particle from O to P. − 1 ds m( )2 0 = mgy 2 dt − That is ds = 2gy dt p Time taken by the particle to move from O to P is given by ⇒ 1 ′ T x1 ds 1 x1 1+ y 2 T = dt = = dx √2gy 2g √y Z0 Z0 Z0 p ′ 1 x1 1+ y 2 T = dx √2g √y Z0 p
12 Brachistochrone Problem is to find y which minimizes the functional
′ 1 x1 1+ y 2 1+ y 2 I(y)= dx and F = ′ √2g √y √y Z0 p p Since x does not appear in F explicitly take the Beltrami Identity. ∂F F y′ = const. − ∂y′ ′ ′ 1+ y 2 ∂ 1+ y 2 y′ ( ) = c p √y − ∂y′ p √y ′2 1+ y 1 y′ y′ ′ = c p √y − √y 1+ y 2 ′2 ′2 1+py y − ′ = c √y 1+ y 2 1 1 p 2 ′ = c y(1 + y′ )= = √a(say) √y 1+ y 2 ⇒ c ′ p yp(1 + y 2) = a ′ a 1+ y 2 = y 2 a y y′ = − y a y y′ = − y r dy a y = − dx y r y dy = dx a y r − x y y dx = dy a y Z0 Z0 r − Since (0,0) is point on the curve, we get c=0. Let y= a sin2 θ; dy = 2a sin θ cos θdθ
θ a sin2 θ Thus, x = 2a sin θ cos θdθ sa a sin2 θ Z0 − θ sin θ θ θ x = 2a sin θ cos θdθ = a 2sin2 dθ = a (1 cos 2θ)dθ 0 cos θ 0 0 − Za Z Z x = [2θ sin 2θ] 2 − a Let 2 = b, 2θ = φ x = b(φ sin φ); y = b(1 cos φ) − − which is a cycloid.
13 Example - Minimum Surface Area of Rotation.
Find the curve passing through the points (x1,y1) and (x2,y2) which when rotated about the x-axis gives a minimum surface.
y
(x2,y2) y(x) (x1,y1) ds
y
O x
Let ds be a small strip on the curve y. Area of the surface generated by ds when revolved is x2 2πy ds. In the figure the total surface area = 2πyds Zx1 x2 2 = 2π y (1 + y′ )dx. x1 Z p This has to be minimum. 2 Since F = y (1 + y′ ) does not contain x explicitly, thus the Euler’s equation reduces to p ∂F F y′ = c : (say) − ∂y′ 2 ∂ 2 y (1 + y′ ) y′ y (1 + y′ ) = c − ∂y′ p 2 y p2 1/2 i.e y (1 + y ) y′ (1 + y′ )− . 2y′ = c ′ − 2 y p or = c 2 (1 + y′ ) 2 2 2 2 p y = c + c y′ dy (y2 c2) y′ = = − dx p c Separating the variables and integrating, we have dy dx = + c′ (y2 c2) c Z − Z 1 y x + a pcos h− = c c x + a i.e y = c cosh( ) c which is catenary. The constants a and c are determined from the points (x1,y1) and (x2,y2).
14 Lecture-4
Constrained Extremization Problem
Isoperimetric Problems
In certain problems of calculus of variations, while extremizing a given functional I(y), along with the end conditions y(x1)= y1, y(x2)= y2, we also need the extremizing function has to satisfy an additional integral constraint as we see in the following Dido’s Problem.
Dido’s Problem
Find the plane curve of fixed perimeter which has maximum area above x - axis.