The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A367796 Primes p such that the sum of p and its reversal is the square of a prime. 4
2, 29, 47, 83, 20147, 23117, 24107, 63113, 80141, 81131, 261104399, 262005299, 262104299, 262203299, 263302199, 264203099, 264302099, 264500099, 270401489, 271500389, 273104189, 273302189, 274401089, 282203279, 284302079, 284500079, 291104369, 291203369, 292005269, 293005169, 293104169, 294302069 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
Terms > 83 have an odd number of digits and an even first digit.
LINKS
David A. Corneth, Table of n, a(n) for n = 1..5743 (terms <= 10^15)
David A. Corneth, PARI program
EXAMPLE
A056964(a(n)) = 121 = 11^2 for 2 <= n <= 4.
A056964(a(n)) = 94249 = 307^2 for 5 <= n <= 10.
A056964(a(n)) = 1254505561 = 35419^2 for 11 <= n <= 71.
MAPLE
digrev:= proc(n) local L, i;
L:= convert(n, base, 10);
add(L[-i]*10^(i-1), i=1..nops(L))
end proc:
filter:= proc(t) local v;
v:= sqrt(t+digrev(t));
v::integer and isprime(v)
end proc:
R:= 2, 29, 47, 83: count:= 4: flag:= true:
for d from 3 to 9 by 2 do
p:= prevprime(10^(d-1));
for i from 1 do
p:= nextprime(p);
p1:= floor(p/10^(d-1));
if p1::odd then p:= nextprime((p1+1)*10^(d-1)) fi;
if p > 10^d then break fi;
if filter(p) then
count:= count+1; R:= R, p;
fi od od:
R;
MATHEMATICA
Select[Prime[Range[10^6]], PrimeQ[Sqrt[#+FromDigits[Reverse[IntegerDigits[#]]]]] &] (* Stefano Spezia, Dec 10 2023 *)
PROG
(PARI) \\ See PARI link
CROSSREFS
Cf. A056964, A067030, A061783. Subset of A367793.
Sequence in context: A105893 A366692 A059799 * A142969 A281546 A115448
KEYWORD
nonn,base
AUTHOR
Robert Israel, Nov 30 2023
STATUS
approved

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 June 1 22:07 EDT 2024. Contains 373032 sequences. (Running on oeis4.)