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.
%I A252495 #25 Dec 23 2024 14:53:44 %S A252495 0,1,2,3,4,5,6,7,8,9,11,12,14,16,20,21,23,25,29,30,32,34,38,41,43,47, %T A252495 49,50,52,56,58,61,65,67,70,74,76,83,85,89,92,94,98,110,112,116,118, %U A252495 130,136,152,158,170,172,221,227,229,245,265,281,310,316,334,338,356 %N A252495 Restricted magnanimous numbers: numbers such that the sum obtained by inserting a "+" anywhere between two digits gives a prime, but no "leading zeros" may appear. %C A252495 Inclusion of the single-digit terms is conventional: here the property is vacuously satisfied since no sum can be constructed by inserting a + sign between two digits, therefore all possible sums are prime. (It is not allowed to prefix a leading zero (e.g., to forbid 4 = 04 = 0+4) since in that case all terms must be prime and one would get A089392.) %C A252495 The restriction on leading zeros means that numbers with digit 0 other than in the last position are excluded, so this sequence equals A252996 with terms in A252480 removed. %C A252495 Since all primes > 2 are odd, all terms different from 11 and 20 have the last digit of opposite parity to that of all other digits. %C A252495 As A252996, this sequence is "finite" (without rigorous proof), and up to 5e16 the only terms with more than 11 digits are 5391391551358 and 97393713331910, the latter being probably the largest element of this sequence (due to _Giovanni Resta_). %C A252495 (See links for "intellectual ownership": The sequence (without single-digit terms) was suggested by _Eric Angelini_, a first list of terms computed by _Lars Blomberg_, then others. _Hans Havermann_ observed that this is a variant of what had been termed "magnanimous numbers" at least 10 years ago by A. Murthy, G. Resta and/or C. Rivera, cf. A089392 and links.) %H A252495 M. F. Hasler, <a href="/A252495/b252495.txt">Table of n, a(n) for n = 1..452</a> %H A252495 E. Angelini and L. Blomberg, <a href="https://web.archive.org/web/*/http://list.seqfan.eu/oldermail/seqfan/2014-December/014169.html">Insert "+" and always get a prime</a>, Dec 2014 %H A252495 G. Resta, <a href="http://www.numbersaplenty.com/set/magnanimous_number/">magnanimous numbers</a>, 2013. %H A252495 C. Rivera, <a href="http://www.primepuzzles.net/puzzles/puzz_401.htm">Puzzle 401. Magnanimous primes</a>, 2007. %e A252495 110 is in the sequence since 1+10=11 and 11+0 = 11 are both prime. %e A252495 101 is not in the sequence because although 10+1 = 11 and 1+01 = 2 are prime, the latter sum is forbidden since 01 has a leading zero. %e A252495 Number, smallest and largest of the n-digit terms: %e A252495 | n # min max %e A252495 | 1 10 0 9 %e A252495 | 2 33 11 98 %e A252495 | 3 69 110 998 %e A252495 | 4 90 1112 9910 %e A252495 | 5 81 11116 99998 %e A252495 | 6 71 111112 999994 %e A252495 | 7 54 1115756 9959374 %e A252495 | 8 25 11771992 95559998 %e A252495 | 9 9 117711170 995955112 %e A252495 |10 4 1777137770 9151995592 %e A252495 |11 4 22226226625 46884486265 %e A252495 |12 0 - %e A252495 |13 1 5391391551358 %e A252495 |14 1 97393713331910 %e A252495 |15 0 - %o A252495 (PARI) is(n)=!for(i=1,#Str(n)-1,ispseudoprime([1,1]*(divrem(n,10^i)))||return)&&(n<100||vecmin(digits(n\10))) %o A252495 t=0;vector(100,i,until(is(t++),);t) %Y A252495 Cf. A252996, A089392, A089393, A089394, A028834, A182175, A088134, A221699, A227823. %K A252495 nonn,base,nice,fini,full %O A252495 1,3 %A A252495 _M. F. Hasler_, Dec 28 2014