Skip to content

Instantly share code, notes, and snippets.

@anthonymorast
Last active October 3, 2021 00:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anthonymorast/1ce9e504a720e306e34b9f2e3130e34a to your computer and use it in GitHub Desktop.
Save anthonymorast/1ce9e504a720e306e34b9f2e3130e34a to your computer and use it in GitHub Desktop.
from TaylorSeries import TaylorSeries
def f(x):
return 2 + x**3 + x**7 + x**2
if __name__ == '__main__':
terms = 15
center = 0
precision = 3
ts = TaylorSeries(f, terms, center)
ts.print_coefficients()
ts.print_equation()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment