Search the Community
Showing results for tags 'mparith'.
Found 1 result
I've implemented Aberth–Ehrlich method for finding all roots of polynomial (actually it's one of steps of eigenvalues finding). It works very well with the degree less or equal 25. But when degree is larger, my Delphi calculations begin to fail. In both cases speed of calctions is acceptable (< 1 sec). I'm quite sure it's because an accumulation of errors of very small and very large numbers during calculations. For an algorithm needs I've developer TComplex = record … end; structure based on Double. The same result I got when the base data type is Extended. I'm quite sure the problem is not an algorithm, because when I've updated TComplex to use MPArith multi precision library rather, I got exactly the same results as Octave and Matlab programs - so I assume they are correct. But in this case time of calculation is veeery slooow (more than 20 min) because MPArith works with the memory rather. So my questions are: Do you know how to bypass multi precision issue in Delphi? Do you think, if I'll port realization of calculation to another programming language (f.e. C++, C# or any other), I'll have no problem with the precision of calculations? Sure, I'll have to wrap it into dll to call within the Delphi code. Did you already fixed a similar issue related to multi precision (maybe other more fast library)? Any thoughts are welcome.