How do you extract useful information from this calculus question? 
Let $f$ be a twice differentiable function defined in $[-3,3]$ such that $f(0)=-4, f’(3)=0, f’(-3)=12$, and $f’’(x)\geq-2, \forall x \in [-3,3]$. If $g(x)=\int_0^x {f(t)dt}$  then find the maximum value of g(x).

The thing is that I’m trying to get some info out of this about the function $f$, by basically having a rough graph, but the criterion $f’’(x)\geq-2$ doesn’t really give me anything because $f$ could be either convex-up(like $x^2$) or convex-down(like $-x^2$) or even have a point of inflection. It just can’t be too-much-concave-down, if you know what I mean. The function starts off as increasing, but IDK what happens after that.
Also if it were just $\int_0^x {f’(t)dt}$ I might have been more confident, but $\int_0^x {f(t)dt}$ just throws me off.
 A: Consider the (well defined, because $f''$ is integrable by the fundamental theorem of calculus) quantity $$
\int_{-3}^{3} (f''(x)+2) dx=S
$$
On the one hand :

*

*Note that $f''(x) + 2 \geq 0$ on the interval $[-3,3]$


*An anti-derivative of $f''(x)+2$ is $f'(x) + 2x + C$ using the fundamental theorem of calculus, therefore $$
S = [f'(x)+2x+C]^{3}_{-3} = f'(3) - f'(-3) + 12 = 0
$$
by the assumptions on $f'(3),f'(-3)$.
All in all, it follows that $$
\int_{-3}^{3} h(x) = 0
$$
where $h$ is a non-negative function on $[-3,3]$. By a well-known result, it follows that $h= 0$ a.e. (almost everywhere), or that $f'' = -2$ a.e.
Next, integrating this equality from $-3$ to $x$ for $x \in [-3,3]$, we get $$
\int_{-3}^x f''(t)dt = \int_{-3}^x (-2)dt \implies f'(x) - f'(-3) = -6-2x \implies f'(x) = 6-2x
$$
(There's no a.e. needed because $f'$ is necessarily continuous being the integral of another function) Integrating that equality from $0$ to $y$ for $y \in [-3,3]$ gives $$
\int_{0}^y f'(x)dx = \int_{0}^y (6-2x)dx \implies f(y) - f(0) = 6y-y^2 \implies f(y) = 6y-y^2-4 
$$
Note that $g'(y) = f(y)$, therefore at a point of maximum we must have that $f(y) = 0$ (using a common result that the derivative must be zero at any extremum). Now, $f(y) = 0$ is a quadratic equation having the roots $3 \pm \sqrt{5}$. Only $3-\sqrt{5}$ lies in the interval, and since $g''(y) = f'(y)$, we note that $$
f'(3 - \sqrt{5}) = 6-2(3-\sqrt{5}) = 2\sqrt{5} > 0
$$
Therefore, ironically enough, by the double derivative test, this point is a point of minimum, and not a maximum. This is confirmed when one sees that $g(3-\sqrt{5}) < 0$ by computation.
It follows that the extreme values must therefore be taken on the ends of the interval i.e. in $\{-3,3\}$ (because the derivative would be zero at an interior point). A simple examination will tell you that $g(-3)> g(-3)$. It follows that $g(-3) = 48$ is the maximum value of $g(x)$ on $[-3,3]$.

There is a shortcut that one can use to avoid the double derivative test. Note that $g''(x) = f'(x)$ is actually non-negative on $[-3,3]$. Such functions, whose second derivative is non-negative on an interval, are called convex functions. Now, as it turns out, there is a result that makes one-dimensional analysis with convex functions very appealing : convex functions on intervals always take their maximum values on the endpoints of the interval (unless they're constant, and therefore take their maximum everywhere).
Once you recognize this, you needn't even go to the derivative test : just get $g$, and find $g(3),g(-3)$. The bigger of the two is the maximum, and you're done.
