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!)
A156851 Primes p=prime(k) such that the largest digit of k is odd and is equal to the largest digit of p. 1

%I #15 Jan 22 2019 08:19:17

%S 17,109,113,131,157,251,367,373,479,491,499,509,599,773,797,859,937,

%T 1009,1129,1193,1289,1303,1327,1499,1553,1567,1579,1733,1741,1747,

%U 1753,1777,1879,1889,1901,1907,1913,1931,1933,1949,1951,1973,1979,2027,2039

%N Primes p=prime(k) such that the largest digit of k is odd and is equal to the largest digit of p.

%e For p=7=odd, prime(7)=17 (1<7=odd); n=29 (2<9=odd), prime(29)=109 (0<1<9=odd), etc.

%p A054055 := proc(n) max(op(convert(n,base,10))) ; end:

%p for n from 1 to 400 do

%p ldn := A054055(n) ;

%p if type(ldn,odd) then

%p p := ithprime(n) ;

%p ldp := A054055(p) ;

%p if ldp = ldn then

%p printf("%d,",p) ;

%p fi;

%p fi;

%p od: # _R. J. Mathar_, Feb 20 2009

%o (PARI) is(n) = vp = vecmax(digits(n)); if(vp % 2 == 0, return(0)); vpp = vecmax(digits(primepi(n))); vp == vpp \\ _David A. Corneth_, Jan 22 2019

%Y Cf. A000040, A054055.

%K nonn,base

%O 1,1

%A _Juri-Stepan Gerasimov_, Feb 17 2009

%E Missing numbers inserted by _R. J. Mathar_, Feb 20 2009

%E Name corrected by _Jon E. Schoenfield_, Jan 22 2019

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 September 6 06:40 EDT 2024. Contains 375704 sequences. (Running on oeis4.)