Log Function

Returns the natural logarithm of a number.

αƒ‘αƒ˜αƒœαƒ’αƒαƒ₯αƒ‘αƒ˜

Log (Number)

αƒ“αƒαƒ‘αƒ αƒ£αƒœαƒ”αƒ‘αƒ£αƒšαƒ˜ αƒ›αƒœαƒ˜αƒ¨αƒ•αƒœαƒ”αƒšαƒαƒ‘αƒ:

Double

Parameters:

Number: Any numeric expression that you want to calculate the natural logarithm for.

The natural logarithm is the logarithm to the base e. Base e is a constant with an approximate value of 2.718282...

You can calculate logarithms to any base (n) for any number (x) by dividing the natural logarithm of x by the natural logarithm of n, as follows:

Log n(x) = Log(x) / Log(n)

Error codes:

D'oh! You found a bug (text/sbasic/shared/00000003.xhp#err5 not found).

αƒ›αƒαƒ’αƒαƒšαƒ˜αƒ—αƒ˜:

Sub ExampleLogExp

Dim a As Double

Dim Const b1=12.345e12

Dim Const b2=1.345e34

    a=Exp( Log(b1)+Log(b2) )

    MsgBox "" & a & chr(13) & (b1*b2) ,0,"Multiplication by logarithm function"

End Sub