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 31-40 of 372 results. Next

A102261 a(n) = A002144(n) - A002145(n).

Original entry on oeis.org

2, 6, 6, 10, 14, 10, 10, 14, 14, 22, 26, 22, 26, 10, 30, 22, 26, 34, 30, 30, 30, 50, 42, 42, 46, 46, 50, 42, 42, 50, 46, 54, 42, 42, 42, 42, 38, 34, 30, 38, 14, 18, 18, 18, 46, 54, 62, 70, 78, 78, 90, 78, 66, 54, 70, 66, 62, 66, 58, 70, 66, 86, 98, 78, 78, 54, 70, 70, 78, 78
Offset: 1

Views

Author

Paul Curtz, Sep 06 2008

Keywords

Comments

a(n) = A108546(2*n+1) - A108546(2*n).

Programs

  • Maple
    A002144 := proc(n) option remember ; if n = 1 then RETURN(5) ; fi; for a from procname(n-1)+2 do if isprime(a) and (a mod 4 = 1 ) then RETURN(a) ; fi; od: end; A002145 := proc(n) option remember ; if n = 1 then RETURN(3) ; fi; for a from procname(n-1)+2 do if isprime(a) and (a mod 4 = 3 ) then RETURN(a) ; fi; od: end; A102261 := proc(n) A002144(n)-A002145(n) ; end: seq(A102261(n),n=1..120) ; # R. J. Mathar, Feb 07 2009
  • Mathematica
    nmax = 70; a1 = Select[Range[1, Prime[3*nmax], 4], PrimeQ]; a3 = Select[Range[3, Prime[3*nmax], 4], PrimeQ]; a[n_] := a1[[n]] - a3[[n]]; Table[a[n], {n, 1, nmax}] (* Jean-François Alcover, Dec 17 2013 *)

Extensions

Edited by N. J. A. Sloane, Sep 06 2008
More terms from R. J. Mathar, Feb 07 2009

A145395 Complement of the primes of form 4k+3 (A002145).

Original entry on oeis.org

0, 1, 2, 4, 5, 6, 8, 9, 10, 12, 13, 14, 15, 16, 17, 18, 20, 21, 22, 24, 25, 26, 27, 28, 29, 30, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 44, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 60, 61, 62, 63, 64, 65, 66, 68, 69, 70, 72, 73, 74, 75, 76, 77, 78, 80, 81, 82, 84
Offset: 1

Views

Author

Reinhard Zumkeller, Oct 12 2008

Keywords

Comments

Numbers n >= 0 such that (n + 1)*(2*r + n)/2 is a cube for some r >= 1. - Ctibor O. Zizka, Dec 28 2024

Crossrefs

Formula

A079261(a(n)) = 0.

A190105 a(n) = (3*A002145(n) - 1)/4.

Original entry on oeis.org

2, 5, 8, 14, 17, 23, 32, 35, 44, 50, 53, 59, 62, 77, 80, 95, 98, 104, 113, 122, 125, 134, 143, 149, 158, 167, 170, 179, 188, 197, 203, 212, 230, 233, 248, 260, 269, 275, 284, 287, 314, 323, 329, 332, 347, 350, 359, 365, 368, 374, 377, 392, 410, 422, 428, 440
Offset: 1

Views

Author

J. M. Bergot, May 04 2011

Keywords

Comments

For primes p of the form 4n+3, in the order of A002145, let us seek solutions for prime p|(a^x + b^y) or p|(a^y + b^x) subject to the conditions p = a+b = x+y and 0 < a,b,x,y < p. The larger of the two exponents x and y is inserted into the sequence.
If either of (a,b) is a primitive root of p, there is a unique solution, either p|(a^x + b^y) or p|(a^y + b^x). If neither is a primitive root (see A060749), there are multiple solutions and p|(a^x + b^y) or p|(a^y + b^x) will always be one of them for some of the given exponents (x,y) contributing to the sequence.

Examples

			For p=43=A002145(7), (x,y)=(11,32) because 43-(43+1)/4=32; hence x=43-32.  With (a,b)=(12,31) the unique solution is 43|(12^11 + 31^32) because 12 is a primitive root of 43. The larger of 11 and 32 is a(7)=32 in the sequence. For 43 multiple solutions occur when neither of the pairs (a,b) is a primitive root of 43: p divides each of 11^4 + 32^39, 11^18 + 32^25, 11^32 + 32^11; note that the exponents (11,32) occur in the last entry.
		

Crossrefs

Cf. A005099 is the list of x in (x,y).

Programs

  • Maple
    for n from 1 to 200 do p:=4*n-1: if(isprime(p))then printf("%d, ", (3*p-1)/4); fi: od: # Nathaniel Johnston, May 18 2011
  • Mathematica
    A002145 := Select[4 Range[300] - 1, PrimeQ]; Table[(3*A002145[[n]] - 1)/4, {n, 1, 60}] (* G. C. Greubel, Nov 07 2018 *)

A378186 With p(n) = A002145(n) = n-th non-Pythagorean prime, a(n) is the least k such p(n) + k is a non-Pythagorean prime and 2 p(n) + k - 5 is a Pythagorean prime; and a(n) = 0 if there is no such k .

Original entry on oeis.org

4, 4, 12, 4, 20, 16, 16, 12, 24, 64, 12, 4, 20, 28, 20, 64, 20, 40, 16, 16, 24, 20, 20, 28, 16, 16, 12, 68, 12, 20, 40, 100, 4, 36, 16, 12, 20, 100, 4, 36, 20, 72, 4, 48, 16, 12, 24, 100, 32, 4, 20, 76, 40, 8, 16, 12, 8, 40, 64, 196, 16, 12, 60, 68, 52, 20
Offset: 1

Views

Author

Clark Kimberling, Jan 13 2025

Keywords

Examples

			3 + 4 = 7, the least non-Pythagorean prime after 3,
and 3 + 7 - 5 = 5, a Pythagorean prime, so a(1) = 4.
		

Crossrefs

Programs

  • Mathematica
    s = Select[Prime[Range[450]], Mod[#, 4] == 3 &]
    a[n_] := Select[Range[200],  MemberQ[s, s[[n]] + #] && PrimeQ[2 s[[n]] + # - 5] &, 1]
    Flatten[Table[a[n], {n, 1, 140}]]

A378187 With p(n) = A002145(n) = n-th non-Pythagorean prime, a(n) is the least k such p(n) + k is a non-Pythagorean prime and 2 p(n) + k - 3 is a Pythagorean prime; and a(n) = 0 if there is no such k.

Original entry on oeis.org

4, 12, 12, 12, 24, 12, 24, 12, 12, 36, 12, 24, 48, 24, 60, 12, 48, 72, 12, 36, 192, 12, 60, 24, 12, 48, 12, 12, 108, 48, 60, 24, 72, 72, 168, 36, 24, 12, 84, 48, 24, 48, 108, 24, 24, 36, 12, 12, 12, 24, 60, 48, 60, 156, 48, 60, 84, 12, 24, 60, 84, 12, 84, 36
Offset: 1

Views

Author

Clark Kimberling, Jan 13 2025

Keywords

Examples

			3 + 4 = 7, the least non-Pythagorean prime after 3,
and 3 + 7 - 3 = 7, a Pythagorean prime, so a(1) = 4.
		

Crossrefs

Programs

  • Mathematica
    s = Select[Prime[Range[450]], Mod[#, 4] == 3 &]
    a[n_] := Select[Range[200],  MemberQ[s, s[[n]] + #] && PrimeQ[2 s[[n]] + # - 3] &, 1]
    Flatten[Table[a[n], {n, 1, 140}]]

A308660 For any Gaussian integer z, let d(z) be the distance from z to the nearest Gaussian prime distinct from z; we build an undirected graph G on top of the Gaussian prime numbers as follows: two Gaussian prime numbers p and q are connected iff at least one of d(p) or d(q) equals the distance from p to q; a(n) is the number of elements in the connected component of G containing A002145(n).

Original entry on oeis.org

100, 100, 3, 3, 3, 15, 48, 48, 9, 19, 5, 18, 18, 3, 17, 7, 41, 7, 17, 3, 3, 3, 9, 31, 3, 6, 6, 3, 11, 33, 3, 3, 9, 5, 13, 3, 15, 7, 23, 7, 3, 3, 3, 3, 5, 3, 13, 3, 3, 5, 11, 15, 3, 9, 3, 25, 19, 29, 23, 13, 3, 3, 5, 5, 3, 7, 15, 3, 25, 3, 7, 5, 3, 5, 3, 3, 3
Offset: 1

Views

Author

Rémy Sigrist, Jun 15 2019

Keywords

Comments

A002145 corresponds to the natural numbers that are also Gaussian prime numbers.
This sequence generalizes to Gaussian integers an idea developed in A308261.
Visually, the connected components of G appear like constellations (see representation in Links section).

Examples

			For n=3:
- A002145(3) = 11,
- the nearest Gaussian primes to 11 (at equal distance) are 10+i and 10-i,
- the other Gaussian primes around 11, 10+i and 10-i are nearer from other Gaussian primes,
- so the connected component containing 11 contains: 11, 10+i and 10-i,
- and a(3) = 3.
		

Crossrefs

Programs

  • PARI
    See Links section.

A374001 a(n) is the number of elements z of Z_p[i] such that #{z^k, k >= 0} = p^2-1 (where p denotes A002145(n), the n-th prime number congruent to 3 modulo 4).

Original entry on oeis.org

4, 16, 32, 96, 160, 256, 480, 704, 896, 1280, 1152, 1536, 1920, 3072, 3744, 4608, 3840, 4224, 5760, 8640, 7872, 8448, 9216, 9600, 9984, 13824, 16128, 12288, 14400, 20800, 18432, 25760, 23040, 23040, 26240, 38528, 34176, 42240, 31104, 48640, 34560, 48384, 46080
Offset: 1

Views

Author

Rémy Sigrist, Jun 24 2024

Keywords

Comments

Z_p[i] is a field iff p is a prime number congruent to 3 modulo 4.
a(n) is the number of generators of the multiplicative group Z_p[i] \ {0} (where p denotes A002145(n)).

Examples

			For n = 2:
- the second prime number congruent to 3 modulo 4 is p = 7,
- the number of elements of {(x + i*y)^k, k >= 0} where x and y belong to Z_7 are:
  x\y | 0   1   2   3   4   5   6
  ----+--------------------------
    0 | 2   4  12  12  12  12   4
    1 | 1  24  48  48  48  48  24
    2 | 3  48   8  16  16   8  48
    3 | 6  48  16  24  24  16  48
    4 | 3  48  16  24  24  16  48
    5 | 6  48   8  16  16   8  48
    6 | 2  24  48  48  48  48  24
- the number 48 appears 16 times, so a(2) = 16.
		

Crossrefs

A385164 Let p = A002145(n) be the n-th prime == 3 (mod 4); 8*a(n) is the multiplicative order of 1+-i modulo p in Gaussian integers.

Original entry on oeis.org

1, 3, 5, 9, 11, 5, 7, 23, 29, 33, 35, 39, 41, 51, 53, 7, 65, 69, 15, 81, 83, 89, 95, 99, 105, 37, 113, 119, 25, 131, 135, 47, 51, 155, 15, 173, 179, 183, 189, 191, 209, 43, 73, 221, 231, 233, 239, 243, 245, 83, 251, 261, 273, 281, 57, 293, 299, 303, 309, 45, 107, 323, 329, 11, 115
Offset: 1

Views

Author

Jianing Song, Jun 20 2025

Keywords

Examples

			For A002145(4) = 19: Since (1+i)^(4k) = (-4)^k, we have (1+i)^72 == 1 (mod 19), and 72 is the smallest such exponent. Hence a(4) = 72/8 = 9.
		

Crossrefs

Programs

  • PARI
    forprime(p=3, 1e3, if(p%4==3, print1(znorder(Mod(-4,p))/2, ", ")))

Formula

a(n) = ord(-4,p)/2, where ord(a,p) is the multiplicative order of a modulo p.

A088592 Let p be the n-th 4k+3 prime (A002145), g be any primitive root of p. The mapping x->g^x mod p gives a permutation of {1,2,...,p-1}. a(n) is 0 if the permutation is even for each g, 1 if odd for each g.

Original entry on oeis.org

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

Views

Author

Joseph Lewittes (jlewittes(AT)optonline.net), Nov 20 2003

Keywords

Comments

For each 4k+1 prime, half of the permutations are even, half are odd.

Examples

			a(2)=0 because x->g^x mod 7 gives an even permutation for each primitive root of 7. For p.r.=3, the cycles are (1 3 6)(2)(4)(5).
a(5)=1 because x->g^x mod 23 gives an odd permutation for each primitive root of 23. For p.r.=5, the cycles are (1 5 20 12 18 6 8 16 3 10 9 11 22)(2)(4)(7 17 15 19)(13 21 14).
		

Crossrefs

Extensions

Edited by Don Reble, Jul 31 2006

A107982 Gaussian-Pythagorean semiprimes. Products of a prime of the form 2 or 4n+1 (A002313) and a prime of the form 4n+3 (A002145).

Original entry on oeis.org

6, 14, 15, 22, 35, 38, 39, 46, 51, 55, 62, 86, 87, 91, 94, 95, 111, 115, 118, 119, 123, 134, 142, 143, 155, 158, 159, 166, 183, 187, 203, 206, 214, 215, 219, 235, 247, 254, 259, 262, 267, 278, 287, 291, 295, 299, 302, 303, 319, 323, 326, 327, 334, 335, 339, 355
Offset: 1

Views

Author

Jonathan Vos Post, Jun 12 2005

Keywords

Comments

Every semiprime must be in one of these three disjoint sets: the product of two primes of the form x^2+y^2, the product of two primes of the form x^2+3y^2, or the product of a prime of the form x^2+y^2 and a prime of the form x^2+3y^2. Equivalently, every semiprime must be in one of these three disjoint sets: the product of two primes of the form x^2+y^2 (2 or 4n+1), or the product of two primes of the form 4n+3, or the product of a prime of the form x^2+y^2 and a prime of the form 4n+3. In the latter case, such a semiprime is itself either of the form 4n+3 or the form 8n+6.

Crossrefs

Programs

  • Mathematica
    Module[{nn=60,f1,f2,minlen},f1=Join[{2},Select[4Range[0,nn]+1,PrimeQ]];f2=Select[4Range[0,nn]+3,PrimeQ];minlen=Min[Length[f1],Length[f2]];Take[Union[Flatten[Outer[Times,Take[f1,minlen],Take[f2,minlen]]]],nn]] (* Harvey P. Dale, May 06 2012 *)

Formula

{a(n)} = {p*q: p in A002313 and q in A002145}.
Previous Showing 31-40 of 372 results. Next