Is it possible to calculate log10 x without using log? Is it possible to calculate $\log_{10} x$ without using $\log_{10}$? I'm interested because I'm working with a framework that has some simple functions, but log is not one of them.
The specific platform is capable of doing addition, subtraction, multiplication and division. I can write a formula of a finite, predefined length; e.g. while loops or for loops that continue indefinitely are not available. It's a black-box project with an interface capable of creating formulas, so basically, I need to write the expression to calculate $\log_{10} x$ in one line, and I can't write my own method or something to do more dynamic calculations.
An approximation of $\log_{10} x$ is perfectly acceptable.

Let x = 1545 and proceed as follows:

*

*Divide x by base 10 until x becomes smaller than base 10.
1545/10 = 154.5
154.5 / 10 = 15.45
15.45 / 10 = 1.545
As we divide 3 times the value of x by 10, the whole digit of our logarithm will be 3.


*Raise x to the tenth power:
1.545 ^ 10 = 77.4969905 ...


*Repeat the procedures from step 1.
As we divide only 1 time, the next digit of our logarithm will be 1.


*Repeat step 2.

7.74969905 ... ^ 10 = 781.354.964,875286221 ...


*Repeat step 1.

Since we divide x by 10 by 8 times, the next digit in our log will be 8.
And so on, as many digits as you want.
