I have a trigonometric polynomial which is something like this:
A = (b1+2) * sin(x) + (b2+q) * sin(x)^2sin(x) + (b3/b1+6) * sin(x)cos(x) + b4 * cos(x)^4 + b5
I want to get the coefficients of the polynomial with respect to sin(x1) and cos(x1). Please note that all other variables should be treated as coefficients, including b1, b2, b3, b4, b5 and q. I would rather do this with coefficient() command, but my only problem is that coefficient command works for univariate polynomial. I can write:
A.coefficients(sin(x))
But I can't write A.coefficients({sin(x),cos(x)}) because it given an error. What can I do?