# Examples from pyvista.CellType.n_edges
# ======================================

# `QUAD` has a fixed number of edges.
import pyvista as pv
pv.CellType.QUAD.n_edges

# `POLYGON` has a variable number of edges and raises a ValueError.
try:
    pv.CellType.POLYGON.n_edges
except ValueError as error:
    print(error)

# Zero- and one-dimensional cell types have no edges.
pv.CellType.VERTEX.n_edges

pv.CellType.LINE.n_edges

# ----------------------------------------------------------------------
# Generated by sphinx-examples-as-code https://github.com/pyvista/sphinx-examples-as-code

