Join 307,007 Programmers for FREE! Get instant access to thousands of experts, tutorials, code snippets, and more! There are 2,007 people online right now. Registration is fast and FREE... Join Now!
I was doing Logarithms in school these days. I bet this is the most helpful forum ever on the WWW. I have always been helped. Now, I don't know why we use a calculator for finding the log of a number? Isn't there a formula? Of course, calculator uses a formula. Is this like the periodic table of elements, that each number has its own log? How long can this continue? Do the bases have anything to do with those in decimal, binary, hexadecimal, blah?
Wow, that sure is a fountain of questions, hope one is for answers too, thanks in advance.
You had few right questions but in a very wrong place [Lounge? that can go to programming help -> Computer Science right? ]. So before you get flamed see here .
--EDIT-- Amadeus gave more links, consider my post as void and go through his links.
This post has been edited by AmitTheInfinity: 16 Sep, 2008 - 04:08 AM
++ thank you all for these suggestions. I am checking out all these. Also, I put this thread in Caffeine lounge and administrators moved it so I can't help. I have always posted all rubbish in Chit Chat Lounges of forums, may it be go4expert.com / ubuntuforums.org / linuxforums....
... but after searching all trashcans on the net, I have even Googled and I don't get how to find the log of a number without a calculator. Could anybody help me out with a formula?
I am not sure whether you went through detailed contents of the links given in above posts. There are formulas to calculate logs, just find them carefully.
Logarithms are the exponent you have to raise any given base number to in order to get your number in question. It can be in base 10, commonly referred to as "log", and often the easiest to understand. Computer folks often do well getting the concept in binary, or base 2. Let's try both.
Let me ask you a question. Log10=log(base 2)2. Given the above description, can you intuit what it is?
Finally, natural logarithms, or ln. People freak at natural logarithms. I've seen strong men cry over natural logarithms. I won't get into how they are derived, but I'll tell you what they do and why they are important. The natural log gives you the time needed to reach a certain level of continuous compounded growth. Period. That's it. This applies identically to decay, which is simply the inverse of growth.
When you are comfortable with natural logarithms (ln), and log(base 10), i.e. Log, and play around with getting the ln of a variable and Log of the same variable on either side of the equals sign (=). Move stuff around using the normal rules of exponents until you can see intuitively how Log and ln are related.
Be patient with yourself. It takes a bit to get the "aha" feeling with natural logarithms.
In computer science log base 2 of X (denoted simple as lg X) is the most common log that you'll be dealing with. For instance, the height of a binary tree can be said to be in the set O(lg n) where n is the number of nodes in the tree. This also comes into play when determining the running time of some recursive algorithms (recurrences). For instance, the running time of the binary search algorithm can be expressed as T(n) = T(n/2) + O(1). It's easy to see that T(n) = O(lg n), as each recursion cuts the problem in half (no need for the master method).
Let me ask you a question. Log10=log(base 2)2. Given the above description, can you intuit what it is?
Yes. Log (base x) Y = 1 when x = Y. Naturally if we write in indical form, 2 Power 2 is 1 and 10 power 10 is one. Now my question was, that there are tables and massive books with logs of numbers. If we know how to that manually, we don't need those. When we do "log blah" in calculator, it gives a number that is log of blah. This is base 10 I know. We know these:
log base10 of blah = whatwedontknow. where we know the base and blah. Suppose we do log 7 in calculator. We get 0.84509804. The indical form is:
10 ^ 0.84509804 = 7. But how did the calculator get to find the power? There must be a formula?
What has the calculator done to blah?
This post has been edited by usamamuneeb: 20 Sep, 2008 - 11:12 PM
Now I am so old and decrepit that I remember calculating the log of a number at school without a calculator. If my memory is not playing tricks, it was by plugging numbers into a convergent series.
In those days we used logs all the time for multiplying floats and for doing indices. You got the log out of a book; in the same book you could look up arctan and stuff. I think it is still there at the back of the cupboard. Do people still use logs, then? I thought they went out with the slide rule (which also works with logs, doesn't it?).
No, I am OK with a calculator. Still, slide rule I have never used one and it won't explain how to find the log manually. So on my part, this topic is closed so I don't slip towards how a slide rule works!!!!!!!!