0% found this document useful (0 votes)
10 views

Notes On Log Functions

Excel has both spreadsheet functions and VBA functions for mathematical operations like logarithms, with different syntaxes. The spreadsheet Log10 function takes a number as its argument, while the VBA Log function requires Application.WorksheetFunction.Log followed by the number. The VBA Log function calculates the natural logarithm (base e), but its argument can be changed to another base like base 10 using the change of base property for logarithms.

Uploaded by

Yeho Shua
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views

Notes On Log Functions

Excel has both spreadsheet functions and VBA functions for mathematical operations like logarithms, with different syntaxes. The spreadsheet Log10 function takes a number as its argument, while the VBA Log function requires Application.WorksheetFunction.Log followed by the number. The VBA Log function calculates the natural logarithm (base e), but its argument can be changed to another base like base 10 using the change of base property for logarithms.

Uploaded by

Yeho Shua
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

Note: Excel has spreadsheet functions (e.g., Log10) and VBA functions (e.g.

, Log), and both


have different syntaxes.

To access the spreadsheet functions, use:

Therefore, for Log10: Argument = Number

For VBA functions:

By the way, the VBA Log function is a logarithm to the base e. Therefore, if you want to
get the log for a different base, use the change base property for logarithms:
log 𝑎 𝑥
log 𝑏 𝑥 =
log 𝑎 𝑏
Therefore, if we want to convert the base from e to 10, then:
ln 𝑥
log 𝑥 =
ln 10

In VBA format:

Note: Please research the syntax first before writing the code. Please use google incessantly.

You might also like