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 100 results. Next

A033200 Primes congruent to {1, 3} (mod 8); or, odd primes of form x^2 + 2*y^2.

Original entry on oeis.org

3, 11, 17, 19, 41, 43, 59, 67, 73, 83, 89, 97, 107, 113, 131, 137, 139, 163, 179, 193, 211, 227, 233, 241, 251, 257, 281, 283, 307, 313, 331, 337, 347, 353, 379, 401, 409, 419, 433, 443, 449, 457, 467, 491, 499
Offset: 1

Views

Author

Keywords

Comments

Rational primes that decompose in the field Q(sqrt(-2)). - N. J. A. Sloane, Dec 25 2017
Fermat knew of the relationship between a prime being congruent to 1 or 3 mod 8 and its being the sum of a square and twice a square, and claimed to have a firm proof of this fact. These numbers are not primes in Z[sqrt(-2)], as they have x - y sqrt(-2) as a divisor. - Alonso del Arte, Dec 07 2012
Terms m in A047471 with A010051(m) = 1. - Reinhard Zumkeller, Dec 29 2012
This sequence gives the primes p which satisfy norm(rho(p)) = + 1 with rho(p) := 2*cos(Pi/p) (the length ratio (smallest diagonal)/side in the regular p-gon). The norm of an algebraic number (over Q) is the product over all zeros of its minimal polynomial. Here norm(rho(p)) = (-1)^delta(p)* C(p, 0), with the degree delta(p) = A055034(p) = (p-1)/2. For the minimal polynomial C see A187360. For p == 1 (mod 8) the norm is C(p, 0) (see a comment on 4*A005123) and for p == 3 (mod 8) the norm is -C(p, 0) (see a comment on A186297). For the primes with norm(rho(p)) = -1 see A003628. - Wolfdieter Lang, Oct 24 2013
If p is a member then it has a unique representation as x^2+2y^2 [Frei, Theorem 3]. - N. J. A. Sloane, May 30 2014
Primes that are the quarter perimeter of a Heronian triangle. Such primes are unique to the Heronian triangle (see Yiu link). - Frank M Jackson, Nov 30 2014

Examples

			Since 11 is prime and 11 == 3 (mod 8), 11 is in the sequence. (Also 11 = 3^2 + 2 * 1^2 = (3 + sqrt(-2))(3 - sqrt(-2)).)
Since 17 is prime and 17 == 1 (mod 8), 17 is in the sequence.
		

References

  • David A. Cox, "Primes of the Form x^2 + n y^2", Wiley, 1989, p. 7.

Crossrefs

Cf. A033203.

Programs

  • Haskell
    a033200 n = a033200_list !! (n-1)
    a033200_list = filter ((== 1) . a010051) a047471_list
    -- Reinhard Zumkeller, Dec 29 2012
    
  • Magma
    [p: p in PrimesUpTo(600) | p mod 8 in [1, 3]]; // Vincenzo Librandi, Aug 04 2012
    
  • Mathematica
    Rest[QuadPrimes2[1, 0, 2, 10000]] (* see A106856 *)
    Select[Prime[Range[200]],MemberQ[{1,3},Mod[#,8]]&] (* Harvey P. Dale, Jun 09 2017 *)
  • PARI
    is(n)=n%8<4 && n%2 && isprime(n) \\ Charles R Greathouse IV, Feb 09 2017

Formula

a(n) = A033203(n+1). - Zak Seidov, May 29 2014
A007519 UNION A007520. - R. J. Mathar, Jun 09 2020
L(-2, a(n)) = +1, n >= 1, with the Legendre symbol L. -Wolfdieter Lang, Jul 24 2024

A133870 Primes of the form 32*n + 1.

Original entry on oeis.org

97, 193, 257, 353, 449, 577, 641, 673, 769, 929, 1153, 1217, 1249, 1409, 1601, 1697, 1889, 2017, 2081, 2113, 2273, 2593, 2657, 2689, 2753, 3041, 3137, 3169, 3329, 3361, 3457, 3617, 4001, 4129, 4289, 4481, 4513, 4673, 4801, 4993, 5153, 5281, 5441, 5569
Offset: 1

Views

Author

Zak Seidov, Sep 27 2007

Keywords

Comments

Corresponding n's: 3, 6, 8, 11, 14, 18, 20, 21, 24, 29, 36, 38, 39, ... (A133869).
These primes p are the only ones with the property that for every integer m from interval [0,p) with the Hamming distance D(m,p) = 2 or 3, there exists an integer h from (m,p) with D(m,h) = D(m,p). - Vladimir Shevelev, Apr 19 2012
Primes p such that p XOR 30 = p + 30. - Brad Clardy, Jul 22 2012
Odd primes p such that -1 is a 16th power mod p. - Eric M. Schmidt, Mar 27 2014

Crossrefs

Programs

  • Haskell
    a133870 n = a133870_list !! (n-1)
    a133870_list = filter ((== 1) . a010051) [1,33..]
    -- Reinhard Zumkeller, Mar 06 2012
    
  • Magma
    [p: p in PrimesUpTo(12000) | p mod 32 eq 1 ]; // Vincenzo Librandi, Aug 18 2012
  • Mathematica
    Select[32*Range[175] + 1, PrimeQ] (* Alonso del Arte, Jul 24 2012 *)
    Select[Prime[Range[4000]],MemberQ[{1},Mod[#,32]]&] (* Vincenzo Librandi, Aug 18 2012 *)

A334826 Decimal expansion of Product_{primes p==1 mod 8} (1 - 4/p)*((p + 1)/(p - 1))^2.

Original entry on oeis.org

9, 5, 6, 9, 4, 5, 3, 4, 7, 8, 5, 1, 6, 0, 1, 1, 8, 3, 4, 3, 6, 9, 6, 7, 0, 5, 7, 2, 7, 3, 8, 9, 1, 8, 2, 8, 7, 5, 3, 1, 7, 4, 9, 7, 7, 2, 9, 1, 3, 9, 1, 4, 7, 8, 9, 0, 5, 4, 3, 2, 6, 0, 4, 2, 4, 6, 0, 1, 7, 0, 1, 6, 4, 4, 4, 8, 8, 8, 8, 5, 9, 4, 8, 1, 4, 4, 0, 5, 1, 2, 0, 3, 9, 0, 7, 9, 5
Offset: 0

Views

Author

Vaclav Kotesovec, May 13 2020

Keywords

Comments

Note that Product_{k>=1} (4*k + 1)^2 * (8*k - 3) / (16 * k^2 * (8*k + 1)) = 2^(1/4) * Gamma(1/8)^2 / (sqrt(Pi) * Gamma(1/4)^3) = 0.79906817873784592665354...

Examples

			0.9569453478516011834369670572738918287531749772913914789...
		

Crossrefs

Programs

  • Mathematica
    S[m_, n_, s_] := (t = 1; sums = 0; difs = 1; While[Abs[difs] > 10^(-digits - 5) || difs == 0, difs = (MoebiusMu[t]/t) * Log[If[s*t == 1, DirichletL[m, n, s*t], Sum[Zeta[s*t, j/m]*DirichletCharacter[m, n, j]^t, {j, 1, m}]/m^(s*t)]]; sums = sums + difs; t++]; sums);
    P[m_, n_, s_] := 1/EulerPhi[m] * Sum[Conjugate[DirichletCharacter[m, r, n]] * S[m, r, s], {r, 1, EulerPhi[m]}] + Sum[If[GCD[p, m] > 1 && Mod[p, m] == n, 1/p^s, 0], {p, 1, m}];
    Z[m_, n_, s_] := (w = 1; sumz = 0; difz = 1; While[Abs[difz] > 10^(-digits - 5), difz = P[m, n, s*w]/w; sumz = sumz + difz; w++]; Exp[sumz]);
    Zs[m_, n_, s_] := (w = 2; sumz = 0; difz = 1; While[Abs[difz] > 10^(-digits - 5), difz = (s^w - s) * P[m, n, w]/w; sumz = sumz + difz; w++]; Exp[-sumz]);
    $MaxExtraPrecision = 1000; digits = 121; RealDigits[Chop[N[Zs[8, 1, 4]/Z[8, 1, 2]^2, digits]], 10, digits-1][[1]] (* Vaclav Kotesovec, Jan 15 2021 *)
    (* -------------------------------------------------------------------------- *)
    (* second program, more general *)
    $MaxExtraPrecision = 1000; digits = 121;
    f[p_] := (1 - 4/p)*((p + 1)/(p - 1))^2;
    coefs = Rest[CoefficientList[Series[Log[f[1/x]], {x, 0, 1000}], x]];
    S[m_, n_, s_] := (t = 1; sums = 0; difs = 1; While[Abs[difs] > 10^(-digits - 5) || difs == 0, difs = (MoebiusMu[t]/t) * Log[If[s*t == 1, DirichletL[m, n, s*t], Sum[Zeta[s*t, j/m]*DirichletCharacter[m, n, j]^t, {j, 1, m}]/m^(s*t)]]; sums = sums + difs; t++]; sums);
    P[m_, n_, s_] := 1/EulerPhi[m] * Sum[Conjugate[DirichletCharacter[m, r, n]] * S[m, r, s], {r, 1, EulerPhi[m]}] + Sum[If[GCD[p, m] > 1 && Mod[p, m] == n, 1/p^s, 0], {p, 1, m}];
    m = 2; sump = 0; difp = 1; While[Abs[difp] > 10^(-digits - 5) || difp == 0, difp = coefs[[m]]*(P[8, 1, m] - 1/17^m); sump = sump + difp; m++];
    RealDigits[Chop[N[f[17]*Exp[sump], digits]], 10, digits - 1][[1]] (* Vaclav Kotesovec, Jan 16 2021 *)

A120305 a(n) = Sum_{i=0..n} Sum_{j=0..n} (-1)^(i+j) * (i+j)!/(i!j!).

Original entry on oeis.org

1, 1, 3, 9, 31, 111, 407, 1513, 5679, 21471, 81643, 311895, 1196131, 4602235, 17757183, 68680169, 266200111, 1033703055, 4020716123, 15662273839, 61092127491, 238582873475, 932758045123, 3650336341239, 14298633670931
Offset: 0

Views

Author

Alexander Adamchuk, Jul 14 2006

Keywords

Comments

p divides a((p+1)/2) for prime p = 3, 11, 17, 19, 41, 43, 59, 67, 73, 83, 89, 97, 107, 113, ... (A033200: primes congruent to {1, 3} mod 8; or, odd primes of the form x^2 + 2*y^2).
p divides a((p-3)/2) for prime p = 17, 41, 73, 89, 97, 113, 137, ... (A007519: primes of the form 8n+1).
Essentially the same as partial sums of A072547. - Seiichi Manyama, Jan 30 2023

Crossrefs

Programs

  • Mathematica
    Table[Sum[Sum[(-1)^(i+j)*(i+j)!/(i!j!),{i,0,n}],{j,0,n}],{n,0,50}]
  • PARI
    a(n) = sum(i=0, n, sum(j=0, n, (-1)^(i+j) * (i+j)!/(i!*j!))); \\ Michel Marcus, Apr 02 2019
    
  • PARI
    a(n) = sum(i=0, 2*n, (-1)^i*i!*polcoef(sum(j=0, n, x^j/j!)^2, i)); \\ Seiichi Manyama, May 20 2019
    
  • PARI
    my(N=30, x='x+O('x^N)); Vec((1+sqrt(1-4*x))/(sqrt(1-4*x)*(1-x)*(3-sqrt(1-4*x)))) \\ Seiichi Manyama, Jan 30 2023

Formula

a(n) = Sum_{j=0..n} Sum_{i=0..n} (-1)^(i+j)*(i+j)!/(i!j!).
Recurrence: 2*n*(3*n-5)*a(n) = 3*(9*n^2 - 19*n + 8)*a(n-1) - 3*(n-1)*(3*n-4)*a(n-2) - 2*(2*n-3)*(3*n-2)*a(n-3). - Vaclav Kotesovec, Aug 13 2013
a(n) ~ 4^(n+1)/(9*sqrt(Pi*n)). - Vaclav Kotesovec, Aug 13 2013
G.f.: ( 1/(sqrt(1-4*x) * (1-x)) ) * ( (1 - x *c(x))/(1 + x *c(x)) ), where c(x) is the g.f. of A000108. - Seiichi Manyama, Jan 30 2023
From Seiichi Manyama, Apr 06 2024: (Start)
a(n) = Sum_{k=0..floor(n/3)} (-1)^k * binomial(2*n-3*k-1,n-3*k).
a(n) = [x^n] 1/((1+x^3) * (1-x)^n). (End)

A139487 Numbers k such that 8k + 7 is prime.

Original entry on oeis.org

0, 2, 3, 5, 8, 9, 12, 15, 18, 20, 23, 24, 27, 29, 32, 33, 38, 44, 45, 47, 53, 54, 57, 59, 60, 62, 74, 75, 78, 80, 89, 90, 92, 93, 102, 104, 107, 110, 113, 114, 120, 122, 123, 128, 129, 132, 135, 137, 143, 152, 153, 159, 162, 164, 165, 170, 174, 177, 179, 180, 183, 185
Offset: 1

Views

Author

Artur Jasinski, Apr 23 2008

Keywords

Comments

For numbers k such that:
8k+1 is prime see A005123, primes see A007519;
8k+3 is prime see A005124, primes see A007520;
8k+5 is prime see A105133, primes see A007521;
8k+7 is prime see A139487, primes see A007522.
8k + 7 divides A000225(4k+3). - Jinyuan Wang, Mar 08 2019

Crossrefs

Programs

  • Magma
    [n: n in [0..200] | IsPrime(8*n+7)]; // Vincenzo Librandi, Jun 25 2014
    
  • Mathematica
    a = {}; Do[If[PrimeQ[8 n + 7], AppendTo[a, n]], {n, 0, 300}]; a
    Select[Range[0,200],PrimeQ[8#+7]&] (* Harvey P. Dale, Oct 10 2012 *)
  • PARI
    is(n)=isprime(8*n+7) \\ Charles R Greathouse IV, Feb 17 2017

Formula

a(n) = (A007522(n) - 7)/8, n >= 1.

A141849 Primes congruent to 1 mod 11.

Original entry on oeis.org

23, 67, 89, 199, 331, 353, 397, 419, 463, 617, 661, 683, 727, 859, 881, 947, 991, 1013, 1123, 1277, 1321, 1409, 1453, 1607, 1783, 1871, 2003, 2069, 2113, 2179, 2267, 2311, 2333, 2377, 2399, 2531, 2663, 2707, 2729, 2861, 2927, 2971, 3037, 3169, 3191, 3257
Offset: 1

Views

Author

N. J. A. Sloane, Jul 11 2008

Keywords

Comments

Conjecture: Also primes p such that ((x+1)^11-1)/x has 10 distinct irreducible factors of degree 1 over GF(p). - Federico Provvedi, Apr 17 2018
Primes congruent to 1 mod 22. - Chai Wah Wu, Apr 28 2025

Crossrefs

Prime sequences A# (k,r) of the form k*n+r with 0 <= r <= k-1 (i.e., primes == r (mod k), or primes p with p mod k = r) and gcd(r,k)=1: A000040 (1,0), A065091 (2,1), A002476 (3,1), A003627 (3,2), A002144 (4,1), A002145 (4,3), A030430 (5,1), A045380 (5,2), A030431 (5,3), A030433 (5,4), A002476 (6,1), A007528 (6,5), A140444 (7,1), A045392 (7,2), A045437 (7,3), A045471 (7,4), A045458 (7,5), A045473 (7,6), A007519 (8,1), A007520 (8,3), A007521 (8,5), A007522 (8,7), A061237 (9,1), A061238 (9,2), A061239 (9,4), A061240 (9,5), A061241 (9,7), A061242 (9,8), A030430 (10,1), A030431 (10,3), A030432 (10,7), A030433 (10,9), this sequence (11,1), A090187 (11,2), A141850 (11,3), A141851 (11,4), A141852 (11,5), A141853 (11,6), A141854 (11,7), A141855 (11,8), A141856 (11,9), A141857 (11,10), A068228 (12,1), A040117 (12,5), A068229 (12,7), A068231 (12,11).
Cf. A034694 (smallest prime == 1 (mod n)).
Cf. A038700 (smallest prime == n-1 (mod n)).
Cf. A038026 (largest possible value of smallest prime == r (mod n)).

Programs

Formula

a(n) ~ 10n log n. - Charles R Greathouse IV, Jul 02 2016

A076339 Primes of the form 512*k+1.

Original entry on oeis.org

7681, 10753, 11777, 12289, 13313, 15361, 17921, 18433, 19457, 23041, 25601, 26113, 32257, 36353, 37889, 39937, 40961, 45569, 50177, 51713, 58369, 59393, 61441, 64513, 65537, 67073, 70657, 76289, 76801, 79873, 80897, 81409, 83969
Offset: 1

Views

Author

Reinhard Zumkeller, Oct 07 2002

Keywords

Comments

Odd primes p such that -1 is a 256th power mod p. - Eric M. Schmidt, Mar 27 2014

Examples

			A076338(15) = 512*15+1 = a(1) = 7681 = A000040(974);
A076338(21) = 512*21+1 = a(2) = 10753 = A000040(1311);
a(38) - a(37) = 95233 - 87553 = 7680 = a(1)-1.
		

References

  • M. Kraitchik, Theorie des Nombres, Gauthier-Villars (I. 1922, II. 1929).
  • M. Kraitchik, Recherches sur la theorie des nombres, Gauthier-Villars (1924).

Crossrefs

Programs

  • Haskell
    a076339 n = a076339_list !! (n-1)
    a076339_list = filter ((== 1) . a010051) [1,513..]
    -- Reinhard Zumkeller, Mar 06 2012
    
  • Mathematica
    Select[512 Range[164] + 1, PrimeQ] (* Bruno Berselli, Feb 23 2012 *)
  • PARI
    forprimestep(p=7681,83969,512, print1(p", ")) \\ Charles R Greathouse IV, Nov 01 2022

Formula

a(n) ~ 256n log n. - Charles R Greathouse IV, Nov 01 2022

A142925 Primes congruent to 1 mod 64.

Original entry on oeis.org

193, 257, 449, 577, 641, 769, 1153, 1217, 1409, 1601, 2113, 2689, 2753, 3137, 3329, 3457, 4289, 4481, 4673, 4801, 4993, 5441, 5569, 5953, 6337, 6529, 6977, 7297, 7489, 7681, 7873, 7937, 8513, 8641, 9281, 9473, 9601, 9857, 10177, 10369, 10433, 10753, 11329
Offset: 1

Views

Author

N. J. A. Sloane, Jul 11 2008

Keywords

Comments

Odd primes p such that -1 is a 32nd power mod p. - Eric M. Schmidt, Mar 27 2014

Crossrefs

Programs

A208177 Primes of the form 128*k + 1.

Original entry on oeis.org

257, 641, 769, 1153, 1409, 2689, 3329, 3457, 4481, 4993, 6529, 7297, 7681, 7937, 9473, 9601, 9857, 10369, 10753, 11393, 11777, 12161, 12289, 13313, 13441, 13697, 14081, 14593, 15233, 15361, 16001, 17921, 18049, 18433, 19073, 19457, 19841, 20353, 21121, 21377
Offset: 1

Views

Author

Bruno Berselli, Feb 25 2012

Keywords

Comments

Odd primes p such that -1 is a 64th power mod p. - Eric M. Schmidt, Mar 27 2014

Crossrefs

Programs

  • Haskell
    a208177 n = a208177_list !! (n-1)
    a208177_list = filter ((== 1) . a010051) [1,129..]
    -- Reinhard Zumkeller, Mar 06 2012
  • Magma
    [ p: p in PrimesUpTo(22000) | p mod 128 eq 1 ];
    
  • Mathematica
    Select[128 Range[167] + 1, PrimeQ]
  • PARI
    for(n=1,167,r=128*n+1; if(isprime(r), print1(r", ")));
    

Formula

a(n) ~ 64n log n. - Charles R Greathouse IV, Nov 01 2022

A014754 Primes p == 1 mod 8 such that 2 and -2 are both 4th powers (one implies other) mod p.

Original entry on oeis.org

73, 89, 113, 233, 257, 281, 337, 353, 577, 593, 601, 617, 881, 937, 1033, 1049, 1097, 1153, 1193, 1201, 1217, 1249, 1289, 1433, 1481, 1553, 1601, 1609, 1721, 1753, 1777, 1801, 1889, 1913, 2089, 2113, 2129, 2273, 2281, 2393, 2441, 2473, 2593, 2657, 2689
Offset: 1

Views

Author

Keywords

Comments

Primes p such that x^4 == 2 has more than two (in fact four) solutions mod p. This is the sequence of terms common to A040098 (primes p such that x^4 == 2 has a solution mod p) and A007519 (primes of form 8n+1). Solutions mod p are represented by integers from 0 to p - 1. For p > 2, i is a solution mod p of x^4 == 2 iff p - i is a solution mod p of x^4 == 2, thus the sum of first and fourth solution is p and so is the sum of second and third solution. The solutions are given in A065909, A065910, A065911 and A065912. - Klaus Brockhaus, Nov 28 2001
Primes of the form x^2+64y^2. - T. D. Noe, May 13 2005

Crossrefs

Programs

  • PARI
    A014754(m) = local(p,s,x,z); forprime(p = 3,m,s = []; for(x = 0,p-1, if(x^4%p == 2%p,s = concat(s,[x]))); z = matsize(s)[2]; if(z>2,print1(p,",")))
    
  • PARI
    {a(n) = local(m, c, x); if( n<1, 0, c = 0; m = 1; while( cMichael Somos, Mar 22 2008 */
    
  • PARI
    forprime(p=1, 9999, p%8==1&&ispower(Mod(2, p), 4)&&print1(p", ")) \\ M. F. Hasler, Feb 18 2014
    
  • PARI
    is_A014754(p)={p%8==1&&ispower(Mod(2, p), 4)&&isprime(p)} \\ M. F. Hasler, Feb 18 2014

Extensions

Removed erroneous Mma program; extended b-file using first PARI program of M. F. Hasler. - N. J. A. Sloane, Jun 06 2014
Previous Showing 31-40 of 100 results. Next