第11章 対数関数の微分
Derivatives of Logarithmic Functions
入門
11.1 自然対数 $\ln x$ の微分
$\ln x$ は $e^x$ の逆関数なので、$x > 0$ で $e^{\ln x} = x$ が成り立つ。$\ln x$ が微分可能であることは認めて(別証で定義から確かめる)、この両辺を $x$ で微分する。
Step 1:左辺は合成関数なので、連鎖律(第8章)と $(e^u)' = e^u$(第10章)を使う。
$$\dfrac{d}{dx}e^{\ln x} = e^{\ln x} \cdot \dfrac{d}{dx}\ln x = x \cdot \dfrac{d}{dx}\ln x$$Step 2:右辺 $x$ の微分は $1$ なので:
$$x \cdot \dfrac{d}{dx}\ln x = 1$$Step 3:両辺を $x$($\gt 0$)で割る。
$$\dfrac{d}{dx}\ln x = \dfrac{1}{x}$$Step 1:対数の性質 $\ln A - \ln B = \ln\dfrac{A}{B}$ を使う。
$$= \lim_{h \to 0} \dfrac{1}{h} \ln\dfrac{x+h}{x} = \lim_{h \to 0} \dfrac{1}{h} \ln\left(1 + \dfrac{h}{x}\right)$$Step 2:$t = \dfrac{h}{x}$ とおくと、$h = tx$, $h \to 0$ で $t \to 0$
$$= \lim_{t \to 0} \dfrac{1}{tx} \ln(1 + t) = \dfrac{1}{x} \lim_{t \to 0} \dfrac{\ln(1+t)}{t}$$Step 3:第10章で示した極限 $\displaystyle \lim_{t \to 0} \dfrac{\ln(1+t)}{t} = 1$ より:
$$= \dfrac{1}{x} \cdot 1 = \dfrac{1}{x}$$11.2 一般の対数関数 $\log_a x$ の微分
$a > 0$, $a \neq 1$ のとき:
$$\dfrac{d}{dx}\log_a x = \dfrac{1}{x \ln a}$$底の変換公式 $\log_a x = \dfrac{\ln x}{\ln a}$ を使う。
Step 1:底を変換する。
$$\log_a x = \dfrac{\ln x}{\ln a}$$Step 2:$\dfrac{1}{\ln a}$ は定数なので:
$$\dfrac{d}{dx}\log_a x = \dfrac{1}{\ln a} \cdot \dfrac{d}{dx}\ln x$$Step 3:$\dfrac{d}{dx}\ln x = \dfrac{1}{x}$ を代入する。
$$= \dfrac{1}{\ln a} \cdot \dfrac{1}{x} = \dfrac{1}{x \ln a}$$11.3 連鎖律との組み合わせ
$g(x) > 0$ のとき:
$$\dfrac{d}{dx}\ln(g(x)) = \dfrac{g'(x)}{g(x)}$$$u = g(x)$ とおくと、$\dfrac{d}{du}\ln u = \dfrac{1}{u}$ なので、連鎖律より:
$$\dfrac{d}{dx}\ln(g(x)) = \dfrac{1}{g(x)} \cdot g'(x) = \dfrac{g'(x)}{g(x)}$$$g(x) = x^2 + 1$, $g'(x) = 2x$ より:
$$\dfrac{d}{dx}\ln(x^2 + 1) = \dfrac{2x}{x^2 + 1}$$$\sin x \gt 0$ の範囲で考える。$g(x) = \sin x$, $g'(x) = \cos x$ より:
$$\dfrac{d}{dx}\ln(\sin x) = \dfrac{\cos x}{\sin x} = \cot x$$$x > 0$ のとき:$\dfrac{d}{dx}\ln x = \dfrac{1}{x}$
$x \lt 0$ のとき:$\ln|x| = \ln(-x)$ なので、$g(x) = -x$ として上の公式を使うと
$$\dfrac{d}{dx}\ln(-x) = \dfrac{-1}{-x} = \dfrac{1}{x}$$よって、$x \neq 0$ のすべてで:
$$\dfrac{d}{dx}\ln|x| = \dfrac{1}{x}$$$g(x) = x + \sqrt{x^2 + 1}$ とおく。
$g'(x) = 1 + \dfrac{2x}{2\sqrt{x^2+1}} = 1 + \dfrac{x}{\sqrt{x^2+1}} = \dfrac{\sqrt{x^2+1} + x}{\sqrt{x^2+1}}$
分子の $\sqrt{x^2+1} + x$ は $g(x)$ そのものなので、$g'(x) = \dfrac{g(x)}{\sqrt{x^2+1}}$ である。よって:
$$\begin{aligned}\dfrac{d}{dx}\ln(x + \sqrt{x^2 + 1}) &= \dfrac{g'(x)}{g(x)} \\ &= \dfrac{1}{\sqrt{x^2+1}}\end{aligned}$$11.4 対数微分法
複雑な積・商・べき乗の微分を簡単にする強力な技法である。
$y = f(x) \gt 0$ のとき、両辺の自然対数をとって:
$$\ln y = \ln f(x)$$両辺を $x$ で微分すると:
$$\dfrac{1}{y} \cdot \dfrac{dy}{dx} = \dfrac{d}{dx}\ln f(x)$$これを $\dfrac{dy}{dx}$ について解く。$f(x)$ が負になるところでは、両辺の絶対値の対数 $\ln|y| = \ln|f(x)|$ をとれば、例3の $(\ln|x|)' = \dfrac{1}{x}$ と同じ理由で同じ式が得られる。
対数をとると、積は和に、商は差に、べき乗は係数になる($\ln(AB) = \ln A + \ln B$、$\ln\dfrac{A}{B} = \ln A - \ln B$、$\ln A^k = k\ln A$)。そのため、微分しにくい積・商・べき乗が、微分しやすい和と差に変わる。
底も指数も $x$ なので、$x^n$ の公式も $a^x$ の公式も使えない。対数微分法を使う。
Step 1:両辺の対数をとる。
$$\ln y = \ln(x^x) = x \ln x$$Step 2:両辺を $x$ で微分する。
$$\dfrac{1}{y} \cdot \dfrac{dy}{dx} = 1 \cdot \ln x + x \cdot \dfrac{1}{x} = \ln x + 1$$Step 3:$\dfrac{dy}{dx}$ を求める。
$$\dfrac{dy}{dx} = y(\ln x + 1) = x^x(\ln x + 1)$$普通に商の公式を使うと非常に複雑になる。対数微分法を使う($x \gt 1$ で考える。ほかの範囲でも、絶対値をとれば同じ結果になる)。
Step 1:両辺の対数をとる。
$$\ln y = \ln x^2 + \ln(x+1)^3 - \ln(x-1)^4$$ $$= 2\ln x + 3\ln(x+1) - 4\ln(x-1)$$Step 2:両辺を $x$ で微分する。
$$\dfrac{1}{y} \cdot \dfrac{dy}{dx} = \dfrac{2}{x} + \dfrac{3}{x+1} - \dfrac{4}{x-1}$$Step 3:$\dfrac{dy}{dx}$ を求める。
$$\dfrac{dy}{dx} = y \left(\dfrac{2}{x} + \dfrac{3}{x+1} - \dfrac{4}{x-1}\right)$$ $$= \dfrac{x^2(x+1)^3}{(x-1)^4} \left(\dfrac{2}{x} + \dfrac{3}{x+1} - \dfrac{4}{x-1}\right)$$$\sin x \gt 0$ かつ $x \gt 0$ の範囲(例えば $0 \lt x \lt \pi$)で考える。
Step 1:両辺の対数をとる。
$$\ln y = x \ln(\sin x)$$Step 2:両辺を $x$ で微分する(積の公式を使用)。
$$\dfrac{1}{y} \cdot \dfrac{dy}{dx} = 1 \cdot \ln(\sin x) + x \cdot \dfrac{\cos x}{\sin x}$$ $$= \ln(\sin x) + x \cot x$$Step 3:$\dfrac{dy}{dx}$ を求める。
$$\dfrac{dy}{dx} = (\sin x)^x \left(\ln(\sin x) + x \cot x\right)$$11.5 $x^{\alpha}$(一般べき)の証明
第5章で $x^\alpha$ の微分公式を紹介したが、$\alpha$ が整数でないときの証明はしていなかった。対数微分法を使うと、任意の実数 $\alpha$ について証明できる。
任意の実数 $\alpha$ に対して($x > 0$):
$$\dfrac{d}{dx}x^\alpha = \alpha x^{\alpha - 1}$$$y = x^\alpha$ とおく。
Step 1:両辺の対数をとる。
$$\ln y = \alpha \ln x$$Step 2:両辺を $x$ で微分する。
$$\dfrac{1}{y} \cdot \dfrac{dy}{dx} = \alpha \cdot \dfrac{1}{x}$$Step 3:$\dfrac{dy}{dx}$ を求める。
$$\dfrac{dy}{dx} = y \cdot \dfrac{\alpha}{x} = x^\alpha \cdot \dfrac{\alpha}{x} = \alpha x^{\alpha - 1}$$11.6 対数関数の微分公式まとめ
| 関数 | 導関数 |
|---|---|
| $\ln x$ | $\dfrac{1}{x}$($x \gt 0$) |
| $\ln|x|$ | $\dfrac{1}{x}$($x \neq 0$) |
| $\ln(g(x))$ | $\dfrac{g'(x)}{g(x)}$($g(x) \gt 0$) |
| $\log_a x$ | $\dfrac{1}{x \ln a}$ |
| $\log_a(g(x))$ | $\dfrac{g'(x)}{g(x) \ln a}$($g(x) \gt 0$) |
- $x^{f(x)}$ のような形(底と指数の両方が変数)
- 多数の因数の積・商
- 複雑なべき乗の組み合わせ
よくある質問
$(\ln x)' = \dfrac{1}{x}$ はなぜ成立するのか
$y = \ln x$ を $e^y = x$ と書き直し、両辺を $x$ で微分すると $e^y \cdot y' = 1$ となる。$y' = \dfrac{1}{e^y} = \dfrac{1}{x}$ が得られる。別の方法として微分の定義から $\lim_{h \to 0}\dfrac{\ln(x+h) - \ln x}{h}$ を変形しても導ける。
$(\log_a x)' = \dfrac{1}{x \ln a}$ の形を覚えるコツは?
$\log_a x = \dfrac{\ln x}{\ln a}$ と変換すると、$\ln a$ は定数なので $(\ln x)' = \dfrac{1}{x}$ を $\ln a$ で割るだけである。$a = e$ なら $\ln e = 1$ となり $(\ln x)' = \dfrac{1}{x}$ に一致する。
対数微分法とはどういう手法か
両辺の自然対数をとってから微分する手法である。例えば $y = x^x$ の微分は $\ln y = x \ln x$ として両辺を $x$ で微分し $\dfrac{y'}{y} = \ln x + 1$ を得て $y' = x^x(\ln x + 1)$ となる。べき乗や積・商の複雑な関数に有効である。
練習問題
次の関数を、対数の中が正になる範囲で微分せよ。
- $\ln(3x)$
- $\ln(x^2 - 1)$
- $\ln(\cos x)$
- $\log_2 x$
対数微分法を使って次の関数を微分せよ(1 と 3 は $x \gt 0$ で考える)。
- $y = x^{\sin x}$
- $y = (x^2 + 1)^x$
- $y = \dfrac{x(x+1)}{(x+2)(x+3)}$
$f(x) = x \ln x$($x \gt 0$)について:
- $f'(x)$ を求めよ。
- $f'(x) = 0$ となる $x$ を求めよ。
- $f(x)$ の極値を求めよ。
解答を見る
練習1の解答
- $\dfrac{3}{3x} = \dfrac{1}{x}$
- $\dfrac{2x}{x^2-1}$
- $\dfrac{-\sin x}{\cos x} = -\tan x$
- $\dfrac{1}{x \ln 2}$
練習2の解答
- $\ln y = \sin x \cdot \ln x$
$\dfrac{y'}{y} = \cos x \cdot \ln x + \sin x \cdot \dfrac{1}{x}$
$y' = x^{\sin x}\left(\cos x \ln x + \dfrac{\sin x}{x}\right)$ - $\ln y = x \ln(x^2+1)$
$\dfrac{y'}{y} = \ln(x^2+1) + x \cdot \dfrac{2x}{x^2+1}$
$y' = (x^2+1)^x\left(\ln(x^2+1) + \dfrac{2x^2}{x^2+1}\right)$ - $\ln y = \ln x + \ln(x+1) - \ln(x+2) - \ln(x+3)$
$\dfrac{y'}{y} = \dfrac{1}{x} + \dfrac{1}{x+1} - \dfrac{1}{x+2} - \dfrac{1}{x+3}$
$y' = \dfrac{x(x+1)}{(x+2)(x+3)}\left(\dfrac{1}{x} + \dfrac{1}{x+1} - \dfrac{1}{x+2} - \dfrac{1}{x+3}\right)$
練習3の解答
- $f'(x) = 1 \cdot \ln x + x \cdot \dfrac{1}{x} = \ln x + 1$
- $f'(x) = 0 \Leftrightarrow \ln x = -1 \Leftrightarrow x = e^{-1} = \dfrac{1}{e}$
- $0 \lt x \lt \dfrac{1}{e}$ で $f'(x) \lt 0$(減少)、$x \gt \dfrac{1}{e}$ で $f'(x) \gt 0$(増加)
よって $x = \dfrac{1}{e}$ で極小
極小値:$f\left(\dfrac{1}{e}\right) = \dfrac{1}{e} \ln\dfrac{1}{e} = \dfrac{1}{e} \cdot (-1) = -\dfrac{1}{e}$