# How do you factor cos^2 x+7 cos x+8?

May 30, 2018

$\frac{1}{4} \left(2 \cos x + 7 + \sqrt{17}\right) \left(2 \cos x + 7 - \sqrt{17}\right)$

#### Explanation:

First let $t = \cos x$.

$y = {t}^{2} + 7 t + 8$

Now, let's complete the square to factor this.

$y = \left({t}^{2} + 7 t\right) + 8$

Note that ${\left(t + \frac{7}{2}\right)}^{2} = \left(t + \frac{7}{2}\right) \left(t + \frac{7}{2}\right)$

$= {t}^{2} + \frac{7}{2} t + \frac{7}{2} t + {\left(\frac{7}{2}\right)}^{2}$

$= {t}^{2} + 7 t + \frac{49}{4}$

So we want to add $\frac{49}{4}$ into the expression and subtract it back out again.

$y = \left({t}^{2} + 7 t + \frac{49}{4}\right) + 8 - \frac{49}{4}$

Note that $8 - \frac{49}{4} = \frac{32}{4} - \frac{49}{4} = - \frac{17}{4}$.

$y = {\left(t + \frac{7}{2}\right)}^{2} - \frac{17}{4}$

Now, note that $\frac{17}{4} = {\left(\frac{\sqrt{17}}{2}\right)}^{2}$.

$y = {\left(t + \frac{7}{2}\right)}^{2} - {\left(\frac{\sqrt{17}}{2}\right)}^{2}$

Now, we have a difference of squares and can factor it as one.

$y = \left[\left(t + \frac{7}{2}\right) + \frac{\sqrt{17}}{2}\right] \left[\left(t + \frac{7}{2}\right) - \frac{\sqrt{17}}{2}\right]$

$y = \left(\cos x + \frac{7 + \sqrt{17}}{2}\right) \left(\cos x + \frac{7 - \sqrt{17}}{2}\right)$

If we wish, we can bring a common factor of $\frac{1}{2}$ out of each part:

$y = \frac{1}{4} \left(2 \cos x + 7 + \sqrt{17}\right) \left(2 \cos x + 7 - \sqrt{17}\right)$

May 30, 2018

$\left(\cos \left(x\right) + \setminus \frac{7 + \setminus \sqrt{17}}{2}\right) \left(\cos \left(x\right) + \setminus \frac{7 - \setminus \sqrt{17}}{2}\right)$

#### Explanation:

let $u = \cos \left(x\right)$
The question then becomes:

Factor ${u}^{2} + 7 u + 8$ you could just use quadratic formula here i.e. $u = \setminus \frac{- b \setminus \pm \setminus \sqrt{{b}^{2} - 4 a c}}{2 a}$

or you could do it the long way (which isn't any better than the formula, in fact it's one of the methods use to formulate the quadratic formula) :
find two roots, ${r}_{1}$ and ${r}_{2}$ such that $\left(u - {r}_{1}\right) \left(u - {r}_{2}\right) = {u}^{2} + 7 u + 8$

Expand: $\left(u - {r}_{1}\right) \left(u - {r}_{2}\right) = {u}^{2} - {r}_{1} u - {r}_{2} u + \left({r}_{1}\right) \left({r}_{2}\right)$
$= {u}^{2} - \left({r}_{1} + {r}_{2}\right) u + \left({r}_{1}\right) \left({r}_{2}\right)$

Thus: ${u}^{2} - \left({r}_{1} + {r}_{2}\right) u + \left({r}_{1}\right) \left({r}_{2}\right) = {u}^{2} + 7 u + 8$
and therefore: $- \left({r}_{1} + {r}_{2}\right) = 7$ and $\left({r}_{1}\right) \left({r}_{2}\right) = 8$

$\left({r}_{1} + {r}_{2}\right) = - 7 , {\left({r}_{1} + {r}_{2}\right)}^{2} = 49$
${\left({r}_{1}\right)}^{2} + 2 \left({r}_{1}\right) \left({r}_{2}\right) + {\left({r}_{2}\right)}^{2} = 49$
${\left({r}_{1}\right)}^{2} + 2 \left({r}_{1}\right) \left({r}_{2}\right) + {\left({r}_{2}\right)}^{2} - 4 \left({r}_{1}\right) \left({r}_{2}\right) = 49 - 4 \left(8\right) = 17$
${\left({r}_{1}\right)}^{2} - 2 \left({r}_{1}\right) \left({r}_{2}\right) + {\left({r}_{2}\right)}^{2} = 17$

${\left({r}_{1} - {r}_{2}\right)}^{2} = 17$
${r}_{1} - {r}_{2} = \setminus \sqrt{17}$
$\setminus \frac{{r}_{1} + {r}_{2} + {r}_{1} - {r}_{2}}{2} = {r}_{1} = \setminus \frac{- 7 + \setminus \sqrt{17}}{2}$
$\setminus \frac{{r}_{1} + {r}_{2} - \left({r}_{1} - {r}_{2}\right)}{2} = {r}_{2} = \setminus \frac{- 7 - \setminus \sqrt{17}}{2}$

Thus, the factored form is $\left(u + \setminus \frac{7 + \setminus \sqrt{17}}{2}\right) \left(u + \setminus \frac{7 - \setminus \sqrt{17}}{2}\right)$

sub $u = \cos \left(x\right)$ to get:

$\left(\cos \left(x\right) + \setminus \frac{7 + \setminus \sqrt{17}}{2}\right) \left(\cos \left(x\right) + \setminus \frac{7 - \setminus \sqrt{17}}{2}\right)$