On Tuesday, December 10, 2013 2:55:41 PM UTC+4, Avichal Dayal wrote:
>
> The way assert is done is as follows:-
> assert solve(some equation) == [{x: x1}, {x: x2}]
>
> However this fails on my system when I added a few tests of mine
> I have to do the following way to get it work:-
> assert solve(some equation) == [x1, x2]
> So instead of a dictionary format, I have to use list.
>If you want to use dictionary format, please use one: assert solve(some equation, dict=True) == ... By default, dict=False. Please, read docstring of the solve function. On Tuesday, December 10, 2013 2:55:41 PM UTC+4, Avichal Dayal wrote: > > 1) assert solve(4**(2*(x**2) + 2*x) - 8, x) == [-3/2, 1/2] > 2) assert solve(5**(x+1) + 5**(2-x) - 126, x) == [-1, 2] > 3) assert solve(log(x+1, 2) + log(x-3, 2) - 5, x) == [7] > > 1) produces the same answer but four times i.e. [-3/2, -3/2, -3/2, -3/2, > 1/2, 1/2, 1/2, 1/2] > 2) gives [-1, log(25)/log(5)] which is correct but it should simplify > log(25)/log(5) to 2, right? > 3) says not implemented error but it can be reduced to a simple quadratic > equation so I expect sympy to solve it > 1) looks like a bug 2) yes. And if you actually try simplify: (log(25)/log(5)).simplify() == 2 3) if it's says, then it's true. Would you like to implement this? -- 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 [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/sympy. For more options, visit https://groups.google.com/groups/opt_out.
