pyvista.Circle#

Circle(radius=0.5, resolution=100)[source]#

Create a single PolyData circle defined by radius in the XY plane.

Parameters:
radiusfloat, default: 0.5

Radius of circle.

resolutionint, default: 100

Number of points on the circle.

Returns:
pyvista.PolyData

Circle mesh.

Notes

Changed in version 0.38.0: Prior to version 0.38, this method had incorrect results, producing inconsistent edge lengths and a duplicated point which is now fixed.

Examples

>>> import pyvista
>>> radius = 0.5
>>> circle = pyvista.Circle(radius)
>>> circle.plot(show_edges=True, line_width=5)
https://d33wubrfki0l68.cloudfront.net/33fff81cdebabdf81ccd9ed2c5fb9e4e427b8b01/662fe/_images/pyvista-circle-1_00_00.png