public int getx() {return x} --> public double getx() {return x}