login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A089392 Magnanimous primes: primes with the property that inserting a "+" in any place between two digits yields a sum which is prime. 11

%I #39 Jan 02 2023 12:30:46

%S 2,3,5,7,11,23,29,41,43,47,61,67,83,89,101,227,229,281,401,443,449,

%T 467,601,607,647,661,683,809,821,863,881,2221,2267,2281,2447,4001,

%U 4027,4229,4463,4643,6007,6067,6803,8009,8221,8821,20261,24407,26881,28429,40427

%N Magnanimous primes: primes with the property that inserting a "+" in any place between two digits yields a sum which is prime.

%C Original definition: Let the digits of n be abcd. Then bcd+a, cd+ab, d+abc, abcd, etc. must all be primes. If n is a k-digit number then it must produce k such primes.

%C Partition the digits of n into two groups by placing a '+' sign anywhere inside; the result of the expression is prime in every case. Conjecture: sequence is infinite. 11 is the largest term with all odd digits. 2 is the only member with all even digits. Observation: all two-digit primes with the most significant digit even are members.

%C In contradiction to the above conjecture, it is rather expected that this sequence is finite, cf. the link to C. Rivera's "Puzzle 401", and G. Resta's web page. Concerning the statement about 2 and 11, one can say that all terms except 2, 11 and 101 consist of even digits followed by a final odd digit. - _M. F. Hasler_, Dec 25 2014

%C Primes among the magnanimous numbers A252996. - _M. F. Hasler_, Dec 25 2014

%H Zak Seidov, <a href="/A089392/b089392.txt">Table of n, a(n) for n = 1..84</a>

%H E. Angelini et al., <a href="http://list.seqfan.eu/oldermail/seqfan/2014-December/014168.html">Insert "+" and always get a prime</a>, Dec

%H 2014

%H G. Resta, <a href="http://www.numbersaplenty.com/set/magnanimous_number/">magnanimous numbers</a>, 2013.

%H C. Rivera, <a href="http://www.primepuzzles.net/puzzles/puzz_401.htm">Puzzle 401. Magnanimous primes</a>, 2007.

%e 2267 is a member which gives primes 2+267 = 269, 22+67 = 89, 226+7 = 233 and 2267 itself.

%p with(combinat): ds:=proc(s) local j: RETURN(add(s[j]*10^(j-1),j=1..nops(s))):end: for d from 1 to 6 do sch:=[seq([1,op(i),d+1],i=[[],seq([j],j=2..d)])]: for n from 10^(d-1) to 10^d-1 do sn:=convert(n,base,10): fl:=0: for s in sch do m:=add(j,j=[seq(ds(sn[s[i]..s[i+1]-1]),i=1..nops(s)-1)]): if not isprime(m) then fl:=1: break fi od: if fl=0 then printf("%d, ",n) fi od od: # C. Ronaldo

%t mpQ[n_]:=Module[{idn=IntegerDigits[n],len},len=Length[idn];And@@PrimeQ[ Table[ FromDigits[Take[idn,i]]+FromDigits[Take[idn,-(len-i)]],{i,len}]]]; Select[Range[41000],mpQ] (* _Harvey P. Dale_, Nov 06 2013 *)

%o (PARI) is_A089392(n)={!for(i=1,#Str(n),ispseudoprime([1,1]*(divrem(n,10^i)))||return)} \\ _M. F. Hasler_, Dec 25 2014

%Y Cf. A089393, A089394, A089695, A028834, A182175, A088134, A221699, A227823, A252996.

%K base,nonn

%O 1,1

%A _Amarnath Murthy_, Nov 10 2003

%E Corrected and extended by C. Ronaldo (aga_new_ac(AT)hotmail.com), Dec 25 2004

%E Comments edited by _Zak Seidov_, Jan 29 2013

%E Edited by _M. F. Hasler_, Dec 25 2014

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 24 09:18 EDT 2024. Contains 371935 sequences. (Running on oeis4.)