init_stencilElement Subroutine

private subroutine init_stencilElement(me, QQN, headerPos, tIDpos)

initialize stencil

Arguments

Type IntentOptional Attributes Name
type(tem_stencilElement_type), intent(out) :: me

stencil element type to be initialized

integer, intent(in) :: QQN

number of discrete velocities in the model (without the center one)

integer, intent(in), optional :: headerPos
integer, intent(in), optional :: tIDpos(:)

Called by

proc~~init_stencilelement~~CalledByGraph proc~init_stencilelement init_stencilElement interface~init~6 init interface~init~6->proc~init_stencilelement

Source Code

  subroutine init_stencilElement( me, QQN, headerPos, tIDpos )
    ! -------------------------------------------------------------------- !
    !> stencil element type to be initialized
    type( tem_stencilElement_type ), intent(out) :: me
    !> number of discrete velocities in the model (without the center one)
    integer, intent(in) :: QQN
    !>
    integer, intent(in), optional :: headerPos
    !>
    integer, intent(in), optional :: tIDpos(:)
    ! -------------------------------------------------------------------- !
    ! -------------------------------------------------------------------- !

    me%QQN = QQN
    if ( allocated(me%tIDpos) ) deallocate(me%tIDpos)
    allocate( me%tIDpos(me%QQN) )

    if ( present(tIDpos) ) then
      me%tIDpos  = tIDpos
    else
      me%tIDpos  = 0
    end if

    me%headerPos = 0

    if ( present(headerPos) ) me%headerPos = headerPos

    allocate( me%totalPos(me%QQN) )
    me%totalPos = 0

  end subroutine init_stencilElement