OFFSET
2,1
COMMENTS
The term a(10) = 8 belongs to A070276.
For any n > 1, a(n^2) <= n.
Is this sequence defined for any n > 1 ?
Apparently, a(k) < k for any odd k > 3.
Among the first 99 999 terms, the digital sum of a(n) in base n is > n for n = 2, 12, 20, 30.
The scatterplot of the sequence shows beams on the upper part, which correspond to clusters of close points for which a(n) = k*n + (n-k-e) for some k > 0 and e in { 0, 2 }.
See also A292787 for a similar sequence involving squares instead of cubes.
The least positive k, not a power of 2, such that the hamming weight of k equals the hamming weight of k^4 is 34225258495.
LINKS
Rémy Sigrist, Table of n, a(n) for n = 2..10000
Rémy Sigrist, Colorized scatterplot of the sequence for n=2..100000
EXAMPLE
For n = 3:
- let d_3 denote the digital sum in base 3 (d_3 = A053735),
- 1 is a power of 3,
- d_3(2) = 2 and d_3(2^3) = 4,
- 3 is a power of 3,
- d_3(4) = 2 and d_3(4^3) = 4,
- d_3(5) = 3 and d_3(5^3) = 7,
- d_3(6) = 2 and d_3(6^3) = 4,
- d_3(7) = 3 and d_3(7^3) = 5,
- d_3(8) = 4 and d_3(8^3) = 8,
- 9 is a power of 3,
- d_3(10) = 2 and d_3(10^3) = 4,
- d_3(11) = 3 and d_3(11^3) = 9,
- d_3(12) = 2 and d_3(12^3) = 4,
- d_3(13) = 3 and d_3(13^3) = 3,
- hence a(3) = 13.
MATHEMATICA
With[{kk = 10^5}, Table[SelectFirst[Complement[Range[2, kk], n^Range@ Floor@ Log[n, kk]], Total@ IntegerDigits[#, n] == Total@ IntegerDigits[#^3, n] &] /. k_ /; MissingQ@ k -> -1, {n, 2, 68}]] (* Michael De Vlieger, Sep 24 2017 *)
PROG
(PARI) a(n) = my (p=1); for (k=1, oo, if (k==p, p*=n, if (sumdigits(k, n) == sumdigits(k^3, n), return (k))))
CROSSREFS
KEYWORD
AUTHOR
Rémy Sigrist, Sep 23 2017
STATUS
approved