php - Calculating an Exponent -
in excel =(b5/2)^2*3.141592654
, b5 rod.
this doesn't produce same results.
$rodarea = $rod/2 ^2*3.141592654 ;
what doing wrong? thanks.
my guess error in whatever language (perl?) written in:
$rodarea = $rod/2 ^2*3.141592654 ;
many programming languages don't honor ^
exponent operator, due ambiguity xor
^
. typically have function pow
or exp
exponents. in case do:
$rodarea = (($rod/2)*($rod/2))*3.141592654 ;
(exponent in perl **
, not ^
, though don't know if that's right language).
php excel exponent
No comments:
Post a Comment