Lemonmath
Tiếng Việt

Maximum and minimum values

Lesson 1.2 · 22 min read · Updated

The temperature in a laboratory is monitored for 55 hours. After tt hours, it is T(t)=t3−6t2+9t+20T(t)=t^3-6t^2+9t+20 (°C), 0≤t≤50\le t\le 5. At the start the room is at 2020 °C, after 11 hour it is 2424 °C, and after 33 hours it is back at 2020 °C. Over those 55 hours, what are the highest and the lowest temperatures?

You might think straight away of the local maximum 2424 °C at t=1t=1. But the answer is not 2424.

Maximum and minimum values

Explore: is a local maximum the highest value?

We compute the temperature at whole hours:

tt 00 11 22 33 44 55
T(t)T(t) 2020 2424 2222 2020 2424 4040

The derivative T′(t)=3t2−12t+9=3(t−1)(t−3)T'(t)=3t^2-12t+9=3(t-1)(t-3) tells us that TT has a local maximum of 2424 at t=1t=1 and a local minimum of 2020 at t=3t=3. Yet by the end of the session, T(5)=40T(5)=40, far above the local maximum. A local maximum is compared only with the moments near it; "the highest" must be compared with every moment.

0.51.01.52.02.53.03.54.04.55.0103040xyO(0, 20)(1, 24)(3, 20)(5, 40)
Laboratory temperature T(t)=t3−6t2+9t+20T(t)=t^3-6t^2+9t+20

The condition "there is x0x_0" matters. For example, f(x)=x2≤4f(x)=x^2\le 4 for every x∈(0,2)x\in(0, 2), but no xx in that interval gives f(x)=4f(x)=4; so 44 is not the maximum value of ff on (0,2)(0, 2), and in fact ff has no maximum value on this interval.

On a closed interval

The maximum can only be reached in two places: at an endpoint, or at an interior point where the graph "turns round", that is, where f′=0f'=0 or f′f' is undefined. At any other interior point, f′f' is not zero, so the function is still increasing or decreasing and there is a larger value nearby. So we only need to compare a few values:

  1. Find the points x1,x2,…x_1, x_2, \dots in the open interval (a,b)(a, b) where f′(x)=0f'(x)=0 or f′(x)f'(x) is undefined.
  2. Compute f(a)f(a), f(x1)f(x_1), f(x2)f(x_2), …, f(b)f(b).
  3. The largest of these numbers is max⁡[a,b]f(x)\max\limits_{[a, b]} f(x), and the smallest is min⁡[a,b]f(x)\min\limits_{[a, b]} f(x).

Rejecting a root outside the interval is an easy step to forget. The next example has one rejected root and one irrational root.

With a square root, we solve f′(x)=0f'(x)=0 carefully, with a condition before squaring.

With a trigonometric function, a substitution often turns the problem into a polynomial on a closed interval.

On an open interval

On an open interval (with no endpoints), a function may have no maximum or no minimum value. Then we draw the table of variations and read the result from it.

24681012246810121416xyO(3, 6)
The graph of y=x+9xy=x+\dfrac{9}{x} for x>0x>0

Real-life problems

Now we answer the temperature question from the start. In real-life problems the endpoints are often the start and the end of a period, so they must not be ignored.

Key terms

Summary

  • M=max⁡DfM=\max\limits_D f when f(x)≤Mf(x)\le M for every x∈Dx\in D and MM is reached at some point of DD. Likewise for min⁡\min.
  • A function continuous on [a,b][a, b] always has a maximum and a minimum value there.
  • On a closed interval: roots of f′f' (and points where f′f' is undefined) inside (a,b)(a, b) → compute ff there and at aa, bb → compare.
  • On an open interval: draw the table of variations; there may be no maximum or no minimum.
  • After a substitution, find the correct range of the new variable.

Practice

Each exercise comes with what you need and some steps to start. Try it yourself first, then open the solution.

Exercise 1

Find the maximum and minimum values of y=x3−3x2y=x^3-3x^2 on [−1,3][-1, 3].

What you need and how to start

What you need: on a closed interval, compare the values at the roots of y′y' in (−1,3)(-1, 3) and at the two endpoints.

Steps:

  1. Solve y′=3x2−6x=0y'=3x^2-6x=0.
  2. Compute yy at the roots and at −1-1, 33.
Show solution

y′=3x(x−2)=0  ⟺  x=0y'=3x(x-2)=0\iff x=0 or x=2x=2, both in (−1,3)(-1, 3). y(−1)=−4y(-1)=-4, y(0)=0y(0)=0, y(2)=8−12=−4y(2)=8-12=-4, y(3)=27−27=0y(3)=27-27=0.

Answer. Maximum value 00 (at x=0x=0 and x=3x=3); minimum value −4-4 (at x=−1x=-1 and x=2x=2).

Exercise 2

Find the maximum and minimum values of y=x−1x+2y=\dfrac{x-1}{x+2} on [0,3][0, 3].

What you need and how to start

What you need: if a function is monotonic on a closed interval, its maximum and minimum are at the endpoints.

Steps:

  1. Compute y′y' and look at its sign.
  2. Compute y(0)y(0) and y(3)y(3).
Show solution

y′=1⋅2−(−1)⋅1(x+2)2=3(x+2)2>0y'=\dfrac{1\cdot2-(-1)\cdot1}{(x+2)^2}=\dfrac{3}{(x+2)^2}>0, so the function is increasing on [0,3][0, 3]. y(0)=−12y(0)=-\dfrac12, y(3)=25y(3)=\dfrac25.

Answer. Maximum value 25\dfrac25; minimum value −12-\dfrac12.

Exercise 3

Find the maximum and minimum values of y=x4−2x2+3y=x^4-2x^2+3 on [0,2][0, 2].

What you need and how to start

What you need: keep only the roots of y′y' in the open interval (0,2)(0, 2).

Steps:

  1. Solve y′=4x3−4x=0y'=4x^3-4x=0.
  2. Reject the roots not in (0,2)(0, 2), then compare the values.
Show solution

y′=4x(x−1)(x+1)y'=4x(x-1)(x+1); the only root in (0,2)(0, 2) is x=1x=1. y(0)=3y(0)=3, y(1)=2y(1)=2, y(2)=16−8+3=11y(2)=16-8+3=11.

Answer. Maximum value 1111 (at x=2x=2); minimum value 22 (at x=1x=1).

Exercise 4

Find the minimum value of y=x2+16xy=x^2+\dfrac{16}{x} on (0,+∞)(0, +\infty).

What you need and how to start

What you need: on an open interval, draw the table of variations to read off the minimum.

Steps:

  1. Compute y′=2x−16x2=2(x3−8)x2y'=2x-\dfrac{16}{x^2}=\dfrac{2(x^3-8)}{x^2}.
  2. Find the positive root of y′y' and the sign on each side.
Show solution

y′=0  ⟺  x3=8  ⟺  x=2y'=0\iff x^3=8\iff x=2. For 0<x<20<x<2, y′<0y'<0; for x>2x>2, y′>0y'>0. So the minimum value is y(2)=4+8=12y(2)=4+8=12.

Answer. min⁡(0,+∞)y=12\min\limits_{(0, +\infty)} y=12 at x=2x=2.

Exercise 5

Consider f(x)=−x3+3x2+2f(x)=-x^3+3x^2+2 on [−1,3][-1, 3]. Is each claim true or false?

a) The equation f′(x)=0f'(x)=0 has two roots in [−1,3][-1, 3].

b) The maximum value of ff on [−1,3][-1, 3] is 66.

c) ff reaches its maximum value only at x=2x=2.

d) The minimum value of ff on [−1,3][-1, 3] is 22.

What you need and how to start

What you need: compare the values at the roots of f′f' and at the two endpoints; a maximum can be reached at several points.

Steps:

  1. Solve f′(x)=−3x2+6x=0f'(x)=-3x^2+6x=0.
  2. Compute f(−1)f(-1), f(0)f(0), f(2)f(2), f(3)f(3).
Show solution

f′(x)=−3x(x−2)=0  ⟺  x=0f'(x)=-3x(x-2)=0\iff x=0 or x=2x=2. f(−1)=1+3+2=6f(-1)=1+3+2=6, f(0)=2f(0)=2, f(2)=−8+12+2=6f(2)=-8+12+2=6, f(3)=−27+27+2=2f(3)=-27+27+2=2.

a) True: 00 and 22 are both in [−1,3][-1, 3].

b) True: the largest of the values is 66.

c) False: f(−1)=6f(-1)=6 as well, so the maximum is reached at both x=−1x=-1 and x=2x=2.

d) True: the smallest value is 22, reached at x=0x=0 and x=3x=3.

Answer. a) True; b) True; c) False; d) True.

Exercise 6

Find the maximum value of y=x9−x2y=x\sqrt{9-x^2} on [0,3][0, 3] (give the result as a decimal).

What you need and how to start

What you need: (u)′=u′2u\left(\sqrt{u}\right)'=\dfrac{u'}{2\sqrt u} and comparing values on a closed interval.

Steps:

  1. Compute y′y' and write it as one fraction: the numerator is 9−2x29-2x^2.
  2. Find the root in (0,3)(0, 3) and compare with y(0)y(0), y(3)y(3).
Show solution

y′=9−x2−x29−x2=9−2x29−x2=0  ⟺  x2=92y'=\sqrt{9-x^2}-\dfrac{x^2}{\sqrt{9-x^2}}=\dfrac{9-2x^2}{\sqrt{9-x^2}}=0\iff x^2=\dfrac92, that is x=32x=\dfrac{3}{\sqrt2}. Then y=32⋅92=92y=\dfrac{3}{\sqrt2}\cdot\sqrt{\dfrac92}=\dfrac92. The endpoints give y(0)=y(3)=0y(0)=y(3)=0.

Answer. 4.54.5.

Exercise 7

A workshop makes xx chairs a week (10≤x≤10010\le x\le 100) at a total cost of C(x)=x2+100x+2500C(x)=x^2+100x+2500 (thousand đồng). The average cost per chair is A(x)=C(x)xA(x)=\dfrac{C(x)}{x}. How many chairs a week should the workshop make to have the lowest average cost? What is that cost?

What you need and how to start

What you need: find the minimum of A(x)=x+100+2500xA(x)=x+100+\dfrac{2500}{x} on [10,100][10, 100].

Steps:

  1. Compute A′(x)A'(x) and solve A′(x)=0A'(x)=0.
  2. Compare the values at the root and at 1010, 100100.
Show solution

A′(x)=1−2500x2=0  ⟺  x=50A'(x)=1-\dfrac{2500}{x^2}=0\iff x=50. A(10)=10+100+250=360A(10)=10+100+250=360, A(50)=50+100+50=200A(50)=50+100+50=200, A(100)=100+100+25=225A(100)=100+100+25=225.

Answer. 5050 chairs a week; the lowest average cost is 200200 thousand đồng per chair.

Exercise 8 Review

Find the maximum and minimum values of y=cos⁡2x+2cos⁡xy=\cos 2x+2\cos x on [0,π][0, \pi].

What you need and how to start

What you need: the double-angle formula cos⁡2x=2cos⁡2x−1\cos 2x=2\cos^2x-1 (grade 11); for x∈[0,π]x\in[0, \pi], cos⁡x∈[−1,1]\cos x\in[-1, 1].

Steps:

  1. Put t=cos⁡xt=\cos x and write y=g(t)y=g(t).
  2. Find the maximum and minimum of gg on [−1,1][-1, 1].
Show solution

y=2t2+2t−1=g(t)y=2t^2+2t-1=g(t) with t∈[−1,1]t\in[-1, 1]. g′(t)=4t+2=0  ⟺  t=−12g'(t)=4t+2=0\iff t=-\dfrac12. g(−1)=−1g(-1)=-1, g(−12)=12−1−1=−32g\left(-\dfrac12\right)=\dfrac12-1-1=-\dfrac32, g(1)=3g(1)=3.

Answer. Maximum value 33 (at x=0x=0); minimum value −32-\dfrac32 (at x=2π3x=\dfrac{2\pi}{3}).

Exercise 9 Review

Find the maximum and minimum values of y=−x2+4x+1y=-x^2+4x+1 on [0,5][0, 5] in two ways: with the vertex of the parabola (grade 10) and with the derivative.

What you need and how to start

What you need: the parabola y=ax2+bx+cy=ax^2+bx+c with a<0a<0 has its highest point at the vertex x=−b2ax=-\dfrac{b}{2a} (see the quadratic function).

Steps:

  1. Method 1: find the vertex, check that it is in [0,5][0, 5], then compare with the two endpoints.
  2. Method 2: solve y′=0y'=0 and compare as usual.
Show solution

Method 1: the vertex is at x=−42⋅(−1)=2∈[0,5]x=-\dfrac{4}{2\cdot(-1)}=2\in[0, 5], y(2)=5y(2)=5. Method 2: y′=−2x+4=0  ⟺  x=2y'=-2x+4=0\iff x=2. Both methods compare y(0)=1y(0)=1, y(2)=5y(2)=5, y(5)=−25+20+1=−4y(5)=-25+20+1=-4.

Answer. Maximum value 55 (at x=2x=2); minimum value −4-4 (at x=5x=5).

Exercise 10 Challenge

Find the maximum and minimum values of y=x+2cos⁡xy=x+\sqrt2\cos x on [0,π2]\left[0, \dfrac{\pi}{2}\right].

What you need and how to start

What you need: comparing values on a closed interval; to compare irrational numbers, use approximations.

Steps:

  1. Solve y′=1−2sin⁡x=0y'=1-\sqrt2\sin x=0 on (0,π2)\left(0, \dfrac{\pi}{2}\right).
  2. Compute yy at the root and at both endpoints, then compare using approximations.
Show solution

sin⁡x=12\sin x=\dfrac{1}{\sqrt2} gives x=π4x=\dfrac{\pi}{4}. y(0)=2≈1.414y(0)=\sqrt2\approx1.414; y(π4)=π4+1≈1.785y\left(\dfrac{\pi}{4}\right)=\dfrac{\pi}{4}+1\approx1.785; y(π2)=π2≈1.571y\left(\dfrac{\pi}{2}\right)=\dfrac{\pi}{2}\approx1.571.

Answer. Maximum value π4+1\dfrac{\pi}{4}+1 (at x=π4x=\dfrac{\pi}{4}); minimum value 2\sqrt2 (at x=0x=0).

Mini test

Mini test

Marked like the Vietnamese graduation exam: Part I 0.25 points per question; Part II up to 1 point per question (1, 2, 3, 4 correct statements give 0.1, 0.25, 0.5, 1 point); Part III 0.5 points per question.

Part I. Multiple choice

Question 1. The maximum value of f(x)=x3−12x+1f(x)=x^3-12x+1 on [−1,3][-1, 3] is
Question 2. The minimum value of y=2x−1x+1y=\dfrac{2x-1}{x+1} on [0,2][0, 2] is
Question 3. The minimum value of y=x+4x−1y=x+\dfrac{4}{x-1} on (1,+∞)(1, +\infty) is
Question 4. A function y=f(x)y=f(x) is continuous on [−2,4][-2, 4] and f′(x)>0f'(x)>0 for every x∈(−2,4)x\in(-2, 4). Which statement is correct?

Part II. True or false

Question 1. Consider f(x)=x4−8x2+3f(x)=x^4-8x^2+3 on [−1,3][-1, 3].
a) The equation f′(x)=0f'(x)=0 has three roots in [−1,3][-1, 3].
b) f(2)=−13f(2)=-13.
c) The maximum value of f(x)f(x) on [−1,3][-1, 3] is 33.
d) The sum of the maximum and minimum values of f(x)f(x) on [−1,3][-1, 3] is −1-1.

Part III. Short answer

Question 1. A workshop produces xx tonnes of goods a month (0≤x≤200\le x\le 20) and makes a profit of P(x)=−x3+18x2+135xP(x)=-x^3+18x^2+135x (million đồng). What is the greatest monthly profit, in million đồng?

Question 2. Find the maximum value of y=x (6−x)y=\sqrt{x}\,(6-x) on [0,6][0, 6]. Give your answer to 1 decimal place.

Show answers and explanations
  1. Part I, question 1: D. f′(x)=3x2−12=0  ⟺  x=±2f'(x)=3x^2-12=0\iff x=\pm2, and only x=2x=2 lies in (−1,3)(-1, 3). Compare f(−1)=12f(-1)=12, f(2)=−15f(2)=-15, f(3)=−8f(3)=-8. Option A is f(−2)=17f(-2)=17, the value at a root outside the interval.
  2. Part I, question 2: A. y′=3(x+1)2>0y'=\dfrac{3}{(x+1)^2}>0, so the function is increasing on [0,2][0, 2] and the minimum value is y(0)=−1y(0)=-1. Option B is the maximum value y(2)y(2); the number 22 is only the limit as x→+∞x\to+\infty.
  3. Part I, question 3: C. y′=1−4(x−1)2=0  ⟺  x=3y'=1-\dfrac{4}{(x-1)^2}=0\iff x=3 (reject x=−1x=-1), and y′y' changes sign from −- to ++ at x=3x=3, so the minimum value is y(3)=5y(3)=5. Option B is the point x=3x=3, option A forgets the +1+1 in y=(x−1)+4x−1+1y=(x-1)+\dfrac{4}{x-1}+1, and option D is y(−1)y(-1).
  4. Part I, question 4: B. The function is increasing on [−2,4][-2, 4], so the maximum is at the right endpoint x=4x=4. A function continuous on a closed interval always has a maximum value, so D is wrong.
  5. Part II, question 1: a) False; b) True; c) False; d) True. a) False: f′(x)=4x(x2−4)f'(x)=4x(x^2-4) has roots 00, 22, −2-2, but −2∉[−1,3]-2\notin[-1, 3]. b) True: 16−32+3=−1316-32+3=-13. c) False: f(−1)=−4f(-1)=-4, f(0)=3f(0)=3, f(2)=−13f(2)=-13, f(3)=12f(3)=12, so the maximum value is 1212 (at an endpoint). d) True: 12+(−13)=−112+(-13)=-1.
  6. Part III, question 1: 2700. P′(x)=−3(x−15)(x+3)=0  ⟺  x=15P'(x)=-3(x-15)(x+3)=0\iff x=15 (reject x=−3x=-3). Compare P(0)=0P(0)=0, P(15)=2700P(15)=2700, P(20)=1900P(20)=1900: the greatest profit is 27002700 million đồng.
  7. Part III, question 2: 5.7. y=6x−xxy=6\sqrt x-x\sqrt x, so y′=3x−32x=0  ⟺  x=2y'=\dfrac{3}{\sqrt x}-\dfrac32\sqrt x=0\iff x=2. Compare y(0)=y(6)=0y(0)=y(6)=0 with y(2)=42≈5.66y(2)=4\sqrt2\approx5.66, which rounds to 5.75.7.