Example 2-24 Decompose an integer into the sum of $1, 2, 3, \cdots, m$, allowing repetitions, and find its generating function; if $m$ appears at least once, find the generating function.
The generating function for partitioning $n$ into the sum of $1, 2, \cdots, m$, allowing repetitions, is
$$
\begin{aligned}
G_{1}(x) & =\left(1+x+x^{2}+\cdots\right)\left(1+x^{2}+x^{4}+\cdots\right) \cdots\left(1+x^{m}+x^{2 m}+\cdots\right) \\
& =\frac{1}{1-x} \frac{1}{1-x^{2}} \cdots \frac{1}{\left(1-x^{m}\right)}=\frac{1}{(1-x)\left(1-x^{2}\right) \cdots\left(1-x^{m}\right)}
\end{aligned}
$$
The generating function for partitions where $m$ appears at least once is
$$
\begin{aligned}
G_{2}(x)= & \left(1+x+x^{2}+\cdots\right)\left(1+x^{2}+x^{4}+\cdots\right) \cdots\left(x^{m}+x^{2 m}+\cdots\right) \\
= & \frac{x^{m}}{(1-x)\left(1-x^{2}\right) \cdots\left(1-x^{m}\right)} \\
= & \frac{1}{(1-x)\left(1-x^{2}\right) \cdots\left(1-x^{m-1}\right)}-\frac{x^{m}}{1-x^{m}} \\
= & \frac{1}{(1-x)\left(1-x^{2}\right) \cdots\left(1-x^{m-1}\right)}\left[\frac{1-\left(1-x^{m}\right)}{1-x^{m}}\right] \\
= & \frac{1}{(1-x)\left(1-x^{2}\right) \cdots\left(1-x^{m}\right)} \\
& -\frac{1}{(1-x)\left(1-x^{2}\right) \cdots\left(1-x^{m-1}\right)}
\end{aligned}
$$

The combinatorial meaning of the above expression is quite clear: the number of partitions of a positive integer $n$ into $1, 2, \cdots, n$ minus the number of partitions of $n$ into $1, 2, \cdots, m-1$ is the number of partitions of $n$ into $1, 2, \cdots, m$, where $m$ appears at least once.