Skip to content

Commit

Permalink
CylinderStructured length fix (pyvista#561)
Browse files Browse the repository at this point in the history
The structured grid generated was shorter than the length argument.
  • Loading branch information
math-artist authored and banesullivan committed Jan 23, 2020
1 parent e5b012f commit 963f7ac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pyvista/utilities/geometric_objects.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ def CylinderStructured(radius=0.5, height=1.0,
# Make all the nodes in the grid
xx = np.array([X] * z_resolution).ravel()
yy = np.array([Y] * z_resolution).ravel()
dz = height / z_resolution
dz = height / (z_resolution - 1)
zz = np.empty(yy.size)
zz = np.full((X.size, z_resolution), dz)
zz *= np.arange(z_resolution)
Expand Down

0 comments on commit 963f7ac

Please sign in to comment.