I mean, when I calculate with my calculator $\cos(1)=0.99984769515639$, what is the $n$ for this calculation?
I ask the question because I was asked to write a function in C++ to calculate $\cos(x)$ but I can't understand the use of the indexer in the series.
I know that the series looks like this:
$\cos(x) =\sum_{i=0}^\infty {(-1)^n{x^{2n}}\over(2n!)}$
Let's say I want to calculate $\cos(1)$ by hand, how would I do it using Taylor Series, what would be in $n$?