preview

Nt1310 Unit 1 Algorithm Report

Decent Essays

Exploiting the tensor product structure of hexahedral elements expresses the volume operations as 1D operators. The details are presented in algorithm \ref{alg_hexvol}.
\begin{algorithm}[h]
\caption{Hexahedron volume kernel}
\label{alg_hexvol}
\KwIn{nodal value of solution $\mathbf{u} = \left(p, \mathbf{v} \right)$, volume geometric factors $\partial (rst)/ \partial (xyz)$, 1D derivative operator $D_{ij} = \partial \hat{l}_j /\partial x_i$, model parameters $\rho, c$}
\KwOut{volume contributions stored in array $\mathbf{r}$}
\For{each element $e$}
{
\For{each volume node $x_{ijk}$} { Compute derivatives with respect to $r,s,t$ $$\frac{\partial \mathbf{u}}{\partial r} = \sum_{m=1}^{N+1}D_{im} \mathbf{u}_{mjk} \qquad \frac{\partial \mathbf{u}}{\partial s} = \sum_{m=1}^{N+1}D_{jm} \mathbf{u}_{imk} \qquad \frac{\partial \mathbf{u}}{\partial s} = \sum_{m=1}^{N+1}D_{km} \mathbf{u}_{ijm}$$ Apply chain rule to compute $\partial \mathbf{u}/\partial x, \partial \mathbf{u}/\partial y, \partial \mathbf{u}/\partial z$ $$\frac{\partial \mathbf{u}}{\partial x} = \frac{\partial \mathbf{u}}{\partial r} \frac{\partial r}{\partial x} + \frac{\partial \mathbf{u}}{\partial s} \frac{\partial s}{\partial x} + \frac{\partial \mathbf{u}}{\partial t} …show more content…

Revisiting figure \ref{GLNodes}, we notice that the SEM nodal points already contain the surface cubature points while the GL nodes do not. Therefore, the SEM implementation is able to utilize the nodal values to compute the numerical flux, while the GL implementation requires additional interpolations. In algorithm \ref{alg_hexsuf}, we present the procedure of the hexahedron surface kernel. In both implementations, the solution values on the surface cubature points are pre-computed and stored in array \texttt{fQ}. The lines and variables marked with GL/SEM are the processes only needed by the GL/SEM implementation

Get Access