When utilizing Galerkin-type solutions for
IBVPs, we often
have to compute integrals using numerical methods such as
Gauss quadrature. In
such a solution, we solve for the values of a function at mesh nodes, whereas
the integration takes place at the quadrature points. Depending on the case,
we may need to compute the values of a function at mesh nodes, given their
values at quadrature points, e.g. stress recovery for mechanical problems.
There are many ways of achieving this, such as
superconvergent patch recovery.
In this post, I wanted to document a widely used solution which is easy to
implement, and which is used in research oriented codebases such as
FEAP.
L2 Projection
Given a function $u \in L^2(\Omega)$, its projection into a finite element space
$V_h\subset L^2(\Omega)$ is defined through the following optimization
problem:
There is a unique solution to the problem since $\Pi(\cdot)$ is convex. Taking
its variation, we have
\(\begin{equation}
D \Pi(u_h) \cdot v_h = \langle u_h-u, v_h \rangle = 0
\end{equation}\)
for all $v_h\in V_h$. Thus we have the following variational formulation
Find $u_h\in V_h$ such that
\[\begin{equation}
\langle u_h,v_h\rangle = \langle u, v_h\rangle
\end{equation}\]
are our bilinear and linear forms respectively. Substituting FE
discretizations $u_h = \sum_{J=1}^{\nnode} u^JN^J$ and
$v_h = \sum_{I=1}^{\nnode} v^IN^I$, we have
Thus L2 projection requires the solution of a linear system
\[\boldsymbol{M}\boldsymbol{u}=\boldsymbol{b}\]
which depending on the algorithm used, can have a complexity of at least
$O(n^2)$ and at most $O(n^3)$.
Lumped L2 Projection
The L2 projection requires the solution of a system which can be
computationally expensive. It is possible to convert the
matrix—called the mass matrix in literature—to a diagonal
form through a procedure called lumping.
since $\sum_{J=1}^{\nnode} N^J = 1$.
Substituting the lumped mass matrix allows us to decouple the linear system of
equations in \eqref{eq:projectionsystem1} and instead write
\[\begin{equation}
m^I u^I = b^I
\end{equation}\]
for $I=1,\dots,\nnode$. The lumped L2 projection is then as simple as
This results in a very efficient algorithm with $O(n)$ complexity.
Conclusion
Lumped L2 projection is a faster working approximation to L2 projection that is
easy to implement for quick results. You can use it when developing a solution
for an IBVP, and don’t want to wait too long when debugging, while not
forgetting that it introduces some error.