A227782 Stufe of Q(sqrt(-n)): least number of squares which add to -1 in the field Q(sqrt(-n)).
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, 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, 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
Offset: 1
Examples
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. a(3) = 2 since ((w+1)/2)^2 + ((w-1)/2)^2 = -1 where w = sqrt(-3).
References
- Ian G. Connell, The stufe of number fields, Mathematische Zeitschrift 124:1 (1972), pp. 20-22.
- A. R. Rajwade, Squares, Cambridge Univ. Press, 1983.
Links
- Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
- Trygve Nagell, Sur la résolubilité de l'équation x^2 + y^2 + z^2 = 0 dans un corps quadratique, Acta Arithmetica 21:1 (1972), pp. 35-43.
- A. R. Rajwade, A note on the stufe of quadratic fields, Indian J. Pure Appl. Math. 6:7 (1975), pp. 725-726.
- Kazimierz Szymiczek, Note on a paper by T. Nagell, Acta Arithmetica 25:3 (1974), pp. 313f.
- Wikipedia, Stufe (algebra)
Programs
-
PARI
a(n)=n=core(n);if(n%8==7,4,if(n==1,1,2))
-
PARI
a(n)=n>>=(valuation(n,2)\2*2); if(n%8==7, 4, 2-issquare(n))
Formula
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.
Comments