Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

Question about calculate the Bessel function with IMSL

Chang_Pai_L_
Beginner
322 Views

Ver. Intel Composer XE2013 with Visual Studio 2010 Ultimate

I want to solve the problem about BesselI0/BesselI1 with using the IMSL. Problem is one extreme value divided by another one extreme value and the result should be an uncomplicated value.   

Unfortunately, I can not calculate when input data over 700, the output data over 300 order, modified Bessel function of the zero and first kind data will present 'infinite' .

My PROBLEM like (double precision)

'"M(I)=DBSI0(L1(I))/DBSI1(L1(I))""    L1(I)  are real data, The  "problem" happened in L1(I)>700, the M(I) output "NaN" result.

How could I calculate this vector?

Thanks for any help!!

 

0 Kudos
2 Replies
mecej4
Honored Contributor III
322 Views

See if you can use Hankel's asymptotic expansions for I0 and I1 ( https://en.wikipedia.org/wiki/Bessel_function#Asymptotic_forms ). Using those expansions, you can write the ratio I0(z)/I1(z) as the ratio of two power series in 1/z. The leading factor, ez/sqrt(z), which causes I0 and I1 to become very large, occurs in both the numerator and the denominator, so you can cancel it out.

For values of z with modulus as large as 700, you should be able to obtain accurate results with a small number of terms in the series.

0 Kudos
Chang_Pai_L_
Beginner
322 Views

Thanks for useful reply! 

0 Kudos
Reply