A247012
Consider the aliquot parts, in ascending order, of a composite number. Take their sum and repeat the process deleting the minimum number and adding the previous sum. The sequence lists the numbers that after some iterations reach a sum equal to the reverse of themselves.
Original entry on oeis.org
6, 133, 172, 841, 1005, 1603, 4258, 5299, 192901, 498906, 1633303, 5307589, 16333303, 20671542, 41673714, 42999958, 73687923
Offset: 1
Aliquot parts of 1005 are 1, 3, 5, 15, 67, 201 and 335:
1 + 3 + 5 + 15 + 67 + 201 + 335 = 627;
3 + 5 + 15 + 67 + 201 + 335 + 627 = 1253;
5 + 15 + 67 + 201 + 335 + 627 + 1253 = 2503;
15 + 67 + 201 + 335 + 627 + 1253 + 2503 = 5001 that is the reverse of 1005.
Aliquot parts of 1603 are 1, 7 and 229:
1 + 7 + 229 = 237;
7 + 229 + 237 = 473;
229 + 237 + 473 = 939;
237 + 473 + 939 = 1649;
473 + 939 + 1649 = 3061 that is the reverse of 1603;
-
with(numtheory): R:=proc(w) local x,y; x:=w; y:=0;
while x>0 do y:=10*y+(x mod 10); x:=trunc(x/10); od: y; end:
P:=proc(q,h) local a,b,c,k,n,t,v; v:=array(1..h);
for n from 2 to q do if not isprime(n) then
a:=sort([op(divisors(n))]); b:=nops(a)-1; c:=ilog10(n)+1;
for k from 1 to b do v[k]:=a[k]; od;
t:=b+1; v[t]:=add(v[k], k=1..b);
if R(v[t])=n then print(n); else
while ilog10(v[t])+1<=c do t:=t+1; v[t]:=add(v[k], k=t-b..t-1);
if R(v[t])=n then print(n); break; fi; od; fi; fi; od;
end: P(10^9, 1000);
-
A247012 = {};
For[n = 4, n <= 1000000, n++,
If[PrimeQ[n], Continue[]];
r = IntegerReverse[n];
a = Most[Divisors[n]];
sum = Total[a];
While[sum < r, sum = Total[a = Join[Rest[a], {sum}]]];
If[sum == r, AppendTo[A247012, n]];
]; A247012 (* Robert Price, Sep 08 2019 *)
-
from sympy import isprime, divisors
A247012_list = []
for n in range(2,10**9):
m = int(str(n)[::-1])
if not isprime(n):
x = divisors(n)
x.pop()
y = sum(x)
while y < m:
x, y = x[1:]+[y], 2*y-x[0]
if y == m:
A247012_list.append(n) # Chai Wah Wu, Sep 12 2014
A247013
Consider the prime factors, with multiplicity, in ascending order, of a composite number not ending in 0. Take their sum and repeat the process deleting the minimum number and adding the previous sum. The sequence lists the numbers that after some iterations reach a sum equal to the reverse of themselves.
Original entry on oeis.org
4, 9, 14, 94, 194, 371, 1887, 1994, 11282, 25656, 61081, 66691, 112082, 394407, 582225, 4284191, 5681778, 9317913, 9361072, 9493615, 19120874, 75519134, 92688481
Offset: 1
Prime factors of 1994 are 2 and 997;
2 + 997 = 999;
997 + 999 = 1996;
999 + 1996 = 2995;
1996 + 2995 = 4991 that is the reverse of 1994.
Prime factors of 25656 are 2^3, 3 and 1069;
2 + 2 + 2 + 3 + 1069 = 1078;
2 + 2 + 3 + 1069 + 1078 = 2154;
2 + 3 + 1069 + 1078 + 2154 = 4306;
3 + 1069 + 1078 + 2154 + 4306 = 8610;
1069 + 1078 + 2154 + 4306 + 8610 = 17217;
1078 + 2154 + 4306 + 8610 + 17217 = 33365;
2154 + 4306 + 8610 + 17217 + 33365 = 65652 that is the reverse of 25656.
-
with(numtheory): R:=proc(w) local x,y; x:=w; y:=0;
while x>0 do y:=10*y+(x mod 10); x:=trunc(x/10); od: y; end:
P:=proc(q,h) local a,b,c,d,j,k,n,t,v; v:=array(1..h);
for n from 2 to q do if not isprime(n) then a:=ifactors(n)[2];
b:=nops(a); c:=ilog10(n)+1; t:=0; d:=[];
for k from 1 to b do for j from 1 to a[k,2] do d:=[op(d),a[k,1]]; od;
od; d:=sort(d); for k from 1 to nops(d) do v[k]:=d[k]; od; a:=nops(d);
t:=a; t:=t+1; v[t]:=add(v[k],k=1..t-1); if R(v[t])=n then print(n);
else while ilog10(v[t])+1<=c do t:=t+1; v[t]:=add(v[k],k=t-a..t-1);
if R(v[t])=n then print(n); break; fi; od; fi; fi; od; end:
P(10^6, 1000);
-
A247013 = {};
For[n = 4, n <= 1000000, n++,
If[Mod[n, 10] == 0 || PrimeQ[n], Continue[]];
r = IntegerReverse[n];
a = Flatten[Map[Table[#[[1]], {#[[2]]}] &, FactorInteger[n]]];
sum = Total[a];
While[sum < r, sum = Total[a = Join[Rest[a], {sum}]]];
If[sum == r, AppendTo[A247013, n]];
]; A247013 (* Robert Price, Sep 08 2019 *)
-
from itertools import chain
from sympy import isprime, factorint
A247013_list = []
for n in range(2,10**8):
m = int(str(n)[::-1])
if n % 10 and not isprime(n):
x = sorted(chain.from_iterable([p]*e for p,e in factorint(n).items()))
y = sum(x)
while y < m:
x, y = x[1:]+[y], 2*y-x[0]
if y == m:
A247013_list.append(n) # Chai Wah Wu, Sep 12 2014
More terms and definition edited by
Chai Wah Wu, Sep 12 2014
A107099
G.f. satisfies A(A(x)) = x + 4*x^3, where A(x) = Sum_{n>=0} a(n)*x^(2*n+1).
Original entry on oeis.org
1, 2, -6, 36, -266, 2028, -13596, 50088, 566694, -16598580, 232284876, -1912070088, 631155132, 239439857272, -2781218767224, -17362458802992, 795693633448710, -458070639409908, -335724554310292548, 4520379769156382616, 109439050270732883028, -3828757746830590219608
Offset: 0
A(x) = 1*x + 2*x^3 - 6*x^5 + 36*x^7 - 266*x^9 + 2028*x^11 - 13596*x^13 +-...
-
b(n) = local(A,B,F);F=x+4*x^3+x*O(x^n);A=F;if(n==0,0, for(i=0,n,B=serreverse(A);A=(A+subst(B,x,F))/2);polcoeff(A,n,x));
a(n) = b(2*n+1);
A372580
Expansion of g.f. A(x) satisfying A( A(x) - 4*A(x)^2 + 4*A(x)^3 ) = x.
Original entry on oeis.org
1, 2, 10, 66, 498, 4056, 34644, 305310, 2749110, 25142172, 232728588, 2176116348, 20532197196, 195344525540, 1872680305544, 18073069864926, 175419949070118, 1710976713480396, 16761489153049788, 164888041322062428, 1628416166697339324, 16136415431311552992, 160333972547949898584
Offset: 1
G.f.: A(x) = x + 2*x^2 + 10*x^3 + 66*x^4 + 498*x^5 + 4056*x^6 + 34644*x^7 + 305310*x^8 + 2749110*x^9 + 25142172*x^10 + 232728588*x^11 + 2176116348*x^12 + ...
where A( A(x)*(1 - 2*A(x))^2 ) = x.
RELATED SERIES.
Let B(x) = A(A(x)), then B(x)/x is the g.f. of A369510:
B(x) = x + 4*x^2 + 28*x^3 + 240*x^4 + 2288*x^5 + 23296*x^6 + 248064*x^7 + 2728704*x^8 + 30764800*x^9 + ... + 2^(n-1)*binomial(3*n-2,n-1)/n * x^n + ...
where B(x)*(1 - 2*B(x))^2 = x.
Let R(x) be the series reversion, R(A(x)) = x, then
R(x) = A(x)*(1 - 2*A(x))^2 = x - 2*x^2 - 2*x^3 - 6*x^4 - 22*x^5 - 80*x^6 - 228*x^7 - 18*x^8 + 6694*x^9 + ... + (-1)^(n-1)*A097090(n)*x^n + ...
where R(R(x)) = x*(1 - 2*x)^2.
-
{a(n) = my(A=x); for(k=2,n+1, A=truncate(A); A = (A + serreverse( A*(1 - 2*A)^2 +x*O(x^k)))/2 ); polcoeff(A,n)}
for(n=1,30, print1(a(n),", "))
Showing 1-4 of 4 results.
Comments