A whole number
is a perfect number when it is equal to the sum of all its factors
(not including itself). The two smallest perfect numbers are 6 and
28.

6 = 1 + 2 + 3 and
28 = 1 + 2 + 4 + 7 + 14

Very few perfect numbers are known. The next three are 496, 8128
and 33 550 336

Here shows few examples of perfect numbers:

6 = 2^{1} (2^{2} - 1) = 1 + 2 + 3,

28 = 2^{2} (2^{3} - 1) = 1 + 2 + 3 + 4 + 5 + 6 + 7 = 1^{3} + 3^{3},

496 = 2^{4} (2^{5} - 1) = 1 + 2 + 3 + ... + 29 + 30 + 31 = 1^{3} + 3^{3}
+ 5^{3} + 7^{3}