1(bps)= 2 3# CEED Bakeoff Problems 4 5```{include} ./README.md 6:start-after: bps-inclusion-marker 7:end-before: bps-exclusion-marker 8``` 9 10(mass-operator)= 11 12## Mass Operator 13 14The Mass Operator used in BP1 and BP2 is defined via the $L^2$ projection 15problem, posed as a weak form on a Hilbert space $V^p \subset H^1$, i.e., 16find $u \in V^p$ such that for all $v \in V^p$ 17 18$$ 19\langle v,u \rangle = \langle v,f \rangle , 20$$ (eq-general-weak-form) 21 22where $\langle v,u\rangle$ and $\langle v,f\rangle$ express the continuous 23bilinear and linear forms, respectively, defined on $V^p$, and, for sufficiently 24regular $u$, $v$, and $f$, we have: 25 26$$ 27\begin{aligned} \langle v,u \rangle &:= \int_{\Omega} \, v \, u \, dV ,\\ \langle v,f \rangle &:= \int_{\Omega} \, v \, f \, dV . \end{aligned} 28$$ 29 30Following the standard finite/spectral element approach, we formally 31expand all functions in terms of basis functions, such as 32 33$$ 34\begin{aligned} 35u(\bm x) &= \sum_{j=1}^n u_j \, \phi_j(\bm x) ,\\ 36v(\bm x) &= \sum_{i=1}^n v_i \, \phi_i(\bm x) . 37\end{aligned} 38$$ (eq-nodal-values) 39 40The coefficients $\{u_j\}$ and $\{v_i\}$ are the nodal values of $u$ 41and $v$, respectively. Inserting the expressions {eq}`eq-nodal-values` 42into {eq}`eq-general-weak-form`, we obtain the inner-products 43 44$$ 45\langle v,u \rangle = \bm v^T M \bm u , \qquad \langle v,f\rangle = \bm v^T \bm b \,. 46$$ (eq-inner-prods) 47 48Here, we have introduced the mass matrix, $M$, and the right-hand side, 49$\bm b$, 50 51$$ 52M_{ij} := (\phi_i,\phi_j), \;\; \qquad b_{i} := \langle \phi_i, f \rangle, 53$$ 54 55each defined for index sets $i,j \; \in \; \{1,\dots,n\}$. 56 57(laplace-operator)= 58 59## Laplace's Operator 60 61The Laplace's operator used in BP3-BP6 is defined via the following variational 62formulation, i.e., find $u \in V^p$ such that for all $v \in V^p$ 63 64$$ 65a(v,u) = \langle v,f \rangle , \, 66$$ 67 68where now $a (v,u)$ expresses the continuous bilinear form defined on 69$V^p$ for sufficiently regular $u$, $v$, and $f$, that is: 70 71$$ 72\begin{aligned} a(v,u) &:= \int_{\Omega}\nabla v \, \cdot \, \nabla u \, dV ,\\ \langle v,f \rangle &:= \int_{\Omega} \, v \, f \, dV . \end{aligned} 73$$ 74 75After substituting the same formulations provided in {eq}`eq-nodal-values`, 76we obtain 77 78$$ 79a(v,u) = \bm v^T K \bm u , 80$$ 81 82in which we have introduced the stiffness (diffusion) matrix, $K$, defined as 83 84$$ 85K_{ij} = a(\phi_i,\phi_j), 86$$ 87 88for index sets $i,j \; \in \; \{1,\dots,n\}$. 89