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-10 of 83 results. Next

A254938 Fundamental positive solution x = x1(n) of the first class of the Pell equation x^2 - 2*y^2 = -A007522(n), n >= 1 (primes congruent to 7 mod 8).

Original entry on oeis.org

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

Views

Author

Wolfdieter Lang, Feb 18 2015

Keywords

Comments

For the corresponding term y1(n) see 2*A255232(n).
For the positive fundamental proper (sometimes called primitive) solutions x2(n) and y2(n) of the second class of this (generalized) Pell equation see A255233(n) and A255234(n).
The present solutions of this first class are the smallest positive ones.
See the Nagell reference Theorem 111, p. 210, for the proof of the existence of solutions (the discriminant of this binary quadratic form is +8 hence it is an indefinite form with an infinitude of solutions if there exists at least one).
See the Nagell reference Theorem 110, p. 208, for the proof that there are only two classes of solutions for this Pell equation, because the equation is solvable and each prime from A007522 does not divide 4.
The present fundamental solutions are found according to the Nagell reference Theorem 108a, p. 206-207, adapted to the case at hand, by scanning the following two inequalities for solutions x1(n) = 2*X1(n) + 1 and y1(n) = 2*Y1(n) (because odd y is out in this Pell equation). The interval to be scanned for X1(n) is [0, floor((sqrt(p(n))-1)/2)] and for Y1(n) it is [0, floor(sqrt(p(n))/2)], with p(n) = A007522(n).
The general positive proper solutions are for both classes obtained by applying positive powers of the matrix M = [[3,4],[2,3]] on the fundamental positive column vectors (x(n),y(n))^T. The n-th power is M^n = S(n-1, 6)*M - S(n-2, 6) 1_2, where 1_2 is the 2 X 2 identity matrix and S(n, 6), with S(-2, 6) = -1 and S(-1, 6) = 0, is the Chebyshev S-polynomial evaluated at x = 6, given in A001109(n).
The least positive x solutions (that is those of the first class) for the primes +1 and -1 (mod 8) together (including prime 2) are given in A255235.

Examples

			The first pairs [x1(n), y1(n)] of the fundamental positive solutions of this first class are (the prime A007522(n) is listed as first entry):
  [7, [1, 2]], [23, [3, 4]], [31, [1, 4]],
  [47, [5, 6]], [71, [1, 6]], [79, [7, 8]],
  [103, [5, 8]], [127, [1, 8]], [151, [7, 10]],
  [167, [11, 12]], [191, [3, 10]], [199, [1, 10]], [223, [13, 14]], [239, [7, 12]], [263, [5, 12]], [271, [11, 14]], [311, [9, 14]], [359, [17, 18]], [367, [5, 14]], [383, [3, 14]], [431, [9, 16]], [439, [19, 20]], [463, [7, 16]], [479, [13, 18]], [487, [5, 16]], [503, [3, 16]], ...
n=1: 1^2 - 2*(2*1)^2 = 1 - 8 = -7 = -A007522(1), ...
		

References

  • T. Nagell, Introduction to Number Theory, Chelsea Publishing Company, New York, 1964.

Crossrefs

Cf. A007522 (primes == 7 mod 8).
Cf. A255232 (corresponding y2 values, halved), A255233 (x2 values), A255234 (y2 values), A255235.
Cf. A254934 - A254937 (similar for primes == 1 mod 8).

Programs

  • PARI
    apply( {A254938(n, p=A007522(n))=Set(abs(qfbsolve(Qfb(-1, 0, 2), p, 1)))[1][1]}, [1..88]) \\ The 2nd optional arg allows to directly specify the prime. - M. F. Hasler, May 22 2025

Formula

a(n)^2 - 2*(2*A255232(n))^2 = -A007522(n), n >= 1, gives the smallest positive (proper) solution of this (generalized) Pell equation.

Extensions

More terms from Colin Barker, Feb 23 2015

A255232 One half of the fundamental positive solution y = y1(n) of the first class of the Pell equation x^2 - 2*y^2 = -A007522(n), n >= 1 (primes congruent to 7 mod 8).

Original entry on oeis.org

1, 2, 2, 3, 3, 4, 4, 4, 5, 6, 5, 5, 7, 6, 6, 7, 7, 9, 7, 7, 8, 10, 8, 9, 8, 8, 9, 11, 10, 9, 10, 13, 11, 10, 13, 14, 12, 11, 13, 11, 11, 12, 13, 12, 14, 13, 16, 12, 12, 17, 13, 14, 13, 16, 13, 18, 14, 16, 15, 14, 17, 14, 15, 14, 14, 14, 17, 16, 19, 16, 17, 16, 20, 21, 17, 16, 17, 16, 16
Offset: 1

Views

Author

Wolfdieter Lang, Feb 18 2015

Keywords

Comments

For the corresponding term x1(n) see A254938(n).
See A254938 also for the Nagell reference.
The least positive y solutions (that is those of the first class) for the primes +1 and -1 (mod 8) together (including prime 2) are given in A255246.

Examples

			See A254938.
n = 3: 1^2 - 2*(2*2)^2 = 1 - 32  = -31 = -A007522(3).
		

Crossrefs

Cf. A007522 (primes == 7 mod 8), A254938 (corresponding x1 values), A255233 (x2 values), A255234 (y2 values), A255246, A254935.

Programs

  • PARI
    apply( {A255232(n, p=A007522(n))=Set(abs(qfbsolve(Qfb(-1, 0, 2), p, 1)))[1][2]\2}, [1..88]) \\ The 2nd optional arg allows to directly specify the prime. - M. F. Hasler, May 22 2025

Formula

A254938(n)^2 - 2*(2*a(n))^2 = -A007522(n) gives the smallest positive (proper) solution of this (generalized) Pell equation.

Extensions

More terms from Colin Barker, Feb 23 2015
Double-checked and extended by M. F. Hasler, May 22 2025

A255233 Fundamental positive solution x = x2(n) of the second class of the Pell equation x^2 - 2*y^2 = -A007522(n), n >= 1 (primes congruent to 7 mod 8).

Original entry on oeis.org

5, 7, 13, 9, 21, 11, 17, 29, 19, 15, 31, 37, 17, 27, 33, 23, 29, 21, 41, 47, 37, 23, 43, 33, 49, 55, 51, 31, 41, 69, 53, 29, 43, 59, 35, 31, 45, 61, 41, 67, 85, 57, 47, 63, 43, 53, 35, 75, 93, 37, 71, 61, 83, 47, 89, 39, 73, 53, 63, 79, 49, 85, 69, 97, 103, 109, 55, 65, 47, 77, 67, 83, 49
Offset: 1

Views

Author

Wolfdieter Lang, Feb 18 2015

Keywords

Comments

The corresponding term y = y2(n) of this fundamental solution of the second class of the (generalized) Pell equation x^2 - 2*y^2 = -A007522(n) = -(1 + A139487(n)*8) is given in 2*A255234(n).
For comments and the Nagell reference see A254938.

Examples

			The first pairs [x2(n), y2(n)] of the fundamental positive solutions of this second class are (the prime A007522(n) appears as first entry):
  [7, [5, 4]], [23, [7, 6]], [31, [13, 10]],
  [47, [9, 8]], [71, [21, 16]], [79, [11, 10]], [103, [17, 14]], [127, [29, 22]],
  [151, [19, 16]], [167, [15, 14]],
  [191, [31, 24]], [199, [37, 28]],
  [223, [17, 16]], [239, [27, 22]],
  [263, [33, 26]], [271, [23, 20]],
  [311, [29, 24]], [359, [21, 20]],
  [367, [41, 32]], [383, [47, 36]],
  [431, [37, 30]], [439, [23, 22]],
  [463, [43, 34]], [479, [33, 28]], ...
n= 4: 9^2 - 2*(2*4)^2 = -47 = -A007522(4).
a(4) = -(3*5 - 4*(2*3)) = 24 - 15 = 9.
		

Crossrefs

Cf. A007522 (primes == 7 mod 8), A139487 (8k+7 is prime).
Cf. 2*A255234 (corresponding y2 values), A254938 (x1 values), 2*A255232 (y2 values), A255247, A254936.

Programs

  • PARI
    apply( {A255233(n, p=A007522(n))=Set(abs(qfbsolve(Qfb(-1, 0, 2), p, 1)))[1]*[-3,4]~}, [1..88]) \\ The 2nd optional arg allows to directly specify the prime. - M. F. Hasler, May 22 2025

Formula

a(n)^2 - 2*(2*A255234(n))^2 = -A007522(n) gives the second smallest positive (proper) solution of this (generalized) Pell equation.
a(n) = -(3*A254938(n) - 4*2*A255232(n)), n >= 1.

Extensions

More terms from Colin Barker, Feb 23 2015
Double-checked and extended by M. F. Hasler, May 22 2025

A255234 One half of the fundamental positive solution y = y2(n) of the second class of the Pell equation x^2 - 2*y^2 = -A007522(n), n>=1 (primes congruent to 7 mod 8).

Original entry on oeis.org

2, 3, 5, 4, 8, 5, 7, 11, 8, 7, 12, 14, 8, 11, 13, 10, 12, 10, 16, 18, 15, 11, 17, 14, 19, 21, 20, 14, 17, 26, 21, 14, 18, 23, 16, 15, 19, 24, 18, 26, 32, 23, 20, 25, 19, 22, 17, 29, 35, 18, 28, 25, 32, 21, 34, 19, 29, 23, 26, 31, 22, 33, 28, 37, 39, 41, 24, 27, 22, 31, 28, 33, 23, 22, 30
Offset: 1

Views

Author

Wolfdieter Lang, Feb 19 2015

Keywords

Comments

The corresponding fundamental solution x2(n) of this second class of positive solutions is given in A255233(n).
See the comments and the Nagell reference in A254938.

Examples

			n = 2: 7^2 - 2*(2*3)^2 = 49 - 72  = -23 = - A007522(2).
a(3) = -(1 - 3*2) = 5.
See also A255233.
		

Crossrefs

Programs

  • PARI
    apply( {A255234(n, p=A007522(n))=Set(abs(qfbsolve(Qfb(-1, 0, 2), p, 1)))[1]*[-1,3/2]~}, [1..88]) \\ The 2nd optional arg allows to directly specify the prime. - M. F. Hasler, May 22 2025

Formula

A255233(n)^2 - 2*(2*a(n))^2 = -A007522(n) gives the second smallest positive (proper) solution of this (generalized) Pell equation.
a(n) = -(A254938(n) - 3*A255232(n)), n >= 1.

Extensions

More terms from Colin Barker, Feb 24 2015
Double-checked and extended by M. F. Hasler, May 22 2025

A141175 Duplicate of A007522.

Original entry on oeis.org

7, 23, 31, 47, 71, 79, 103, 127, 151, 167, 191, 199, 223, 239, 263, 271, 311, 359, 367, 383, 431, 439, 463, 479, 487, 503, 599, 607, 631, 647, 719, 727, 743, 751, 823, 839, 863, 887, 911, 919, 967, 983, 991, 1031, 1039, 1063, 1087, 1103, 1151, 1223, 1231
Offset: 1

Views

Author

Laura Caballero Fernandez, Lourdes Calvo Moguer, Maria Josefa Cano Marquez, Oscar Jesus Falcon Ganfornina and Sergio Garrido Morales (oscfalgan(AT)yahoo.es), Jun 12 2008

Keywords

Comments

Original title was "Primes of the form -x^2 + 4xy + 4y^2 (as well as of the form 7x^2 + 12xy + 4y^2)."
R. J. Mathar was the first to wonder if this entry is a duplicate. By elementary means, I very easily proved that all primes of this form are also of the form 8n + 7 (which is A007522). Then Don Reble demonstrated that each prime of the form 8n + 7 has a corresponding representation as -x^2 + 4xy + 4y^2. Therefore the two sequences are in fact the same. - Alonso del Arte, Nov 21 2016

Extensions

More terms from Colin Barker, Apr 05 2015

A095012 Number of 8k+7 primes (A007522) in range ]2^n,2^(n+1)].

Original entry on oeis.org

0, 1, 0, 2, 1, 4, 6, 12, 17, 36, 62, 118, 222, 395, 773, 1412, 2699, 5100, 9690, 18384, 35074, 67076, 128446, 246483, 473737, 911126, 1757021, 3390639, 6551367, 12675525, 24545392, 47584301, 92330675, 179318608, 348546687, 678022783, 1319953810, 2571408262
Offset: 1

Views

Author

Antti Karttunen and Labos Elemer, Jun 01 2004

Keywords

Crossrefs

Programs

Formula

a(n) = A095013(n) - A095009(n).

Extensions

a(34)-a(38) from Amiram Eldar, Jun 12 2024

A096635 Let p = n-th prime == 7 mod 8 (A007522); a(n) = smallest prime q such that p is not a square mod q.

Original entry on oeis.org

5, 3, 7, 3, 3, 11, 5, 5, 11, 3, 3, 7, 5, 3, 3, 7, 3, 3, 5, 3, 3, 7, 5, 3, 5, 3, 3, 5, 13, 3, 3, 5, 3, 17, 5, 3, 3, 3, 3, 11, 5, 3, 17, 3, 7, 5, 5, 3, 3, 3, 7, 7, 5, 3, 5, 3, 7, 5, 3, 5, 11, 3, 3, 5, 3, 5, 3, 3, 5, 11, 5, 3, 13, 3, 3, 7, 7, 11, 3, 3, 3, 3, 5, 3, 7, 5, 19, 3, 5, 3, 3, 3, 5, 3, 7, 3, 5, 3, 13
Offset: 1

Views

Author

Robert G. Wilson v, Jun 24 2004

Keywords

Programs

  • Maple
    P:= select(isprime, [seq(i,i=7..3000,8)]):
    f:= proc(n) local p,q;
      p:= P[n]; q:= 2;
      while numtheory:-quadres(p,q)=1 do q:= nextprime(q) od;
      q
    end proc:
    map(f, [$1..nops(P)]); # Robert Israel, Mar 13 2020
  • Mathematica
    f[n_] := Block[{k = 2}, While[ JacobiSymbol[n, Prime[k]] == 1, k++ ]; Prime[k]]; f /@ Select[ Prime[ Range[435]], Mod[ #, 8] == 7 &]

A186302 a(n) = ( A007522(n)-1 )/2.

Original entry on oeis.org

3, 11, 15, 23, 35, 39, 51, 63, 75, 83, 95, 99, 111, 119, 131, 135, 155, 179, 183, 191, 215, 219, 231, 239, 243, 251, 299, 303, 315, 323, 359, 363, 371, 375, 411, 419, 431, 443, 455, 459, 483, 491, 495, 515, 519, 531, 543, 551
Offset: 1

Views

Author

Marco Matosic, Feb 17 2011

Keywords

Comments

From Wolfdieter Lang, Oct 24 2013: (Start)
Each a(n) is of course congruent 3 (mod 4).
a(n) = A055034(p7m8(n)), with p7m8(n) := A007522(n). This is the degree of the minimal polynomial of rho(p7m8(n)):= 2*cos(Pi/p7m8(n)), called C(p7m8(n), x) in A187360. (End)

Examples

			Degree of minimal polynomial C(prime 7 (mod 8), x):
n = 2, p7m8(2) = A007522(2) = 23, delta(23) = 11. - _Wolfdieter Lang_, Oct 24 2013
		

Crossrefs

Programs

Formula

a(n) = A186303(n)-1.

A254766 Fundamental positive solution x = x2(n) of the second class of the Pell equation x^2 - 2*y^2 = A007522(n), n >=1 (primes congruent to 7 mod 8).

Original entry on oeis.org

5, 11, 9, 17, 13, 23, 21, 17, 27, 35, 23, 21, 41, 31, 29, 39, 37, 53, 33, 31, 41, 59, 39, 49, 37, 35, 43, 63, 53, 37, 49, 77, 59, 47, 75, 83, 65, 53, 73, 51, 45, 61, 71, 59, 79, 69, 95, 55, 49, 101
Offset: 1

Views

Author

Wolfdieter Lang, Feb 11 2015

Keywords

Comments

The corresponding term y = y2(n) of this fundamental solution of the second class of the (generalized) Pell equation x^2 - 2*y^2 = A007522(n) = 7 + 8*A139487(n) is given in A254929(n).
The positive fundamental solutions of the first classes are given in (A254764(n), A254765(n)).
For comments and the Nagell reference see A254764.

Examples

			The first pairs [x2(n), y2(n)] of the fundamental positive solutions of the second class are (we list the prime A007522(n) as first entry): [7,[5,3]], [23,[11,7]], [31,[9,5]], [47,[17,11]], [71,[13,7]], [79,[23,15]], [103,[21,13]], [127,[17,9]], [151,[27,17]], [167,[35,23]], [191,[23,13]], [199,[21,11]], [223,[41,27]], [239,[31,19]], [263,[29,17]], [271,[39,25]], ...
		

Crossrefs

Formula

a(n)^2 - 2*(A254929(n))^2 = A007522(n) gives the second smallest positive (proper) solution of this (generalized) Pell equation.
a(n) = 3*A254764(n) - 4*A254765(n), n >= 1.

A254929 Fundamental positive solution y = y2(n) of the second class of the Pell equation x^2 - 2*y^2 = A007522(n), n>=1 (primes congruent to 7 mod 8).

Original entry on oeis.org

3, 7, 5, 11, 7, 15, 13, 9, 17, 23, 13, 11, 27, 19, 17, 25, 23, 35, 19, 17, 25, 39, 23, 31, 21, 19, 25, 41, 33, 19, 29, 51, 37, 27, 49, 55, 41, 31, 47, 29, 23, 37, 45, 35, 51, 43, 63, 31, 25, 67
Offset: 1

Views

Author

Wolfdieter Lang, Feb 11 2015

Keywords

Comments

The corresponding fundamental solution x2(n) of this second class of positive solutions is given in A254766(n).
See the comments and the Nagell reference in A254764.

Examples

			n = 2: 11^2 - 2*7^2 = 121 - 98 = 23.
The smallest positive solution is (x1(2), y1(2)) = (5, 1) from (A254764(2), A254765(2)).
See also A254766.
a(4) = 2*7 - 3*1 = 11.
		

Crossrefs

Formula

A254766(n)^2 - 2*a(n)^2 = A007522(n) gives the second smallest positive (proper) solution of this (generalized) Pell equation.
a(n) = 2*A254764(n) - 3*A254765(n), n >= 1.
Showing 1-10 of 83 results. Next