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.

A266836 Odd Löschian numbers.

Original entry on oeis.org

1, 3, 7, 9, 13, 19, 21, 25, 27, 31, 37, 39, 43, 49, 57, 61, 63, 67, 73, 75, 79, 81, 91, 93, 97, 103, 109, 111, 117, 121, 127, 129, 133, 139, 147, 151, 157, 163, 169, 171, 175, 181, 183, 189, 193, 199, 201, 211, 217, 219, 223, 225, 229, 237, 241, 243, 247, 259, 271, 273, 277, 279, 283, 289, 291, 301, 307, 309
Offset: 1

Views

Author

Joerg Arndt, Jan 04 2016

Keywords

Comments

Löschian numbers are numbers of the form x^2 + xy + y^2 for integers x, y; they can all be written in the form 4^e * m where e is a nonnegative integer and m is an odd Löschian number. - Charles R Greathouse IV, Jan 04 2016

Crossrefs

Cf. Loeschian numbers: A003136 (all), A202822 (3*k+1), A260682 (6*k+1).

Programs

  • Mathematica
    fQ[n_] := Resolve[Exists[{x, y}, Reduce[n == x^2 + x y + y^2, {x, y}, Integers]]]; Select[2 Range@ 155 - 1, fQ] (* Michael De Vlieger, Jan 04 2016, after Jean-François Alcover at A003136 *)
  • PARI
    is(n)=(n%2==1) && #bnfisintnorm(bnfinit(z^2+z+1), n);
    
  • PARI
    x='x+O('x^1000); p=eta(x)^3/eta(x^3); for(n=0, 999, if(polcoeff(p, n) != 0 && n%2==1, print1(n, ", "))) \\ Altug Alkan, Jan 04 2016
    
  • PARI
    list(lim)=my(v=List(), y, t); for(x=0, sqrtint(lim\3), my(y=x, t); while((t=x^2+x*y+y^2)<=lim, if(t%2, listput(v, t)); y++)); Set(v) \\ Charles R Greathouse IV, Jul 05 2017