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!)
A230279 Number of nonnegative integer solutions to the equation x^2 - 16*y^2 = n. 1
1, 0, 0, 1, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 2, 0, 0, 1, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 1, 2, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 3, 0, 0, 2, 0, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,9
COMMENTS
For (x, y) to be a solution to the more general equation x^2 - d^2*y^2 = n, it can be shown that n-f^2 must be divisible by 2*f*d, where f is a divisor of n not exceeding sqrt(n). Then y = (n-f^2)/(2*f*d) and x = d*y+f.
LINKS
EXAMPLE
a(33)=2 because x^2 - 16*y^2 = 33 has two solutions: (x,y) = (17,4) and (7,1).
PROG
(PARI) a(n) = sumdiv(n, f, f^2<=n && (n-f^2)%(8*f)==0);
(Magma) d:=4; solutions:=func<i | [f: f in Divisors(i) | f le Isqrt(i) and IsZero((i-f^2) mod (2*f*d))]>; [#solutions(n): n in [1..100]]; // Bruno Berselli, Oct 15 2013
CROSSREFS
Sequence in context: A078359 A107329 A263717 * A085859 A218218 A332006
KEYWORD
nonn
AUTHOR
Colin Barker, Oct 15 2013
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 May 11 20:45 EDT 2024. Contains 372414 sequences. (Running on oeis4.)