Unified Implementation of Finite Element Methods involving Jumps and Averages in Matlab

Yue Yu
DOI: https://doi.org/10.48550/arXiv.2209.10800
2022-12-12
Abstract:We provide unified implementations of the finite element methods involving jumps and averages in Maltab by combing the use of the software package varFEM, including the adaptive finite element methods for the Poisson equation and the $C^0$ interior penalty methods for the biharmonic equation. The design ideas can be extended to other Galerkin-based methods, for example, the discontinuous Galerkin methods and the virtual element methods.
Numerical Analysis
What problem does this paper attempt to address?
The problem that this paper attempts to solve is to provide a unified framework to implement the finite element method (FEM) involving jump and average terms, especially for the adaptive finite element method of the Poisson equation and the C0 interior penalty method of the biharmonic equation. By using the varFEM software package in combination, the authors aim to simplify the implementation of these complex methods and improve the efficiency and accuracy of numerical simulations. ### Specific Problem Description 1. **Adaptive Finite Element Method for the Poisson Equation**: - **Problem Background**: The Poisson equation is a classical partial differential equation (PDE), which is widely used in physics, engineering and other fields. The adaptive finite element method improves the accuracy of the solution through local mesh refinement. - **Objective**: Implement the adaptive finite element method, including four steps: solving, error estimation, marking and mesh refinement. The focus is on calculating the local error indicator, especially the calculation of the jump term. 2. **C0 Interior Penalty Method for the Biharmonic Equation**: - **Problem Background**: The biharmonic equation is a fourth - order PDE, which is often used in problems such as elasticity mechanics. Traditional finite element methods have difficulty dealing with the continuity requirements of its high - order derivatives. - **Objective**: Propose a symmetric C0 interior penalty method. By introducing jump terms and penalty terms, the H2 consistency condition is weakened, so as to achieve effective numerical solution of the biharmonic equation. ### Solution 1. **Unified Implementation Framework**: - Use the varFEM software package, which provides a set of general - purpose tools and functions to handle jump and average terms in the finite element method. - Implement it through the MATLAB programming language to ensure the readability and maintainability of the code. 2. **Specific Implementation Details**: - **Data Structure**: Define the basic data structure of the triangular mesh (such as nodes, elements, etc.), and implement functions such as boundary integral and jump term calculation. - **Error Estimation**: For the Poisson equation, implement the posteriori error estimation based on residuals, including the calculation of internal residuals of elements and jump terms. - **Jump Term Calculation**: Explain in detail how to calculate the jump term, especially the treatment method on the boundary. - **Penalty Term Design**: For the biharmonic equation, introduce penalty terms to ensure numerical stability, and give the method for selecting penalty parameters. ### Conclusion Through the above methods, the authors successfully provide a unified implementation framework, which can be conveniently applied to different types of finite element methods. This not only improves the efficiency of numerical simulations but also provides a powerful tool for researchers to explore more complex PDE problems. ### Key Formulas - Variational form of the Poisson equation: \[ a(u, v)=\int_{\Omega} \nabla u\cdot \nabla v \, d\sigma, \quad \ell(v)=\int_{\Omega} f v \, d\sigma \] - Local error indicator: \[ \eta_K = h_K^2 \| f+\Delta u_h \|^2_{0,K}+\sum_{e \subset \partial K} h_e \| [\partial_n u_h] \|^2_{0,e} \] - Bilinear form of the C0 interior penalty method: \[ a_h(u_h, v_h)=a_{pw}(u_h, v_h)-(J(u_h, v_h)+J(v_h, u_h))+c_{IP}(u_h, v_h) \] where, \[ a_{pw}(u_h, v_h)=\sum_{K \in T}(\nabla^2 u_h, \nabla^2 v_h)_K \] \[ J(u_h, v_h)=\sum_{e \in E} \int_e \{ \nabla^2 u_h n_e \} \cdot [\nabla v_h] \,