add global basis authored by Praetorius, Simon's avatar Praetorius, Simon
......@@ -34,4 +34,24 @@ with $`0=t^0<t^1<\ldots<t^N=T`$, timestep $`\tau=t^{k+1} - t^k`$, and given init
### Finite-Element formulation
Let $`\Omega`$ be partitioned into quasi-uniform elements by a conforming triangulation $`\mathcal{T}_h`$. The functions $`\mathbf{u}`$ and $`p`$ are approximated by functions from the discrete functionspace $`\mathbb{T}_h := [V_{2,\,g_i}]^d\times V_1`$ with $`V_{p} := \{v\in C^0(\Omega)\,:\, v|_T\in\mathbb{P}_p(T),\, \forall T\in\mathcal{T}_h\}`$ and $`V_{p,\,g} := \{v\in V_p\,:\,\operatorname{tr}_{\partial\Omega}=g\}`$.
Let $`\Omega`$ be partitioned into quasi-uniform elements by a conforming triangulation $`\mathcal{T}_h`$. The functions $`\mathbf{u}`$ and $`p`$ are approximated by functions from the discrete functionspace $`\mathbb{T}_h := [\mathbb{V}_{2,\,g_i}]^d\times \mathbb{V}_1`$ with $`\mathbb{V}_{p} := \{v\in C^0(\Omega)\,:\, v|_T\in\mathbb{P}_p(T),\, \forall T\in\mathcal{T}_h\}`$ and $`\mathbb{V}_{p,\,g} := \{v\in \mathbb{V}_p\,:\,\operatorname{tr}_{\partial\Omega}=g\}`$, where $`\mathbb{P}_p`$ is the space of polynomials of order at most $`p`$. The space $`\mathbb{T}_h`$ will be denoted as Taylor-Hood space.
Let `Grid grid` be the Duen grid type representing the triangulation $`\mathcal{T}_h`$ of the domain $`\Omega`$, then
the basis of the Taylor-Hood space can be written as a composition of Lagrange bases:
```c++
using namespace Dune::Functions::BasisFactory;
auto basis = makeBasis(grid.leafGridView(),
composite(
power<Grid::dimensionworld>(lagrange<2>(), flatInterleaved()),
lagrange<1>(),
flatLexicographic()
)
);
```
At this point, any Dirichlet boundary conditions is ignored in the definition of the bases. We
build the Taylor-Hood basis as a composition of a product of $`d`$ $`\mathbb{V}_2`$ bases for
the velocity components and a $`\mathbb{V}_1`$ basis for the pressure.
For efficiency, we use flat blocking strategies `flatInterleaved` and `flatLexicographic`
to build a global continuous numbering of the basis functions.