maroba / findiff

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

Avoid possible overflow in system matrix for extreme accuracy orders by equilibration #6

Closed maroba closed 6 years ago

maroba commented 6 years ago

I have implemented a version with equilibration which solves the overflow problem. However, the problem is that with this solution all exceptions vanish, but nevertheless there is a big numerical error due to subtraction of similiar numbers, which is kind of unavoidable. I therefore prefer to have an exception indicating some bad conditions instead of no exception and no indication that the result may be significantly wrong.