0
Can someone solve expansion of sine function in c language?
2 Réponses
+ 2
What did you try ?
+ 1
sin(x) = x - (x^3)/ 3! + (x^5)/ 5! - ....
Make a loop that increments n from 1 to the number of terms that you want to calculate.
In every iteration sum up:
(-1)^(n-1) * (x ^(2 n +1) / ((2n+1)!)
To a variable. After the loop this variable will have the value of sin(x)