使用 Windows 7 计算器计算对数
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/9766988/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Logarithm Calculation with Windows 7 Calculator
提问by Kerim Atasoy
I would like to use the Windows Calculatorin Scientific Mode in order solve a very basic Logarithm equation but, unfortunately, I couldn't do that.
我想在科学模式下使用Windows 计算器来求解一个非常基本的对数方程,但不幸的是,我不能这样做。
Here is the problem:
这是问题所在:
log_5 125=?
Thank you very much for your help...
非常感谢您的帮助...
Well, I know it equals to "3", but, how can I use the Windows Calculator to get computed that equation for example?
好吧,我知道它等于“3”,但是,例如,我如何使用 Windows 计算器来计算该方程?
回答by Shay
You can calculate a logarithm in a given base by calculating two logarithms in an arbitrary base, using the following equation:
您可以通过计算任意底中的两个对数来计算给定底中的对数,使用以下等式:
log_b (x) = log_k (x) / log_k (b)
As the windows calculator got a ln button, which stands for the natural logarithm (that is, log in basis e,) then you can press 125, ln, /, 5, ln, and get the desired result.
由于windows计算器有一个ln按钮,代表自然对数(即以e为登录基数),那么你可以按125、ln、/、5、ln,得到想要的结果。
For bonus points, here is why the above equation holds:
对于奖励积分,这就是上述公式成立的原因:
- Let ab= c. Remember that this sets b = log_a (c).
- Take log_k of both sides of the first equation. We get: log_k (ab) = log_k (c)
- Using the logarithmic identity log (xy) = y * log (x), we get b * log_k (a) = log_k (c)
- Hence b = log_k (c) / log_k (a).
- From the first step, we have b = log_a (c), hence log_a (c) = log_k (c) / log_k (a). QED.
- 让 a b= c。请记住,这会设置 b = log_a (c)。
- 取第一个方程两边的 log_k。我们得到: log_k (a b) = log_k (c)
- 使用对数恒等 log (x y) = y * log (x),我们得到 b * log_k (a) = log_k (c)
- 因此 b = log_k (c) / log_k (a)。
- 从第一步开始,我们有 b = log_a (c),因此 log_a (c) = log_k (c) / log_k (a)。QED。