How can I get the first non-zero term of a Taylor Series, when I don't know beforehand what power it will be? Example:
Series[Sin[a]^6],{a,0,6}]
returns $a^6$, but I have to know the order is 6. If I instead just say:
Series[Sin[a]^6],{a,0,1}]
I get back $O[a]^6$ but I don't know what command to use to extract the 6 from that to redo the Seres[] calculation.
The function I want would just work like this:
f[(Sin[a*Cos[a]]^7)*Cos[2a]^3]
$a^7$
Any ideas?
f[(Sin[Cos[a]]^7)*Cos[2a]^3]
is what you intended to write. $\endgroup$but I don't know what command to use to extract the 6
if you look at InputForm of what is returned fromSeries
command, you'll see the form. Compare to what it says in help about it. It has all the info you want there. Therefores = Series[Sin[a]^6, {a, 0, 6}]; s[[4]]
gives6
. Same fors = Series[Sin[a]^6, {a, 0, 1}]; s[[4]]
$\endgroup$