OFFSET
1,2
COMMENTS
The number of geometric-progression subsequences of [1,...,n] with integral successive-term ratio r and length k is floor(n/r^(k-1))(n > 0, r > 1, k > 0).
FORMULA
a(n) = n + sum {r > 1, j > 0} floor(n/r^j)
EXAMPLE
a(1): [1]; a(2): [1],[2],[1,2]; a(3): [1],[2],[3],[1,2],[1,3]
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Robert E. Sawyer (rs.1(AT)mindspring.com), Jan 08, 2003
STATUS
approved