OFFSET
1,3
COMMENTS
Are there any other numbers besides n=12 for which n=a(n) ? - Ctibor O. Zizka, Oct 08 2008
The sequence is a morphism from (N*,*) into (N,+), cf. formula. Up to n=1023, the digit sum A007953(a(n)) equals Omega(n) = A001222(n). This holds whenever A051903(n)<10. Restricted to these n, the sequence is also injective. However, when n is a multiple of 2^10, 3^10, 5^10 etc, then a(n) is equal to some a(m) with m<n. - M. F. Hasler, Nov 16 2008
This has been called the "Exponential Prime Power Representation" of n by W. Nissen in a post to the sci.math newsgroup (where probably some more sophisticated convention for representing digits > 10 would be used). - M. F. Hasler, Jul 03 2016
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000 (n=1..1023 from Michael De Vlieger)
Evans A Criswell, A Sequence Puzzle (Posted to rec.puzzles Jan 01 1997)
Walter Nissen, Exponential Prime Power Representation, sci.math newsgroup, May 23 1995.
FORMULA
a(m*n) = a(m) + a(n) for all m,n > 0. A007953(a(n))=A001222(n) for all n such that A051903(n) < 10. - M. F. Hasler, Nov 16 2008
a(n) = sum(10^(A049084(A027748(k))-1) * A124010(k): k = 1..A001221(n)). - Reinhard Zumkeller, Aug 03 2015
a(A054842(n)) = n for all n >= 0. - Antti Karttunen, Aug 29 2016
a(n) = Sum_{i>0} e_i*10^(i-1) when n = Product_{i>0} prime(i)^e_i. - M. F. Hasler, Mar 14 2018
EXAMPLE
a(25) = 200 because 25 = 5^2 * 3^0 * 2^0.
a(1024) = 10 = a(3), because 1024 = 2^10; but this two-digit multiplicity overflows into the 10^1 position, which encodes for powers of three.
MAPLE
A:= n -> add(t[2]*10^(numtheory:-pi(t[1])-1), t= ifactors(n)[2]);
seq(A(n), n=1..1000); # Robert Israel, Jul 24 2014
MATHEMATICA
a054841[n_Integer] := Catch[FromDigits[IntegerDigits[Apply[Plus,
Which[n == 0, Throw["undefined"],
n == 1, 0,
Max[Last /@ FactorInteger @ n] > 9, Throw["overflow"],
True, Power[10, PrimePi[Abs[#]] - 1]] & /@
Flatten[ConstantArray @@@ FactorInteger[n]]]]]] (* Michael De Vlieger, Jul 24 2014 *)
PROG
(PARI) A054841(n)=sum(i=1, #n=factor(n)~, 10^primepi(n[1, i])*n[2, i])/10 \\ M. F. Hasler, Nov 16 2008
(Haskell)
a054841 1 = 0
a054841 n = sum $ zipWith (*)
(map ((10 ^) . subtract 1 . a049084) $ a027748_row n)
(map fromIntegral $ a124010_row n)
-- Reinhard Zumkeller, Aug 03 2015
(Python)
from sympy import factorint, primepi
def a(n): return sum(e*10**(primepi(p)-1) for p, e in factorint(n).items())
print([a(n) for n in range(1, 41)]) # Michael S. Branicky, Mar 17 2024
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Henry Bottomley, Apr 11 2000
STATUS
approved