New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
solve running forever #22248
Comments
Here you wanted to substitute values in
|
I agree with you , I have understood the issue in a wrong way ,so there seems to be a bug in |
If you pass In [7]: solve(y, rational=False)
Out[7]: [11.610838471061, 5.33333333333333⋅W(-0.184305885067861, -1) + 12.8511722731906] The problem is that the floats In [8]: nsimplify(y)
Out[8]:
-3⋅x
─────
16
1308⋅x 672373333333333 572373333333333⋅ℯ
- ────── + ─────────────── - ──────────────────────
25 1000000000000 1000000000000 Internally the slow part in There are a number of related issues but see also #6835 |
from fractions import Fraction
from pprint import pprint
from sympy import *
import numpy as np
x = symbols('x')
g = 9.81; y0 =100; v0 = 55; m = 80; c = 15
y = y0 + (m / c) * (v0 + ((m * g) / c)) * (1 - exp(- (c / m) * x)) - ((m * g) / c) * x
print('Equation:')
print(y)
Output:
Equation:
-52.32x + 672.373333333333 - 572.373333333333exp(-0.1875*x)
When I try to solve this using solve, the program runs forever and don't stop, without any error message.
solve(y)
The text was updated successfully, but these errors were encountered: