Time dependent problems are commonplace in physics, chemistry and many other
disciplines. In this post, I’ll introduce the FE formulation of linear
time-dependent problems and derive formulas for explicit and implicit Euler
integration.
The weak formulation of a first order time-dependent problem reads:
\[\begin{equation}
\boxed{
\Bu_{n+1} = [\BM_{n+1}+\Delta t \BA_{n+1}]\inv [\BM_n\Bu_n + \Delta t \,\Bb_{n+1}]
}
\end{equation}\]
If $m$ is time-independent, one can just substitute $\BM=\BM_{n+1}=\BM_n$.
Example: Reaction-Advection-Diffusion Equation
The IBVP of a linear reaction-advection-diffusion problem reads
\[\begin{equation}
\begin{alignedat}{4}
\partd{u}{t} &=
\nabla\dtp(\BD\nabla u) - \nabla\dtp(\Bc u) + ru + f
\qquad&& \text{in} \qquad&& \Omega\times I\\
u &= \bar{u} && \text{on} && \del\Omega\times I\\
u &= u_0 && \text{in} && \Omega, t = 0 \\
\end{alignedat}
\end{equation}\]
where $t\in I = [0,\infty)$,
$\BD$ is a second-order tensor describing the diffusivity of $u$,
$\Bc$ is a vector describing the velocity of advection,
$r$ is a scalar describing the rate of reaction,
and $f$ is a source term for $u$.
The weak formulation is then
Find $u \in V$ such that
\[\begin{equation}
\int_\Omega \dot{u} v \dv =
\int_\Omega [\nabla\dtp(\BD\nabla u) - \nabla\dtp(\Bc u) + ru + f] v \dv
\end{equation}\]
for all $v \in V$ and $t \in I$.
We have the following integration by parts relationships:
\[\require{cancel}\begin{equation}
\int_\Omega \nabla \dtp(\BD\nabla u) v \dv
= \cancel{\int_\Omega \nabla\dtp(v\BD\nabla u) \dv}
- \int_\Omega (\BD\nabla u)\dtp\nabla v \dv
\end{equation}\]
for the diffusive part and
\[\begin{equation}
\int_\Omega \nabla\dtp(\Bc u) v \dv
= \cancel{\int_\Omega \nabla \dtp (\Bc u v) \dv}
- \int_\Omega u \Bc \dtp \nabla v \dv
\end{equation}\]
for the advective part. The canceled terms are due to divergence theorem and
the fact that $v=0$ on the boundary. Then our variational formulation is of
the form \eqref{eq:timedependentweak1} where