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-5 of 5 results.

A329544 Add the odd terms and subtract the even ones, the result must always be a palindrome. This is the lexicographically earliest sequence of distinct positive integers with this property.

Original entry on oeis.org

1, 3, 2, 5, 4, 19, 11, 22, 6, 17, 14, 8, 7, 15, 16, 27, 24, 13, 18, 29, 26, 37, 33, 44, 28, 39, 36, 25, 30, 41, 38, 49, 46, 35, 40, 51, 48, 59, 45, 10, 68, 32, 21, 20, 9, 55, 58, 47, 50, 61, 60, 71, 66, 77, 23, 12, 88, 191, 101, 111, 91, 112, 31, 81, 121, 131, 141, 70, 132, 80, 122, 90, 142, 174, 43, 54, 72, 83, 53, 42
Offset: 1

Views

Author

Eric Angelini and Jean-Marc Falcoz, Nov 16 2019

Keywords

Comments

Negative palindromes are not allowed (0 is OK). After 50000 terms, the smallest unused integers are 919, 1020, 1029, 1031, 1038, 1041, 1047, ... and the largest used is 208831. The largest palindrome produced so far is 1000001. Is the sequence a permutation of the integers > 0?
After one million terms, the smallest unused integers are still the seven mentioned (above) for 50000 terms. - Hans Havermann, Nov 27 2019
This sequence is not a permutation of the nonnegative integers because it cannot contain any term of A104444. The value 919 may only appear after a running total equal to 0 (see A083142, A084843). - Rémy Sigrist, Dec 11 2019. There are only two 0's in the first million terms of A329796, at n=12 and n=1002, so the chance that this happens seems slight. On the other hand, the zeros in the base 3 analog, A330314, are more plentiful (see A330325), so further investigation is needed. - Hans Havermann and N. J. A. Sloane, Dec 12 2019

Examples

			The sequence starts with 1 which is positive and a palindrome.
1 + 3 = 4 (palindrome). (2 is not allowed because 1 - 2 < 0.)
1 + 3 - 2 = 2 (palindrome)
1 + 3 - 2 + 5 = 7 (palindrome)
1 + 3 - 2 + 5 - 4 = 3 (palindrome)
1 + 3 - 2 + 5 - 4 + 19 = 22 (palindrome)
1 + 3 - 2 + 5 - 4 + 19 + 11 = 33 (palindrome)
1 + 3 - 2 + 5 - 4 + 19 + 11 - 22 = 11 (palindrome), etc.
		

Crossrefs

Cf. A329545 (same idea, but where the odd integers are subtracted and the even ones are added).
Cf. A002113 (palindromes), A086862 (first differences), A104444, A329796 (running totals), A329797, A329798 (records), A330311 (when n appears).

Programs

  • PARI
    A329544_vec(N,u=1,U,a,s,d)={vector(N,n, a=u; while(bittest(U,a-u)|| Vecrev(d=digits(s-(-1)^a*a))!=d|| (a>s&&!bittest(a,0)),a++); s-=(-1)^a*a; U+=1<<(a-u); while(bittest(U,0), U>>=1; u++);a)} \\ M. F. Hasler, Nov 16 2019

A104444 Not the difference of two palindromes (where 0 is considered a palindrome).

Original entry on oeis.org

1020, 1029, 1031, 1038, 1041, 1047, 1051, 1061, 1065, 1071, 1074, 1081, 1091, 1101, 1130, 1131, 1139, 1141, 1148, 1151, 1157, 1161, 1171, 1175, 1181, 1191, 1201, 1231, 1240, 1241, 1249, 1251, 1258, 1261, 1267, 1271, 1281, 1291, 1301, 1314, 1341, 1350
Offset: 1

Views

Author

David W. Wilson, Mar 07 2005

Keywords

Crossrefs

Formula

A084843 \ A002113 (conjecture). [R. J. Mathar, Jul 23 2009]

A082272 Smallest palindrome m such that n + m (m>0) is also a palindrome, or 0 if no such number exists.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 11, 99, 9, 8, 7, 6, 5, 4, 3, 2, 1, 11, 88, 9, 8, 7, 6, 5, 4, 3, 2, 1, 11, 77, 9, 8, 7, 6, 5, 4, 3, 2, 1, 11, 66, 9, 8, 7, 6, 5, 4, 3, 2, 1, 11, 55, 9, 8, 7, 6, 5, 4, 3, 2, 1, 11, 44, 9, 8, 7, 6, 5, 4, 3, 2, 1, 11, 33, 9, 8, 7, 6, 5, 4, 3, 2, 1, 11, 22, 9, 8, 7, 6, 5, 4, 3
Offset: 1

Views

Author

Amarnath Murthy, Apr 13 2003

Keywords

Comments

The first occurrence of 0 happens at n = 919.

Examples

			a(11) = 11, 11 + 11 = 22; a(12) = 99, 99 + 12 = 111; etc.
		

Crossrefs

Programs

  • PARI
    ispal(n) = eval(concat(Vecrev(Str(n)))) == n;
    nextpal(k) = k++; while(! ispal(k), k++); k;
    a(n) = {m = 1; while (! ispal(n+m), m = nextpal(m)); m;} \\ Michel Marcus, Jul 24 2014

Extensions

Edited by Patrick De Geest, Jun 08 2003

A082273 Palindromes arising in A082272.

Original entry on oeis.org

2, 3, 4, 5, 6, 7, 8, 9, 11, 11, 22, 111, 22, 22, 22, 22, 22, 22, 22, 22, 22, 33, 111, 33, 33, 33, 33, 33, 33, 33, 33, 33, 44, 111, 44, 44, 44, 44, 44, 44, 44, 44, 44, 55, 111, 55, 55, 55, 55, 55, 55, 55, 55, 55, 66, 111, 66, 66, 66, 66, 66, 66, 66, 66, 66, 77, 111, 77, 77
Offset: 1

Views

Author

Amarnath Murthy, Apr 13 2003

Keywords

Examples

			a(11) = 22, 11 + 11 = 22; a(12) = 111, 99 + 12 = 111; etc.
		

Crossrefs

Formula

a(n) = A082272(n) + n.

Extensions

Edited by Patrick De Geest, Jun 08 2003

A083142 Palindromes that cannot be expressed as the difference of two palindromes.

Original entry on oeis.org

919, 9119, 90109, 91019, 91119, 91219, 91319, 91419, 91519, 91619, 91719, 91819, 91919, 92129, 93139, 94149, 95159, 96169, 97179, 98189, 99199, 901109, 910019, 911119, 912219, 913319, 914419, 915519, 916619, 917719, 918819, 919919, 921129
Offset: 1

Views

Author

Amarnath Murthy and Meenakshi Srikanth (menakan_s(AT)yahoo.com), Apr 25 2003

Keywords

Comments

Palindromes in A084843. All terms begin with 9. Do all terms contain a 1?

Examples

			9 is not a member because 9 = 11 - 2.
		

Crossrefs

Extensions

Edited and extended by David Wasserman, Oct 19 2004
Showing 1-5 of 5 results.