[sympy] EmptySet() after sympify - nonlinsolve combo

2019-04-13 Thread Michele Strada
Hello, I'm trying to create a system solver for my project. I created a string-list in order to save my expressions: system = ["exp1", "exp2"] after that I sympify it (and it works). I substitute unknown values if I have that ones. (subs function) At the end I try to use nonlinsolve on syste

Re: [sympy] EmptySet() after sympify - nonlinsolve combo

2019-04-13 Thread Jogi Miglani
Hi Michele, Its okay to create string list and then sympifying it. I want to know what type of expressions are you trying to solve through nonlinsolve?. If you have an particular example that is not working then you can open up an issue on the gihub and will see it there. (Make sure you are using c

Re: [sympy] EmptySet() after sympify - nonlinsolve combo

2019-04-15 Thread Michele Strada
#!/usr/bin/env python from sympy import Symbol, sympify from sympy import * from mpmath import * from sympy.solvers import linsolve import re var = {"m1": 1, "m2": 2, "v1i": 3, "v1f": 4, "v2i": '', "v2f": ''} c = 0 unk = [] x, y = 0, 0 for key, val in var.items(): if val == '': c+=1

Re: [sympy] EmptySet() after sympify - nonlinsolve combo

2019-04-15 Thread Michele Strada
I tryed the same expressions on sympy online and it worked, so I don't think it is a specific expressions issue, but I can be wrong of course. Online I tryed without sympify 'cause I wanted to try if it was just a specific error as you said. I post my code if it can help: #!/usr/bin/env pytho