/* Problem: given a point (x0,y0) and a real D>=0, find
   all the points (x,y) such that x is an integer in [-5,7],
   D is the distance between (x,y) and (x0,y0), and
   either y<=0 or y>=x */


Constants
  D  = 1.25,
  x0 = 1.5,
  y0 = 0.5
;

Variables
  int  x in [-5,  +7 ],
  real y in ]-oo, +oo[
;

Constraints
  /* D: distance between two points (x,y) and (x0,y0) */
  (x-x0)^2 + (y-y0)^2 = D^2,

  /* y<=0 or y>=x */
  min( y, x-y ) <= 0
;
