These are all issues that Harsh should be addressing in his GSoC project. Aaron Meurer
On Wed, Jun 4, 2014 at 6:56 AM, F. B. <franz.bona...@gmail.com> wrote: > I had a look at SymPy, it looks like this: > > In [1]: solve(cos(3*x), x) > Out[1]: > ⎡π π⎤ > ⎢─, ─⎥ > ⎣6 2⎦ > > In [2]: solve(cos(n*x), x) > Out[2]: > ⎡ π 3⋅π⎤ > ⎢───, ───⎥ > ⎣2⋅n 2⋅n⎦ > > > It looks like the cos( ) solver just thinks that cos( ) can be zero at two > points (pi/2 and 3*pi/2), then calls a solver to match its argument to those > values. > > cos(3*x) == 0 misses thus 5*pi/2, which divided by 3 would give 5*pi/6, the > missing solution. > > By the way, why did the solver implicitly assume that n != 0 ? If n == 0, > there are no solutions to cos(n*x) == 0. > > Is there any representation for periodic infinite sets in SymPy? > > > On Tuesday, June 3, 2014 6:03:26 PM UTC+2, Aaron Meurer wrote: >> >> It's getting stuck in the checking routine. Try check=False. >> >> If you do rewrite(exp), you get some solutions. >> >> Aaron Meurer >> >> On Mon, Jun 2, 2014 at 11:33 PM, Rathmann <rathm...@gmail.com> wrote: >> > Interestingly, the problem that Richard Fateman uses to introduce his >> > critique of Press (and other systems) doesn't look to be a happy one for >> > Sympy. >> > >> > from sympy.abc import x >> > from sympy import cos, solve >> > solve(cos(x)+cos(3*x)+cos(5*x), x) >> > <At least in my (not quite up to date) tree, this gives a hang/infinite >> > loop> >> > >> > If you do the high-school level cleverness by hand, and replace it with >> > >> > solve(cos(3*x)*(1+2*cos(2*x)), x) >> > [pi/6, pi/3, pi/2, 2*pi/3] >> > >> > which is better, although missing a root at 5pi/6 >> > >> > >> > On Monday, June 2, 2014 8:42:13 AM UTC-7, Aaron Meurer wrote: >> >> >> >> Ah, but the concept is sound, I think. One just needs to be more >> >> careful in the implementation. >> >> >> >> Given that this program was designed to solve "high school algebra," >> >> it's not surprising that the author chose to ignore complex variables, >> >> for better or for worse. >> >> >> >> Aaron Meurer >> >> >> >> On Mon, Jun 2, 2014 at 6:15 AM, Richard Fateman <fat...@gmail.com> >> >> wrote: >> >> > >> >> > >> >> > On Wednesday, May 28, 2014 9:16:46 PM UTC-7, Aaron Meurer wrote: >> >> >> >> >> >> How does it return invalid results? Does it not check if spurious >> >> >> solutions were introduced through multiplying both sides of an >> >> >> equation? >> >> >> >> >> >> yes. >> >> > >> >> > Also, if one is inclined to say that computer programs "know" things, >> >> > then >> >> > computer programs presumably are "ignorant of" things. >> >> > In which case I think one would say that this program is ignorant of >> >> > complex variables. >> >> > >> >> > >> >> > -- >> >> > You received this message because you are subscribed to the Google >> >> > Groups >> >> > "sympy" group. >> >> > To unsubscribe from this group and stop receiving emails from it, >> >> > send >> >> > an >> >> > email to sympy+un...@googlegroups.com. >> >> > To post to this group, send email to sy...@googlegroups.com. >> >> > Visit this group at http://groups.google.com/group/sympy. >> >> > To view this discussion on the web visit >> >> > >> >> > >> >> > https://groups.google.com/d/msgid/sympy/ebdacb2f-d41b-44cf-ba1d-9259ef825e1d%40googlegroups.com. >> >> > >> >> > For more options, visit https://groups.google.com/d/optout. >> > >> > -- >> > You received this message because you are subscribed to the Google >> > Groups >> > "sympy" group. >> > To unsubscribe from this group and stop receiving emails from it, send >> > an >> > email to sympy+un...@googlegroups.com. >> > To post to this group, send email to sy...@googlegroups.com. >> > Visit this group at http://groups.google.com/group/sympy. >> > To view this discussion on the web visit >> > >> > https://groups.google.com/d/msgid/sympy/325f15d8-200a-4022-b21f-8286879941d1%40googlegroups.com. >> > >> > For more options, visit https://groups.google.com/d/optout. > > -- > You received this message because you are subscribed to the Google Groups > "sympy" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to sympy+unsubscr...@googlegroups.com. > To post to this group, send email to sympy@googlegroups.com. > Visit this group at http://groups.google.com/group/sympy. > To view this discussion on the web visit > https://groups.google.com/d/msgid/sympy/fc862b0e-800c-4e5e-a2dd-a3f4151a61fa%40googlegroups.com. > > For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "sympy" group. To unsubscribe from this group and stop receiving emails from it, send an email to sympy+unsubscr...@googlegroups.com. To post to this group, send email to sympy@googlegroups.com. Visit this group at http://groups.google.com/group/sympy. To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/CAKgW%3D6%2Bb8gz8gPrQ1-Kes1J-n5-r0GjJAkW78C-aGzn-YVNcdA%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.