Ciarlet's definition of a finite element
The mathematical foundation of finite elements.
Introduction
The finite element method (FEM) is a powerful technique for numerically solving partial differential equations. At its heart lies the concept of a finite element, which provides a systematic way to construct piecewise-polynomial approximations on a mesh.
The most widely used formal definition of a finite element was introduced by Philippe G. Ciarlet. This definition provides a clean mathematical framework that separates three concerns:
- Geometry: on which shape is the element defined?
- Approximation: which polynomial space is used?
- Degrees of freedom: how are functions in the space uniquely determined?
This separation is precisely mirrored in Rodin's architecture: the Geometry module handles shapes, the Variational module defines polynomial spaces and DOFs, and the Assembly module puts them together.
The Ciarlet Triple
A finite element in the sense of Ciarlet is defined as a triple where:
- is a geometric domain — a compact, connected subset of with nonempty interior (e.g. a triangle, tetrahedron, quadrilateral). This is also called the reference element. In Rodin, reference element geometry is defined by the Polytope::
Type enumeration (Triangle, Tetrahedron, Quadrilateral, etc.). is a finite-dimensional function space defined on — typically a space of polynomials of a certain degree. For instance, , the space of polynomials of degree at most , whose dimension is:
For : , . For : , .
- is a set of degrees of freedom (DOFs) — linear functionals — such that any function is uniquely determined by the values .
The key requirement is that the DOFs must form a basis for the dual space . This means , and the map
is an isomorphism from to . Equivalently, if for all , then . This property is called unisolvence.
Basis Functions
Given a Ciarlet triple , there exists a unique set of basis functions such that:
where is the Kronecker delta. This is called the nodal basis of the finite element. These basis functions are the shape functions that are used to represent any function in the finite element space.
Any function can then be written as:
The values are the degrees of freedom (DOF values) of . In Rodin, these DOF values are stored as the coefficient vector of a GridFunction.
Common Finite Elements
P1 (Piecewise Linear) Elements
The simplest and most widely used finite element is the P1 element on a triangle:
- = a triangle with vertices
- = polynomials of degree (i.e. ), dimension 3
- where (point evaluations at vertices)
The basis functions are the barycentric coordinates , satisfying . Each basis function is 1 at one vertex and 0 at the other two, varying linearly between them.
In Rodin, a P1 finite element space is created with:
P1 Vh(mesh); // Number of DOFs = number of vertices std::cout << Vh.getSize() << std::endl;
The P1 class constructs one DOF per mesh vertex, producing a space of continuous piecewise linear functions that is -conforming.
P0 (Piecewise Constant) Elements
An even simpler element is the P0 element, used for discontinuous quantities:
- = a polytope (triangle, tetrahedron, etc.)
- = constant functions, dimension 1
- where is the value of the constant, often defined as the average over
In Rodin:
P0 Wh(mesh); // Number of DOFs = number of cells std::cout << Wh.getSize() << std::endl;
The P0 class constructs one DOF per mesh cell. Functions in P0 are discontinuous across cell boundaries, making this space a subspace of (not ).
Higher-Order Elements (H1<k>)
For polynomial degree , additional DOFs are placed on edges and (for ) on cell interiors. For example, the P2 element on a triangle has:
- = a triangle
- = quadratic polynomials, dimension 6
- = point evaluations at the 3 vertices and 3 edge midpoints
In Rodin, higher-order elements are provided by the H1<k> class:
// Quadratic (P2) finite element space H1 Vh(std::integral_constant<size_t, 2>{}, mesh);
The polynomial order is a compile-time template parameter.
From Local to Global
The Ciarlet definition describes a local finite element on a single reference cell . To construct a global finite element space on an entire mesh , we:
- Define a reference element
- Map it to each physical cell using a geometric transformation . In Rodin, the Jacobian of this transformation is accessible through Point::
getJacobian(). - Assemble local DOFs into global DOFs, enforcing inter-element continuity conditions at shared entities (vertices, edges, faces)
The result is a finite-dimensional subspace of the function space in which we seek our approximate solution.
The assembly of local DOFs into global DOFs is handled automatically when you create a finite element space. For example, P1 Vh(mesh) constructs the global DOF numbering by identifying vertex-based DOFs on shared mesh vertices.
Conformity
Different types of inter-element continuity give rise to different types of conforming finite element spaces:
| Conformity | Continuity requirement | Typical use | Rodin class |
|---|---|---|---|
| -conforming | Continuous across element boundaries | Scalar PDEs (Poisson, heat) | P1, H1 |
| -conforming | Normal component continuous | Mixed methods, fluid flow | — |
| -conforming | Tangential component continuous | Electromagnetics | — |
| (no conformity) | No continuity required | Discontinuous Galerkin, indicators | P0 |
Rodin currently provides -conforming elements (P1, H1) and elements (P0). The P1 and H1 spaces produce global functions that are continuous across element boundaries: values at shared vertices (and shared edge/face DOFs for higher order) are identified.
Connection to Rodin
In Rodin, the Ciarlet definition is realized through the interaction of several classes:
| Ciarlet component | Mathematical object | Rodin class |
|---|---|---|
| Reference element geometry | Polytope + Polytope:: | |
| Local polynomial space | Defined internally by P0, P1, H1 | |
| Degrees of freedom | DOF numbering managed by the finite element space class | |
| Global finite element space | The space object itself (e.g. P1 Vh(mesh)) | |
| Discrete function | GridFunction | |
| (unknown) | Trial function | TrialFunction |
| (weight) | Test function | TestFunction |
// The mesh provides the cells K and the geometric transformations F_K Mesh mesh; mesh = mesh.UniformGrid(Polytope::Type::Triangle, {16, 16}); // P1 defines the local element (K, P1, point evaluations at vertices) // and assembles them into a global space Vh P1 Vh(mesh); // Trial and test functions live in this global space TrialFunction u(Vh); TestFunction v(Vh);
See Also
- Finite element spaces — Available spaces in Rodin
- Core Concepts — Practical guide to using finite elements in Rodin
- Polytopes — Geometric shapes used as reference elements
- Notation — Mathematical notation reference