Let $f(x)=x^3+6x^2+ax+2,$if $(-3,-1)$ is the largest possible interval for which $f(x)$ is decreasing function Let $f(x)=x^3+6x^2+ax+2,$if $(-3,-1)$ is the largest possible interval for which $f(x)$ is decreasing function.Find $a$.

$f'(x)=3x^2+12x+a<0$
So $144-12a<0\implies a>12$
Now let $f(x)$ is decreasing in the interval $(d,e)\subset (-3,-1)$
So $f'(d)=0,f'(e)=0$ and $-3\le d<e\le-1$
I am stuck here.I could not solve further.
 A: The first derivative $f'(x) = 3x^2 + 12x + a$
You're told that the largest interval with a negative first derivative is $(-3,-1)$
As polynomial functions are continuous over the entire real line, you can conclude that $f'(-3) =f'(-1) = 0$
Trying the left hand bound gives $3(-3)^2 + 12(-3) + a = 0 \implies a = 9$
Verify that the right hand bound gives the same value (otherwise the problem cannot be solved), $3(-1)^2 + 12(-1) + a = 0 \implies a = 9$.
All that is left is to verify that $f'(x) = 3x^2 + 12x + 9$ is strictly negative over $(-3,-1)$
$f'(x) = 3(x+1)(x+3)$, and a bit of curve sketching will immediately establish that it is negative for $x \in (-3,-1)$ (and non-negative everywhere else).
A: Since $f'(x)=3x^2+12x+a$, the derivative is everywhere positive if $144-12a<0$, that is, $a>12$. For $a=12$ the function is increasing.
If $a<12$, the smallest root of the derivative is
$$
\frac{-6-\sqrt{36-3a}}{3}
$$
which should be $\ge-3$; the largest root is
$$
\frac{-6+\sqrt{36-3a}}{3}
$$
which should be $\le-1$.
Both conditions reduce to $\sqrt{36-3a}\le3$.
A: Since the derivative function is quadratic, the solution takes the form of a quadratic inequality.  We're given that $(-3,-1)$ is the largest interval on which $f'(x)$ should be negative, so look at $3(x+3)(x+1)=3x^2+12x+9$, and we see $a=9$ is a choice which will work, since it is the graph of a parabola opening up with roots at $-1$ and $-3$ hence negative on $(-3,-1)$  Moreover any other choice of $a$ corresponds to a vertical translation of $f'$ with $a=9$.  Thinking about the graph it's clear other choices of $a$ lead to intervals where $f'<0$ which are larger or smaller (or don't exist!) than the desired $(-3,-1)$, hence $a=9$ is the solution.
