# Dome Difficulties Continued

Howdy all,

I’m back again to wrestle with meshing dome volumes. @gvernon had helped me to a certain point previously in this thread, but the example we ended up on had a flat surface on the bottom which does not match my use case exactly.

I’ll go through an example from geometry generation through to my attempts at meshing to illustrate the issue I’m encountering. Let’s assume I’m trying to make an ellipsoidal end cap for a tube. First, I create the tube:

``````create cylinder height 24 radius 6
create cylinder height 24 radius 4.5
subtract volume 2 from volume 1
``````

Next, I want to create the end cap with a thickness consistent with the tube but only 4 unit lengths beyond where the tube ends. There are a few ways to do this (and maybe this is where I’m immediately going wrong), but here is the way I figure is easiest to do knowing the desired maximum height:

Create three vertices, one for the maximum outer ellipse height, one for maximum inner ellipse height, and one for ellipse center:

``````create vertex 0 0 14.5
create vertex 0 0 16
create vertex 0 0 12
``````

Next, I create the curves to define a surface to sweep around the z-axis:

``````create curve vertex 2 8 9 ellipse
create curve vertex 6 7 9 ellipse
create curve vertex 7 8
create curve vertex 10 11
create surface curve 7 to 10
sweep surface 10 zaxis angle 360
merge all
``````

I now have this shape:

I would like to get folks’ ideas on how to mesh this. To pull from the previous thread, one approach might be to webcut a central cylinder through the dome and split the remaining bit of the dome along the “seam” leftover from constructing the geometry.

``````webcut volume 3 with cylinder radius 2.5 axis z merge
webcut volume 3 with plane yplane imprint merge
``````

This allows me to easily mesh volumes 3 and 5 by meshing one surface created in the previous cut and sweeping to the other surface for both volumes, but my understanding is that I still have the same problem as before with volume 4 which is to say that I can mesh using Pave on one of the surfaces, but that sweeping from that surface to the one inside (or vice versa) still gives me an error:

``````surface 19 size 0.5
mesh surface 19
volume 4 redistribute nodes off
volume 4 scheme Sweep  source surface 19   target surface 18   sweep transform least squares
volume 4 autosmooth target on  fixed imprints off  smart smooth off
mesh volume 4
``````
``````Command: mesh volume 4
ERROR: Inconsistent edge to face count relationship.
ERROR: Mesh of Surface 18 is invalid.
ERROR: No 3d elements.
ERROR: Mesh of Volume 4 is invalid.
ERROR: Volume 4 meshing unsuccessful using scheme: sweep
ERROR: 1 volume did not mesh : Volume 4
``````

Any help would be greatly appreciated!

Hi @jbtompkins,

Here is one way to do this. I have found that sometimes dividing cyllindrical bodies in quarters is helpful for improving quality. I did have to specify the source and target surfaces of the dome sections.

Karl

``````reset
create cylinder height 24 radius 6
create cylinder height 24 radius 4.5
subtract volume 2 from volume 1
create vertex 0 0 14.5
create vertex 0 0 16
create vertex 0 0 12
create curve vertex 2 8 9 ellipse
create curve vertex 6 7 9 ellipse
create curve vertex 7 8
create curve vertex 10 11
create surface curve 7 to 10
sweep surface 10 zaxis angle 360

webcut volume all with plane xplane offset 0 rotate 90 about z center 0 0 0
webcut volume all with plane xplane offset 0
imprint all
merge all

volume 5  redistribute nodes off
volume 5  scheme Sweep  source surface 68    target surface 66   sweep transform least squares
volume 5  autosmooth target on  fixed imprints off  smart smooth off
volume 3  redistribute nodes off
volume 3  scheme Sweep  source surface 46    target surface 48   sweep transform least squares
volume 3  autosmooth target on  fixed imprints off  smart smooth off
volume 7  redistribute nodes off
volume 7  scheme Sweep  source surface 52    target surface 50   sweep transform least squares
volume 7  autosmooth target on  fixed imprints off  smart smooth off
volume 9  redistribute nodes off
volume 9  scheme Sweep  source surface 70    target surface 73   sweep transform least squares
volume 9  autosmooth target on  fixed imprints off  smart smooth off

mesh vol all
quality vol all
``````

Hi James,

I can reduce the clicks by using scheme polyhedron. However, to get the same quality levels I had to smooth the surfaces and volumes with the mean ratio smooth scheme.

``````vol 5 3 7 9 scheme poly
mesh vol all
surf all smooth scheme mean
vol all smooth scheme mean
smooth surf all
smooth vol all
``````

This is definitely what I was looking for! Thanks!