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.

A227782 Stufe of Q(sqrt(-n)): least number of squares which add to -1 in the field Q(sqrt(-n)).

This page as a plain text file.
%I A227782 #11 Aug 15 2013 08:53:48
%S A227782 1,2,2,1,2,2,4,2,1,2,2,2,2,2,4,1,2,2,2,2,2,2,4,2,1,2,2,4,2,2,4,2,2,2,
%T A227782 2,1,2,2,4,2,2,2,2,2,2,2,4,2,1,2,2,2,2,2,4,2,2,2,2,4,2,2,4,1,2,2,2,2,
%U A227782 2,2,4,2,2,2,2,2,2,2,4,2,1,2,2,2,2,2,4,2,2,2,2,4,2
%N A227782 Stufe of Q(sqrt(-n)): least number of squares which add to -1 in the field Q(sqrt(-n)).
%C A227782 If n >= 0 then Q(sqrt(n)) is formally real and its stufe is said to be infinite.
%D A227782 Ian G. Connell, The stufe of number fields, Mathematische Zeitschrift 124:1 (1972), pp. 20-22.
%D A227782 A. R. Rajwade, Squares, Cambridge Univ. Press, 1983.
%H A227782 Charles R Greathouse IV, <a href="/A227782/b227782.txt">Table of n, a(n) for n = 1..10000</a>
%H A227782 Trygve Nagell, <a href="http://matwbn.icm.edu.pl/ksiazki/aa/aa21/aa21130.pdf">Sur la résolubilité de l'équation x^2 + y^2 + z^2 = 0 dans un corps quadratique</a>, Acta Arithmetica 21:1 (1972), pp. 35-43.
%H A227782 A. R. Rajwade, <a href="http://www.new.dli.ernet.in/rawdataupload/upload/insa/INSA_1/20005b92_725.pdf">A note on the stufe of quadratic fields</a>, Indian J. Pure Appl. Math. 6:7 (1975), pp. 725-726.
%H A227782 Kazimierz Szymiczek, <a href="http://matwbn.icm.edu.pl/ksiazki/aa/aa25/aa2536.pdf">Note on a paper by T. Nagell</a>, Acta Arithmetica 25:3 (1974), pp. 313f.
%H A227782 Wikipedia, <a href="http://en.wikipedia.org/wiki/Stufe_(algebra)">Stufe (algebra)</a>
%F A227782 a(n) = 1 if n is a square; a(n) = 4 if n is of the form 4^k(8m+7) for some m; a(n) = 2 otherwise.
%e A227782 a(1) = a(4) = a(9) = 1 since Q(sqrt(-1)) = Q(sqrt(-4)) = Q(sqrt(-9)) = Q(i) has a square equal to -1: i^2 = -1.
%e A227782 a(3) = 2 since ((w+1)/2)^2 + ((w-1)/2)^2 = -1 where w = sqrt(-3).
%o A227782 (PARI) a(n)=n=core(n);if(n%8==7,4,if(n==1,1,2))
%o A227782 (PARI) a(n)=n>>=(valuation(n,2)\2*2); if(n%8==7, 4, 2-issquare(n))
%Y A227782 Cf. A227781, A227783.
%K A227782 nonn,easy
%O A227782 1,2
%A A227782 _Charles R Greathouse IV_, Jul 31 2013