tem_global_mesh_internal Subroutine

private subroutine tem_global_mesh_internal(me, conf, thandle, myPart, nParts, comm)

Arguments

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

Structure to load the mesh to

type(flu_State) :: conf

Directory containing the mesh informations

integer, intent(in) :: thandle

Handle for the table to read the description of the mesh from.

integer, intent(in) :: myPart

Partition to use on the calling process (= MPI Rank in comm)

integer, intent(in) :: nParts

Number of partitions, the mesh is partitioned into (= Number of MPI processes in comm).

integer, intent(in) :: comm

MPI Communicator to use


Calls

proc~~tem_global_mesh_internal~~CallsGraph proc~tem_global_mesh_internal tem_global_mesh_internal proc~gen_treelm_slice_global gen_treelm_slice_global proc~tem_global_mesh_internal->proc~gen_treelm_slice_global proc~gen_treelm_single_global gen_treelm_single_global proc~tem_global_mesh_internal->proc~gen_treelm_single_global proc~aot_get_val~2 aot_get_val proc~tem_global_mesh_internal->proc~aot_get_val~2 proc~gen_treelm_line_global gen_treelm_line_global proc~tem_global_mesh_internal->proc~gen_treelm_line_global proc~gen_treelm_cube_global gen_treelm_cube_global proc~tem_global_mesh_internal->proc~gen_treelm_cube_global proc~tem_abort tem_abort proc~tem_global_mesh_internal->proc~tem_abort proc~gen_treelm_slice_global->proc~aot_get_val~2 proc~gen_treelm_single_global->proc~aot_get_val~2 proc~gen_treelm_line_global->proc~aot_get_val~2 proc~gen_treelm_line_global->proc~tem_abort proc~gen_treelm_cube_global->proc~aot_get_val~2 mpi_abort mpi_abort proc~tem_abort->mpi_abort

Called by

proc~~tem_global_mesh_internal~~CalledByGraph proc~tem_global_mesh_internal tem_global_mesh_internal proc~tem_global_mesh_read tem_global_mesh_read proc~tem_global_mesh_read->proc~tem_global_mesh_internal

Contents


Source Code

  subroutine tem_global_mesh_internal( me, conf, thandle, myPart, nParts, comm )
    ! -------------------------------------------------------------------- !
    !> Structure to load the mesh to
    type(tem_global_type), intent(out) :: me
    !> Directory containing the mesh informations
    type(flu_State) :: conf
    !> Handle for the table to read the description
    !! of the mesh from.
    integer, intent(in) :: thandle
    !> Partition to use on the calling process (= MPI Rank in comm)
    integer, intent(in) :: myPart
    !> Number of partitions, the mesh is partitioned into (= Number of MPI
    !! processes in comm).
    integer, intent(in) :: nParts
    !> MPI Communicator to use
    integer, intent(in) :: comm
    ! -------------------------------------------------------------------- !
    character(len=labelLen) :: meshtype
    integer :: iError
    ! -------------------------------------------------------------------- !

    call aot_get_val( L       = conf,         &
      &               thandle = thandle,      &
      &               val     = meshtype,     &
      &               ErrCode = iError,       &
      &               key     = 'predefined', &
      &               default = 'cube'        )

    select case(trim(meshtype))
    case('cube')
      ! Generate a single level full cube mesh
      call gen_treelm_cube_global( me, conf, thandle,   &
        &                          myPart, nParts, comm )
    case('slice')
      ! Generate a single level slice
      call gen_treelm_slice_global( me, conf, thandle,   &
        &                           myPart, nParts, comm )
    case('line', 'line_bounded')
      ! Generate a single level line
      call gen_treelm_line_global( me, conf, thandle,                   &
        &                          myPart, nParts, comm, trim(meshtype) )
    case('single')
      ! Generate a single level slice
      call gen_treelm_single_global( me, conf, thandle,   &
        &                            myPart, nParts, comm )
    case('default')
      write(logUnit(1),*)'Do not know how to generate mesh ' &
        &            //trim(meshtype)
      call tem_abort()
    end select
  end subroutine tem_global_mesh_internal