Rational Numbers

max($arr) or max($m1,$m2……) returns the highest of the parameter values. A non-numeric string is evaluated as 0. If arrays are passed, the longest array is returned. min($arr) or min($m1,$m2……) is similar but returns the lowest of the parameter values.

abs($num) returns the absolute value of $num. ceil($f) returns the next higher integer value. floor($f) returns the next lower integer value. round($f[,$i1=0[$,i2]]) rounds $f to the specified precision $i1 (number of digits after the decimal point). $i2 can be PHP_ROUND_HALF_UP, PHP_ROUND_HALF_DOWN, PHP_ROUND_HALF_ODD, or PHP_ROUNd_HALF_EVEN.

<!DOCTYPE html><html><head></head>
<body><?php
var_dump(max(["car","cats","bus"])); echo "<br />";
var_dump(max(-2,"hello","world",-1)); echo "<br />";
var_dump(max([1,2,3],[4,5],6)); echo "<br />";
var_dump(abs(-3)); echo "<br />";
var_dump(ceil(-3.2)); echo "<br />";
var_dump(floor(3.8)); echo "<br />";
var_dump(round(3.856,1)); echo "<br />";
var_dump(round(3.55,1,PHP_ROUND_HALF_ODD)); 
echo "<br />";
var_dump(round(3.55,1,PHP_ROUND_HALF_EVEN));
echo "<br />";
var_dump(round(3.551,1,PHP_ROUND_HALF_ODD));
echo "<br />";
?></body></html>
fmod($f1,$f2) returns the floating point remainder of $f1 divided by $f2. sqrt($f) returns the square root of $f. pow($num1,$num2) returns the result of $num1 raised to the power of $num2. exp($f) returns the result of e raised to the power of $f. expm1($f) returns ‘exp($f)-1’, computed in a way that is accurate even when $f is near zero. log10 ($f) returns the base-10 logarithm of $f. log($f1 [,$f2=M_E]) returns the natural algorithm of $f1. If $f2 is specified, the function returns log$f2$f1, ie using $f2 as the base of the logarithm. log1p($f) returns log(1+$f), computed in a way that is accurate even when $f is near zero.

RESETRUNFULL
<!DOCTYPE html><html><head></head>
<body><?php

var_dump(fmod(4.2,1.5)); echo "<br />";
echo sqrt(2)."<br />";
echo pow(2,3.5)."<br />";
echo log(8,2)."<br />";
echo expm1(0)."<br />";
echo log1p(0)."<br />";

?></body></html>
is_finite($f) returns true if $f is finite, false otherwise. is_infinite($f) returns true if $f is infinite, false otherwise. is_nan($f) returns true if $f is not a number, false otherwise.