Yes, you're right! The first step is rewriting the equation as
[tex] \ln(a) + \ln(b^x) = M [/tex]
Subtract [tex] \ln(a) [/tex] from both sides:
[tex] \ln(b^x) = M-\ln(a) [/tex]
Use the property [tex] \ln(a^b) = b\ln(a) [/tex] to rewrite the equation as
[tex] x\ln(b) = M-\ln(a) [/tex]
Divide both sides by [tex] \ln(b)[/tex]
[tex] x = \dfrac{M-\ln(a)}{\ln(b)} [/tex]
Alternative strategy:
Consider both sides as exponents of e:
[tex] e^{\ln(ab^x)} = e^M [/tex]
Use [tex] e^{\ln(x)} = x [/tex] to write
[tex] ab^x = e^M [/tex]
Divide both sides by a:
[tex] b^x = \dfrac{e^M}{a} [/tex]
Consider the logarithm base b of both sides:
[tex] x = \log_b\left(\dfrac{e^M}{a}\right) [/tex]
The two numbers are the same: you can check it using the rule for changing the base of logarithms