A035256 Positive integers of the form x^2+3xy-y^2.
1, 3, 4, 9, 12, 13, 16, 17, 23, 25, 27, 29, 36, 39, 43, 48, 49, 51, 52, 53, 61, 64, 68, 69, 75, 79, 81, 87, 92, 100, 101, 103, 107, 108, 113, 116, 117, 121, 127, 129, 131, 139, 144, 147, 153, 156, 157, 159, 169, 172, 173, 179, 181, 183, 191, 192, 196, 199, 204, 207, 208, 211, 212, 221, 225, 233, 237, 243, 244, 251
Offset: 1
Keywords
Links
- N. J. A. Sloane et al., Binary Quadratic Forms and OEIS (Index to related sequences, programs, references)
Programs
-
Mathematica
formQ[n_] := Reduce[a > 0 && b > 0 && n == a^2 + 3 a*b - b^2, {a, b}, Integers] =!= False; Select[Range[100], formQ] (* Wesley Ivan Hurt, Jun 18 2014 *)
-
PARI
m=13; select(x -> x, direuler(p=2,101,1/(1-(kronecker(m,p)*(X-X^2))-X)), 1) \\ Fixed by Andrey Zabolotskiy, Jul 30 2020
Extensions
Entry revised by N. J. A. Sloane, Jun 01 2014
Comments