[Fortran] (real number)**( or + real number)
I am computing a switch to choose a criteria depending on a value. In doing it, I need to compute a value like below
(real number)**( or + real number).. so I used the usual syntax "**" to consider the power as the pow in c++. But it gave me a NaN value. Please let me know how to treat such a power in fortran. Thanks in advance. 
Re: [Fortran] (real number)**( or + real number)
The problem is occurred when I tried to compute following
0.24987**0.3846 > it's okay but when I tried to use r**GammaK > it cause NaN Of course, r is a value containing 0.24978 and Gammak has something. 
Re: [Fortran] (real number)**( or + real number)
1) 0.24987**0.3846 is evaluated as (0.24987**0.3846) because of the operator precedence in Fortran
2) r**GammaK is not a real number for r<0 and GammaK real. Check your formulas! 
Re: [Fortran] (real number)**( or + real number)
Thanks. You're right. It's a complex number.

All times are GMT 4. The time now is 16:52. 