title: Bounding Boxes for Circle and Arcs in 3D
body: <p>Given curves of type Circle and Circular-Arc in 3D space, what is a good way to compute accurate bounding boxes (world axis aligned)?</p>
  
  <hr>
  
  <p><strong>Edit: found solution for circles, still need help with Arcs.</strong></p>
  
  <p>C# snippet for solving BoundingBoxes for Circles:</p>
  
  <pre><code>public static BoundingBox CircleBBox(Circle circle)
  {
    Point3d O = circle.Center;
    Vector3d N = circle.Normal;
  
    double ax = Angle(N, new Vector3d(1,0,0));
    double ay = Angle(N, new Vector3d(0,1,0));
    double az = Angle(N, new Vector3d(0,0,1));
  
    Vector3d R = new Vector3d(Math.Sin(ax), Math.Sin(ay), Math.Sin(az));
    R *= circle.Radius;
  
    return new BoundingBox(O - R, O + R);
  }
  
  private static double Angle(Vector3d A, Vector3d B)
  {
    double dP = A * B;
    if (dP &lt;= -1.0) { return Math.PI; }
    if (dP &gt;= +1.0) { return 0.0; }
  
    return Math.Acos(dP);
  }
  </code></pre>