array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'uk', ), 'this' => array ( 0 => 'function.log.php', 1 => 'log', ), 'up' => array ( 0 => 'ref.math.php', 1 => 'Функції Math', ), 'prev' => array ( 0 => 'function.is-nan.php', 1 => 'is_nan', ), 'next' => array ( 0 => 'function.log10.php', 1 => 'log10', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'en', 'path' => 'reference/math/functions/log.xml', ), 'history' => array ( ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); contributors($setup); ?>

log

(PHP 4, PHP 5, PHP 7, PHP 8)

logNatural logarithm

Опис

log(float $num, float $base = M_E): float

If the optional base parameter is specified, log() returns logbase num, otherwise log() returns the natural logarithm of num.

Параметри

num

The value to calculate the logarithm for

base

The optional logarithmic base to use (defaults to 'e' and so to the natural logarithm).

Значення, що повертаються

The logarithm of num to base, if given, or the natural logarithm.

Прогляньте також