cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-2 of 2 results.

A105399 Largest prime <= numbers of the form 6k+3 (duplicates removed).

Original entry on oeis.org

3, 7, 13, 19, 23, 31, 37, 43, 47, 53, 61, 67, 73, 79, 83, 89, 97, 103, 109, 113, 127, 131, 139, 151, 157, 163, 167, 173, 181, 193, 199, 211, 223, 229, 233, 241, 251, 257, 263, 271, 277, 283, 293, 307, 313, 317, 331, 337, 349, 353, 359, 367, 373, 379, 383, 389
Offset: 1

Views

Author

Giovanni Teofilatto, May 01 2005

Keywords

Comments

Apart from the initial 3, the same as A049591. [Proof from T. Khovanova, Jan 23 2008: True for primes up to 5 by inspection. Higher primes must be of the form 6k+1 or 6k+5 since 6k+2 and 6k+4 are divisible by 2 and 6k+3 is divisible by 3. So searching the prime p backwards from the composite, odd 6k+3 in steps of 2 implies that p+2, skipped during that scan, is composite. So p is not in A001359 but in A049591.] - R. J. Mathar, Jan 28 2008

Examples

			7 is in the sequence because 7 is the largest prime < 9=6*1+3.
		

Crossrefs

Cf. A106002.
Cf. A049591.

Programs

  • Mathematica
    pp[n_] := Block[{k = n},While[ ! PrimeQ[k], k-- ];k];Union[Table[pp[6n + 3], {n, 0, 65}]] (* Ray Chandler, Oct 17 2006 *)
    Union[If[PrimeQ[#],#,NextPrime[#,-1]]&/@(6*Range[0,70]+3)] (* Harvey P. Dale, Aug 20 2021 *)

Extensions

Edited, corrected and extended by Ray Chandler, Oct 17 2006

A105470 a(n)=1 if there is number of the form 6k+3 with prime(n) <= 6k+3 <= prime(n+1), otherwise 0.

Original entry on oeis.org

1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 1, 0, 1, 0, 1, 0, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 0, 1
Offset: 1

Views

Author

Giovanni Teofilatto, May 02 2005

Keywords

Comments

Except for the first pair of primes and for twin primes there is always at least one number of the form 6n+3 between two successive primes.

Examples

			a(3)=0 because between prime(3) and prime(4) there are no numbers of the form 6k+3;
a(4)=1 because between prime(4) and prime(5) there is one number of the form 6k+3: 9.
		

Crossrefs

Programs

  • Mathematica
    f[n_] := Count[Table[Mod[k, 6], {k, Prime[n], Prime[n + 1]}], 3];Table[If[f[n] == 0, 0, 1], {n, 120}] (* Ray Chandler, Oct 17 2006 *)
    Join[{1,1},If[Last[#]-First[#]==2,0,1]&/@Partition[Prime[Range[ 3,200]],2,1]] (* Harvey P. Dale, Nov 27 2013 *)

Extensions

Edited by Ray Chandler, Oct 17 2006
Showing 1-2 of 2 results.