# How do you use the first and second derivatives to sketch y = (x+2)(25 -x^2)?

Jun 17, 2016

I got:

and Socratic graphs show:

graph{(x+2)(25 - x^2) [-8, 6, -107.6, 107.8]}

To graph this, you need:

• All $x$ intercepts
• Coordinates for all extrema
• What these extrema are (maximum or minimum)

GETTING THE X INTERCEPTS

You fortunately have $y$ mostly factored.

$\textcolor{g r e e n}{y} = - \left(x + 2\right) \left({x}^{2} - 25\right)$

$= \textcolor{g r e e n}{- \left(x + 2\right) \left(x + 5\right) \left(x - 5\right)}$ --- difference of two squares

Right now, if you set this equal to $0$, you'll find that the roots are:

• $x = - 5$, or $\textcolor{b l u e}{\text{("-5,0")}}$
• $x = - 2$, or $\textcolor{b l u e}{\text{("-2,0")}}$
• $x = 5$, or $\textcolor{b l u e}{\text{("5,0")}}$

The three roots tell you that there are three $x$ intercepts and the polynomial is a cubic.

GETTING THE COORDINATES FOR ALL EXTREMA

Now multiply it all out to take the derivatives more easily using the power rule.

$- \left(x + 2\right) \left({x}^{2} - 25\right)$

$= - \left({x}^{3} - 25 x + 2 {x}^{2} - 50\right)$

$= - {x}^{3} - 2 {x}^{2} + 25 x + 50$

Now the first derivative, which gives you where the extrema are, is:

$\textcolor{g r e e n}{\frac{\mathrm{dy}}{\mathrm{dx}}}$

$= \frac{d}{\mathrm{dx}} \left[- 3 {x}^{2} - 4 x + 25\right]$

$= \textcolor{g r e e n}{- 3 {x}^{2} - 4 x + 25}$

When you set this equal to $0$ and solve, you are looking for where the graph changes direction, which is where its slope is $0$.

Because you're solving a quadratic, you should get two roots that each tell you where the extrema are. But you don't know whether they are minima or maxima yet. The second derivative tells you that.

Unfortunately this doesn't factor into integer solutions, so we'll have to complete the square.

1. Get the ${x}^{2}$ term coefficient to be $1$.
2. Take the resultant $x$ term, halve the coefficient, and square the coefficient to get the ${x}^{0}$ term.
3. Make sure you've added the resultant ${x}^{0}$ term to both sides.

$- 3 {x}^{2} - 4 x = - 25$

$3 {x}^{2} + 4 x = 25$

$3 \left({x}^{2} + \frac{4}{3} x\right) = 3 \left(\frac{25}{3}\right)$

$3 \left({x}^{2} + \frac{4}{3} x + \frac{4}{9}\right) = 3 \left(\frac{25}{3} + \frac{4}{9}\right)$

$3 {\left(x + \frac{2}{3}\right)}^{2} = \frac{79}{3}$

$\implies \textcolor{g r e e n}{\frac{\mathrm{dy}}{\mathrm{dx}} = 3 {\left(x + \frac{2}{3}\right)}^{2} - \frac{79}{3} = 0}$

Now, solve this for $x$ to get:

${\left(x + \frac{2}{3}\right)}^{2} = \frac{79}{9}$

$x + \frac{2}{3} = \pm \sqrt{\frac{79}{9}}$

$\textcolor{g r e e n}{{x}_{1} = \sqrt{\frac{79}{9}} - \frac{2}{3} \approx 2.30}$

$\textcolor{g r e e n}{{x}_{2} = - \sqrt{\frac{79}{9}} - \frac{2}{3} \approx - 3.63}$

If we plug these in back to the original equation, we can get the coordinates for the extrema.

$\textcolor{g r e e n}{{y}_{1}} = - {x}_{1}^{3} - 2 {x}_{1}^{2} + 25 {x}_{1} + 50 \approx \textcolor{g r e e n}{84.75}$

$\textcolor{g r e e n}{{y}_{2}} = - {x}_{2}^{3} - 2 {x}_{2}^{2} + 25 {x}_{2} + 50 \approx \textcolor{g r e e n}{- 19.27}$

So the two extrema in the graph are:

• $\textcolor{b l u e}{\text{("2.30,84.75")}}$
• $\textcolor{b l u e}{\text{("-3.63,-19.27")}}$

Now to figure out which one is the maximum and which one is the minimum.

DETERMINING WHETHER THEY'RE MAXIMA OR MINIMA

With the second derivative, we have three options:

• If $| \left[\frac{{d}^{2} y}{{\mathrm{dx}}^{2}}\right] {|}_{x = a} > 0$, we have a minimum.
• If $| \left[\frac{{d}^{2} y}{{\mathrm{dx}}^{2}}\right] {|}_{x = a} < 0$, we have a maximum.
• If $| \left[\frac{{d}^{2} y}{{\mathrm{dx}}^{2}}\right] {|}_{x = a} = 0$, we have an inflection point, where the concavity changes from concave up to concave down or vice versa.

We have to select the ${x}_{1}$ or ${x}_{2}$ values we found just now since those correspond to the only two extrema.

$\textcolor{b l u e}{| \left[\frac{{d}^{2} y}{{\mathrm{dx}}^{2}}\right] {|}_{x \approx 2.30}}$

$= \frac{d}{\mathrm{dx}} \left[\frac{\mathrm{dy}}{\mathrm{dx}}\right]$

$= \frac{d}{\mathrm{dx}} \left[- 3 {x}^{2} - 4 x + 25\right]$

$= - 6 x - 4$

$\implies - 6 \left(2.30\right) - 4 \approx \textcolor{b l u e}{- 17.78 < 0}$

$\implies$ $\setminus m a t h b f \left(\textcolor{b l u e}{\text{maximum}}\right)$ (inside of curve faces down)

$\textcolor{b l u e}{| \left[\frac{{d}^{2} y}{{\mathrm{dx}}^{2}}\right] {|}_{x \approx - 3.63}}$

$\implies - 6 \left(- 3.63\right) - 4 = \textcolor{b l u e}{17.78 > 0}$

$\implies$ $\setminus m a t h b f \left(\textcolor{b l u e}{\text{minimum}}\right)$ (inside of curve faces up)

There, now we have enough information to sketch this!

GRAPHING THE RESULT

All our coordinates that we just solved for are...

x-intercepts

• $\left(- 5 , 0\right)$
• $\left(- 2 , 0\right)$
• $\left(5 , 0\right)$

extrema

• $\left(- 3.63 , - 19.27\right)$ --- minimum
• $\left(2.30 , 84.75\right)$ --- maximum

So now we graph this as:

and Socratic graphs show:

graph{(x+2)(25 - x^2) [-8, 6, -107.6, 107.8]}