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.

A249782 a(1)=2; thereafter, a(n) is the smallest prime not yet used which is compatible with the condition that a(n) is a quadratic residue modulo a(k) for the next n indices k = n+1, n+2, ..., 2n.

This page as a plain text file.
%I A249782 #24 Jan 26 2024 12:47:28
%S A249782 2,7,3,37,11,83,107,139,43,211,193,881,751,2777,2633,5981,6563,10531,
%T A249782 3407,9871,12421,23873,6449,164789,3547,39877,248909,370081,528883,
%U A249782 1144453,574813,1201153,1428929,2225053,1397719
%N A249782 a(1)=2; thereafter, a(n) is the smallest prime not yet used which is compatible with the condition that a(n) is a quadratic residue modulo a(k) for the next n indices k = n+1, n+2, ..., 2n.
%C A249782 L(a(n)/a(k)) = 1 for the next n indices k = n+1, n+2, ..., 2n where L(a/p) is the Legendre symbol.
%e A249782 a(1) = 2 because the next term is 7 and L(2/7) = 1;
%e A249782 a(2) = 7 because the next two terms are (3,37) => L(7/3) = 1 and L(7/37) = 1;
%e A249782 a(3) = 3 because the next three terms are (37,11,83) => L(3/37) = 1, L(3/11) = 1 and L(3/83) = 1.
%o A249782 (PARI) m=35; v=vector(m); u=vectorsmall(10000*m); for(n=1, m, for(i=1, 10^9, if(!u[i], for(j=(n+1)\2, n-1, if(kronecker(v[j], prime(i))==-1 | | kronecker(v[j],prime(i))==0, next(2))); v[n]=prime(i); u[i]=1; break))); v
%Y A249782 Cf. A249692, A249778.
%K A249782 nonn,more
%O A249782 1,1
%A A249782 _Michel Lagneau_, Nov 05 2014