MapArrays_Vector2D_t Subroutine

public subroutine MapArrays_Vector2D_t(this, Np, nVar, nElem)

Size the backing pools for (Np,nVar,nElem) and remap the public arrays onto them at the exact logical shape. See SELF_DataPool for why this is done with pointer remapping rather than by over-allocating the element dimension.

Arguments

TypeIntentOptionalAttributesName
class(Vector2D_t), intent(inout) :: this
integer, intent(in) :: Np
integer, intent(in) :: nVar
integer, intent(in) :: nElem

Calls

proc~~maparrays_vector2d_t~~CallsGraph proc~maparrays_vector2d_t MapArrays_Vector2D_t proc~ensurepool EnsurePool proc~maparrays_vector2d_t->proc~ensurepool

Contents

Source Code


Source Code

  subroutine MapArrays_Vector2D_t(this,Np,nVar,nElem)
    !! Size the backing pools for (Np,nVar,nElem) and remap the public arrays onto them at the
    !! exact logical shape. See SELF_DataPool for why this is done with pointer remapping rather
    !! than by over-allocating the element dimension.
    implicit none
    class(Vector2D_t),intent(inout) :: this
    integer,intent(in) :: Np
    integer,intent(in) :: nVar
    integer,intent(in) :: nElem
    ! Local
    integer :: nInt,nBnd,nNrm

    nInt = Np*Np*nElem*nVar*2
    nBnd = Np*4*nElem*nVar*2
    nNrm = Np*4*nElem*nVar

    call EnsurePool(this%pool_interior,nInt)
    call EnsurePool(this%pool_boundary,nBnd)
    call EnsurePool(this%pool_extBoundary,nBnd)
    call EnsurePool(this%pool_avgBoundary,nBnd)
    call EnsurePool(this%pool_boundaryNormal,nNrm)

    this%interior(1:Np,1:Np,1:nElem,1:nVar,1:2) => this%pool_interior(1:nInt)
    this%boundary(1:Np,1:4,1:nElem,1:nVar,1:2) => this%pool_boundary(1:nBnd)
    this%extBoundary(1:Np,1:4,1:nElem,1:nVar,1:2) => this%pool_extBoundary(1:nBnd)
    this%avgBoundary(1:Np,1:4,1:nElem,1:nVar,1:2) => this%pool_avgBoundary(1:nBnd)
    this%boundaryNormal(1:Np,1:4,1:nElem,1:nVar) => this%pool_boundaryNormal(1:nNrm)

  endsubroutine MapArrays_Vector2D_t