Solution 0b3efc05-933f-4dc1-92f1-9a8dece2d3e1
Points: 2 pts
Lemma 1: Every divisor has the form $p_1^{b_1}p_2^{b_2}\cdots p_r^{b_r}$.
Every divisor $d\in\operatorname{div}(n)$ has the form
\[
d=p_1^{b_1}p_2^{b_2}\cdots p_r^{b_r},
\qquad 0\leq b_i\leq a_i.
\]
We showed this in a previous problem.
Lemma 2: The proposed product generates all terms.
Consider
\[
(1+p_1+\cdots+p_1^{a_1})
(1+p_2+\cdots+p_2^{a_2})
\cdots
(1+p_r+\cdots+p_r^{a_r}).
\]
Choose $p_1^{b_1}$ from the first factor, and then continue choosing $p_i^{b_i}$ from each following factor for the divisor we want. The resulting term is
\[
p_1^{b_1}p_2^{b_2}\cdots p_r^{b_r}.
\]
By Lemma 1, these are exactly the elements of $\operatorname{div}(n)$. Therefore, expanding the product and adding all of its terms gives the sum of all divisors of $n$.
Final answer:
D=(1+p_1+\cdots+p_1^{a_1})(1+p_2+\cdots+p_2^{a_2})\cdots(1+p_r+\cdots+p_r^{a_r})