# What is the difference between Intermediate Value Theorem and the Extreme Value Theorem?

The Intermediate Value Theorem (IVT) says functions that are continuous on an interval ##[a,b]## take on all (intermediate) values between their extremes. The Extreme Value Theorem (EVT) says functions that are continuous on ##[a,b]## attain their extreme values (high and low).

Here’s a statement of the EVT: Let ##f## be continuous on ##[a,b]##. Then there exist numbers ##c,din [a,b]## such that ##f(c)leq f(x)leq f(d)## for all ##xin [a,b]##. Stated another way, the “supremum ” ##M## and “infimum ” ##m## of the range ##{f(x):xin [a,b]}## exist (they’re finite) and there exist numbers ##c,din [a,b]## such that ##f(c)=m## and ##f(d)=M##.

Note that the function ##f## must be continuous on ##[a,b]## for the conclusion to hold. For example, if ##f## is a function such that ##f(0)=0.5##, ##f(x)=x## for ##0<x<1##, and ##f(1)=0.5##, then ##f## attains no maximum or minimum value on ##[0,1]##. (The supremum and infimum of the range exist (they’re 1 and 0, respectively), but the function never attains (never equals) these values.)

Note also that the interval must be closed. The function ##f(x)=x## attains no maximum or minimum value on the open interval ##(0,1)##. (Once again, the supremum and infimum of the range exist (they’re 1 and 0, respectively), but the function never attains (never equals) these values.)

The function ##f(x)=1/x## also does not attain a maximum or minimum value on the open interval ##(0,1)##. Moreover, the supremum of the range does not even exist as a finite number (it’s “infinity”).

Here’s a statement of the IVT: Let ##f## be continuous on ##[a,b]## and suppose ##f(a)!=f(b)##. If ##v## is any number between ##f(a)## and ##f(b)##, then there exists a number ##cin (a,b)## such that ##f(c)=v##. Moreover, if ##v## is a number between the supremum and infimum of the range ##{f(x):xin [a,b]}##, then there exists a number ##cin [a,b]## such that ##f(c)=v##.

If you draw pictures of various discontinuous functions, it’s pretty clear why ##f## needs to be continuous for the IVT to be true.