diff options
author | Lily Lin | 2022-10-26 23:30:06 +0000 |
---|---|---|
committer | Lily Lin | 2022-10-26 23:30:06 +0000 |
commit | af03b3cd051a8a8b1442147136156f271f07ac5c (patch) | |
tree | 6239bbd269f8c682fcd2bd1aecd29cc8b2edf6b5 /entries/Tarcisio-Teixeira | |
parent | 66fdac7a5ab7040a29fdd6a49cb0123db5ea916a (diff) | |
parent | 18d17f9fb578df5f20e689481ed06f44fcf4b80c (diff) |
Merge branch 'main' into lily
Diffstat (limited to 'entries/Tarcisio-Teixeira')
-rw-r--r-- | entries/Tarcisio-Teixeira/differential.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/entries/Tarcisio-Teixeira/differential.py b/entries/Tarcisio-Teixeira/differential.py new file mode 100644 index 0000000..8abbdae --- /dev/null +++ b/entries/Tarcisio-Teixeira/differential.py @@ -0,0 +1,10 @@ +from sympy import * + +def fib(n): + x = symbols('x') + f = diff(1/(1-x-x**2),x,0) + fact = 1 + for i in range(1,n): + f = diff(f,x) + fact *= i + return f.subs(x,0)/fact |