[sympy] Numeric differentiation

2013-12-07 Thread Alexander Birukov
Just wondeing about one thing. I have a function: It can be differentiated, but no way to solve(== find break monotony points). So I'm about using numeric diff. Is there any implented

Re: [sympy] evalf() and subs

2013-12-04 Thread Alexander Birukov
expr1 = parse_expr('x**3 - 3*x') expr2 = parse_expr('-x-1') print(expr1.subs({x: p_infinity}).evalf()) print(expr1.evalf(subs={x: p_infinity})) print(expr2.subs({x: p_infinity}).evalf()) print(expr2.evalf(subs={x: p_infinity})) output: nan +inf -inf +inf Question was why method subs and arg sub

[sympy] evalf() and subs

2013-12-03 Thread Alexander Birukov
a = rule.evalf(subs={x: inter.end}) a = rule.subs({x: inter.end}).evalf() quieston is why this 2 lines gives 2 different ways of calculation infinity? like I'd eval x**3 - 3*x, where x = +-oo. First line will give me exactly what I want: +-infinity, and the second one will give me nan for both

Re: [sympy] solving trigonometry eqs in negative direction

2013-11-27 Thread Alexander Birukov
h function. > > Aaron Meurer > > > On Tue, Nov 26, 2013 at 12:28 PM, Alexander Birukov > > > wrote: > > Hello everyone. > > > > Basic example: > > solve(sin(x)) = [0, pi] > > > > I would like to have: > > solve(sin(x)) = [-pi

[sympy] solving trigonometry eqs in negative direction

2013-11-26 Thread Alexander Birukov
Hello everyone. Basic example: solve(sin(x)) = [0, pi] I would like to have: solve(sin(x)) = [-pi, 0, pi] Can lib handle it or I should do it myself? Thanks, Alexander. -- You received this message because you are subscribed to the Google Groups "sympy" group. To unsubscribe from this grou

Re: [sympy] evalf() and logarithms

2013-11-03 Thread Alexander Birukov
t; On Sun, Nov 3, 2013 at 11:10 PM, Alexander Birukov > > > wrote: > > Oh, sorry. > > > > chop= > > Replace tiny real or imaginary parts in subresults > > by exact zeros (default=False) > > > > No idea

Re: [sympy] evalf() and logarithms

2013-11-03 Thread Alexander Birukov
ssing > chop=True, like log(x, 2).evalf(subs={x: 1}, chop=True). > > Aaron Meurer > > > On Sun, Nov 3, 2013 at 2:04 PM, Alexander Birukov > > > wrote: > > I dont really understand why it happens, although solve(log(x, 2)) gives > 1 > > as an answer. I&#x

[sympy] evalf() and logarithms

2013-11-03 Thread Alexander Birukov
I dont really understand why it happens, although solve(log(x, 2)) gives 1 as an answer. I'd use solve for sure, but unfortunetly, I have to calculate expression with different x. Any solution to fix this? -- You received this message because you are subscribed to the Google Groups "sympy" gro

Re: [sympy] How to make solve() returns non-complex numbers

2013-11-02 Thread Alexander Birukov
int(solve(x**3 - 4, x)) > [2**(2/3)] > > Aaron Meurer > > On Sat, Nov 2, 2013 at 10:17 AM, Alexander Birukov > > > wrote: > > Hello everyone. I have another question, and as topic name says: how can > I > > sort return of solve, so complex numbers wont be in

[sympy] How to make solve() returns non-complex numbers

2013-11-02 Thread Alexander Birukov
Hello everyone. I have another question, and as topic name says: how can I sort return of solve, so complex numbers wont be in anymore? I've seached in flags for it, but no luck, and then I've played with .is_* attributes and got something wierd(?): sols = solve(x**3 - 4) sols = [sol for sol in

Re: [sympy] Image based on interval

2013-10-30 Thread Alexander Birukov
: > > Hello, > I think that this problem is impossible to solve in general. > > What are the functions you want to study ? > > Christophe, a simple user > > > 2013/10/30 Alexander Birukov > > >> Hello everyone. >> >> Was wondering how ca

[sympy] Image based on interval

2013-10-30 Thread Alexander Birukov
Hello everyone. Was wondering how can I get an image of function if I have an interval for it (problem comes if I have unioned intervals. I dont know how can I call each interval start/end or at least split union into Nth intervals). SymPy docs gives info about transform. but I've browsed sour