import element.*; public class DrawCircle { public static void main(String args[]) { DrawingWindow d = new DrawingWindow(); // draw a circle with these parameters: final double RADIUS = 90.0; final int CENTER_X = 100; final int CENTER_Y = 100; // number of points to draw: final int N = 500; // current point information: int i; double theta, x, y; for (i = 0; i < N; i++) { theta = i*Math.PI*2.0/n; x = RADIUS*Math.cos(theta)+CENTER_X; y = RADIUS*Math.sin(theta)+CENTER_Y; d.draw(new Pt((int)Math.round(x),(int)Math.round(y))); } } } /* */