jadonn / cosine-taylor-series-expansion Goto Github PK
View Code? Open in Web Editor NEWScript that uses Taylor Series expansion to n = 6 to approximate the value of cos(x) at x_i+1 = pi/3 using the value of cos(x) and its derivatives at x_i = pi/4. The script uses modulus division trickery to make sure the right derivative of cos is used in each loop. The script was written as part of a Computer Science class on numerical methods.
License: GNU General Public License v3.0