1 | initial version |
A trivial, brute-force solution to get a Latex expression of this series :
# The function
sage: f=(x/sqrt(x^2-6*x+13))
Its requested Taylor series
sage: %time s=f.taylor(x,4,1000)
CPU times: user 5.57 s, sys: 11.9 ms, total: 5.58 s
Wall time: 5.29 s
# Latex each ot its terms
sage: %time t=list(map(lambda u:str(latex(u)), reversed(s.operands())))
CPU times: user 59.2 ms, sys: 83 µs, total: 59.3 ms
Wall time: 59.3 ms
# Latex of the series
sage: %time p = " + ".join(t)
CPU times: user 127 µs, sys: 0 ns, total: 127 µs
Wall time: 133 µs
which I won't try to print since it would require about
sage: ceil(len(p)/35/60)
274
274 pages typeset at 60 characters per line on 35 lines per page.
Note that the result you'll get will express the development in terms of powers of $x-4$ ; if you need it in terms of $x$, try the same trick on se = s.expand()
. This will tell you that the $x^{1000}$ coefficient is about $1.3\cdot10^{352}$.
What are you trying to do ? Frighten the horses ?
HTH,
2 | No.2 Revision |
A trivial, brute-force solution to get a Latex expression of this series :
# The function
sage: f=(x/sqrt(x^2-6*x+13))
Its requested Taylor series
sage: %time s=f.taylor(x,4,1000)
CPU times: user 5.57 s, sys: 11.9 ms, total: 5.58 s
Wall time: 5.29 s
# Latex each ot its terms
sage: %time t=list(map(lambda u:str(latex(u)), reversed(s.operands())))
CPU times: user 59.2 ms, sys: 83 µs, total: 59.3 ms
Wall time: 59.3 ms
# Latex of the series
sage: %time p = " + ".join(t)
CPU times: user 127 µs, sys: 0 ns, total: 127 µs
Wall time: 133 µs
which I won't try to print since it would require about
sage: ceil(len(p)/35/60)
274
274 pages typeset at 60 characters per line on 35 lines per page.
Note that the result you'll get will express the development in terms of powers of $x-4$ ; if you need it in terms of $x$, try the same trick on se = s.expand()
. This will tell you that the $x^{1000}$ coefficient is about $1.3\cdot10^{352}$.$1.3\cdot10^{-352}$.
What are you trying to do ? Frighten the horses ?
HTH,