It's been a while, but I believe that you can solve integer programming
problems of this type using Groebner bases.
(Google for integer programming with Groebner bases).
I have some Groebner basis code in Haskell at
http://www.polyomino.f2s.com/david/haskell/commalg.html
Simon Brenner wrote:
Do you simply want the set of coordinates, or do you want to do
something smart with the them (i.e. optimize a function value etc)?
In the first case, with a good starting point and a function that
enumerates all coordinates (by going in a spiral, perhaps), I think
this