Returns the logarithm to the base e (natural logarithm) of a specified number.

Syntax

LOG(<expN>)

<expN>

A positive nonzero number that equals e raised to the log. If you specify 0 or a negative number for <expN>, dBASE Plus generates an error.

Description

LOG( ) returns the natural logarithm of <expN>. The natural logarithm is the power (exponent) to which you raise the mathematical constant e to get <expN>. For example, LOG(5) returns 1.61 because e^1.61= 5.

LOG( ) is the inverse of EXP( ). In other words, if LOG(y) = x, then y = EXP(x).

Use SET DECIMALS to set the number of decimal places LOG( ) displays.