AHL 2.10 — Log–log and semi-log scaling(対数目盛りと線形化)
- 桁の大きく違うデータに、logarithm(対数)の目盛りを使う理由を説明できる。
- semi-log(片対数)のグラフが直線なら exponential、log-log(両対数)のグラフが直線なら power の関係だと判断できる。
- データの \(\log\) をとって直線にすることを linearize(線形化)といい、その手順を実行できる。
- 直線の gradient(傾き)と intercept(切片)から、元の \(y = ka^{x}\) や \(y = ax^{n}\) を復元できる。
- \(\log\) でも \(\ln\) でも線形化できることを知り、戻すときに底をそろえられる。
- 傾き・切片の値を、文脈の言葉で解釈できる。
The idea
1. Logarithmic scales(対数目盛り)
桁が大きくちがうデータは、ふつうの目盛りでは読めません。そこで、logarithm(対数)の目盛りを使います。
あるサイトの月ごとの訪問数が、\(50\)、\(400\)、\(3200\)、\(25600\)、\(204800\)、\(1638400\) だったとします。毎月 \(8\) 倍に増えています。
図 1 の (a) が、ふつうの目盛りでかいたものです。はじめの \(4\) か月が、軸の上にぺしゃんこに潰れています。 \(50\) も \(400\) も \(3200\) も \(25600\) も、区別が付きません。
- は、縦軸を対数の目盛りにしたものです。目盛りが \(10\)、\(100\)、\(1000\)、\(10^{4}\)、\(\ldots\) と、\(10\) 倍ごとに等間隔になっています。
すると \(6\) 点が一直線に並びます。 しかも、\(1\) か月ぶんの上がり幅がどこでも同じです。
\[ \log(8 \times \text{前月}) - \log(\text{前月}) = \log 8 = 0.903 \]
「毎月 \(8\) 倍」という一定の割合が、一定の高さとして目に見える——これが対数目盛りの働きです。
対数目盛りは、値そのものの大きさよりも、増える割合を見せたいときに使います。数そのものは驚くほど大きくても、増え方は落ち着いている——それを見せられるのが対数目盛りです。
試験では、対数目盛りのグラフを自分でかくことは求められません。読むことと、元の式に戻すことができれば十分です。
2. Semi-log graphs(片対数グラフ)
semi-log(片対数)のグラフとは、横軸が \(x\) のまま、縦軸が \(\log y\) のグラフです。
このページでは、\(\log\) は底 \(10\) の対数を表します。\(\log_{10}\) の下付きを省いた書き方です(\(\ln\) については第6節)。
同じ「semi-log のグラフ」でも、縦軸の目盛りの数字が \(2\) とおりあります。
- 元の数を、対数の間隔で並べる … 図 1 の (b) です。目盛りには \(10\)、\(100\)、\(1000\) と元の数が書いてあります。ただし間隔が等しくありません
- \(\log y\) の値を、ふつうの間隔で並べる … 図 2 の (b) です。目盛りには \(0.301\)、\(0.699\) と対数の値が書いてあります
中身は同じものです。\(1\) つ目は新聞や電卓のグラフ、\(2\) つ目は回帰にかけるときの形だと思ってください。
このページで読むのは、たいてい \(2\) つ目です。縦軸に \(\log_{10} y\) と書いてあったら、そこに書かれている数は \(y\) ではありません。 \(\log y = 2\) は \(y = 100\) という意味です(演習 \(5\))。
exponential(指数)の関係 \(y = ka^{x}\)(\(k > 0\)、\(a > 0\))の両辺の \(\log\) をとります。\(\log y\) を取るので、\(y\) はつねに正でなければなりません(AHL 1.9)。
\[ \log y = \log\left(k a^{x}\right) = \log k + x\log a \tag{1}\]
ここで使ったのは、AHL 1.9 の対数法則 \(\log xy = \log x + \log y\) と \(\log x^{m} = m\log x\) だけです(公式集にあります)。このページに新しい公式はありません。
右辺は \(x\) の \(1\) 次式です。 \(\log y\) を縦、\(x\) を横に取れば、直線になります(例 1)。
\[ \underbrace{\log y}_{\text{縦}} = \underbrace{(\log a)}_{\text{傾き}} \, x + \underbrace{\log k}_{\text{切片}} \]
図 2 が、\(y = 5 \times 2^{x}\) の場合です。(a) では曲線ですが、(b) ではきれいな直線になります。
- 傾き \(= \log 2 = 0.301\)
- 切片 \(= \log 5 = 0.699\)
3. Log-log graphs(両対数グラフ)
log-log(両対数)のグラフとは、横軸が \(\log x\)、縦軸が \(\log y\) のグラフです。
power(累乗)の関係 \(y = ax^{n}\)(\(a > 0\)、\(x > 0\))の両辺の \(\log\) をとります。両方の \(\log\) を取るので、\(x\) も \(y\) も正でなければなりません。
\[ \log y = \log\left(a x^{n}\right) = \log a + n\log x \tag{2}\]
\[ \underbrace{\log y}_{\text{縦}} = \underbrace{n}_{\text{傾き}} \, \underbrace{\log x}_{\text{横}} + \underbrace{\log a}_{\text{切片}} \]
図 3 が、\(y = 2x^{3}\) の場合です。(a) では曲線ですが、(b) では直線になります。傾きは \(3\)、切片は \(\log 2 = 0.301\) です。
傾きが指数 \(n\) そのものになるのが、log-log のいちばんの特徴です。
ただし、縦と横で同じ底の対数を使ったときです。\(\log_{10} y\) を \(\ln x\) に対してかくと、傾きは \(n\) になりません。\(2\) つの軸の底をそろえてください(第6節)。
4. Exponential or power relationship(指数か累乗かの見分け方)
データの \(\log\) をとって直線にすることを、linearize(線形化)といいます。semi-log と log-log のどちらが直線になるかで、指数の関係か累乗の関係かが決まります。
| 直線になるグラフ | 元の関係 | 傾き | 切片 |
|---|---|---|---|
| semi-log(\(\log y\) 対 \(x\)) | \(y = ka^{x}\)(exponential) | \(\log a\) | \(\log k\) |
| log-log(\(\log y\) 対 \(\log x\)) | \(y = ax^{n}\)(power) | \(n\) | \(\log a\) |
覚え方は \(1\) つです。
\(x\) が指数の位置にいるなら、\(x\) はそのまま。\(x\) が底の位置にいるなら、\(x\) にも \(\log\)。
- \(y = k a^{x}\) … \(x\) は指数の位置 → 横軸は \(x\) のまま(semi-log)
- \(y = a x^{n}\) … \(x\) は底の位置 → 横軸も \(\log x\)(log-log)
\(2\) 通りとも計算して、Pearson’s correlation coefficient(相関係数)の \(\lvert r \rvert\) が \(1\) に近いほうが、より直線に近いといえます。ここで SL 4.4 の \(r\) を使います。
演習 \(6\) のデータでは、log-log で \(r = 1.000\)、semi-log で \(r = 0.959\) です。どちらもそれなりに高いので、\(2\) つを出して比べる必要があります。
\(r\) が言えることと、言えないことを分けておきます。
- \(\lvert r \rvert\) が \(1\) に近い … 変換したあとの点が、直線に近く並んでいる
- それだけでは、元のデータが本当に exponential model や power model に従うとは断定できません
- 判断には、scatter diagram(散布図)の形、residual(残差)の並び方、文脈、変数の意味も要ります
- このページでは、\(r\) を semi-log と log-log のどちらがより直線に近いかを比べる補助として使います
反例を \(1\) つ挙げます。\(y = x^{2}+40\) のようなデータでは semi-log の \(r = 0.997\)、log-log の \(r = 0.925\) となり、\(r\) で選ぶと exponential になりますが、実際にはどちらのモデルでもありません。 AHL 4.13 と同じ注意です。散布図の形と文脈を先に見て、\(r\) はそのあとの裏づけに使ってください。
\(r\) の意味は SL 4.4 にあります。
5. Recovering the equation(元の式への戻し方)
直線の gradient(傾き)と intercept(切片)から、元の \(y = ka^{x}\) や \(y = ax^{n}\) を求めます。ここが、この項目でいちばん使う操作です。
\(\log\) を外すには、\(10\) を底に乗せます。 使うのは対数の定義 \(10^{\log x} = x\) です(SL 1.5)。
semi-log の直線が \(\log y = mx + c\) のとき、
\[ y = 10^{mx+c} = 10^{c} \times \left(10^{m}\right)^{x} \tag{3}\]
表 1 と見くらべて
\[ k = 10^{c}, \qquad a = 10^{m} \]
log-log の直線が \(\log y = m\log x + c\) のとき、
\[ y = 10^{m\log x + c} = 10^{c} \times \left(10^{\log x}\right)^{m} = 10^{c} \, x^{m} \tag{4}\]
\[ a = 10^{c}, \qquad n = m \]
semi-log の傾きが \(0.3\) でも、増え方は \(0.3\) 倍ではありません。
\[ a = 10^{0.3} = 2.00 \]
約 \(2\) 倍です。切片も同じで、\(c = 1.8\) なら \(k = 10^{1.8} = 63.1\) であって、\(1.8\) ではありません。
\(\log\) の世界の数を、そのまま元の世界に持ち出さない。 これがこの項目の最大の注意点です(演習 \(10\))。
例題 1 The graph of \(\log_{10} y\) against \(x\) is a straight line with gradient \(0.25\) and \(y\)-intercept \(1.8\).
(a) Write down an equation for \(\log_{10} y\) in terms of \(x\).
(b) Find an expression for \(y\) in terms of \(x\).
(c) Find the value of \(y\) when \(x = 6\).
日本語訳
\(\log_{10} y\) を \(x\) に対してかいたグラフが、傾き \(0.25\)、\(y\) 切片 \(1.8\) の直線になります。
(a) \(\log_{10} y\) を \(x\) で表す式を書きなさい。
(b) \(y\) を \(x\) で表す式を求めなさい。
(c) \(x = 6\) のときの \(y\) の値を求めなさい。
(a) 直線なので \(y = mx+c\) の形です。縦は \(\log y\) です。
\[ \log y = 0.25x + 1.8 \]
(b) 式 3 です。\(10\) を両辺に乗せます。
\[ y = 10^{0.25x+1.8} = 10^{1.8} \times \left(10^{0.25}\right)^{x} \]
\[ 10^{1.8} = 63.0957\ldots, \qquad 10^{0.25} = 1.77827\ldots \]
\[ y = 63.1 \times 1.78^{x} \]
傾きの \(0.25\) をそのまま使わないでください(第5節)。増え方は \(1.78\) 倍です。
(c) (a) の式のほうが速いです。\(\log\) の世界で計算してから、最後に戻します。
\[ \log y = 0.25(6) + 1.8 = 1.5 + 1.8 = 3.3 \]
\[ y = 10^{3.3} = 1995.26\ldots = 2000 \ (3\ \text{s.f.}) \]
検算。 (b) の式でも出します。\(63.0957 \times 1.778279^{6} = 1995.26\ldots\) ✓ 一致しました。
丸めた \(63.1 \times 1.78^{6}\) で計算すると \(2007\) になります。丸めた値を使わないでください(第7節)。
(a) \[\log_{10} y = 0.25x + 1.8\]
(b) \[y = 10^{0.25x+1.8} = 10^{1.8}\left(10^{0.25}\right)^{x} = 63.1 \times 1.78^{x}\]
(c) \[\log_{10} y = 0.25(6)+1.8 = 3.3 \ \Rightarrow \ y = 10^{3.3} = 1995.26\ldots = 2000 \ (3\ \text{s.f.})\]
例題 2 For \(x > 0\), the graph of \(\log_{10} y\) against \(\log_{10} x\) is a straight line with gradient \(1.5\) and \(y\)-intercept \(0.6\).
(a) Show that \(y = ax^{n}\) for constants \(a\) and \(n\), and state their values.
(b) Find the value of \(y\) when \(x = 16\).
日本語訳
\(\log_{10} y\) を \(\log_{10} x\) に対してかいたグラフが、傾き \(1.5\)、\(y\) 切片 \(0.6\) の直線になります。
(a) \(y = ax^{n}\)(\(a\)、\(n\) は定数)の形になることを示し、その値を述べなさい。
(b) \(x = 16\) のときの \(y\) の値を求めなさい。
(a) 直線の式を書きます。横軸が \(\log x\) であることに注意してください。
\[ \log y = 1.5\log x + 0.6 \]
\(1.5\log x = \log x^{1.5}\) です(AHL 1.9)。
\[ \log y = \log x^{1.5} + 0.6 \]
\(10\) を乗せます。
\[ y = 10^{0.6} \times x^{1.5} \]
\(10^{0.6} = 3.98107\ldots\) なので
\[ a = 3.98, \qquad n = 1.5 \]
傾きが、そのまま指数 \(n\) になります(表 1)。切片のほうだけ \(10\) を乗せます。
(b) \(\log\) の世界で計算します。\(\log 16 = 1.20412\ldots\) なので
\[ \log y = 1.5(1.20412) + 0.6 = 1.80618 + 0.6 = 2.40618 \]
\[ y = 10^{2.40618} = 254.79\ldots = 255 \]
検算。 \(3.981072 \times 16^{1.5} = 3.981072 \times 64 = 254.79\ldots\) ✓ \(16^{1.5} = 16 \times \sqrt{16} = 64\) です(AHL 1.10)。
(a) \[\log_{10} y = 1.5\log_{10} x + 0.6 = \log_{10} x^{1.5} + 0.6\] \[y = 10^{0.6}x^{1.5}\] So \(a = 3.98\) and \(n = 1.5\).
(b) \[\log_{10} y = 1.5\log_{10} 16 + 0.6 = 2.40618 \ \Rightarrow \ y = 255\]
6. Choice of base(対数の底の選び方)
線形化は、\(\log\) でも \(\ln\) でも、どの底の対数でもできます。 AHL 1.9 のとおり、法則は底によらないからです。
\(\ln\) を使うと、式 1 は
\[ \ln y = \ln k + x\ln a \]
になります。直線であることは変わりませんが、傾きと切片の値が変わります。
| 使った対数 | semi-log の傾き | 元に戻すとき |
|---|---|---|
| \(\log\)(底 \(10\)) | \(\log a\) | \(a = 10^{m}\) |
| \(\ln\)(底 \(e\)) | \(\ln a\) | \(a = e^{m}\) |
表 2 のとおりです。\(\ln\) で線形化したのに \(10^{m}\) で戻す——これがよくある誤りです。\(\ln\) で取ったなら \(e\) で戻す、と覚えてください(演習 \(8\))。
\(\ln\) を使うと、指数の形が \(e\) の形で出るという利点があります。
\[ \ln y = mx + c \ \Longrightarrow \ y = e^{c}e^{mx} \]
AHL 2.9a の \(M = M_0e^{-kt}\) と直接つながる形です。
7. The linearization procedure(線形化の手順)
データを渡されたときにやることは、いつも同じです。手順は \(3\) 段階です。
- \(\log\) の列を作る(semi-log なら \(\log y\) だけ、log-log なら \(\log x\) と \(\log y\))
- 直線回帰をかける(SL 4.4 と同じ操作)。\(m\)、\(c\)、\(r\) が出ます
- 式 3 か 式 4 で元に戻す
\(2\) 段目までは電卓に任せられます。\(3\) 段目だけは、自分で \(10^{c}\) を計算します(GDC)。
\(m\) と \(c\) を \(3\) 桁に丸めてから \(10^{c}\) を計算すると、答えがずれます。\(c = 2.07857\) を \(2.08\) にすると
\[ 10^{2.07857} = 119.8, \qquad 10^{2.08} = 120.2 \]
指数の中の小さなずれが、外に出ると大きくなります。 電卓の中の値のまま進めてください(例 3)。
例題 3 A biologist counts the bacteria in a dish once an hour. The results are shown below.
| \(t\) (hours) | \(0\) | \(1\) | \(2\) | \(3\) | \(4\) |
|---|---|---|---|---|---|
| \(N\) | \(120\) | \(190\) | \(305\) | \(480\) | \(770\) |
(a) Complete a table of values of \(\log_{10} N\), giving each value correct to \(4\) decimal places.
(b) The graph of \(\log_{10} N\) against \(t\) is close to a straight line. Find the equation of the regression line of \(\log_{10} N\) on \(t\).
(c) Hence find a model of the form \(N = k a^{t}\).
(d) Interpret the value of \(a\) in this context.
日本語訳
ある生物学者が、シャーレの中の細菌を \(1\) 時間おきに数えました。結果は上の表のとおりです。
(a) \(\log_{10} N\) の値の表を完成させなさい。各値は小数第 \(4\) 位まで答えなさい。
(b) \(\log_{10} N\) を \(t\) に対してかいたグラフは、ほぼ直線になります。\(\log_{10} N\) の \(t\) への回帰直線の式を求めなさい。
(c) これを用いて、\(N = k a^{t}\) の形のモデルを求めなさい。
(d) この文脈で \(a\) の値を解釈しなさい。
(a) 電卓の \(C\) 列に、まとめて出します(GDC)。
| \(t\) | \(0\) | \(1\) | \(2\) | \(3\) | \(4\) |
|---|---|---|---|---|---|
| \(\log_{10} N\) | \(2.0792\) | \(2.2788\) | \(2.4843\) | \(2.6812\) | \(2.8865\) |
表 3 で差がほぼ一定(約 \(0.20\))であることに気づけば、この時点で直線だと見当が付きます。
(b) \(t\) を \(x\)、\(\log N\) を \(y\) として直線回帰をかけます(GDC)。
\[ \log_{10} N = 0.20171 t + 2.07857 \]
\(r = 0.99998\) で、直線に非常に近いことが分かります。
(c) 式 3 です。
\[ N = 10^{2.07857} \times \left(10^{0.20171}\right)^{t} \]
\[ 10^{2.07857} = 119.83\ldots, \qquad 10^{0.20171} = 1.5911\ldots \]
\[ N = 120 \times 1.59^{t} \]
検算。 \(t = 4\) を入れます。\(119.83 \times 1.5911^{4} = 768.0\) で、実際の \(770\) に近い値です ✓
(d) Interpret なので、文脈の言葉で答えます。
試験ではこう書く
The value \(a = 1.59\) is the growth factor per hour: according to the model, the number of bacteria is multiplied by about \(1.59\) each hour, an increase of about \(59\%\) per hour.
It is the same factor at every stage, which is why the semi-log graph is a straight line.
(\(a = 1.59\) は \(1\) 時間あたりの growth factor(増加倍率)である。このモデルによれば、細菌の数は \(1\) 時間ごとに約 \(1.59\) 倍、つまり \(1\) 時間あたり約 \(59\%\) 増える。どの時点でも同じ倍率であり、それが semi-log のグラフが直線になる理由である、という意味です。)
(a) \(2.0792\), \(2.2788\), \(2.4843\), \(2.6812\), \(2.8865\)
(b) \[\log_{10} N = 0.202t + 2.08 \qquad (r = 0.99998)\]
(c) \[N = 10^{2.07857}\left(10^{0.20171}\right)^{t} = 120 \times 1.59^{t}\]
(d) \(a = 1.59\) is the growth factor per hour: the number of bacteria is multiplied by about \(1.59\), that is, it grows by about \(59\%\), each hour.
例題 4 The table shows the mean distance \(d\) from the Sun, in astronomical units, and the orbital period \(T\), in years, of six planets.
| planet | Mercury | Venus | Earth | Mars | Jupiter | Saturn |
|---|---|---|---|---|---|---|
| \(d\) | \(0.387\) | \(0.723\) | \(1.000\) | \(1.524\) | \(5.203\) | \(9.537\) |
| \(T\) | \(0.241\) | \(0.615\) | \(1.000\) | \(1.881\) | \(11.86\) | \(29.45\) |
(a) The graph of \(\log_{10} T\) against \(\log_{10} d\) is a straight line. Find the equation of the regression line, giving the gradient and the intercept correct to \(3\) significant figures.
(b) Hence write down a model of the form \(T = a d^{n}\).
(c) Uranus has \(d = 19.19\). Use the model to predict its orbital period.
(d) Comment on what the value of \(n\) tells you about the relationship between \(d\) and \(T\).
日本語訳
表は、\(6\) つの惑星について、太陽からの平均距離 \(d\)(天文単位)と公転周期 \(T\)(年)を示しています。
(a) \(\log_{10} T\) を \(\log_{10} d\) に対してかいたグラフは直線になります。回帰直線の式を求めなさい。傾きと切片は有効数字 \(3\) 桁で答えなさい。
(b) これを用いて、\(T = a d^{n}\) の形のモデルを書きなさい。
(c) 天王星は \(d = 19.19\) です。このモデルを使って公転周期を予測しなさい。
(d) \(n\) の値が \(d\) と \(T\) の関係について何を示しているか、コメントしなさい。
(a) 両方の \(\log\) を取ります(log-log)。\(d\) と \(T\) が、どちらも \(0.2\) から \(30\) まで大きく変わるからです。
\[ \log_{10} T = 1.50\log_{10} d + 0.000114 \]
\(r = 1.000\) です。これ以上ないほど直線に近いといえます。
(b) 切片が \(0.000114\) なので、\(10^{0.000114} = 1.0003\)——ほぼ \(1\) です。
\[ T = 10^{0.000114} \times d^{1.49963} = 1.00 \times d^{1.50} \]
\[ T = d^{1.5} \]
(c) \(\log\) の世界で計算します。\(\log 19.19 = 1.28307\ldots\) なので
\[ \log T = 1.49963(1.28307) + 0.000114 = 1.92424\ldots \]
\[ T = 10^{1.92424} = 84.0 \text{ 年} \]
検算。 \(19.19^{1.5} = 19.19 \times \sqrt{19.19} = 19.19 \times 4.3806 = 84.06\) ✓ ほぼ同じです。
(d) Comment on なので、言葉で答えます。
\(n = 1.5 = \dfrac{3}{2}\) です。\(T = d^{\frac{3}{2}}\) の両辺を \(2\) 乗すると \(T^{2} = d^{3}\) になります。
試験ではこう書く
The gradient \(n = 1.50\) means that \(T\) is proportional to \(d^{1.5}\), that is, \(T = d^{\frac{3}{2}}\).
Squaring both sides gives \(T^{2} = d^{3}\): the square of the orbital period is proportional to the cube of the mean distance.
Because \(r = 1.000\), the points lie almost exactly on a straight line on the log-log graph, so a power model fits this data extremely well.
A semi-log graph of the same data gives only \(r = 0.940\), so the power model is the better of the two.
(傾き \(n = 1.50\) は、\(T\) が \(d^{1.5}\) に比例する、つまり \(T = d^{\frac{3}{2}}\) であることを示している。両辺を \(2\) 乗すると \(T^2 = d^3\) となり、公転周期の \(2\) 乗が平均距離の \(3\) 乗に比例する。\(r = 1.000\) なので log-log のグラフはほぼ完全な直線であり、累乗のモデルがこのデータに非常によく合う。同じデータの semi-log では \(r = 0.940\) にとどまるので、\(2\) つのうちでは累乗のほうがよい、という意味です。)
(a) \[\log_{10} T = 1.50\log_{10} d + 0.000114 \qquad (r = 1.000)\]
(b) \[T = 10^{0.000114}d^{1.49963} = d^{1.50}\]
(c) \[\log_{10} T = 1.49963\log_{10}(19.19) + 0.000114 = 1.92424\] \[T = 10^{1.92424} = 84.0 \text{ years}\]
(d) \(n = 1.5\) means \(T = d^{\frac{3}{2}}\), so \(T^{2} = d^{3}\): the square of the period is proportional to the cube of the distance.
8. Linearizing versus curve fitting(曲線の当てはめとの使い分け)
AHL 4.13 では、電卓に Exponential Regression や Power Regression を直接かけました。同じ答えが出るのに、なぜ \(2\) つあるのでしょうか。
| AHL 2.10(このページ) | AHL 4.13 | |
|---|---|---|
| やること | \(\log\) を取って直線にする | 電卓に曲線を当てはめさせる |
| 電卓の操作 | Linear Regression | Exponential / Power Regression |
| 見るもの | 直線の傾きと切片、\(r\) | \(a\)、\(b\)、\(R^{2}\) |
| 分かること | どの形の関係かを見分けられる | 当てはめた曲線の式 |
表 4 のとおり、AHL 2.10 の強みは、\(2\) つの候補を同じものさしで比べられることです。 semi-log と log-log は、どちらも縦軸が \(\log y\) です。ですから \(r\) を並べて比べるのが公平です。
AHL 4.13 の Exponential / Power Regression でも比べられますが、返ってくる \(R^{2}\) の出し方が機種やモデルによって違うので、比べ方に注意が要ります(AHL 4.13 の注意)。
答えの式は、ふつうよく似た値になりますが、まったく同じとはかぎりません。 対数を取ってから直線を当てはめるのは「\(\log y\) のずれ」を小さくすることで、\(y\) そのもののずれを小さくするのとは別だからです。試験でこの違いを問われることはありません。
Why it works
なぜ \(\log\) を取ると直線になるのか。 使うのは AHL 1.9 の \(2\) つの法則だけです。
\[ \log xy = \log x + \log y, \qquad \log x^{m} = m\log x \]
指数の場合を見ます。\(y = ka^{x}\) の両辺に \(\log\) をかけます。
\[ \log y = \log\left(k \cdot a^{x}\right) \]
\(1\) つ目の法則で、掛け算が足し算になります。
\[ \log y = \log k + \log a^{x} \]
\(2\) つ目の法則で、指数が前に出ます。
\[ \log y = \log k + x\log a \]
\(\log k\) も \(\log a\) も、ただの数です。 \(x\) が動いても変わりません。ですから、これは
\[ (\text{縦}) = (\text{定数}) \times (\text{横}) + (\text{定数}) \]
の形——直線の式です。
累乗の場合も同じ流れです。\(y = ax^{n}\) で
\[ \log y = \log a + \log x^{n} = \log a + n\log x \]
こちらは、右辺に \(\log x\) が残ります。だから横軸も \(\log x\) にしないと直線になりません。
\(2\) つの違いは、\(x\) が式のどこにいたかだけです。
- \(a^{x}\) … \(x\) は指数 → \(2\) つ目の法則でそのまま前に出る → 横軸は \(x\)
- \(x^{n}\) … \(x\) は底 → \(2\) つ目の法則で出るのは \(n\) のほう → \(\log x\) が残る → 横軸は \(\log x\)
逆に、直線になったという事実から、元の関係が言えます。 semi-log が直線なら、\(\log y = mx+c\) が成り立っているので、\(10\) を乗せて
\[ y = 10^{mx+c} = 10^{c}\left(10^{m}\right)^{x} \]
これは \(y = ka^{x}\) の形です。「semi-log がぴったり直線になった」=「\(y = ka^{x}\) の形である」(\(y > 0\) のとき)というのは、この計算を逆にたどっているだけです。
「指数っぽい」だけでは足りません。 \(y = 3 + 2^{x}\) のように定数が足されている式は、\(\log\) を取っても直線になりません(\(x = 0\) から \(7\) で \(r = 0.989\)——直線に見えてしまう程度には高い値です)。
Common errors
semi-log の直線が \(\log y = 0.3x + 1.8\) のとき、\(y = 0.3x + 1.8\) や \(y = 1.8 \times 0.3^{x}\) と書いてしまう誤りです。どちらも違います。 正しくは
\[ y = 10^{1.8}\left(10^{0.3}\right)^{x} = 63.1 \times 2.00^{x} \]
\(\log\) の世界の数は、\(10\) を乗せてから元の世界に持ち出します(第5節、演習 \(10\))。
\(\ln y = 0.25x + 3\) を \(y = 10^{3}\left(10^{0.25}\right)^{x}\) としてしまう誤りです。
\(\ln\) で取ったなら、\(e\) で戻します。
\[ y = e^{3}\left(e^{0.25}\right)^{x} = 20.1 \times 1.28^{x} \]
\(10^{3} = 1000\) と \(e^{3} = 20.1\) では、\(50\) 倍近く違います(第6節、演習 \(8\))。
Using your GDC (TI-Nspire CX II)
1. Log columns(\(\log\) の列の作り方)
ctrl + doc → Add Lists & Spreadsheet
\(A\) 列に \(t\)、\(B\) 列に \(N\) を入れて、いちばん上の名前の行に t と n と打ちます。
\(C\) 列の名前の下にある灰色の式の行に、
=log(b[])
と入れます。b[] は「\(B\) 列全体」という意味です。\(1\) つずつ計算する必要はありません。 \(C\) 列に \(\log N\) が並びます。
log-log なら、\(D\) 列にも同じように =log(a[]) を入れます。
名前を付けておくと、回帰の画面で選びやすくなります。logn、logt のように、中身が分かる名前にしてください。
\(4\) 桁で答えよと言われたら、表示されている値をそこから \(4\) 桁に丸めて書きます。列に入っている値そのものは丸められていませんが、画面の表示は Document Settings の Display Digits の設定で決まります。
桁が足りないと感じたら、doc → Settings → Document Settings で Display Digits を Float 6 以上にしてください。
2. Linear regression(直線回帰)
menu → Statistics → Stat Calculations → Linear Regression (mx+b)
SL 4.4 と同じ操作です。
| 欄 | semi-log のとき | log-log のとき |
|---|---|---|
X List |
\(t\) の列 | \(\log t\) の列 |
Y List |
\(\log N\) の列 | \(\log N\) の列 |
表 5 のとおりに入れると、m(傾き)、b(切片)、r が返ります。Linear Regression (a+bx) のほうを選ぶと \(a\) と \(b\) が逆になるので、気をつけてください(SL 4.4)。
3. Recovering the equation(元の式への戻し方)
ここだけは、自分でやります。 電卓は \(\log\) の世界の直線しか返しません。
Calculator ページで
- \(10^{2.07857}\)
- \(10^{0.20171}\)
と打つと、\(119.83\) と \(1.5911\) が出ます。
丸めずにやる方法もあります。回帰のあと、電卓には stat.m と stat.b という変数が残っています。
- \(10^{\texttt{stat.b}}\)
- \(10^{\texttt{stat.m}}\)
と打てば、丸めのない値がそのまま使えます(第7節)。
stat.m と stat.b は、上書きされます
回帰をもう \(1\) 回かけると、stat.m と stat.b の中身は新しいほうに入れかわります。
semi-log と log-log を両方かけたときは、使いたいほうを最後にかけ直してから \(10^{\texttt{stat.b}}\) を打ってください。
4. Comparing \(r\) values(\(r\) の比べ方)
\(r\) を使って、semi-log と log-log のどちらが直線に近いかを比べます。両方の回帰をかけて、\(r\) を比べます(\(x\) の値がすべて正のときにかぎります)。
- \(\lvert r \rvert\) が \(1\) に近いほう … そちらのほうが直線に近い。モデルの断定は、散布図の形と文脈で裏づけてからです(第4節)
- どちらも \(1\) に近い … データの範囲が狭いのかもしれません。\(r\) の差だけで決めつけないでください
演習 \(6\) のデータでは、log-log が \(1.000\)、semi-log が \(0.959\) です。差がはっきりしています。
5. Checking your answer(検算のしかた)
元の式に戻したあとは、次の方法で確かめます。
- 元の式に戻したら、データの点を \(1\) つ代入して、実際の値に近いか見る
- \(\log\) の列の差を見る。semi-log で差がほぼ一定なら、直線です
- \(r\) を \(2\) 通りとも出して、比べる
- 予測値を出したら、\(\log\) の世界の計算と、元の式の計算の両方でやって突き合わせる(例 4 の (c))
\(1\) つ目がいちばん確実です。データに戻せなければ、どこかで \(10\) の乗せ方を間違えています。
Exercises
1 The graph of \(\log_{10} y\) against \(x\) is a straight line with equation \(\log_{10} y = 0.4x + 1.2\). Find an expression for \(y\) in terms of \(x\).
日本語訳
\(\log_{10} y\) を \(x\) に対してかいたグラフが、\(\log_{10} y = 0.4x + 1.2\) という直線になります。\(y\) を \(x\) で表す式を求めなさい。
\[y = 10^{0.4x+1.2} = 10^{1.2}\left(10^{0.4}\right)^{x}\]
\[y = 15.8 \times 2.51^{x}\]
式 3 です。\(10^{1.2} = 15.8489\ldots\)、\(10^{0.4} = 2.51188\ldots\)。
\(0.4\) をそのまま底にしないでください(Common errors の \(1\) つ目)。\(0.4^{x}\) なら減っていく式になり、意味が逆になります。
検算。 \(x = 1\) を入れます。式では \(15.8489 \times 2.51188 = 39.8\)。もとの直線では \(\log y = 0.4(1)+1.2 = 1.6\)、すなわち \(y = 10^{1.6} = 39.8\) ✓
\(x = 0\) で確かめても足りません。 \(x = 0\) では底が何であっても \(15.8489\) になるので、\(0.4^{x}\) と書く誤りを見つけられないからです。
2 For \(x > 0\), the graph of \(\log_{10} y\) against \(\log_{10} x\) is a straight line with equation \(\log_{10} y = 2\log_{10} x - 0.5\). Find an expression for \(y\) in terms of \(x\).
日本語訳
\(\log_{10} y\) を \(\log_{10} x\) に対してかいたグラフが、\(\log_{10} y = 2\log_{10} x - 0.5\) という直線になります。\(y\) を \(x\) で表す式を求めなさい。
\[\log_{10} y = \log_{10} x^{2} - 0.5\]
\[y = 10^{-0.5}x^{2} = 0.316x^{2}\]
log-log なので、傾きがそのまま指数です(表 1)。\(n = 2\)。
切片のほうだけ \(10\) を乗せます。\(10^{-0.5} = \dfrac{1}{\sqrt{10}} = 0.31623\ldots\)。
マイナスの切片でも、やることは同じです。\(10^{-0.5}\) は \(1\) より小さい数になります。
検算。 \(x = 10\) を入れます。式では \(0.31623 \times 100 = 31.623\)。直線では \(\log y = 2(1) - 0.5 = 1.5\) すなわち \(y = 10^{1.5} = 31.623\) ✓
3 For the relationship \(y = 7 \times 4^{x}\), state which of a log-log graph or a semi-log graph would give a straight line, and write down the gradient of that line.
日本語訳
関係 \(y = 7 \times 4^{x}\) について、log-log と semi-log のどちらのグラフが直線になるかを述べ、その直線の傾きを書きなさい。
A semi-log graph (\(\log_{10} y\) against \(x\)) gives a straight line.
\[\log_{10} y = \log_{10} 7 + x\log_{10} 4\]
The gradient is \(\log_{10} 4 = 0.602\).
\(x\) が指数の位置にいるので semi-log です(第4節)。
傾きは \(\log 4 = 0.60206\ldots\)。\(4\) ではありません。
\(\log\) を取った式を \(1\) 行書いておくと、傾きと切片がそのまま読めます。
検算。 \(x = 0\) と \(x = 1\) で確かめます。\(y\) は \(7\) から \(28\) になり、\(\log y\) は \(0.8451\) から \(1.4472\)。差は \(0.6021\) ✓ 傾きと一致しました。
4 For the relationship \(y = 6x^{-2}\), where \(x > 0\), state which of a log-log graph or a semi-log graph would give a straight line, and write down the gradient of that line.
日本語訳
関係 \(y = 6x^{-2}\) について、log-log と semi-log のどちらのグラフが直線になるかを述べ、その直線の傾きを書きなさい。
A log-log graph (\(\log_{10} y\) against \(\log_{10} x\)) gives a straight line.
\[\log_{10} y = \log_{10} 6 - 2\log_{10} x\]
The gradient is \(-2\).
\(x\) が底の位置にいるので log-log です。
傾きは指数そのもので、\(-2\)。負の指数でも同じです。\(10\) を乗せる必要はありません。
傾きが負なので、右下がりの直線になります。\(x\) が増えると \(y\) は減るからです。
検算。 \(x = 1\) で \(y = 6\)、\(x = 10\) で \(y = 0.06\)。\(\log y\) は \(0.7782\) から \(-1.2218\) で、\(\log x\) が \(0\) から \(1\) に増えるあいだに \(-2\) 変わっています ✓
5 The graph of \(\log_{10} y\) against \(x\) is a straight line passing through the points \((2,\ 1.5)\) and \((8,\ 3.3)\). Find an expression for \(y\) in terms of \(x\).
日本語訳
\(\log_{10} y\) を \(x\) に対してかいたグラフが、点 \((2,\ 1.5)\) と \((8,\ 3.3)\) を通る直線になります。\(y\) を \(x\) で表す式を求めなさい。
\[m = \frac{3.3-1.5}{8-2} = \frac{1.8}{6} = 0.3\]
\[1.5 = 0.3(2) + c \ \Rightarrow \ c = 0.9\]
\[\log_{10} y = 0.3x + 0.9 \ \Rightarrow \ y = 10^{0.9}\left(10^{0.3}\right)^{x} = 7.94 \times 2.00^{x}\]
まずふつうの直線の問題として傾きと切片を出します(SL 2.1)。
与えられた点の縦座標は \(\log y\) の値です。\((2,\ 1.5)\) は「\(x = 2\) のとき \(y = 10^{1.5} = 31.6\)」という意味であって、「\(y = 1.5\)」ではありません。
\(10^{0.9} = 7.94328\ldots\)、\(10^{0.3} = 1.99526\ldots\)。\(2\) 倍にとても近いので、\(2\) 倍ずつ増えるモデルだと読めます。
検算。 \(x = 8\) を入れます。直線では \(\log y = 0.3(8)+0.9 = 3.3\) すなわち \(y = 10^{3.3} = 1995.3\)。式では \(10^{0.9}\left(10^{0.3}\right)^{8} = 10^{3.3}\) で、同じ値です ✓
6 The table shows four data points, together with \(\log_{10} x\) and \(\log_{10} y\).
| \(x\) | \(1\) | \(2\) | \(4\) | \(8\) |
|---|---|---|---|---|
| \(y\) | \(3.00\) | \(16.97\) | \(96.0\) | \(543.06\) |
| \(\log_{10} x\) | \(0\) | \(0.3010\) | \(0.6021\) | \(0.9031\) |
| \(\log_{10} y\) | \(0.4771\) | \(1.2297\) | \(1.9823\) | \(2.7348\) |
(a) State, with a reason, whether the data fit an exponential relationship or a power relationship.
(b) Find a model for \(y\) in terms of \(x\).
日本語訳
表は \(4\) 組のデータと、\(\log_{10} x\)、\(\log_{10} y\) の値を示しています。
(a) データが exponential の関係と power の関係のどちらに合うかを、理由とともに述べなさい。
(b) \(y\) を \(x\) で表すモデルを求めなさい。
(a) A power relationship. The values of \(\log_{10} x\) increase by \(0.3010\) each time, and the values of \(\log_{10} y\) increase by about \(0.7526\) each time, so \(\log_{10} y\) against \(\log_{10} x\) is a straight line (\(r = 1.000\)). Against \(x\) itself the increases are not constant, so the semi-log graph is not straight (\(r = 0.959\)).
(b) \[m = \frac{0.7526}{0.3010} = 2.5, \qquad c = 0.4771\]
\[y = 10^{0.4771}x^{2.5} = 3.00\,x^{2.5}\]
(a) with a reason なので、なぜそう言えるかを書きます。
表は \(x\) が \(2\) 倍ずつ(\(1, 2, 4, 8\))なので、\(\log x\) は等間隔です。その上で \(\log y\) も等間隔なら、log-log が直線です。
\[2.7348 - 1.9823 = 0.7525, \qquad 1.9823 - 1.2297 = 0.7526\]
いっぽう \(x\) そのものは \(1, 2, 4, 8\) と等間隔ではありません。同じ \(\log y\) の増え方に対して \(x\) の増え方が変わるので、semi-log は直線になりません。
(b) 傾きは、\(\log y\) の増分を \(\log x\) の増分で割った値です。切片は \(\log x = 0\) のときの \(\log y\)、つまり \(0.4771\)。
\(10^{0.4771} = 3.0000\) です。
検算。 \(x = 4\) を入れます。\(3 \times 4^{2.5} = 3 \times 32 = 96\) ✓ 表と一致しました(\(4^{2.5} = 4^{2}\sqrt{4} = 32\))。
試験ではこう書く
A power relationship.
The values of \(\log_{10} x\) go up in equal steps of \(0.3010\), and the values of \(\log_{10} y\) go up in equal steps of about \(0.7526\), so the graph of \(\log_{10} y\) against \(\log_{10} x\) is a straight line, with \(r = 1.000\).
Plotted against \(x\) itself the points are not evenly spaced, so the semi-log graph is not straight and \(r\) is only \(0.959\).
A straight log-log graph means a relationship of the form \(y = ax^{n}\).
7 A news article shows a graph of the number of users of an app each month. The vertical axis is labelled \(\log_{10}(\text{users})\), and the plotted points lie close to a straight line with a positive gradient. Interpret what this tells you about the growth of the app.
日本語訳
あるニュース記事に、アプリの月ごとの利用者数のグラフが載っています。縦軸には \(\log_{10}(\text{利用者数})\) と書かれており、点はほぼ、傾きが正の直線の上に並んでいます。これがアプリの成長について何を示しているかを解釈しなさい。
Because \(\log_{10}\) of the number of users is plotted against time and the points lie close to a straight line, the growth is approximately exponential: the number of users is multiplied by roughly the same factor each month.
A straight line here does not mean that the same number of users is added each month. The gradient \(m\) gives the monthly multiplier \(10^{m}\), so the number added each month is itself growing.
Interpret なので、文脈の言葉で答えます。言うべきことは \(2\) つです。
- 縦が \(\log\) で直線 → exponential な増え方(第2節)
- 直線でも、毎月同じ人数が増えるという意味ではない(Common errors の \(5\) つ目)
\(2\) つ目まで書けると、しっかりした答案になります。 対数目盛りのグラフを「ふつうのグラフ」として読んでしまうのが、この項目のいちばんの落とし穴です。
数そのものは驚くほど大きく見えても、増える割合は落ち着いていることがあります。対数目盛りのグラフは、それを読み取るためのものです。
試験ではこう書く
Plotting \(\log_{10}\) of the number of users against time and obtaining points close to a straight line means the relationship is approximately exponential: the number of users is multiplied by a fixed factor \(10^{m}\) each month, where \(m\) is the gradient.
The growth rate is constant, but the number of new users added each month keeps increasing, so a straight line on this graph does not mean steady, linear growth.
8 A student takes natural logarithms of some data and finds that \(\ln y = 0.25x + 3\). Find an expression for \(y\) in terms of \(x\).
日本語訳
ある生徒がデータの自然対数を取り、\(\ln y = 0.25x + 3\) となることを見つけました。\(y\) を \(x\) で表す式を求めなさい。
\[y = e^{0.25x+3} = e^{3}\left(e^{0.25}\right)^{x}\]
\[y = 20.1 \times 1.28^{x}\]
\(\ln\) で取ったので、\(e\) で戻します(第6節)。\(10\) ではありません。
\(e^{3} = 20.0855\ldots\)、\(e^{0.25} = 1.28403\ldots\)。
\(y = 20.1e^{0.25x}\) と書いても正しい答えです。\(e^{0.25x} = \left(e^{0.25}\right)^{x}\) だからです。AHL 2.9a の \(M_0e^{kt}\) の形になります。
検算。 \(x = 4\) を入れます。\(e^{3}e^{1} = e^{4} = 54.598\)。式では \(20.0855 \times 1.28403^{4} = 54.598\) ✓
もし \(10\) で戻していたら \(10^{3} = 1000\) から始まり、\(50\) 倍近くずれます(Common errors の \(2\) つ目)。
9 For a group of animals, the graph of \(\log_{10} B\) against \(\log_{10} M\) is a straight line with gradient \(0.75\) and intercept \(0.85\), where \(M\) is body mass and \(B\) is metabolic rate.
(a) Find a model for \(B\) in terms of \(M\).
(b) Interpret the value of the gradient in this context.
日本語訳
ある動物のグループについて、\(\log_{10} B\) を \(\log_{10} M\) に対してかいたグラフが、傾き \(0.75\)、切片 \(0.85\) の直線になります。ここで \(M\) は体重、\(B\) は代謝速度です。
(a) \(B\) を \(M\) で表すモデルを求めなさい。
(b) この文脈で、傾きの値を解釈しなさい。
(a) \[\log_{10} B = 0.75\log_{10} M + 0.85\]
\[B = 10^{0.85}M^{0.75} = 7.08\,M^{0.75}\]
(b) The gradient \(0.75\) is the power of \(M\) in the model: metabolic rate is proportional to \(M^{0.75}\). Since \(0.75 < 1\), doubling the body mass multiplies the metabolic rate by \(2^{0.75} = 1.68\), not by \(2\): a heavier animal uses more energy in total, but less per unit of mass.
(a) log-log なので、傾きがそのまま指数です。\(10^{0.85} = 7.07946\ldots\)。
(b) Interpret なので、文脈の言葉で答えます。
\(0.75\) という指数の意味を、数を \(1\) つ出して説明すると伝わります。\(M\) を \(2\) 倍にすると、\(B\) は \(2^{0.75} = 1.68\) 倍になります。\(2\) 倍ではありません。 \(0.75 < 1\) なので、体重ほどには代謝が増えない、ということです。
試験ではこう書く
The gradient of a log-log graph is the power in the model, so \(B\) is proportional to \(M^{0.75}\).
Because \(0.75\) is less than \(1\), metabolic rate grows more slowly than body mass: doubling the mass multiplies \(B\) by \(2^{0.75} = 1.68\) rather than by \(2\).
A larger animal therefore uses more energy in total but less energy per kilogram than a smaller one.
10 A student is given a semi-log graph of \(\log_{10} y\) against \(x\), which is a straight line with gradient \(0.3\) and intercept \(1.8\). The student writes
The growth factor is \(0.3\), so the quantity is decreasing.
Identify the error and state the correct growth factor.
日本語訳
ある生徒が、\(\log_{10} y\) を \(x\) に対してかいた semi-log のグラフを渡されました。傾き \(0.3\)、切片 \(1.8\) の直線です。生徒は「growth factor は \(0.3\) なので、量は減っている」と書きました。誤りを指摘し、正しい growth factor を述べなさい。
The gradient \(0.3\) is the value of \(\log_{10} a\), not of \(a\) itself. The growth factor is
\[a = 10^{0.3} = 2.00\]
So the quantity is multiplied by about \(2\) each time \(x\) increases by \(1\): it is increasing, not decreasing. On a graph of \(\log_{10} y\) against \(x\), a positive gradient \(m\) means growth, because \(10^{m} > 1\) whenever \(m > 0\); a negative gradient would mean decay.
Identify the error なので、どこが違うかを言葉で書きます。
生徒は、\(\log\) の世界の数を、そのまま元の世界に持ち出しています(第5節)。
\(0.3 < 1\) を見て「減っている」と考えたのでしょう。しかし \(\log\) を取った世界では、\(0\) が境目です。
\[ m > 0 \ \Longrightarrow \ a = 10^{m} > 1 \ \Longrightarrow \ \text{増加} \]
\[ m < 0 \ \Longrightarrow \ a = 10^{m} < 1 \ \Longrightarrow \ \text{減少} \]
(縦軸が \(\log_{10} y\) のときの話です。\(\ln y\) なら \(e^{m}\) で見ます。)
傾きが正なら増加です。\(10^{0.3} = 1.9953 = 2.00\)(\(3\) s.f.)なので、\(x\) が \(1\) 増えるごとに約 \(2\) 倍です。
検算。 \(x = 0\) で \(y = 10^{1.8} = 63.1\)、\(x = 1\) で \(y = 10^{2.1} = 125.9\) ✓ たしかに約 \(2\) 倍に増えています。
試験ではこう書く
On a graph of \(\log_{10} y\) against \(x\) the gradient is \(\log_{10} a\), not \(a\).
Here \(\log_{10} a = 0.3\), so the growth factor is \(a = 10^{0.3} = 2.00\) and the quantity roughly doubles each time \(x\) increases by \(1\).
It is increasing.
With this vertical axis a quantity decreases only when the gradient is negative, since \(10^{m} < 1\) requires \(m < 0\).