Skip to content

Meshing Basics

Once the geometry is ready, the next crucial step in any finite element or numerical simulation is meshing. A mesh divides your continuous geometry into a collection of smaller, discrete elements that can be solved numerically. In simple terms, it converts your physical model into a mathematical model that the solver (like FEniCS) can process.

What is a Mesh

A mesh is a network of elements and nodes that represents the geometry of your model. Each element connects a set of points (called nodes) that define its shape and location in space. The solver then approximates the governing equations (such as stress, heat, or electromagnetic fields) over these elements.

Meshes can be composed of different element types, depending on the geometry and analysis type:

  • 1D elements: Lines or edges — used for beam or truss models
  • 2D elements: Triangles or quadrilaterals — used for surface or shell models
  • 3D elements: Tetrahedrons, hexahedrons, or prisms — used for volumetric models

Importance of Correct Meshing

The quality of your mesh has a direct impact on the accuracy, stability, and efficiency of your simulation. A poor-quality mesh can lead to:

  • Numerical instability
  • Non-physical results
  • Large errors near boundaries or stress concentrations

Conversely, a well-refined and properly generated mesh can produce results that closely match analytical or experimental data.

Mesh quality depends on several factors:

  • Element size and aspect ratio
  • Smoothness and gradation between regions
  • Alignment with geometry features and boundaries

In short, the mesh is not just a technical step — it defines the resolution of your simulation.

Mesh Convergence Studies

In finite element analysis, mesh convergence is an essential validation process. It involves refining the mesh progressively and observing how the solution changes.

The idea is simple:

  • Start with a coarse mesh and solve the problem.
  • Gradually refine the mesh (reduce element size).
  • Compare the results — for example, displacement, stress, or field intensity — against analytical or benchmark data.

When further mesh refinement causes negligible change in the solution, the model is said to be mesh-converged.

This ensures that your results are not artifacts of the mesh but are instead a true approximation of the physical behavior.

Mesh Density Guidelines

Mesh refinement isn’t just about adding more elements — it’s about adding them where they matter. Different disciplines follow different mesh-density guidelines based on the physics involved.

For Electromagnetic Simulations

The mesh size should be related to the wavelength (λ) of the electromagnetic field:

  • Generally, element size ≤ λ/5
  • For higher accuracy, element size ≤ λ/10

This ensures that the field variations are captured correctly across the domain.

For Structural and Dynamic Studies

In dynamic problems, the element size also influences the time-step size through the Courant–Friedrichs–Lewy (CFL) condition (also known as the UFL condition). A smaller mesh size typically requires a smaller time-step to maintain numerical stability.

Therefore, both mesh density and time-step are interdependent in dynamic analyses.

Summary

Meshing is the bridge between geometry and numerical simulation. A good mesh leads to reliable and physically meaningful results, while a poor one can distort even the most well-formulated models.

Through proper mesh generation, refinement, and convergence studies, you can ensure that your simulations are both accurate and efficient.

In the next section, we’ll use the geometry created earlier in Salome to generate a finite element mesh, assign parameters, and prepare it for export into FEniCS.