Summary
In this lecture, we'll cover the following:
- How to define and incorporate openings (holes) within a 2D mesh.
- How to extend the existing meshing function to support single and multiple polygonal holes.
- How to construct internal curve loops and integrate them with the outer boundary.
- How Gmsh handles multiple loops to correctly mesh around openings.
- How to extract and store node tags along hole boundaries for later use.
- How to enhance visualisation to highlight nodes around openings.
We begin by modifying our existing mesh generation function to accept an optional input describing openings as polygons defined by their corner coordinates. We ensure the function can handle both single and multiple holes by checking the structure of the input and iterating accordingly. For each hole, we replicate the same workflow used for the outer boundary: creating points, joining them with lines, and forming a curve loop. These internal loops are then combined with the outer loop and passed to Gmsh, which automatically interprets them as voids and generates a mesh that respects the openings.
We then focus on extracting useful data from the generated mesh, specifically the node tags along the boundaries of each hole. By collecting nodes along each defining line and combining them with the original corner points, we build a complete set of boundary nodes for every opening. This information is stored for downstream tasks, such as applying boundary conditions. Finally, we make a small improvement to the plotting function to visually distinguish nodes along hole perimeters.
Next up
In the next lecture, we will add the ability to embed specific nodal positions — such as column locations — directly into the mesh.
Tags
Please log in or enroll to continue
If you've already enrolled, please log in to continue.
Finite Element Analysis of Plate and Shell Structures: Part 1 - Plates
An analysis pipeline for thick and thin plate structures, a roadmap from theory to toolbox
After completing this course...
- You will understand how Reissner-Mindlin theory enables us to accurately capture both thin and thick plate behaviour.
- You will understand how to turn the fundamental mechanics of plate behaviour into a custom finite element solver written in Python.
- You will have developed meshing workflows that utilise the powerful open-source meshing engine, GMSH.
- In addition to using your own custom finite element code, you will be comfortable validating your results using OpenSeesPy and Pynite.