login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A227782 Stufe of Q(sqrt(-n)): least number of squares which add to -1 in the field Q(sqrt(-n)). 2
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 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
If n >= 0 then Q(sqrt(n)) is formally real and its stufe is said to be infinite.
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)
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.
EXAMPLE
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).
PROG
(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))
CROSSREFS
Sequence in context: A038541 A070215 A071457 * A255771 A334590 A115034
KEYWORD
nonn,easy
AUTHOR
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified August 25 06:02 EDT 2024. Contains 375422 sequences. (Running on oeis4.)