Status: New
Owner: ----
Labels: Type-Enhancement Priority-Low
New issue 3896 by [email protected]: sum of three-phase cos^2 or cos^4 do
not simplify to 3/2 and 9/8, respectively
http://code.google.com/p/sympy/issues/detail?id=3896
These are simple trig identities:
theta=symbols('theta')
k=1
simplify(cos(theta)**k + cos(theta+2*pi/3)**k + cos(theta+4*pi/3)**k)
0
# hurray
k=2
simplify(cos(theta)**k + cos(theta+2*pi/3)**k + cos(theta+4*pi/3)**k)
sin(theta + pi/6)**2 + cos(theta)**2 + cos(theta + pi/3)**2
# this should be 3/2
k=4
simplify(cos(theta)**k + cos(theta+2*pi/3)**k + cos(theta+4*pi/3)**k)
sin(theta + pi/6)**4 + cos(theta)**4 + cos(theta + pi/3)**4
# this should be 9/8
see:
http://www.wolframalpha.com/input/?i=cos%28x%29%5E2+%2B+cos%28x%2B2*pi%2F3%29%5E2+%2B+cos%28x%2B4*pi%2F3%29%5E2
http://www.wolframalpha.com/input/?i=cos%28x%29%5E4+%2B+cos%28x%2B2*pi%2F3%29%5E4+%2B+cos%28x%2B4*pi%2F3%29%5E4
I have no idea how hard it is for symbolic algebra + simplification to
work, but it's pretty easy to simplify these by hand, when you substitute
sin(theta)**2 or cos(theta)**2 with a double-angle identity.
--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings
--
You received this message because you are subscribed to the Google Groups
"sympy-issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sympy-issues.
For more options, visit https://groups.google.com/groups/opt_out.