# How can I factor my trigonometric equation?

The equation

$$3\sin^2 x - 3\cos x -6\sin x + 2\sin 2x + 3=0$$

has a solution $x = 0$. That means it has a factor of $\cos x - 1$. I tried to write the given equation has the form

$$(\cos x - 1)P(x)=0.$$

I am looking for the factor $P(x)$. How can I get Mathematica to find it?

-
TrigFactor[3 Sin[x]^2 - 3 Cos[x] - 6 Sin[x] + 2 Sin[2 x] + 3] gives the output -2 Sqrt[2] Sin[\[Pi]/4 - x/2] (Cos[x/2] - 3 Sin[x/2]) (2 Cos[x/2] - Sin[x/2]) Sin[x/2]. This has an overall factor Sin[x/2] which gives your x = 0 solution. – Stephen Luttrell Mar 31 '13 at 15:11

Because $$3\sin^2 x - 3\cos x -6\sin x + 2\sin 2x + 3 = (\cos x - 1)P(x)$$ then $$P(x) = \frac{3\sin^2 x - 3\cos x -6\sin x + 2\sin 2x + 3}{\cos x - 1}$$ I think you can just simplify this expression in Mathematica:

FullSimplify[(
3 - 3 Cos[x] - 6 Sin[x] + 3 Sin[x]^2 + 2 Sin[2 x])/(-1 + Cos[x])]

-6 - 3 Cos[x] + 2 Cot[x/2] + 4 Sin[x]


then $$P(x)=-6 - 3 \cos x + 2 \cot \frac{x}{2} + 4 \sin x$$

-
Sorry I find my answer is error... but I don't know how to delete it – Ai Xin Mar 31 '13 at 4:06
I don't think your answer is wrong. It's the question that's inaccurate. The stated factor isn't really a factor, in the sense that one can't convert the equation to a polynomial such that the variable $z = \cos x-1$ is a factor. And your answer shows this, I think. I edited your answer to format the code. – Jens Mar 31 '13 at 4:09
The reason why I think I am wrong is that (cos(x)-1)*P(x) is not strictly equal to the original expression---when I divided the original expression by (cos(x)-1) ,I ignore the case that (cos(x)-1) may be zero.So when x=0,(cos(x)-1)*P(x) is meaningless,for P(x) contain cot(x/2) and cot(0) is meaningless.(however, when x approaches to 0, the limit of (cos(x)-1)*P(x) is 0 ) – Ai Xin Mar 31 '13 at 12:06