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.

A260911 Least positive integer k < prime(n) such that there are 0 < i < j < k for which i^2 + j^2 = k^2 and i,j,k are all quadratic residues modulo prime(n), or 0 if no such k exists.

Original entry on oeis.org

0, 0, 0, 0, 5, 0, 0, 0, 0, 25, 0, 34, 0, 41, 25, 25, 5, 5, 26, 5, 37, 0, 41, 0, 0, 65, 17, 34, 5, 61, 17, 5, 17, 25, 25, 29, 37, 26, 25, 41, 5, 5, 5, 25, 25, 53, 34, 17, 34, 5, 109, 5, 5, 5, 17, 37, 34, 41, 34, 53
Offset: 1

Views

Author

Zhi-Wei Sun, Aug 03 2015

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 25. In other words, for any prime p > 100, we have a^2 + b^2 = c^2 for some a,b,c in the set R(p) = {0
(ii) For any prime p > 50, we have a^2 + b^2 = c^2 for some a,b,c in the set N(p) = {0
(iii) For any prime p > 32, we have a^2 + b^2 = c^2 for some a,b in the set R(p) and c in the set N(p).
(iv) For any prime p > 72, we have a^2 + b^2 = c^2 for some a,b in the set N(p) and c in the set R(p).
I have verified the conjecture for primes p < 1.5*10^7.

Examples

			a(10) = 25 since 7^2 + 24^2 = 25^2, and 7, 24, 25 are all quadratic residues modulo prime(10) = 29.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=IntegerQ[Sqrt[n]]
    Do[Do[If[JacobiSymbol[k,Prime[n]]<1,Goto[bb]];Do[If[JacobiSymbol[j,Prime[n]]<1,Goto[cc]];
    If[SQ[k^2-j^2]&&JacobiSymbol[Sqrt[k^2-j^2],Prime[n]]==1,Print[n," ",k];Goto[aa]];Label[cc];Continue,{j,1,k-1}];Label[bb];Continue,{k,1,Prime[n]-1}];
    Print[n," ",0];Label[aa];Continue,{n,1,50}]