ln() vs. log()
04-17-2016, 10:06 PM
Post: #1
 Don Shepherd Senior Member Posts: 745 Joined: Dec 2013
ln() vs. log()
I have often wondered why these two functions exist. Many calculators (HP 17b, HP 65, TI 84+) have both. Some (12c) have only one (ln). Interestingly, the original Dartmouth BASIC had log() but it was really ln().

Is one more accurate than the other? Why the two standards?
04-17-2016, 10:15 PM
Post: #2
 Massimo Gnerucci Senior Member Posts: 2,333 Joined: Dec 2013
RE: ln() vs. log()
(04-17-2016 10:06 PM)Don Shepherd Wrote:  I have often wondered why these two functions exist. Many calculators (HP 17b, HP 65, TI 84+) have both. Some (12c) have only one (ln). Interestingly, the original Dartmouth BASIC had log() but it was really ln().

Is one more accurate than the other? Why the two standards?

Why 10^x and e^x then?

Greetings,
Massimo

-+×÷ ↔ left is right and right is wrong
04-17-2016, 10:19 PM (This post was last modified: 04-17-2016 10:19 PM by Han.)
Post: #3
 Han Senior Member Posts: 1,878 Joined: Dec 2013
RE: ln() vs. log()
Mathematically the are equivalent, just in different bases. That is $$\ln(x) = \frac{\log(x)}{\log(10)}$$ with log just being a conventional shortcut for $$\log_{10}$$. Sometimes log may also be implemented as base-2 logarithms in some programming languages. Anyway the use of base-10 logs is likely due the fact that we count in base-10.

Graph 3D | QPI | SolveSys
04-17-2016, 11:50 PM
Post: #4
 Dave Shaffer Member Posts: 55 Joined: Dec 2013
RE: ln() vs. log()
Electrical engineers working in decibels sure need log()!
04-18-2016, 01:37 AM
Post: #5
 Tim Wessman Senior Member Posts: 2,270 Joined: Dec 2013
RE: ln() vs. log()
There's also the added wrinkle that in most CAS software packages use log(...) as base e and many don't have a base 10 variant.

TW

Although I work for the HP calculator group, the views and opinions I post here are my own.
04-18-2016, 02:48 AM (This post was last modified: 04-18-2016 02:50 AM by Katie Wasserman.)
Post: #6
 Katie Wasserman Super Moderator Posts: 631 Joined: Dec 2013
RE: ln() vs. log()
Base-10 logs are a lot easier to understand when you first encounter logarithms. I can't imagine trying to teach a 12 year old about logs that use a transcendental number as their base. You need to know a lot more about mathematics before natural logarithms make sense. Once you do know more about math, it's hard to find any good use for base-10 logs, with the exception of db measurements.

-katie

04-18-2016, 03:05 AM
Post: #7
 Han Senior Member Posts: 1,878 Joined: Dec 2013
RE: ln() vs. log()
(04-18-2016 02:48 AM)Katie Wasserman Wrote:  Base-10 logs are a lot easier to understand when you first encounter logarithms. I can't imagine trying to teach a 12 year old about logs that use a transcendental number as their base. You need to know a lot more about mathematics before natural logarithms make sense. Once you do know more about math, it's hard to find any good use for base-10 logs, with the exception of db measurements.

Richter scale and pH are the only others that come to mind. That said, I remember having to do a lot of lab experiments in physics and chemistry where, in order to show that there was an exponential relationship, we used log-scaled graph paper and obtain a linear regression. I think it was base-10.

Graph 3D | QPI | SolveSys
04-18-2016, 03:42 AM
Post: #8
 wojtek Member Posts: 131 Joined: Dec 2015
RE: ln() vs. log()
(04-17-2016 10:06 PM)Don Shepherd Wrote:  I have often wondered why these two functions exist. Many calculators (HP 17b, HP 65, TI 84+) have both. Some (12c) have only one (ln). Interestingly, the original Dartmouth BASIC had log() but it was really ln().

Is one more accurate than the other? Why the two standards?

Good question. When I was very young (really very jung) I was wondering why Easter and Christmas exist, which one was better and which one could I give up. Of course Christmas won :-)
04-18-2016, 04:00 AM (This post was last modified: 04-18-2016 06:48 AM by Alejandro Paz(Germany).)
Post: #9
 Alejandro Paz(Germany) Member Posts: 134 Joined: Mar 2016
RE: ln() vs. log()
well with pH is rather simple to see, at least for chemists because of what that p means:
p = -log10 of the concentration

in other words pH is just one of the possibilities, there is pOH of course and so on .
Edit: and that H means actually protons.
04-18-2016, 10:51 AM
Post: #10
 Jeff_Kearns Member Posts: 147 Joined: Dec 2013
RE: ln() vs. log()
(04-18-2016 04:00 AM)Alejandro Paz(Germany) Wrote:  Edit: and that H means actually protons.

(Chemistry) potential of hydrogen; a measure of the acidity or alkalinity of a solution equal to the common logarithm of the reciprocal of the concentration of hydrogen ions in moles per cubic decimetre of solution. Pure water has a pH of 7, acid solutions have a pH less than 7, and alkaline solutions a pH greater than 7.

Jeff
04-18-2016, 01:14 PM
Post: #11
 Thomas Radtke Senior Member Posts: 775 Joined: Dec 2013
RE: ln() vs. log()
My 35s returns zero for ln(1000)/ln(10)-3. Not too bad. But the same fails with 10,000 miserably (by 1*10^-11) ;-)
04-18-2016, 01:25 PM (This post was last modified: 04-18-2016 01:57 PM by Tugdual.)
Post: #12
 Tugdual Senior Member Posts: 755 Joined: Dec 2013
RE: ln() vs. log()
Also decibel is
$20*\log _{ 10 }{ (\frac { V }{ { V }_{ ref } } ) }$

I also find it interesting because it tells me the # of digits you need to write a number in base 10.
04-18-2016, 02:41 PM
Post: #13
 emece67 Senior Member Posts: 377 Joined: Feb 2015
RE: ln() vs. log()
(04-18-2016 01:25 PM)Tugdual Wrote:  Also decibel is
$20*\log _{ 10 }{ (\frac { V }{ { V }_{ ref } } ) }$

I also find it interesting because it tells me the # of digits you need to write a number in base 10.

Incidentally, the Neper (Np) is:

$\ln({V\over V_{ref}})$

César - Information must flow.
04-18-2016, 04:38 PM
Post: #14
 Csaba Tizedes Senior Member Posts: 491 Joined: May 2014
RE: ln() vs. log()
Lots of E and I&C engineers here...
I'm a mechanical, so I believe that the HP32SII keyboard is the only one which is designed for the engineering calculations:

LN() and EXP() as primary(!) function,
Y^X and 1/X also as primary(!) functions.

With this keyboard layout any engineering problem solved as fast as possible.

In the nature everything is depends on how many driving force is available. No more changes will be done what is available: everything is exponential because its derivative is also exponential function: No more U235 will be splitting what is available, no more people will be die what is lives now, not cooles below your room temperature what is the temperature outside - because almost all the changes in the nature exponential. Solution of a simple differential equation.

I know it not everything is simple. But lot of things is that.

Csaba
04-19-2016, 05:33 AM
Post: #15
 Joe Horn Senior Member Posts: 1,767 Joined: Dec 2013
RE: ln() vs. log()
(04-18-2016 04:38 PM)Csaba Tizedes Wrote:  I'm a mechanical, so I believe that the HP32SII keyboard is the only one which is designed for the engineering calculations:

LN() and EXP() as primary(!) function,
Y^X and 1/X also as primary(!) functions.

With this keyboard layout any engineering problem solved as fast as possible.

By that criterion, the HP33s is a real winner; it not only has all four of those functions on primary keys, but has them all together as the first 4 keys on the top row! The HP-97 also has them on primary keys. Do any other models?

<0|ɸ|0>
-Joe-
04-19-2016, 12:48 PM (This post was last modified: 04-19-2016 01:01 PM by jebem.)
Post: #16
 jebem Senior Member Posts: 1,341 Joined: Feb 2014
RE: ln() vs. log()
(04-19-2016 05:33 AM)Joe Horn Wrote:
(04-18-2016 04:38 PM)Csaba Tizedes Wrote:  I'm a mechanical, so I believe that the HP32SII keyboard is the only one which is designed for the engineering calculations:

LN() and EXP() as primary(!) function,
Y^X and 1/X also as primary(!) functions.

By that criterion, the HP33s is a real winner; it not only has all four of those functions on primary keys, but has them all together as the first 4 keys on the top row! The HP-97 also has them on primary keys. Do any other models?

The amazing HP-20S and HP-21S calculators also have those four functions $$e^x$$, $$LN$$, $$y^x$$ and $$1/x$$ in the same exact positions as the HP-32SII.
In fact they have all the top row six primary functions identical to the 32SII:
$$\sqrt(x)$$, $$e^x$$, $$LN$$, $$y^x$$, $$1/x$$, and $$\sum$$

Also the even more amazing HP-27S have those four functions as primary keys at the top row starting at column 3 thru 6.
It also has the $$\sqrt(x)$$ at the same position as the 32SII in column 1.

I say they are all amazing because they are pure Algebraic instead of the regular RPN found in almost all of the HP machines

Let us not forget the venerable HP-35!
It has those functions as primary keys as well, despite being at different positions when compared to the 32SII.

Jose Mesquita

04-19-2016, 02:00 PM (This post was last modified: 04-19-2016 03:02 PM by jebem.)
Post: #17
 jebem Senior Member Posts: 1,341 Joined: Feb 2014
RE: ln() vs. log()
(04-18-2016 01:14 PM)Thomas Radtke Wrote:  My 35s returns zero for ln(1000)/ln(10)-3. Not too bad. But the same fails with 10,000 miserably (by 1*10^-11) ;-)

Got the same results (I think) with the HP 10bii+ and with the mighty HP Prime in Home mode:
$$\frac{LN(10000)} {LN(10)} -4 = 0.00000000001$$

The HP Prime in CAS mode gives a much smaller difference result of just: $$-1.42108547152^{-14}$$

Although my humble Hp 300S+ and another Casio fx-991SPX manage to return zero for both cases.
To be fair, these two models only shows up to 10 mantissa digits, so they are not in the same league as the others.

However, taking the popular top class Texas ti-89 Titanium (at least in other forums...), with a setup to display 12 float digits in scientific format, it returns Zero for both cases.
Is this impressive?

Jose Mesquita

04-19-2016, 09:47 PM (This post was last modified: 04-19-2016 09:55 PM by Dieter.)
Post: #18
 Dieter Senior Member Posts: 2,397 Joined: Dec 2013
RE: ln() vs. log()
(04-19-2016 02:00 PM)jebem Wrote:  [ ln 10000 : ln 10 = 4,000 0000 0001 ]
However, taking the popular top class Texas ti-89 Titanium (at least in other forums...), with a setup to display 12 float digits in scientific format, it returns Zero for both cases.
Is this impressive?

No, it's simply wrong.

ln 10000, evaluated to 12 digits, equals 9,210 3403 7198.
ln 10, evaluated to 12 digits, equals 2,302 5850 9299.

The quotient of both values is 4,000 0000 0000 868... which is 4,000 0000 0001 when rounded to the same 12 digits again. So the exact result of this quotient is not (!) exactly 4. If you get a plain 4 the calculator is doing something behind your back you do not know.

Now do the same calculation with merely 10 digits. Here the 10-digit representations of ln 10000 resp. ln 10 happen to match the exact value quite closely:

ln 10000, evaluated to 10 digits, equals 9,210 3403 72.
ln 10, evaluated to 10 digits, equals 2,302 5850 93.

The quotient of both values is exactly 4. This is not because of more accuracy but simply because the two intermediate values happen to round to 10 digits they way they do. Which in turn is caused by the fact that ln 10 happens to round so nicely to 10 digits.

Dieter
04-20-2016, 07:33 AM
Post: #19
 Csaba Tizedes Senior Member Posts: 491 Joined: May 2014
RE: ln() vs. log()
BTW: Has anybody a technical application where you can (must to) use both LOG() and LN() or these inverses (in any permutation)?

Csaba
04-20-2016, 08:45 AM (This post was last modified: 04-20-2016 08:53 AM by emece67.)
Post: #20
 emece67 Senior Member Posts: 377 Joined: Feb 2015
RE: ln() vs. log()
(04-20-2016 07:33 AM)Csaba Tizedes Wrote:  BTW: Has anybody a technical application where you can (must to) use both LOG() and LN() or these inverses (in any permutation)?

Csaba

When working on acoustics the dB is always present, so you use $$\log/10^x$$.

If, working on acoustics, you deal with horns, many times such horns are exponential ones and you also use $$\ln/e^x$$. I suppose that this also applies to people working with microwave horns.

There are other uses of $$\ln/e^x$$ in EE, such as the Ebers-Moll equations (of bipolar transistors), diode equation, skin effect,... So if you work with any of them and also use dB, you need both kind of logs. Also, the magnetic Reynolds number many times goes into an exponential function $$e^{-R_m}$$.

In information theory $$log_2$$ is of interest. In fact I many times use both of $$\log/\log_2$$. Unfortunately, I only got a calculator with direct $$\log_2$$ quite lately (wp34S).

But if you are asking for a single equation using both of $$\log/\ln$$, none comes to my mind.

Regards.

p.s. Why on Earth is so difficult to me to enter the combinations "\ (" and "\ )" needed to write equations here? Perhaps an artefact of the Spanish keyboard layout.

César - Information must flow.
 « Next Oldest | Next Newest »

User(s) browsing this thread: 1 Guest(s)