MASTER YOUR CASTLE with your new build or reno project
Enter competition

How to get logarithm of base 10 value in Vijeo Designer software.

FA11612

30/07/2018

Only natural logarithm(of base e) is available under Math package of standard Java package version associated with Vijeo Designer software.

A workaround to calculate logarithm of base 10 is shown below:

Log base 10 = Math.log(x)/Math.log(10)

Log base 2 = Math.log(x)/Math.log(2) 

Given a number n greater than 0.0.

Then the log10(n) is equal to ln(n)/ln(10)(where "ln()" is the natural logarithm (base e))

If you store ln(10) as a constant, then you can get the log10(n) from ln(n) with one additional divide.

Example:

Given a number 'n' greater than 0.0 and a number 'b'greater than 0.0

Then the log<b>(n) is equal to ln(n)/ln(b)

where log<b>(n) means log value of (n) on base 'b' and "ln( )" is the natural logarithm (on base 'e')