跳转至

小数部分的周期性

本节再来拆解一道取整函数经典题!这道题的命题核心围绕小数部分函数 \(\{\cdot\}\) 的周期性展开。我准备了两种解法:一种是使用分段拆区间的常规做法;另一个直接利用黎曼 - 勒贝格引理(\(\mathrm{Riemann-Lebesgue \;Lemma}\)),直接一步秒杀。

例题

Example

求解:

\[ \displaystyle\lim_{n\to\infty} \int_0^{+\infty} \mathrm{e}^{-x} (nx - [nx]) \mathrm{d}x \]

其中 \([x]\) 表示不超过 \(x\) 的最大整数。

方法一:拆区间

首先考虑做换元 \(u = nx\) ,通过这个换元,我们可以把取整函数里讨厌的系数 \(n\) 摘出去,让它回归最自然的整数分段。从而避免拆分区间后积分上下限带有分式。

\[ \begin{aligned} I &= \lim_{n\to\infty} \int_0^{+\infty} \mathrm{e}^{-\frac{u}{n}} (u - [u]) \frac{1}{n} \mathrm{d}u \\ &= \lim_{n\to\infty} \frac{1}{n} \int_0^{+\infty} \mathrm{e}^{-\frac{u}{n}} \{u\} \mathrm{d}u \end{aligned} \]

现在,取整函数 \([u]\) 的跳跃点全变成了最自然的整数。按照常规套路,我们将 \([0, +\infty)\) 拆分为无限个区间 \([k, k+1)\)(其中 \(k = 0, 1, 2, \dots\)):

当 \(u \in [k, k+1)\) 时,\([u] = k\),所以 \(\{u\} = u - k\)。积分式转化为无穷级数:

\[ I = \lim_{n\to\infty} \frac{1}{n} \sum_{k=0}^{+\infty} \int_{k}^{k+1} \mathrm{e}^{-\frac{u}{n}} (u - k) \mathrm{d}u \]

接下来计算单项子区间的定积分:为了计算方便,令 \(t = u - k\),则 \(\mathrm{d}u = \mathrm{d}t\),且 \(u = t + k\)。

代入该项积分:

\[ \begin{aligned} \int_{k}^{k+1} \mathrm{e}^{-\frac{u}{n}} (u - k) \mathrm{d}u &= \int_0^1 \mathrm{e}^{-\frac{t+k}{n}} \cdot t \cdot \mathrm{d}t \\ &= \mathrm{e}^{-\frac{k}{n}} \int_0^1 \mathrm{e}^{-\frac{t}{n}} \cdot t \,\mathrm{d}t \end{aligned} \]

看!通过这个换元我们成功把关于 \(k\) 的指数项 \(\mathrm{e}^{-\frac{k}{n}}\) 当作常数提到了积分外面!

现在我们用分部积分法(可用表格法加速)计算剩下这个与 \(k\) 无关的积分 \(\displaystyle\int_0^1 \mathrm{e}^{-\frac{t}{n}} \cdot t \,\mathrm{d}t\):

\[ \begin{aligned} \int_0^1 t \,\mathrm{d}\left( -n\mathrm{e}^{-\frac{t}{n}} \right) &= \left[ -nt\mathrm{e}^{-\frac{t}{n}} \right]_0^1 - \int_0^1 \left( -n\mathrm{e}^{-\frac{t}{n}} \right) \mathrm{d}t\\ &= -n\mathrm{e}^{-\frac{1}{n}} + n \left[ -n\mathrm{e}^{-\frac{t}{n}} \right]_0^1 \\&= -n\mathrm{e}^{-\frac{1}{n}} - n^2 \left( \mathrm{e}^{-\frac{1}{n}} - 1 \right)\\ &= n^2 - (n^2+n)\mathrm{e}^{-\frac{1}{n}} \end{aligned} \]

我们将这个积分结果记为常数 \(A_n = n^2 - (n^2+n)\mathrm{e}^{-\frac{1}{n}}\)。

带回得:

\[ I = \lim_{n\to\infty} \frac{1}{n} \sum_{k=0}^{+\infty} \left( \mathrm{e}^{-\frac{k}{n}} \cdot A_n \right) = \lim_{n\to\infty} \frac{A_n}{n} \sum_{k=0}^{+\infty} \left(\mathrm{e}^{-\frac{1}{n}}\right)^k \]

后面的求和是一个公比为 \(t = \mathrm{e}^{-\frac{1}{n}}\) 的等比级数。利用公式 \(\displaystyle\sum_{k=0}^{+\infty} t^k = \frac{1}{1-t}\):

\[ \sum_{k=0}^{+\infty} \left(\mathrm{e}^{-\frac{1}{n}}\right)^k = \frac{1}{1 - \mathrm{e}^{-\frac{1}{n}}} \]

代入得:

\[ I = \lim_{n\to\infty} \frac{n^2 - (n^2+n)\mathrm{e}^{-\frac{1}{n}}}{n\left(1 - \mathrm{e}^{-\frac{1}{n}}\right)} = \lim_{n\to\infty} \frac{n - (n+1)\mathrm{e}^{-\frac{1}{n}}}{1 - \mathrm{e}^{-\frac{1}{n}}} \]

接下来处理这个极限问题,考虑分子分母同乘以 \(\mathrm{e}^{\frac{1}{n}}\):

\[ I = \lim_{n\to\infty} \frac{n\mathrm{e}^{\frac{1}{n}} - (n+1)}{\mathrm{e}^{\frac{1}{n}} - 1} \]

令 \(h = \dfrac{1}{n}\),当 \(n \to \infty\) 时,\(h \to 0^+\)。式子化为:

\[ I = \lim_{h\to0^+} \frac{h^{-1}\mathrm{e}^h - (h^{-1}+1)}{\mathrm{e}^h - 1} = \lim_{h\to0^+} \frac{\mathrm{e}^h - (1+h)}{h(\mathrm{e}^h - 1)} \]

利用 \(\mathrm{Taylor}\) 展开,当 \(h \to 0\) 时,\(\mathrm{e}^h - 1 \sim h\),且 \(\displaystyle\mathrm{e}^h = 1 + h + \dfrac{1}{2}h^2 + o(h^2)\):

\[ \begin{aligned} I &= \lim_{h\to0^+} \frac{\left(1 + h + \frac{1}{2}h^2\right) - (1+h)}{h^2} \\ &= \lim_{h\to0^+} \frac{\dfrac{1}{2}h^2}{h^2} \\ &= \frac{1}{2} \end{aligned} \]

方法二:Riemann-Lebesgue

事实上,在 结合积分中值定理 一文中,我曾提及到这种方法,只不过那个题目使用 \(\mathrm{Riemann-Lebesgue \;Lemma}\) 的有限区间形式即可,而本题需要使用到一般形式,下面一起来回顾一下这两种形式:

有限区间形式

设 \(f(x)\) 是以 \(T\) 为周期的连续(或分段连续)周期函数, \(g(x)\) 在 \([a, b]\) 上可积,则:

\[ \lim_{n \to \infty} \int_a^b g(x) f(nx) \,\mathrm{d}x = \left( \frac{1}{T} \int_0^T f(x) \,\mathrm{d}x \right) \cdot \int_a^b g(x) \,\mathrm{d}x \]

无穷区间形式

若函数 \(g\) 在 \([0,+\infty]\) 上被有界变差函数有界变差函数控制,函数 \(f\) 可积且最小正周期为 \(T\),则:

\[ \lim_{n \to \infty} \int_0^{+\infty} g(x) f(nx) \,\mathrm{d}x = \left( \frac{1}{T} \int_0^T f(x) \,\mathrm{d}x \right) \cdot \int_0^{+\infty} g(x) \,\mathrm{d}x \]

本题中:

  • \(g(x) = \mathrm{e}^{-x}\)
  • \(f(x) = \{x\} = x - [x]\),它的周期 \(T = 1\)。

如果不理解小数部分函数周期性的话可以参考下面这张图片:

alt text

首先计算平均值:

\[ M = \frac{1}{1} \int_0^1 \{x\} \,\mathrm{d}x = \int_0^1 x \,\mathrm{d}x = \left[ \frac{1}{2}x^2 \right]_0^1 = \frac{1}{2} \]

根据上述定理,当 \(n \to \infty\) 时,被积函数中的 \(\{nx\}\) 可以直接等价替换为其平均值 \(\dfrac{1}{2}\):

\[ \lim_{n \to \infty} \int_0^{+\infty} \mathrm{e}^{-x} \{nx\} \,\mathrm{d}x = \int_0^{+\infty} \mathrm{e}^{-x} \cdot \left( \frac{1}{2} \right) \,\mathrm{d}x \]

把常数 \(\dfrac{1}{2}\) 提出来:

\[ \begin{aligned} I &= \frac{1}{2} \int_0^{+\infty} \mathrm{e}^{-x} \,\mathrm{d}x \\ &= \frac{1}{2} \Big[ -\mathrm{e}^{-x} \Big]_0^{+\infty} \\ &= \frac{1}{2} (0 - (-1)) \\ &= \frac{1}{2} \end{aligned} \]

通过上面两种方法,相信大家对于取整函数和取小数函数有了更深刻的理解,尤其是对于本题所涉及到的周期性!

  • 更多精彩内容欢迎关注我的微信公众号!

搜一搜

评论区