Exponentiation with negative base

Hi ROOT family,

I just got a very stupid and quick question on exponentiation function pow(). I was trying to calculate (-0.25)^{1.4} by writing pow(-0.25,1.4). However, I should obtain -0.1435 as my correct result, but I got nan from ROOT. I do not know why the result for this negative base case was wrong. Thanks so much for anyone who can help!


You can find your case in “error handling”.

1 Like

Thanks so much!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.