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.

Previous Showing 11-14 of 14 results.

A140378 Lengths of runs of consecutive primes and nonprimes in A007775.

Original entry on oeis.org

1, 12, 1, 6, 1, 3, 1, 6, 2, 2, 1, 2, 1, 3, 1, 2, 1, 3, 1, 4, 2, 1, 2, 6, 1, 1, 1, 1, 1, 6, 2, 1, 2, 4, 3, 2, 2, 4, 1, 1, 1, 1, 1, 3, 1, 2, 2, 1, 1, 2, 1, 2, 1, 3, 1, 4, 2, 1, 1, 2, 2, 3, 2, 2, 4, 2, 2, 1, 1, 4, 2, 1, 1, 4, 1, 3, 2, 1, 1, 3, 1, 3, 2, 2, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 3, 2, 2, 2
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Jun 13 2008

Keywords

Comments

Primes can be classified according to their remainder modulo 30: remainder 1 (A136066), 7 (A132231), 11 (A132232), 13 (A132233), 17 (A039949), 19 (A132234), 23 (A132235), or 29 (A132236). In the sequence A007775 of all numbers (prime or nonprime) in any of these remainder classes, we look for runs of numbers that are successively prime or nonprime and place the lengths of these runs in this sequence.

Examples

			Groups of runs in A007775 are (1), (7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47), (49), (53, 59, 61, 67, 71, 73), (77), (79, 83,...), which is 1 nonprime followed by 12 primes followed by 1 nonprime followed by 6 primes etc.
		

Crossrefs

Programs

  • Maple
    A007775 := proc(n) option remember ; local a; if n = 1 then 1; else for a from A007775(n-1)+1 do if a mod 2 <>0 and a mod 3 <>0 and a mod 5 <> 0 then RETURN(a) ; fi ; od: fi ; end: A := proc() local al,isp,n; al := 0: isp := false ; n := 1: while n< 300 do a := A007775(n) ; if isprime(a) <> isp then printf("%d,",al) ; al := 1; isp := not isp ; else al := al+1 ; fi ; n := n+1: od: end: A() ; # R. J. Mathar, Jun 16 2008

Extensions

Edited by R. J. Mathar, Jun 16 2008

A227869 Composite numbers congruent to 7 (mod 30).

Original entry on oeis.org

187, 217, 247, 427, 517, 637, 667, 697, 817, 847, 1027, 1057, 1147, 1177, 1207, 1267, 1357, 1387, 1417, 1477, 1507, 1537, 1687, 1717, 1807, 1837, 1897, 1927, 1957, 2047, 2077, 2107, 2167, 2197, 2227, 2257, 2317, 2407, 2497, 2527, 2587, 2737, 2827, 2947, 2977
Offset: 1

Views

Author

M. F. Hasler, Nov 02 2013

Keywords

Comments

Up to 4897, there are more primes than composites among the numbers of the form 7+30k, only from 4927 on, composite numbers become more frequent.
See A132231 for primes of that form. See also A132237 (primes = 7 or 23 (mod 30)) and A229947 (primes not = 7 or 23 (mod 30)).

Programs

  • Mathematica
    Select[Table[30n + 7, {n, 100}], Not[PrimeQ[#]] &] (* Alonso del Arte, Nov 03 2013 *)
    Select[Range[7,3000,30],CompositeQ] (* Harvey P. Dale, Oct 09 2023 *)
  • PARI
    forstep(p=7,1999,30,isprime(p)||print1(p","))

A142786 Primes congruent to 7 mod 60.

Original entry on oeis.org

7, 67, 127, 307, 367, 487, 547, 607, 727, 787, 907, 967, 1087, 1327, 1447, 1567, 1627, 1747, 1867, 1987, 2287, 2347, 2467, 2647, 2707, 2767, 2887, 3067, 3187, 3307, 3547, 3607, 3727, 3847, 3907, 3967, 4027, 4327, 4447, 4507, 4567, 4987, 5107, 5167, 5227
Offset: 1

Views

Author

N. J. A. Sloane, Jul 11 2008

Keywords

Comments

Comment from Joshua S.M. Weiner, Oct 12 2012 (Start)
Intersection of A068229 and A141882. Subsequence of A132231.
Congruence classes of primes mod 60: A088955 (1), (this sequence 7), A117047 (11), A142787 (13), A142788 (17), A142789 (19), A142790 (23), A142791 (29), A142792 (31), A142793 (37), A142794 (41), A142795 (43), A142796 (47), A142797 (49), A142798 (53), A142799 (59). (End)

Crossrefs

Programs

  • Magma
    [p: p in PrimesUpTo(6000) | p mod 60 eq 7 ]; // Vincenzo Librandi, Sep 04 2012
  • Mathematica
    Select[Prime[Range[1000]], Mod[#, 60] == 7 &] (* T. D. Noe, Oct 12 2012 *)
    Select[Range[7,5300,60],PrimeQ] (* Harvey P. Dale, Nov 21 2018 *)

A329262 Prime pairs of the form (30k - 7, 30k + 7).

Original entry on oeis.org

23, 37, 53, 67, 83, 97, 113, 127, 263, 277, 293, 307, 353, 367, 383, 397, 443, 457, 563, 577, 593, 607, 743, 757, 773, 787, 863, 877, 953, 967, 983, 997, 1103, 1117, 1223, 1237, 1283, 1297, 1433, 1447, 1553, 1567, 1583, 1597, 1613, 1627
Offset: 1

Views

Author

Harry E. Neel, Nov 09 2019

Keywords

Comments

The terms of this sequence are created by pairing the terms of the primes when the terms 30k - 7 and 30k + 7 are both prime. As has been pointed out, it is only a guess as to whether, or not, that (like the twin primes, etc.) there is or is not an infinite number of these pairings.

Examples

			As 4 * 30 - 7 = 113 and 4 * 30 + 7 = 127 are prime, both 113 and 127 are in the sequence. - _David A. Corneth_, Nov 10 2019
		

Crossrefs

Odd- (resp. even-) indexed terms are a subsequence of A132235 (resp. A132231).

Programs

  • Magma
    &cat[[30*k-7] cat [30*k+7]:k in [1..60]|IsPrime(30*k-7) and IsPrime(30*k+7)]; // Marius A. Burtea, Nov 17 2019
  • Mathematica
    Select[Prime[Range[1000]], MemberQ[{7, 23}, Mod[#, 30]] &] (* Jinyuan Wang, Nov 16 2019 *)
    Flatten[Select[Table[30n + {-7, 7}, {n, 90}], PrimeQ[#[[1]]] && PrimeQ[#[[2]]] &]] (* Alonso del Arte, Dec 07 2019 *)
  • PARI
    first(n) = n+=(n%2); my(res=List(),todo=n); for(i=1,oo, if(isprime(30*i-7) && isprime(30*i+7), listput(res,30*i-7); listput(res,30*i+7); todo-=2; if(todo<=0, return(res)))) \\ David A. Corneth, Nov 10 2019
    
Previous Showing 11-14 of 14 results.