src/main/java/org/teachingextensions/logo/utils/MazeUtils/StdDraw.java
public static void circle(double x, double y, double radius)
  {
    if (!(radius >= 0))
      throw new IllegalArgumentException("radius must be nonnegative");
    double xs = scaleX(x);
    double ys = scaleY(y);
    double ws = factorX(2 * radius);
    double hs = factorY(2 * radius);
    if (ws <= 1 && hs <= 1)
      pixel(x, y);
    else
      offscreen.draw(new Ellipse2D.Double(xs - ws / 2, ys - hs / 2, ws, hs));
    draw();
  }
public static void circle(double x, double y, double radius)
  {
    if (!(radius >= 0))
      throw new IllegalArgumentException("radius must be nonnegative");
    double xs = scaleX(x);
    double ys = scaleY(y);
    double ws = factorX(2 * radius);
    double hs = factorY(2 * radius);
    if (ws <= 1 && hs <= 1)
      pixel(x, y);
    else
      offscreen.draw(new Ellipse2D.Double(xs - ws / 2, ys - hs / 2, ws, hs));
    draw();
  }
public static void circle ( double x , double y , double radius ) { if ( ! ( radius >= 0 ) ) throw new IllegalArgumentException ( "radius must be nonnegative" ) ; double xs = scaleX ( x ) ; double ys = scaleY ( y ) ; double ws = factorX ( 2 * radius ) ; double hs = factorY ( 2 * radius ) ; if ( ws <= 1 && hs <= 1 ) pixel ( x , y ) ; else offscreen . draw ( new Ellipse2D . Double ( xs - ws / 2 , ys - hs / 2 , ws , hs ) ) ; draw ( ) ; }
Draws a circle of the specified radius, centered at (<em>x</em>, <em>y</em>).

@param  x the <em>x</em>-coordinate of the center of the circle
@param  y the <em>y</em>-coordinate of the center of the circle
@param  radius the radius of the circle
@throws IllegalArgumentException if {@code radius} is negative
Draws a circle of the specified radius centered at ( <em > x< / em > <em > y< / em > ) .