Circle

class rhino3dm.Circle
Circle(radius)

Initializes a circle with center (0,0,0) in the world XY plane.

Parameters:radius (float) – Radius of circle, should be a positive number.
Circle(center, radius)

Initializes a circle parallel to the world XY plane with given center and radius.

Parameters:
  • center (rhino3dm.Point3d) – Center of circle.
  • radius (float) – Radius of circle (should be a positive value).
IsValid

bool: A valid circle has radius larger than 0.0 and a base plane which is must also be valid.

Radius

float: Gets or sets the radius of this circle. Radii should be positive values.

Diameter

float: Gets or sets the diameter (radius * 2.0) of this circle. Diameters should be positive values.

Center

rhino3dm.Point3d: Gets or sets the center point of this circle.

Normal

rhino3dm.Vector3d: Gets the normal vector for this circle.

Circumference

float: Gets or sets the circumference of this circle.

PointAt(t)

Circles use trigonometric parameterization: t -> center + cos(t)*radius*xaxis + sin(t)*radius*yaxis.

Parameters:t (float) – Parameter of point to evaluate.
Returns:The point on the circle at the given parameter.
Return type:rhino3dm.Point3d
TangentAt(t)

Circles use trigonometric parameterization: t -> center + cos(t)*radius*xaxis + sin(t)*radius*yaxis.

Parameters:t (float) – Parameter of tangent to evaluate.
Returns:The tangent at the circle at the given parameter.
Return type:rhino3dm.Vector3d
DerivativeAt(derivative, t)

Determines the value of the Nth derivative at a parameter.

Parameters:
  • derivative (int) – Which order of derivative is wanted.
  • t (float) – Parameter to evaluate derivative. Valid values are 0, 1, 2 and 3.
Returns:

The derivative of the circle at the given parameter.

Return type:

rhino3dm.Vector3d

ClosestPoint(testPoint)

Gets the point on the circle which is closest to a test point.

Parameters:testPoint (rhino3dm.Point3d) – Point to project onto the circle.
Returns:The point on the circle that is closest to testPoint or Point3d.Unset on failure.
Return type:rhino3dm.Point3d
Translate(delta)

Moves the circle.

Parameters:delta (rhino3dm.Vector3d) – Translation vector.
Returns:True on success, False on failure.
Return type:bool
Reverse()

Reverse the orientation of the circle. Changes the domain from [a,b] to [-b,-a].

Return type:void
ToNurbsCurve()

Constructs a nurbs curve representation of this circle. This amounts to the same as calling NurbsCurve.CreateFromCircle().

Returns:A nurbs curve representation of this circle or None if no such representation could be made.
Return type:rhino3dm.NurbsCurve
Encode()

[todo] add documentation