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!)
A106711 Smaller prime of the set of two consecutive primes each of whose sum of digits is prime. 0

%I #10 Jan 25 2018 14:29:30

%S 2,3,5,7,23,41,43,61,83,131,137,151,173,191,193,197,223,227,263,281,

%T 311,313,317,331,353,373,397,401,443,461,463,571,593,599,601,641,643,

%U 733,751,797,821,823,827,881,883,911,971,1013,1031,1033,1091,1093,1097,1103

%N Smaller prime of the set of two consecutive primes each of whose sum of digits is prime.

%e a(5)=23 is a term because sum of digits of two consecutive primes i.e. 23 and 29 is prime i.e. 2+3=5 and 2+9=11.

%t Select[Partition[Prime[Range[200]],2,1],PrimeQ[Total[IntegerDigits[ #[[1]]]]] && PrimeQ[Total[IntegerDigits[#[[2]]]]]&][[All,1]] (* or *) Prime[#]&/@SequencePosition[Table[If[PrimeQ[Total[IntegerDigits[n]]],1,0],{n,Prime[Range[200]]}],{1,1}][[All,1]] (* The second program requires Mathematica version 10 or later, but is more efficient because it only requires testing each prime for its sum of digits once. *) (* _Harvey P. Dale_, Jul 27 2017 *)

%K base,nonn

%O 1,1

%A _Shyam Sunder Gupta_, May 14 2005

%E Definition clarified by _Harvey P. Dale_, Jul 27 2017

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 25 01:35 EDT 2024. Contains 371964 sequences. (Running on oeis4.)