cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-10 of 32 results. Next

A089493 a(n) = smallest k such that the Reverse and Add! trajectory of A063048(n) joins the trajectory of k.

Original entry on oeis.org

196, 879, 106, 1077, 10553, 111, 1, 10583, 10022, 10071, 10331, 10128, 10210, 10132, 10278, 113, 10746, 10748, 1057, 10122, 10123, 10248, 10337, 10220, 10204, 10212, 10969, 10437, 10983, 10222, 10183, 12898, 128, 10119, 13694, 10036, 10292, 10173
Offset: 1

Views

Author

Klaus Brockhaus, Nov 04 2003

Keywords

Comments

a(n) <= A063048(n); a(n) = A063048(n) iff the trajectory of A063048(n) does not join the trajectory of any smaller number, i.e. A063048(n) is also a term of A070788.
a(n) determines a 1-1-mapping from the terms of A063048 to the terms of A070788. For the inverse mapping cf. A089494.

Examples

			A063048(3) = 1997, the trajectory of 1997 joins the trajectory of 106 = A070788(8) at 97768, so a(3) = 106. A063048(7) = 10577, the trajectory of 10577 joins the trajectory of 1 = A070788(1) at 7309126, so a(7) = 1.
		

Crossrefs

A089521 Terms of A088753 that are not terms of A063048.

Original entry on oeis.org

9999, 99999, 990099, 999999, 9901099, 9905099, 9993999, 9996999, 9997999, 9998999, 9999999, 99999999, 990959099, 990969099, 999010999, 999020999, 999030999, 999040999, 999070999, 999929999, 999939999, 999969999, 999989999
Offset: 1

Views

Author

Klaus Brockhaus, Nov 10 2003

Keywords

Comments

Palindromes in A088753; palindromes for which the Reverse and Add! process does not lead to another palindrome. The numbers were extracted from W. VanLandingham's list of Lychrel numbers.

Crossrefs

A306359 a(n) is the seed as given in A063048 such that the Lychrel number in A023108(n) joins the trajectory of this seed; 0 if A023108(n) is a seed.

Original entry on oeis.org

0, 196, 196, 196, 196, 196, 196, 196, 196, 0, 196, 879, 196, 196, 879, 196, 879, 196, 879, 196, 879, 196, 879, 196, 879, 0, 196, 879, 196, 879, 196, 879, 196, 879, 196, 879, 196, 879, 1997, 196, 879, 196, 879, 196, 879, 196, 879, 196, 879, 196, 879, 1997, 196, 196, 196, 196, 196, 196, 879, 196, 196, 879, 196, 196, 879
Offset: 1

Views

Author

A.H.M. Smeets, Feb 10 2019

Keywords

Comments

If A023108(n) in A063048 then a(n) = 0 else a(n) in A063048.

Crossrefs

A056964 a(n) = n + reversal of digits of n.

Original entry on oeis.org

0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 11, 22, 33, 44, 55, 66, 77, 88, 99, 110, 22, 33, 44, 55, 66, 77, 88, 99, 110, 121, 33, 44, 55, 66, 77, 88, 99, 110, 121, 132, 44, 55, 66, 77, 88, 99, 110, 121, 132, 143, 55, 66, 77, 88, 99, 110, 121, 132, 143, 154, 66, 77, 88, 99, 110
Offset: 0

Views

Author

Henry Bottomley, Jul 18 2000

Keywords

Comments

If n has an even number of digits then a(n) is a multiple of 11.
Also called the Reverse and Add!, or RADD operation. Iteration of this function leads to the definition of Lychrel and related numbers, cf. A023108, A063048, A088753, A006960, and many others. - M. F. Hasler, Apr 13 2019

Examples

			a(17) = 17 + 71 = 88.
		

Crossrefs

Differs from A052008 when n=101 and a(101)=202 while A052008(101)=121
Cf. A036839.

Programs

Formula

a(n) = n + A004086(n) = 2*n - A056965(n).
n < a(n) < 11n for n > 0. - Charles R Greathouse IV, Nov 17 2022

A023108 Positive integers which apparently never result in a palindrome under repeated applications of the function A056964(x) = x + (x with digits reversed).

Original entry on oeis.org

196, 295, 394, 493, 592, 689, 691, 788, 790, 879, 887, 978, 986, 1495, 1497, 1585, 1587, 1675, 1677, 1765, 1767, 1855, 1857, 1945, 1947, 1997, 2494, 2496, 2584, 2586, 2674, 2676, 2764, 2766, 2854, 2856, 2944, 2946, 2996, 3493, 3495, 3583, 3585, 3673, 3675
Offset: 1

Views

Author

Keywords

Comments

196 is conjectured to be smallest initial term which does not lead to a palindrome. John Walker, Tim Irvin and others have extended this to millions of digits without finding one (see A006960).
Also called Lychrel numbers, though the definition of "Lychrel number" varies: Purists only call the "seeds" or "root numbers" Lychrel; the "related" or "extra" numbers (arising in the former's orbit) have been coined "Kin numbers" by Koji Yamashita. There are only 2 "root" Lychrels below 1000 and 3 more below 10000, cf. A088753. - M. F. Hasler, Dec 04 2007
Question: when do numbers in this sequence start to outnumber numbers that are not in the sequence? - J. Lowell, May 15 2014
Answer: according to Doucette's site, 10-digit numbers have 49.61% of Lychrels. So beyond 10 digits, Lychrels start to outnumber non-Lychrels. - Dmitry Kamenetsky, Oct 12 2015
From the current definition it is unclear whether palindromes are excluded from this sequence, cf. A088753 vs A063048. 9999 would be the first palindromic term that will never result in a palindrome when the Reverse-then-add function A056964 is repeatedly applied. - M. F. Hasler, Apr 13 2019

Examples

			From _M. F. Hasler_, Feb 16 2020: (Start)
Under the "add reverse" operation, we have:
196 (+ 691) -> 887 (+ 788) -> 1675 (+ 5761) -> 7436 (+ 6347) -> 13783 (+ 38731) -> etc. which apparently never leads to a palindrome.
Similar for 295 (+ 592) -> 887, 394 (+ 493) -> 887, 790 (+ 097) -> 887 and 689 (+ 986) -> 1675, which all merge immediately into the above sequence, and also for the reverse of any of the numbers occurring in these sequences: 493, 592, 691, 788, ...
879 (+ 978) -> 1857 -> 9438 -> 17787 -> 96558 is the only other "root" Lychrel below 1000 which yields a sequence distinct from that of 196. (End)
		

References

  • Daniel Lignon, Dictionnaire de (presque) tous les nombres entiers, Ellipses, Paris, 2012, 702 pages. See Entry 196.

Crossrefs

Cf. A056964 ("reverse and add" operation on which this is based).

Programs

  • Mathematica
    With[{lim = 10^3}, Select[Range@ 4000, Length@ NestWhileList[# + IntegerReverse@ # &, #, ! PalindromeQ@ # &, 1, lim] == lim + 1 &]] (* Michael De Vlieger, Dec 23 2017 *)
  • PARI
    select( {is_A023108(n, L=exponent(n+1)*5)=while(L--&& n*2!=n+=A004086(n),);!L}, [1..3999]) \\ with {A004086(n)=fromdigits(Vecrev(digits(n)))}; default value for search limit L chosen according to known records A065199 and indices A065198. - M. F. Hasler, Apr 13 2019, edited Feb 16 2020

Extensions

Edited by M. F. Hasler, Dec 04 2007

A006960 Reverse and Add! sequence starting with 196.

Original entry on oeis.org

196, 887, 1675, 7436, 13783, 52514, 94039, 187088, 1067869, 10755470, 18211171, 35322452, 60744805, 111589511, 227574622, 454050344, 897100798, 1794102596, 8746117567, 16403234045, 70446464506, 130992928913, 450822227944, 900544455998, 1800098901007, 8801197801088, 17602285712176
Offset: 0

Views

Author

Keywords

Comments

196 is conjectured to be the smallest initial term which does not lead to a palindrome. John Walker, Tim Irvin and others have extended the trajectory of 196 to millions of digits without finding a palindrome.
From A.H.M. Smeets, Jan 31 2019: (Start)
Palindromes for a(9)/2, a(14)/2 and a(20)/2.
Observed: It seems that most, but not all, Lychrel numbers (seeds given in A063048) have a trajectory term that, divided by 2, becomes palindromic. Note that 196 is the first Lychrel number (A063048(1)). (End)
Observed: On average, 0.414 digits are gained by each step of the reverse and add procedure; i.e., 2.416 steps are needed on average to gain a factor of 10. This holds for any trajectory of reverse and add for decimal number representation. - A.H.M. Smeets, Feb 03 2019

Examples

			From _M. F. Hasler_, Apr 13 2019: (Start)
Start with 196 = a(0), then:
A056964(196) = 196 + 691 = 887 = a(1); then:
A056964(887) = 887 + 788 = 1675 = a(2); then:
A056964(1675) = 1675 + 5761 = 7436 = a(3); then:
A056964(7436) = 7436 + 6347 = 13783 = a(4); then:
A056964(13783) = 13783 + 38731 = 52514 = a(5); etc. (End)
		

References

  • J.-M. De Koninck, Ces nombres qui nous fascinent, Entry 196, p. 58, Ellipses, Paris 2008.
  • D. H. Lehmer, "Sujets d'étude. No. 74," Sphinx (Bruxelles), 8 (1938), 12-13. (This is the currently earliest known reference to the 196 Problem). - James D. Klein, Apr 09 2012
  • Daniel Lignon, Dictionnaire de (presque) tous les nombres entiers, Ellipses, Paris, 2012, 702 pages. See Entry 196.
  • Clifford A. Pickover, A Passion for Mathematics, Wiley, 2005; see p. 70.
  • Popular Computing (Calabasas, CA), The 196 Problem, Vol. 3 (No. 30, Sep 1975), pages PC30-6 to PC30-9.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Haskell
    a006960 n = a006960_list !! n
    a006960_list = iterate a056964 196 -- Reinhard Zumkeller, Sep 22 2011
    
  • Maple
    a:= proc(n) option remember; `if`(n=0, 196, (h-> h+ (s->
          parse(cat(s[-i]$i=1..length(s))))(""||h))(a(n-1)))
        end:
    seq(a(n), n=0..40);  # Alois P. Heinz, Jul 25 2014
  • Mathematica
    a = {196}; For[i = 2, i < 26, i++, a = Append[a, a[[i - 1]] + ToExpression[ StringReverse[ToString[a[[i - 1]]]]]]]; a
    NestList[#+FromDigits[Reverse[IntegerDigits[#]]]&,196,25] (* Harvey P. Dale, Jun 05 2011 *)
    NestList[#+IntegerReverse[#]&,196,25] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Jan 04 2019 *)
  • PARI
    A006960_vec(N=99)=vector(N,i,N=if(i>1,A056964(N),196)) \\ M. F. Hasler, Apr 13 2019

Formula

a(n+1) = A056964(a(n)). - A.H.M. Smeets, Jan 27 2019

Extensions

More terms from Vit Planocka (planocka(AT)mistral.cz), Sep 28 2002

A033665 Number of 'Reverse and Add' steps needed to reach a palindrome starting at n, or -1 if n never reaches a palindrome.

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 0, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 0, 1, 1, 1, 2, 1, 2, 1, 1, 1, 1, 0, 1, 2, 1, 2, 2, 1, 1, 1, 1, 1, 0, 1, 2, 2, 3, 1, 1, 1, 1, 2, 1, 0, 2, 3, 4, 1, 1, 1, 2, 1, 2, 2, 0, 4, 6, 1, 1, 2, 1, 2, 2, 3, 4, 0, 24, 1, 2, 1, 2, 2, 3, 4, 6, 24, 0, 1, 0, 1, 1
Offset: 0

Views

Author

Keywords

Comments

Palindromes themselves are not 'Reverse and Add!'ed, so they yield a zero!
Numbers n that may have a(n) = -1 (i.e., potential Lychrel numbers) appear in A023108. - Michael De Vlieger, Jan 11 2018
Record indices and values are given in A065198 and A065199. - M. F. Hasler, Feb 16 2020

Examples

			19 -> 19+91 = 110 -> 110+011 = 121 = palindrome, took 2 steps, so a(19)=2.
n = 89 needs 24 steps to end up with the palindrome 8813200023188. See A240510. - _Wolfdieter Lang_, Jan 12 2018
		

References

  • D. Wells, The Penguin Dictionary of Curious and Interesting Numbers Penguin Books, 1987, pp. 142-143.

Crossrefs

Equals A030547(n) - 1.
Cf. A065198, A065199 (record indices & values).

Programs

  • Mathematica
    rev[n_]:=FromDigits[Reverse[IntegerDigits[n]]];radd[n_]:=n+rev[n];
    pal[n_]:=If[n==rev[n],True,False];
    raddN[n_]:=Length[NestWhileList[radd[#]&,n,pal[#]==False&]]-1;
    raddN/@Range[0,195] (* Ivan N. Ianakiev, Aug 31 2015 *)
    With[{nn = 10^3}, Array[-1 + Length@ NestWhileList[# + IntegerReverse@ # &, #, !PalindromeQ@ # &, 1, nn] /. k_ /; k == nn -> -1 &, 200]] (* Michael De Vlieger, Jan 11 2018 *)
  • PARI
    rev(n)={d=digits(n);p="";for(i=1,#d,p=concat(Str(d[i]),p));return(eval(p))}
    a(n)=if(n==rev(n),return(0));for(k=1,10^3,i=n+rev(n);if(rev(i)==i,return(k));n=i)
    n=0;while(n<100,print1(a(n),", ");n++) \\ Derek Orr, Jul 28 2014
    
  • PARI
    A033665(n,LIM=333)={-!for(i=0,LIM,my(r=A004086(n)); n==r&&return(i); n+=r)} \\ with {A004086(n)=fromdigits(Vecrev(digits(n)))}. The second optional arg is a search limit that could be taken smaller up to very large n, e.g., 99 for n < 10^9, 200 for n < 10^14, 250 for n < 10^18: see A065199 for the records and A065198 for the n's. - M. F. Hasler, Apr 13 2019, edited Feb 16 2020
    
  • Python
    A033665 = lambda n, LIM=333: next((i for i in range(LIM) if is_A002113(n) or not(n := A004086(n)+n)), -1) # The second, optional argument is a search limit, see above. - M. F. Hasler, May 23 2024

Extensions

More terms from Patrick De Geest, Jun 15 1998
I truncated the b-file at n=195, since the value of a(196) is not presently known (cf. A006960). The old b-files are now a-files. - N. J. A. Sloane, May 09 2015

A065001 a(n) = (presumed) number of palindromes in the 'Reverse and Add!' trajectory of n, or -1 if this number is not finite.

Original entry on oeis.org

11, 10, 8, 9, 10, 7, 6, 8, 4, 9, 9, 6, 7, 5, 5, 7, 6, 3, 4, 8, 6, 8, 5, 5, 7, 6, 3, 4, 4, 6, 7, 5, 6, 7, 6, 3, 4, 4, 4, 7, 5, 5, 7, 7, 3, 4, 4, 4, 2, 5, 5, 7, 6, 3, 5, 4, 4, 2, 6, 5, 7, 6, 3, 4, 4, 5, 2, 6, 3, 7, 6, 3, 4, 4, 4, 2, 7, 3, 5, 6, 3, 4, 4, 4, 2, 6, 3, 6, 1, 3, 4, 4, 4, 2, 6, 3, 5, 1, 3, 8, 8, 6, 6
Offset: 1

Views

Author

Klaus Brockhaus, Nov 01 2001

Keywords

Comments

Presumably a(196) = 0 (see A016016). Conjecture: There is no n > 0 such that the trajectory of n contains an infinite number of palindromes; the trajectory of n eventually leads to a term in the trajectory of some integer k which belongs to sequence A063048, i.e. whose trajectory (presumably) never leads to a palindrome.

Examples

			8, 77, 1111, 2222, 4444, 8888, 661166, 3654563 are the eight palindromes in the trajectory of 8 and 3654563 + 3654563 = 7309126 is the sixth term in the trajectory of 10577 (see A063433) which (presumably) never leads to a palindrome (see A063048), so a(8) = 8.
		

Crossrefs

Programs

  • ARIBAS
    maxarg := 120; stop := 500; for k := 1 to maxarg do n := k; count := 0; c := 0; while c < stop do if n = int_reverse(n) then inc(count); c := 0; end; inc(c); n := n + int_reverse(n); end; write(count," " ); end;

A070788 Positive integers n such that the Reverse and Add! trajectory of n (presumably) does not join the trajectory of any m < n.

Original entry on oeis.org

1, 3, 5, 7, 9, 100, 102, 106, 108, 111, 112, 113, 114, 116, 117, 118, 119, 122, 124, 128, 133, 135, 137, 138, 166, 184, 186, 196, 199, 359, 399, 459, 539, 659, 679, 739, 759, 779, 799, 859, 879, 919, 939, 959, 979, 999, 1000, 1006, 1011, 1013, 1022, 1033, 1037
Offset: 1

Views

Author

Klaus Brockhaus, May 07 2002, revised Oct 15 2003

Keywords

Comments

The conjecture that the trajectories of the terms of this sequence do not join is based on the observation that if the trajectories of two integers below 10000 join, this happens after at most 15 steps, while for any two terms the trajectories do not join within 1200 steps. For pairs from 1, 3, 5, 7, 9, 100, 102, 106 this has even been checked for 10000 steps.
The positive integers are the domain of the equivalence relation 'the trajectories of a and b join'; each of its presumably infinitely many equivalence classes is represented by a term of this sequence. Each class contains infinitely many integers (cf. A070789 - A070798). In such a class the relation 'the trajectory of a is part of the trajectory of b' is a partial order for which a term c is a maximal element if it is in A067031 (integers not of the form k + reverse(k) for any k) and the integer at which the trajectories of a and b join is the greatest lower bound of a and b.

Examples

			The trajectory of 2 is part of the trajectory of 1; the trajectory of 3 does not join the trajectory of 1 within 10000 steps; the trajectory of 5 does not join the trajectory of 1 or of 3 within 10000 steps.
		

Crossrefs

Programs

  • Mathematica
    limit = 10^3; utraj = {};
    Select[Range[1037], (x = NestList[ # + IntegerReverse[#] &, #, limit]; If[Intersection[x, utraj] == {}, utraj = Union[utraj, x]; True, utraj = Union[utraj, x]]) &] (* Robert Price, Oct 20 2019 *)

A075252 Trajectory of n under the Reverse and Add! operation carried out in base 2 does not reach a palindrome and (presumably) does not join the trajectory of any term m < n.

Original entry on oeis.org

22, 77, 442, 537, 775, 1066, 1081, 1082, 1085, 1115, 1562, 1575, 1587, 2173, 3355, 3599, 3871, 4099, 4153, 4185, 4193, 4202, 4262, 4285, 4402, 4633, 4666, 6163, 6166, 6374, 9241, 9466, 16544, 16546, 16586, 16601, 16613, 16616, 16720, 16748, 16994
Offset: 1

Views

Author

Klaus Brockhaus, Sep 10 2002

Keywords

Comments

Base-2 analog of A063048 (base 10) and A075421 (base 4); subsequence of A066059. - For the trajectory of 22 (cf. A061561) and the trajectory of 77 (cf. A075253) it has been proved that they do not contain a palindrome. A similar proof can be given for most terms of this sequence, but there are a few terms (4262, 17498, 33378, 33898, ...) whose trajectory does not show the kind of regularity that can be utilized for the construction of a proof. - If the trajectory of an integer k joins the trajectory of a smaller integer which is a term of the present sequence, then this occurs after very few 'Reverse and Add!' steps (at most 84 for numbers < 20000). On the other hand, the trajectories of the terms of this sequence do not join the trajectory of any smaller term within at least 1000 steps.
From A.H.M. Smeets, Feb 12 2019: (Start)
Most terms in this sequence eventually give rise to a regular binary pattern. These regular patterns can be represented by contextfree grammars:
S_a -> 10 T_a 00, T_a -> 1 T_a 0 | A_a(n);
S_b -> 11 T_b 01, T_b -> 0 T_b 1 | B_a(n);
S_c -> 10 T_c 000, T_c -> 1 T_c 0 | C_a(n) and
S_d -> 11 T_d 101, T_d -> 0 T_d 1 | D_a(n).
A_22 = 1101, B_22 = 1000, C_22 = 1101, D_22 = 0010 (see also A058042);
A_77 = 1100010, B_77 = 0000101, C_77 = 1101011, D_77 = 0100000 (see also A075253)
Decimal representations for 10 A_a(n) 00 are given by A306514(n).
Binary representations for 10 A_a(n) 00 are given by A306515(n).
(End)

Examples

			442 is a term since the trajectory of 442 (presumably) does not lead to an integer which occurs in the trajectory of 22 or of 77.
		

Crossrefs

Programs

  • Mathematica
    limit = 10^2; (* Assumes that there is no palindrome if none is found before "limit" iterations *)
    utraj = {};
    Select[Range[0, 17000], (x = NestWhileList[# + IntegerReverse[#, 2] &, #, # != IntegerReverse[#, 2] & , 1, limit];
       If[Length[x] >= limit  && Intersection[x, utraj] == {},
        utraj = Union[utraj, x]; True,
    utraj = Union[utraj, x]]) &] (* Robert Price, Oct 16 2019 *)
Showing 1-10 of 32 results. Next