A two-point vector field for use in split-form DGSEM in 2-D.
Memory layout: interior(n, i, j, nEl, nVar, 1:2) dim 1 (n) : two-point index; looping over n is equivalent to looping over n in the split-form divergence sum (0:N in 0-based) dim 2 (i) : first computational coordinate direction (xi^1) dim 3 (j) : second computational coordinate direction (xi^2) dim 4 : element index dim 5 : variable index dim 6 (idir): vector direction (1 or 2)
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| integer, | public | :: | M | ||||
| integer, | public | :: | N | ||||
| type(EquationParser), | public, | allocatable | :: | eqn(:) | |||
| real(kind=prec), | public, | pointer, contiguous, dimension(:,:,:,:,:,:) | :: | interior | |||
| type(Lagrange), | public, | pointer | :: | interp | |||
| type(Metadata), | public, | allocatable | :: | meta(:) | |||
| integer, | public | :: | nElem | ||||
| integer, | public | :: | nVar |
Computes the split-form (two-point) divergence of a 2-D vector field in the reference element (computational coordinates).
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(TwoPointVector2D_t), | intent(in) | :: | this | |||
| real(kind=prec), | intent(out) | :: | df(1:this%N+1,1:this%N+1,1:this%nElem,1:this%nVar) |
Computes the split-form (two-point) divergence of a 2-D vector field in the reference element (computational coordinates).
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(TwoPointVector2D_t), | intent(in) | :: | this | |||
| real(kind=prec), | intent(out) | :: | df(1:this%N+1,1:this%N+1,1:this%nElem,1:this%nVar) |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(TwoPointVector2D_t), | intent(inout) | :: | this |
Allocate the interior array for a 2-D two-point vector field. The interior array has rank 6 with layout (n,i,j,nEl,nVar,idir).
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(TwoPointVector2D_t), | intent(out) | :: | this | |||
| type(Lagrange), | intent(in), | target | :: | interp | ||
| integer, | intent(in) | :: | nVar | |||
| integer, | intent(in) | :: | nElem |
Set the description of the ivar-th variable
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SELF_DataObj), | intent(inout) | :: | this | |||
| integer, | intent(in) | :: | ivar | |||
| character, | intent(in) | :: | description |
Sets the equation parser for the ivar-th variable
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SELF_DataObj), | intent(inout) | :: | this | |||
| integer, | intent(in) | :: | ivar | |||
| character, | intent(in) | :: | eqnChar |
Set the name of the ivar-th variable
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SELF_DataObj), | intent(inout) | :: | this | |||
| integer, | intent(in) | :: | ivar | |||
| character, | intent(in) | :: | name |
Set the units of the ivar-th variable
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SELF_DataObj), | intent(inout) | :: | this | |||
| integer, | intent(in) | :: | ivar | |||
| character, | intent(in) | :: | units |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(TwoPointVector2D_t), | intent(inout) | :: | this |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(TwoPointVector2D_t), | intent(inout) | :: | this |
type,extends(SELF_DataObj),public :: TwoPointVector2D_t
!! A two-point vector field for use in split-form DGSEM in 2-D.
!!
!! Memory layout: interior(n, i, j, nEl, nVar, 1:2)
!! dim 1 (n) : two-point index; looping over n is equivalent to looping
!! over n in the split-form divergence sum (0:N in 0-based)
!! dim 2 (i) : first computational coordinate direction (xi^1)
!! dim 3 (j) : second computational coordinate direction (xi^2)
!! dim 4 : element index
!! dim 5 : variable index
!! dim 6 (idir): vector direction (1 or 2)
real(prec),pointer,contiguous,dimension(:,:,:,:,:,:) :: interior
contains
procedure,public :: Init => Init_TwoPointVector2D_t
procedure,public :: Free => Free_TwoPointVector2D_t
procedure,public :: UpdateHost => UpdateHost_TwoPointVector2D_t
procedure,public :: UpdateDevice => UpdateDevice_TwoPointVector2D_t
generic,public :: Divergence => Divergence_TwoPointVector2D_t
procedure,private :: Divergence_TwoPointVector2D_t
endtype TwoPointVector2D_t