maroba / findiff

Python package for numerical derivatives and partial differential equations in any number of dimensions.
MIT License
420 stars 60 forks source link

Generating a high accuracy results in TypeError #25

Closed diehlpk closed 4 years ago

diehlpk commented 4 years ago
GCC 10.1.1 20200507 (Red Hat 10.1.1-1)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import findiff
>>> coefs = findiff.coefficients(deriv=1, acc=15)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/diehlpk/.local/lib/python3.8/site-packages/findiff/coefs.py", line 42, in coefficients
    ret["forward"] = _calc_coef(0, num_coef - 1, deriv)
  File "/home/diehlpk/.local/lib/python3.8/site-packages/findiff/coefs.py", line 58, in _calc_coef
    "coefficients": np.linalg.solve(matrix, rhs),
  File "<__array_function__ internals>", line 5, in solve
  File "/home/diehlpk/.local/lib/python3.8/site-packages/numpy/linalg/linalg.py", line 399, in solve
    r = gufunc(a, b, signature=signature, extobj=extobj)
TypeError: No loop matching the specified signature and casting was found for ufunc solve1