Closed dweindl closed 7 months ago
Current sympy master (tested: 0ededfcfc033ddca2d1d54a0eda85bf53c63761c):
IPython console for SymPy 1.13.dev (Python 3.12.2-64-bit) (ground types: python) In [1]: Float(0) == 0 Out[1]: False In [2]: Float(0).is_zero Out[2]: True
vs 1.12:
Python console for SymPy 1.12 (Python 3.12.2-64-bit) (ground types: python) >>> Float(0) == 0 True >>> Float(0).is_zero True
Therefore, replace == 0 by .is_zero.
== 0
.is_zero
Amongst other potential issues, this fixes zeros in sparse matrices. Closes #2320.
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 77.94%. Comparing base (2235ab7) to head (d3e069e).
2235ab7
d3e069e
Current sympy master (tested: 0ededfcfc033ddca2d1d54a0eda85bf53c63761c):
vs 1.12:
Therefore, replace
== 0
by.is_zero
.Amongst other potential issues, this fixes zeros in sparse matrices. Closes #2320.