Aliases for logarithm and exponentials

At some stage in the future I would expect that some people might like to see ln(x) be allowed as an alias for log(x), the latin name whch has persisted to this day.

The former name is the abbreviation for logarithmus naturalis, there also being functions lg(x) and lb(x) for logarithmus generalis and logarithmus binarius for log10(x) and log2(x). Similarly there are functions pn(x), pg(x) and pb(x) which are equivalent antilogarithm or exponential routines where that p is potentia. There are all in an ISO standard. If you are European, you have probably seen these commonly in textbooks.

This would only affect the Math module's namespace. Unless there is some disapproval, I would like to put a placeholder in Github to consider this in 2026. or later. For now, it is just a distraction from far more significant issues. That said, addressing it is trivial.

Hi Damian: there is already a ln function in Math, and it appears to do exactly the same as log.

Regards

Nelson

2 Likes

Thanks Nelson

Anyway, I will see if people object for the others to be included.

1 Like

Hi Damian —

In my computer science courses, I'm fairly certain that lg() was used as a shorthand for log_2, and in the past I've advocated for supporting this in our modules without realizing it might mean log_10 in other communities. This website seems to confirm both perspectives, suggesting that it may introduce more potential for confusion than clarity if added to the standard Math module (of course, other modules might choose to define it one way or the other).

-Brad

Scary. Food for thought, I will think about it a bit more. Background below.

logarithmus generalis = lg = genaral logarithm = log to base 10

logarithmus binarius = lb = binary logarithm = log to base 2

logarihmus naturalis = ln = natural logarithm = ......

The names and abbreviations have been around for over 100 years as far as I can tell. Any textbook using an abbreviation oflg for a binary logarithm is plain wrong. Probably a case of some English speaking author who got lazy. No wonder students learn the wrong thing. The ISO-80000-2 standard only codified a precise and long standing and rigorous practice.

Scary stuff. No wonder young students and pick up bad habits which they then carry with them until their 50s and even beyond.

Guilty of the same crime.

The IEEE 754 abbreviates the base of its floating point as b and thereafter refers to it that way. Interestingly, it is the mathematical concept of a radix. Exactly when radix became known as the base is not in any of my grey cells. Radix has been around for 2000+ years. Long before the English word base.

In all my own algebra, I use b as the abbreviation for the exponent bias although I try and note the hijacking.

Naughty Damian.