Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Search: a048401 -id:a048401
     Sort: relevance | references | number | modified | created      Format: long | short | data
Primes with consecutive digits that differ exactly by 8.
+10
12
2, 3, 5, 7, 19, 191, 919, 919191919, 91919191919, 91919191919191919, 91919191919191919191919, 191919191919191919191919191919191
OFFSET
1,1
COMMENTS
The next term (a(13)) has 133 digits. - Harvey P. Dale, Jan 04 2023
LINKS
EXAMPLE
2 is a term since all its consecutive digits differ by 5 (there aren't any).
19 is a term because 1 and 9 differ by 8.
23 is not a term because its consecutive digits differ only by 1.
MATHEMATICA
Module[{nn=500, nine, one}, one=Select[Table[FromDigits[PadRight[{}, n, {1, 9}]], {n, nn}], PrimeQ]; nine=Select[Table[FromDigits[PadRight[{}, n, {9, 1}]], {n, nn}], PrimeQ]; Sort[Join[{2, 3, 5, 7}, nine, one]]] (* Harvey P. Dale, Jan 04 2023 *)
KEYWORD
nonn,base
AUTHOR
Patrick De Geest, Apr 15 1999
EXTENSIONS
Offset corrected by Sean A. Irvine, Jun 16 2021
STATUS
approved
Primes with consecutive digits that differ exactly by 2.
+10
10
2, 3, 5, 7, 13, 31, 53, 79, 97, 131, 313, 353, 757, 797, 31357, 35353, 35753, 35797, 75353, 75797, 79757, 97579, 131357, 135353, 135757, 353531, 531353, 535757, 575753, 579757, 757579, 797579, 975313, 975797, 979757, 1313579, 3131353
OFFSET
1,1
LINKS
MATHEMATICA
Join[{2, 3, 5, 7}, Select[Prime[Range[230000]], Union[Abs[ Differences[ IntegerDigits[ #]]]]=={2}&]] (* Harvey P. Dale, Nov 03 2013 *)
KEYWORD
nonn,base
AUTHOR
Patrick De Geest, Apr 15 1999
STATUS
approved
Primes with consecutive digits that differ exactly by 3.
+10
8
2, 3, 5, 7, 41, 47, 14741, 14747, 74747, 1414741, 1474141, 7414741, 4141414747, 4147414147, 14141414141, 14141414741, 14141474741, 14141474747, 14147414741, 14147474141, 14147474147, 14741414747, 74141414147, 74141414741, 74147414741, 74741474741, 74747414141
OFFSET
1,1
COMMENTS
All terms with more than a single digit must comprise only the digits 1, 4, and 7, because no number comprising the digits 2, 5, and 8 or the digits 3, 6, and 9 can be prime. - Harvey P. Dale, Mar 01 2023
LINKS
MATHEMATICA
Join[{2, 3, 5, 7}, Table[Select[FromDigits/@Tuples[{1, 4, 7}, n], PrimeQ[#]&& Union[ Abs[ Differences[ IntegerDigits[ #]]]]=={3}&], {n, 11}]//Flatten] (* Harvey P. Dale, Mar 01 2023 *)
KEYWORD
nonn,base
AUTHOR
Patrick De Geest, Apr 15 1999
EXTENSIONS
More terms from Naohiro Nomoto, Jul 28 2001
More terms from Sean A. Irvine, Jun 15 2021
STATUS
approved
Primes with consecutive digits that differ exactly by 5.
+10
7
2, 3, 5, 7, 61, 83, 383, 727, 72727, 94949, 1616161, 383838383, 727272727, 383838383838383, 38383838383838383, 72727272727272727, 94949494949494949, 383838383838383838383
OFFSET
1,1
LINKS
MATHEMATICA
Module[{nn=50, w1, w2}, w1=Flatten[Table[Select[FromDigits/@Table[ PadRight[ {}, n, {a, a+5}], {n, 2, nn}], PrimeQ], {a, 4}]]; w2=Flatten[Table[Select[ FromDigits/@ Table[PadRight[{}, n, {a+5, a}], {n, 2, nn}], PrimeQ], {a, 4}]]; Join[ {2, 3, 5, 7}, w1, w2]//Union] (* Harvey P. Dale, Jan 09 2021 *)
KEYWORD
nonn,base
AUTHOR
Patrick De Geest, Apr 15 1999
STATUS
approved
Primes with consecutive digits that differ exactly by 7.
+10
7
2, 3, 5, 7, 29, 181, 929, 18181, 929292929, 18181818181818181818181818181818181818181818181818181818181818181818181818181
OFFSET
1,1
COMMENTS
The next term (a(11)) has 163 digits. - Harvey P. Dale, Mar 23 2023
LINKS
MATHEMATICA
Module[{s18, s81, s29, s92}, s18=Select[Table[FromDigits[PadRight[{}, n, {1, 8}]], {n, 1, 181, 2}], PrimeQ]; s81=Select[Table[FromDigits[PadRight[{}, n, {8, 1}]], {n, 2, 182, 2}], PrimeQ]; s29 = Select[ Table[FromDigits[PadRight[{}, n, {2, 9}]], {n, 2, 182, 2}], PrimeQ]; s92 =Select[Table[ FromDigits[ PadRight[{}, n, {9, 2}]], {n, 1, 183, 2}], PrimeQ]; Join[{2, 3, 5, 7}, s18, s81, s29, s92]//Sort] (* Harvey P. Dale, Mar 23 2023 *)
KEYWORD
nonn,base
AUTHOR
Patrick De Geest, Apr 15 1999
STATUS
approved
Primes with consecutive digits that differ exactly by 6.
+10
6
2, 3, 5, 7, 17, 71, 1717171717171717171717171717171, 1717171717171717171717171717171717171
OFFSET
1,1
COMMENTS
From Andrew Howroyd, Aug 13 2024: (Start)
Terms with more than 1 digit have digits alternating between 1 and 7.
No more terms < 10^3000. (End)
PROG
(PARI) upto(limit)={my(L=List([t|t<-[2, 3, 5], t<=limit]), m=1); while(m<limit, foreach([m*17\10, m*71\10, m*17, m*71], t, if(isprime(t)&&t<=limit, listput(L, t))); m=m*100+1); Vec(L)}
upto(10^100) \\ Andrew Howroyd, Aug 13 2024
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Patrick De Geest, Apr 15 1999
EXTENSIONS
Offset changed by Andrew Howroyd, Aug 13 2024
STATUS
approved
Prime worms [successive digit differences with absolute value of 4].
+10
3
151, 373, 95959, 9515959, 159595151, 159595951, 15151595951, 15951595151, 95951515159, 1515159515951, 1515959515951, 1515959595151, 1595159515151, 1595159595151, 9515151515159, 9515159515159, 9515159595959, 9595159515959
OFFSET
0,1
REFERENCES
Carlos Rivera's primepuzzles.net, Puzzle 246
FORMULA
Select prime numbers having the same first and last digits; if the uniform absolute value of successive digit differences is 4, add to sequence.
EXAMPLE
a(1)=373; first and last digits are 3; abs(3-7)=4; abs(7-3)=4; the worm is 3.
CROSSREFS
This is a subsequence of A048401. Cf. A089291, A089315-A089316, A048398-A048405.
KEYWORD
easy,nonn,base
AUTHOR
Enoch Haga, Dec 25 2003
EXTENSIONS
More terms from David Wasserman, Sep 09 2005
STATUS
approved

Search completed in 0.015 seconds