## LOG bases

Discussion around the Swiss Micros DM42 calculator.
jvanoort
Posts: 16
Joined: Wed Feb 24, 2021 1:30 pm

### LOG bases

hi all,

This may be more a general HP 42s question, but is there a way to use the LOG function with different bases?
salvomic
Posts: 186
Joined: Sat Dec 30, 2017 10:09 am
Location: Ragusa, Sicily
Contact:

### Re: LOG bases

something like:

Code: Select all

input y (base)
ENTER
input x (number)

then

Code: Select all

LN
x<>y
LN
÷

you could save a little program like this.
Otherwise, see here for a better solution, by Fernando: «The menu adds a the LGyX function to compute base-y logarithm»...

Salvo
∫aL√0mic (IT9CLU) :: DM42 (SN: 00881), DM41X (SN 00523), DM16, HP Prime, 50g, 41CX, 42s, 71b, 15C, 12C, 35s, WP34s -- Free42
jvanoort
Posts: 16
Joined: Wed Feb 24, 2021 1:30 pm

### Re: LOG bases

Thank you. Interesting solution

I now use the solver and solve b^e=x for the exponent e, which works as well, but I just wondered if there was a trick to use LOG with a different base without resorting to solvers or programs. Apparently not.

salvomic
Posts: 186
Joined: Sat Dec 30, 2017 10:09 am
Location: Ragusa, Sicily
Contact:

### Re: LOG bases

jvanoort wrote:
Thu Mar 18, 2021 10:51 pm
you're welcome!
∫aL√0mic (IT9CLU) :: DM42 (SN: 00881), DM41X (SN 00523), DM16, HP Prime, 50g, 41CX, 42s, 71b, 15C, 12C, 35s, WP34s -- Free42
jneven
Posts: 9
Joined: Sat Jan 23, 2021 6:32 pm
Location: Belgium

### Re: LOG bases

Do you mean this one:
LOGb(X) = LOG10(X)/LOG10(b)
If yes...no solver required
Thomas Okken
Posts: 913
Joined: Tue May 02, 2017 5:48 pm
Location: United States
Contact:

### Re: LOG bases

jneven wrote:
Fri Mar 19, 2021 5:10 pm
LOGb(X) = LOG10(X)/LOG10(b)
LOGb(X) = LN(X)/LN(b)

...is slightly faster
jvanoort
Posts: 16
Joined: Wed Feb 24, 2021 1:30 pm

### Re: LOG bases

That’s not a HP 42s trick, but a gaping gap in my fundamental knowledge and understanding of math in general and LOG / LN in particular!

I’m dedicating tonight to trying understand why LOGb(x) = LN(x)/LN(b), but indeed: no solver required!

Learning something new everyday, thank you guys!
Calambres
Posts: 23
Joined: Wed Dec 16, 2020 6:49 pm
Contact:

### Re: LOG bases

jvanoort wrote:
Fri Mar 19, 2021 7:40 pm
I’m dedicating tonight to trying understand why LOGb(x) = LN(x)/LN(b)...
https://en.wikipedia.org/wiki/List_of_l ... g_the_base
Calambres
Posts: 23
Joined: Wed Dec 16, 2020 6:49 pm
Contact:

### Re: LOG bases

Thomas Okken wrote:
Fri Mar 19, 2021 7:29 pm
LOGb(X) = LN(X)/LN(b)
...is slightly faster
Just curious: why is it faster a LN than a LOG?
Walter
Posts: 1846
Joined: Tue May 02, 2017 11:13 am
Location: Close to FRA, Germany

### Re: LOG bases

Calambres wrote:
Sat Mar 20, 2021 9:52 am
Thomas Okken wrote:
Fri Mar 19, 2021 7:29 pm
LOGb(X) = LN(X)/LN(b)
...is slightly faster
Just curious: why is it faster a LN than a LOG?
Because LN is calculated while LG is derived from LN.

(Nitpicky remark: LG is identical to LOG10 like LN being identical to LOGe and LB to LOG2. Never let any mathematician catch you with a naked LOG in your text!)
DM42 SN: 00041 β
WP 43S running on this device

HP-35, HP-45, ..., HP-35S, WP 34S, WP 31S, DM16L