Teie kommentaarid

Hello Jeremy,


Yes, of course. Toolbox provides full spectrum of numerical integration routines - from fixed Gauss quadrature to adaptive quadgk.


Or did you mean something else?

I have finished updating the Bessel library today. Now all of them support arbitrary orders & arguments, much more stable and produce guaranteed accuracy up-to last one-two digits.


That was fun week - finally I've done everything I planned for Bessel. The only thing left is deep optimization, I think x50-100 times possible for quadruple mode.


Btw, I found several/many bugs in MATLAB's Bessel functions (from Symbolic Math Toolbox) - few of them are shown in changelog: http://www.advanpix.com/documentation/version-history/

Please be cautious when using the Symbolic Toolbox.

Half-integer or arbitrary (real, complex)?


P.S. As of today, bessely is faster for integer orders (speed-up is similar to besselk).

Now is in the development trunk, will release it in a few days.

Exact speed-up factor is difficult to estimate, especially when older version had issues with accuracy at some regions :(.


I am asking because I need to know what precision to optimize further :).

Now optimizing the bessely (you also asked for it before, right?)

Do you use quadruple or higher precision?

Dear Michael,


I have just released new version with improved besselk & besseli: http://goo.gl/1jRKP0


Now both are more accurate, stable and faster. Accuracy is guaranteed up to last digit for all integer orders and complex arguments.


Please let me know if you notice any speed improvement.


Current timings on Core i7 (1st gen):

% real arguments
>> X = 150*mp(rand(50));
>> tic; Y = besselk(0,X); toc;
Elapsed time is 0.345778 seconds.
>> tic; Y = besselk(1,X); toc;
Elapsed time is 0.469967 seconds.
% complex arguments
>> X = 150*mp((rand(50)-0.5)+(rand(50)-0.5)*1i);
>> tic; Y = besselk(0,X); toc;
Elapsed time is 1.663378 seconds.
>> tic; Y = besselk(1,X); toc;
Elapsed time is 1.662077 seconds.

There is a good chance that speed will be even higher in next releases - work is in progress.

Dear Stefan,

Please download & test the newest version of toolbox.
Now it honors "format compact/loose" among other things.

Would appreciate any further feedback.
What arguments you use for besselk? Real, complex (what quadrant)?

Now I am working on building efficient rational approximations for besselk for real arguments (quadruple case). Should be fast.
These issues have been already fixed in Windows version - you can download it from our website the usual way.
Updates for GNU Linux & Mac OSX follow (I know you probably use the GNU Linux version).