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-20 of 39 results. Next

A002972 a(n) is the odd member of {x,y}, where x^2 + y^2 is the n-th prime of the form 4i+1.

Original entry on oeis.org

1, 3, 1, 5, 1, 5, 7, 5, 3, 5, 9, 1, 3, 7, 11, 7, 11, 13, 9, 7, 1, 15, 13, 15, 1, 13, 9, 5, 17, 13, 11, 9, 5, 17, 7, 17, 19, 1, 3, 15, 17, 7, 21, 19, 5, 11, 21, 19, 13, 1, 23, 5, 17, 19, 25, 13, 25, 23, 1, 5, 15, 27, 9, 19, 25, 17, 11, 5, 25, 27, 23, 29, 29, 25, 23, 19, 29, 13, 31, 31
Offset: 1

Views

Author

Keywords

Comments

It appears that the terms in this sequence are the absolute values of the terms in A046730. - Gerry Myerson, Dec 02 2010
"the n-th prime of the form 4i+1" is A005098(n). - Rainer Rosenthal, Aug 24 2022

Examples

			The 2nd prime of the form 4i+1 is 13 = 2^2 + 3^2, so a(2)=3.
		

References

  • E. Kogbetliantz and A. Krikorian, Handbook of First Complex Prime Numbers, Gordon and Breach, NY, 1971, p. 243.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Mathematica
    pmax = 1000; odd[p_] := Module[{k, m}, 2m+1 /. ToRules[Reduce[k>0 && m >= 0 && (2k)^2 + (2m+1)^2 == p, {k, m}, Integers]]]; For[n=1; p=5, pJean-François Alcover, Feb 26 2016 *)
  • PARI
    decomp2sq(p) = {my (m=(p-1)/4, r, x, limit=ceil(sqrt(p))); if (p>4 && denominator(m)==1, forprime (c=2,oo, if (!issquare(Mod(c,p)), r=c; break)); x=lift (Mod(r,p)^m); until (px%2,decomp2sq(p))[1],", "))) \\ Hugo Pfoertner, Aug 27 2022

Formula

a(n) = Min(A173330(n), A002144(n) - A173330(n)). - Reinhard Zumkeller, Feb 16 2010
a(n)^2 + 4*A002973(n)^2 = A002144(n); A002331(n+1) = Min(a(n),2*A002973(n)) and A002330(n+1) = Max(a(n),2*A002973(n)). - Reinhard Zumkeller, Feb 16 2010
(a(n) - 1)/2 = A208295(n), n >= 1. - Wolfdieter Lang, Mar 03 2012
a(A267858(k)) == 1 (mod 4), k >= 1. - Wolfdieter Lang, Feb 18 2016

Extensions

Better description from Jud McCranie, Mar 05 2003

A002973 a(n) is half of the even member of {x,y}, where x^2 + y^2 is the n-th prime of the form 4i+1.

Original entry on oeis.org

1, 1, 2, 1, 3, 2, 1, 3, 4, 4, 2, 5, 5, 4, 2, 5, 3, 1, 5, 6, 7, 1, 4, 2, 8, 5, 7, 8, 1, 6, 7, 8, 9, 4, 9, 5, 3, 10, 10, 7, 6, 10, 2, 5, 11, 10, 5, 7, 10, 12, 4, 12, 9, 8, 2, 11, 3, 6, 13, 13, 11, 1, 13, 10, 6, 11, 13, 14, 7, 5, 9, 2, 3, 8, 10, 12, 5, 14, 2, 3, 14, 11, 15, 16, 16, 5, 15, 1, 8, 11
Offset: 1

Views

Author

Keywords

Comments

a(n) is odd iff x^2 + y^2 == 5 (mod 8). [Vladimir Shevelev, Jul 12 2009]
A002972(n)^2 + 4*a(n)^2 = A002144(n); A002331(n+1) = Min(A002972(n),2*a(n)) and A002330(n+1) = Max(A002972(n),2*a(n)). [Reinhard Zumkeller, Feb 16 2010]

Examples

			The 3rd prime of the form 4i+1 is 17 = 1^2 + 4^2, so a(3) = 4/2 = 2.
		

References

  • E. Kogbetliantz and A. Krikorian, Handbook of First Complex Prime Numbers, Gordon and Breach, NY, 1971, p. 243.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Mathematica
    pmax = 1000; k[p_] := Module[{k, m}, k /. ToRules[Reduce[k>0 && m >= 0 && (2k)^2 + (2m+1)^2 == p, {k, m}, Integers]]]; For[n=1; p=5, pJean-François Alcover, Feb 26 2016 *)
  • PARI
    \\ use function decomp2sq from A002972
    forprime (p=5, 1000, if (p%4==1, print1(select(x->!(x%2),decomp2sq(p))[1]/2,", "))) \\ Hugo Pfoertner, Aug 27 2022

Formula

a(n) = Min(A173331(n), A002144(n) - A173331(n)) / 2. [Reinhard Zumkeller, Feb 16 2010]

Extensions

Better description from Jud McCranie, Mar 05 2003

A123998 Numbers k such that 2k+1 and 4k+1 are primes.

Original entry on oeis.org

1, 3, 9, 15, 18, 39, 48, 69, 78, 99, 105, 114, 135, 153, 165, 168, 183, 189, 219, 249, 273, 288, 300, 303, 309, 330, 345, 363, 405, 414, 438, 468, 483, 498, 504, 534, 585, 618, 639, 648, 699, 714, 729, 765, 804, 813, 828, 879, 933, 1005, 1014, 1044, 1065, 1068
Offset: 1

Views

Author

Artur Jasinski, Oct 31 2006

Keywords

Comments

Note that if n == 1 (mod 3) then 2n+1 is not prime (except n=1); and if n == 2 (mod 3) then 4n+1 is not prime. Therefore n must be a multiple of 3, except for n=1. - Max Alekseyev, Nov 02 2006

Crossrefs

Programs

  • Magma
    [n: n in [0..1100] |IsPrime(2*n+1) and IsPrime(4*n+1)]; // Vincenzo Librandi, Apr 17 2013
    
  • Mathematica
    Select[Range[1100], And @@ PrimeQ /@ ({2, 4}*# + 1) &] (* Ray Chandler, Nov 20 2006 *)
  • PARI
    is(k) = isprime(2*k+1) && isprime(4*k+1); \\ Jinyuan Wang, Aug 04 2019

Extensions

Extended by Ray Chandler, Nov 20 2006

A123986 Numbers n for which 4n+1 and 4n+3 are primes.

Original entry on oeis.org

1, 4, 7, 10, 25, 34, 37, 49, 67, 70, 115, 130, 142, 154, 160, 202, 205, 214, 220, 262, 265, 307, 319, 322, 325, 370, 424, 430, 469, 487, 499, 520, 532, 535, 559, 577, 595, 637, 664, 682, 697, 700, 742, 814, 832, 847, 865, 889, 895, 955, 979, 982, 1000, 1012, 1039
Offset: 1

Views

Author

Artur Jasinski, Oct 30 2006

Keywords

Comments

All terms == 1 mod 3. - Zak Seidov, Dec 02 2011
Intersection of A005098 and A095278. - Michel Marcus, Jan 31 2015

Crossrefs

Programs

  • Magma
    [n: n in [0..1100] |IsPrime(4*n+1) and IsPrime(4*n+3)]; // Vincenzo Librandi, Feb 01 2015
  • Mathematica
    Select[Range[1100], And @@ PrimeQ /@ ({1, 3} + 4#) &] (* Ray Chandler, Nov 05 2006 *)
    nn=10000;k=0;x=1;re=Reap[While[kZak Seidov, Dec 02 2011 *)

Extensions

Extended by Ray Chandler, Nov 05 2006

A111199 Numbers k such that 4k + 9 is prime.

Original entry on oeis.org

1, 2, 5, 7, 8, 11, 13, 16, 20, 22, 23, 25, 26, 32, 35, 37, 41, 43, 46, 47, 55, 56, 58, 62, 65, 67, 68, 71, 76, 77, 82, 85, 86, 91, 95, 97, 98, 100, 103, 106, 110, 112, 113, 125, 128, 133, 137, 140, 142, 146, 148, 151, 152, 158, 161, 163, 166, 167, 173, 175, 181, 187
Offset: 1

Views

Author

Parthasarathy Nambi, Oct 24 2005

Keywords

Examples

			For k=98, 4*k + 9 = 401 (prime).
		

Crossrefs

Programs

Formula

a(n) = A005098(n+1) - 2. - R. J. Mathar, Sep 23 2009

Extensions

More terms from R. J. Mathar, Sep 23 2009

A171555 Numbers of the form prime(n)*(prime(n)-1)/4.

Original entry on oeis.org

5, 39, 68, 203, 333, 410, 689, 915, 1314, 1958, 2328, 2525, 2943, 3164, 4658, 5513, 6123, 7439, 8145, 9264, 9653, 13053, 13514, 14460, 16448, 18023, 19113, 19670, 21389, 24414, 25043, 28308, 30363, 31064, 34689, 37733, 39303, 40100, 41718, 44205, 46764, 50288
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Dec 11 2009

Keywords

Comments

The halves of even numbers of the form p(p-1)/2 for p prime.
Sum of the quadratic residues of primes of the form 4k + 1. For example, a(3)=68 because 17 is the 3rd prime of the form 4k + 1 and the quadratic residues of 17 are 1, 4, 9, 16, 8, 2, 15, 13 which sum to 68. This sum is also the sum of the quadratic nonresidues. Cf. A230077. - Geoffrey Critzer, May 07 2015

References

  • R. Crandall and C. Pomerance, Prime Numbers: A Computational Perspective, Springer, NY, 2001; see Exercise 2.21 p. 110.

Crossrefs

Sums of residues, nonresidues, and their differences, for p == 1 (mod 4), p == 3 (mod 4), and all p: A171555; A282035, A282036, A282037; A076409, A125615, A282038.

Programs

  • Mathematica
    Table[Table[Mod[a^2, p], {a, 1, (p - 1)/2}] // Total, {p,
    Select[Prime[Range[100]], Mod[#, 4] == 1 &]}] (* Geoffrey Critzer, May 07 2015 *)
    Select[(# (#-1))/4&/@Prime[Range[100]],IntegerQ] (* Harvey P. Dale, Dec 24 2022 *)
  • PARI
    lista(nn) = forprime(p=2, nn, if ((p % 4)==1, print1(p*(p-1)/4, ", "))); \\ Michel Marcus, Mar 23 2016

Extensions

Corrected (16448 inserted, 25043 inserted) by R. J. Mathar, May 22 2010

A124408 Numbers k such that 2k+1, 4k+1 and 6k+1 are primes.

Original entry on oeis.org

1, 3, 18, 105, 135, 153, 165, 168, 300, 363, 585, 618, 648, 765, 828, 1110, 1140, 1278, 1518, 1530, 1533, 2130, 2223, 2400, 2475, 2613, 2790, 2925, 3075, 3180, 3345, 3420, 3483, 3810, 3840, 3843, 3933, 4008, 4083, 4095, 4143, 4260, 4263, 4323, 4470, 4545
Offset: 1

Views

Author

Artur Jasinski, Oct 31 2006

Keywords

Crossrefs

Programs

  • Mathematica
    Select[Range[4600], And @@ PrimeQ /@ ({2, 4, 6}*# + 1) &] (* Ray Chandler, Nov 20 2006 *)
  • PARI
    is(k) = sum(j = 1, 3, isprime(2*j*k+1)) == 3; \\ Jinyuan Wang, Aug 04 2019

A124409 Numbers k such that 2k+1, 4k+1, 6k+1 and 8k+1 are primes.

Original entry on oeis.org

165, 765, 1530, 2130, 2475, 3420, 5415, 7695, 9060, 11505, 12705, 13020, 15885, 16650, 20055, 20745, 22530, 24915, 26940, 29670, 32925, 35070, 36885, 39270, 44370, 47730, 48465, 54735, 55860, 56310, 58860, 65655, 66600, 67365, 67650
Offset: 1

Views

Author

Artur Jasinski, Oct 31 2006

Keywords

Crossrefs

Programs

  • Mathematica
    Select[Range[68000], And @@ PrimeQ /@ ({2, 4, 6, 8}*# + 1) &] (* Ray Chandler, Nov 20 2006 *)
  • PARI
    is(k) = sum(j = 1, 4, isprime(2*j*k+1)) == 4; \\ Jinyuan Wang, Aug 04 2019

A124410 Numbers k such that 2k+1, 4k+1, 6k+1, 8k+1 and 10k+1 are primes.

Original entry on oeis.org

5415, 12705, 13020, 44370, 82950, 98280, 105525, 112200, 115140, 123855, 134250, 134460, 187740, 188745, 210165, 225705, 247170, 256410, 296310, 302085, 367875, 375645, 382890, 399585, 404040, 476340, 487830, 526845, 532095, 566430, 578085
Offset: 1

Views

Author

Artur Jasinski, Oct 31 2006

Keywords

Crossrefs

Programs

  • Mathematica
    Select[Range[600000], And @@ PrimeQ /@ ({2, 4, 6, 8, 10}*# + 1) &] (* Ray Chandler, Nov 20 2006 *)
  • PARI
    is(k) = sum(j = 1, 5, isprime(2*j*k+1)) == 5; \\ Jinyuan Wang, Aug 04 2019

A124411 Numbers k such that 2k+1, 4k+1, 6k+1, 8k+1, 10k+1 and 12k+1 are primes.

Original entry on oeis.org

12705, 13020, 105525, 256410, 966840, 1707510, 1944495, 2310000, 2478630, 3132675, 3836070, 3976770, 4112430, 4532325, 5499585, 5920005, 6610485, 7390845, 8552250, 10739505, 11120340, 12231450, 12338130, 13243230, 16467255
Offset: 1

Views

Author

Artur Jasinski, Oct 31 2006

Keywords

Crossrefs

Programs

  • Mathematica
    Select[Range[10^7], And @@ PrimeQ /@ ({2, 4, 6, 8, 10, 12}*# + 1) &] (* Ray Chandler, Nov 20 2006 *)
  • PARI
    is(k) = sum(j = 1, 6, isprime(2*j*k+1)) == 6; \\ Jinyuan Wang, Aug 04 2019

Extensions

Extended by Ray Chandler, Nov 20 2006
Previous Showing 11-20 of 39 results. Next