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!)
A136799 Last term in a sequence of at least 3 consecutive composite integers. 7
10, 16, 22, 28, 36, 40, 46, 52, 58, 66, 70, 78, 82, 88, 96, 100, 106, 112, 126, 130, 136, 148, 156, 162, 166, 172, 178, 190, 196, 210, 222, 226, 232, 238, 250, 256, 262, 268, 276, 280, 292, 306, 310, 316, 330, 336, 346, 352, 358, 366, 372, 378, 382, 388, 396 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
An equivalent definition is "Last term in a sequence of at least 2 consecutive composite integers". - Jon E. Schoenfield, Dec 04 2017
The BASIC program below is useful in testing Grimm's Conjecture, subject of Carlos Rivera's Puzzle 430
Use the program with lines 30 and 70 enabled in the first run and then disabled with lines 31 and 71 enabled in the second run.
Composite numbers m such that m-1 is composite, and m+1 is not. - Martin Michael Musatov, Oct 24 2017
LINKS
Carlos Rivera, Puzzle 430, Grimm's Conjecture, Prime puzzles and problems connection.
FORMULA
a(n) = A025584(n+2) - 1. - R. J. Mathar, Jan 24 2008
a(n) ~ n log n. - Charles R Greathouse IV, Oct 27 2015
EXAMPLE
a(1)=10 because 10 is the last term in a run of three composites beginning with 8 and ending with 10 (8,9,10).
MATHEMATICA
Select[Prime@ Range@ 78, CompositeQ[# - 2] &] - 1 (* Michael De Vlieger, Oct 23 2015, after PARI *)
PROG
(UBASIC) 10 'puzzle 430 (gap finder) 20 N=1 30 A=1:S=sqrt(N):print N; 31 'A=1:S=N\2:print N; 40 B=N\A 50 if B*A=N and B=prmdiv(B) then print B; 60 A=A+1 70 if A<=sqrt(N) then 40 71 'if A<=N\2 then 40 80 C=C+1:print C 90 N=N+1: if N=prmdiv(N) then C=0:print:stop:goto 90:else 30
(PARI) forprime(p=5, 1000, if(isprime(p-2)==0, print1(p-1, ", "))) \\ Altug Alkan, Oct 23 2015
(Magma) [p-1: p in PrimesInInterval(4, 420) | not IsPrime(p - 2)]; // Vincenzo Librandi, Apr 11 2019
CROSSREFS
Sequence in context: A242057 A245024 A264721 * A055987 A187397 A152138
KEYWORD
easy,nonn
AUTHOR
Enoch Haga, Jan 21 2008
EXTENSIONS
Edited by R. J. Mathar, May 27 2009
a(53) corrected by Bill McEachen, Oct 27 2015
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 April 16 19:21 EDT 2024. Contains 371754 sequences. (Running on oeis4.)