login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A273913 Consider the sequence b(k) with initial values b(1) = 1 and b(2) = n and satisfying b(k) = b(k-1) + Pd(b(k-2)), where Pd(x) is the product of the digits of x. Then b(k) eventually becomes constant, and this constant is a(n). 1
1902, 1902, 730, 230, 550, 420, 502, 1902, 2150, 1074, 1074, 1074, 1902, 1902, 8170, 730, 550, 730, 600, 230, 80, 230, 470, 550, 1074, 4045, 4990, 180, 230, 106, 90, 4990, 1062, 102, 902, 1230, 730, 108, 1406, 1017, 1410, 630, 2038, 505, 230, 1810, 150, 2306, 630 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

Maximum value in the first 10^5 terms is a(6874) = 209875, from b(128) on.

First n's whose last repetitive number of the sequence b(k) is a multiple: 1, 2, 5, 6, 34, 42, 135, 195, 460, 893, 2370, 4230, 7165, 237945.

LINKS

Paolo P. Lava, Table of n, a(n) for n = 1..10000

EXAMPLE

b(1) = 1, b(2) = 7. Then:

b(3) = 7 + Pd(1) = 7+1 = 8; b(4) = 8 + Pd(7) = 8+7 = 15;

b(5) = 15 + Pd(8) = 15+8 = 23; b(6) = 23 + Pd(15) = 23+5 = 28;

b(7) = 28 + Pd(23) = 28+6 = 34; b(8) = 34 + Pd(28) = 34+16 = 50;

b(19) = 270 + Pd(214) = 270+8 = 278; b(20) = 278 + Pd(270) = 278+0 = 278;

b(21) = 278 + Pd(278) = 278+112 = 390; b(22) = 390 + Pd(278) = 390+112 = 502;

b(23) = 502 + Pd(502) = 502+0 = 502; therefore a(7) = 502.

MAPLE

with(numtheory); T:=proc(w) local x, y, z; x:=w; y:=1;

for z from 1 to ilog10(x)+1 do y:=y*(x mod 10); x:=trunc(x/10); od; y; end:

P:=proc(q) local a1, a2, a3, n; for n from 1 to q do a1:=1; a2:=n; a3:=T(a1)+a2;

while not (a1=a2 and a2=a3) do a1:=a2; a2:=a3; a3:=T(a1)+a2; od;  print(a1);

od; end: P(10^7);

MATHEMATICA

a[n_] := Block[{b=0, c=1, d=n, p}, While[! (b == c == d), b=c; p = Times @@ IntegerDigits@ c; c = d; d += p]; d]; Array[a, 50] (* Giovanni Resta, Jun 20 2016 *)

PROG

(PARI) pd(n) = my(d=digits(n)); prod(k=1, #d, d[k]);

a(n) = {ba = 1; bb = n; bc = bb + pd(ba); while (!((ba ==bb) && (bc == bb)), newb = bb + pd(ba); ba = bb; bb = bc; bc = bb + pd(ba); ); bc; } \\ Michel Marcus, Jun 20 2016

CROSSREFS

Cf. A007954, A063108.

Sequence in context: A078862 A190652 A177137 * A190651 A237787 A190653

Adjacent sequences:  A273910 A273911 A273912 * A273914 A273915 A273916

KEYWORD

nonn,base,easy

AUTHOR

Paolo P. Lava, Jun 17 2016

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified November 16 19:17 EST 2019. Contains 329201 sequences. (Running on oeis4.)