# Local max/min

Sketch the graph of a function f that is continuous on [1,5] and has the given properties:
f has no local maximum or minimum, but 2 and 4 are critical numbers.

my professor drew a constant function (horizontal line) from x=1 to x=5. How come there is no local maximum or minimum for a horizontal line? My professor said that all the values of a horizontal line are the absolute maxima and minima...

According to my book, "A function f has a local maximum at c if f(c) >= f(x) when x is near c. [This means that f(c) >= f(x) for all x in some open interval containing c.]" Let's say the open interval is (1,5), and since f(x)=f(c) (because we have a horizontal line), shouldn't f have a local maximum????

Tom Mattson
Staff Emeritus
Gold Member
The function does have a local max--and a local min--at 2 and 4. But what a boring example! Surely we can come up with a more interesting one. Note that critical numbers are points at which the derivative is zero or at which it fails to exist. One way to achieve this is to graph a function with vertical asymptotes at x=2 and x=4.

so, in drawing a horizontal line, there are local maxima and minima at every location on the horizontal line??

Tom Mattson
Staff Emeritus
Gold Member
According to the definition, yes.

Tom Mattson said:
The function does have a local max--and a local min--at 2 and 4. But what a boring example! Surely we can come up with a more interesting one. Note that critical numbers are points at which the derivative is zero or at which it fails to exist. One way to achieve this is to graph a function with vertical asymptotes at x=2 and x=4.

One of the problem with using vertical asymptotes is that you still have to consider the endpoints of the interval. If the derivative is negative at 5, for instance, there would be a local minimum at x = 5, with the open interval being (5-$\epsilon$, 5]. I know it doesn't look open, but it is, since [1, 5] is the interval we started with. I'm pretty sure a horizontal line is as interesting of an example as is possible. Although it fails when you apply the strict definition of local maxima and local minima, it's about as close as you can get.:yuck:

Well, the text for a constant, continuous function $$f(x)$$ on $$[a, b]$$ is that $$f'(x)=0,\;\forall x\in[a, b]$$.

The classification for local extrema are strict inequalities in the second derivative, ie. $$f''(x)>0$$ and $$f''(x)<0$$.

For the constant function, we have $$f''(x)=0$$. Therefore, no conclusion can be drawn to whether it's a maximum or minimum.

I think this is what your teacher was getting at.

Last edited:
Tom Mattson said:
According to the definition, yes.
No.

If you look at an interval containing the critical point, you have to have the opposite strict inequalities on the first derivative either side of it.

HallsofIvy
Homework Helper
J77 said:
No.

If you look at an interval containing the critical point, you have to have the opposite strict inequalities on the first derivative either side of it.

But the original poster said:
endeavor said:
According to my book, "A function f has a local maximum at c if f(c) >= f(x) when x is near c. [This means that f(c) >= f(x) for all x in some open interval containing c.]"

Since that is the definition in his book, that is the definition that should be used. In fact, I have never seen any definition of "local max" or "local min" that said anything about the first derivative.

HallsofIvy said:
But the original poster said...
OK, my mistake.

And you're right, I used a theorem

endeavor said:
so, in drawing a horizontal line, there are local maxima and minima at every location on the horizontal line??
Tom Mattson said:
According to the definition, yes.
Does this mean that my professor is wrong in drawing a horizontal line??

What are the possible ways to draw this graph?
endeavor said:
Sketch the graph of a function f that is continuous on [1,5] and has the given properties:
f has no local maximum or minimum, but 2 and 4 are critical numbers.

HallsofIvy