I need an expiation on a math concept, because I know the right answer, I just don't know why it is

The problem says to find the absolute maximum and minimum of the function f(x)=x^3-12x over the interval [-5, 2]

I found the 1st der. 3x^2-12 and set equal to zero, got the x values -2 and 2

f(-2)= 16 f(2)= -16 f(-5)=-65

The second der. is 6x

6(-2)=-12
6(2)= 12
6(-5)= -30

I read somewhere that if f''(x) > 0 it was a minimum, and if f''(x) < 0 it was a maximum. So by that, I would say that the max was x= -5, at -65
and min was x=-2, at 16

However, the max was said to be what I thought the min was and vice versa, but why? I know for other parts of my homework my mins and maxs were correct, so why is it not so for this problem?
Thanks

1 answer

The relative max/min occur at x = -2,2 as you said.

Since f"(-2) < 0, f(x) has a max at x = -2 (f is concave down)
Since f"(2) > 0, f(x) has a minimum at x=2 (f is concave up)

f(-5) = -65, so the absolute minimum of f(x) on [-5,2] is at x = -5, but that is just because f(-5) < f(2), not because is a critical point. f'(-5)≠0

See the graph at

http://www.wolframalpha.com/input/?i=x^3-12x