6.23.4 Putting together sine and cosine of the same angle: tcollecttCollect
The tcollect command linearizes
trigonometric expressions (in terms of sin(n*x) and cos(n*x)) and
combines sines and cosines of the same angle. tCollect is a synonym for tcollect.
tcollect takes one argument: expr, an expression containing trigonometric functions.
tcollect(expr) returns expr
after first linearizing it and then combining sines and cosines of
the same angle.