This is a read only copy of the old FEniCS QA forum. Please visit the new QA forum to ask questions

Mesh generator (mshr) not filling entire volume

0 votes

I have made a volume mesh of a thick-walled vessel using mshr, but found that the entire volume is not filled with elements as it should be. The issue seems to go away when the resolution is sufficiently high.

  • Is this the expected behavior?
  • How can I be sure that there aren't any internal elements missing when using a higher resolution?

Code:

import mshr
import dolfin as dlf

c0 = dlf.Point()
ri = 2.0
ro = ri + 0.2
l = 20.0

annulus = mshr.Circle(c0, ro) - mshr.Circle(c0, ri)
domain = mshr.Extrude2D(annulus, l)

for resolution in range(10,51):
    mesh = mshr.generate_mesh(domain, resolution)
    dlf.File('meshfiles/mesh-%i.pvd' % resolution) << mesh

Results:
Screenshots of my results can be found here.

asked Sep 17, 2016 by miguelr FEniCS Novice (420 points)
...