Write down the Maclaurin expansion
f(x)=n=0∑∞n!f(n)(0)xn Each coefficient needs one derivative evaluated at x=0.
Evaluate the function at the expansion point
f(0)=0 This provides the constant term of the expansion.
Differentiate to obtain the derivative of order 1
f(1)(x)=cos(x) Differentiating once more gives the next derivative.
Evaluate the derivative of order 1 at the expansion point
f(1)(0)=1 This value supplies the coefficient of (x−a)1 after division by 1!.
Differentiate to obtain the derivative of order 2
f(2)(x)=−sin(x) Differentiating once more gives the next derivative.
Evaluate the derivative of order 2 at the expansion point
f(2)(0)=0 This value supplies the coefficient of (x−a)2 after division by 2!.
Differentiate to obtain the derivative of order 3
f(3)(x)=−cos(x) Differentiating once more gives the next derivative.
Evaluate the derivative of order 3 at the expansion point
f(3)(0)=−1 This value supplies the coefficient of (x−a)3 after division by 3!.
Differentiate to obtain the derivative of order 4
f(4)(x)=sin(x) Differentiating once more gives the next derivative.
Evaluate the derivative of order 4 at the expansion point
f(4)(0)=0 This value supplies the coefficient of (x−a)4 after division by 4!.
Differentiate to obtain the derivative of order 5
f(5)(x)=cos(x) Differentiating once more gives the next derivative.
Evaluate the derivative of order 5 at the expansion point
f(5)(0)=1 This value supplies the coefficient of (x−a)5 after division by 5!.
Differentiate to obtain the derivative of order 6
f(6)(x)=−sin(x) Differentiating once more gives the next derivative.
Evaluate the derivative of order 6 at the expansion point
f(6)(0)=0 This value supplies the coefficient of (x−a)6 after division by 6!.
Differentiate to obtain the derivative of order 7
f(7)(x)=−cos(x) Differentiating once more gives the next derivative.
Evaluate the derivative of order 7 at the expansion point
f(7)(0)=−1 This value supplies the coefficient of (x−a)7 after division by 7!.
Substitute the derivative values into the Taylor formula
f(x)≈0+1!1x+2!0x2+3!−1x3+4!0x4+5!1x5+6!0x6+7!−1x7 Each derivative is divided by the corresponding factorial.
Simplify the coefficients
−5040x7+120x5−6x3+x Cancelling the factorials gives the coefficients in their simplest form.
Count the non-zero terms that have been obtained
4 non-zero terms, of degrees 1,3,5,7 Terms whose coefficient is zero do not count, so the expansion must be taken as far as degree 7.
State the required expansion
f(x)≈−5040x7+120x5−6x3+x This is the Taylor polynomial requested.