1 | initial version |
Hm... Its very strange for me but answer is following:
res = -1/2*sin(1/16*pi)*... # expression in your question
import sympy
sympy.simplify(res) # you will get 0
The strange moment is that next code won't get you 0:
res = -1/2*sin(1/16*pi)*... # expression in your question
res.simplify_full().n() # you will get 6.52256026967279e-16 in Sagemathcloud
I check all code in Sagemathcloud. In my opinion the difference is because 2nd way Maxima is used as backend. But now I don't know how to check when you should use Maxima via Sage functions and when - Sympy.
2 | check --> checked (past simple) |
Hm... Its very strange for me but answer is following:
res = -1/2*sin(1/16*pi)*... # expression in your question
import sympy
sympy.simplify(res) # you will get 0
The strange moment is that next code won't get you 0:
res = -1/2*sin(1/16*pi)*... # expression in your question
res.simplify_full().n() # you will get 6.52256026967279e-16 in Sagemathcloud
I check checked all code in Sagemathcloud. In my opinion the difference is because 2nd way Maxima is used as backend. But now I don't know how to check when you should use Maxima via Sage functions and when - Sympy.
3 | 2nd way - in 2nd way |
Hm... Its very strange for me but answer is following:
res = -1/2*sin(1/16*pi)*... # expression in your question
import sympy
sympy.simplify(res) # you will get 0
The strange moment is that next code won't get you 0:
res = -1/2*sin(1/16*pi)*... # expression in your question
res.simplify_full().n() # you will get 6.52256026967279e-16 in Sagemathcloud
I checked all code in Sagemathcloud. In my opinion the difference is because in 2nd way Maxima is used as backend. But now I don't know how to check when you should use Maxima via Sage functions and when - Sympy.