dyn_mpas_get_pool_pointer Subroutine

private subroutine dyn_mpas_get_pool_pointer(self, pool_pointer, pool_name)

Uses

    • mpas_derived_types
    • mpas_pool_routines
  • proc~~dyn_mpas_get_pool_pointer~~UsesGraph proc~dyn_mpas_get_pool_pointer mpas_dynamical_core_type%dyn_mpas_get_pool_pointer mpas_derived_types mpas_derived_types proc~dyn_mpas_get_pool_pointer->mpas_derived_types mpas_pool_routines mpas_pool_routines proc~dyn_mpas_get_pool_pointer->mpas_pool_routines

This subroutine returns a pointer of mpas_pool_type to the named pool. Supported pool names include: "all", "cfg", "dim", and a subset of the var_struct elements in MPAS registry. It is mostly used by the dyn_mpas_get_variable_{pointer,value}_* subroutines to draw a variable from a pool.

Type Bound

mpas_dynamical_core_type

Arguments

Type IntentOptional Attributes Name
class(mpas_dynamical_core_type), intent(in) :: self
type(mpas_pool_type), intent(out), pointer :: pool_pointer
character(len=*), intent(in) :: pool_name

Calls

proc~~dyn_mpas_get_pool_pointer~~CallsGraph proc~dyn_mpas_get_pool_pointer mpas_dynamical_core_type%dyn_mpas_get_pool_pointer mpas_pool_get_subpool mpas_pool_get_subpool proc~dyn_mpas_get_pool_pointer->mpas_pool_get_subpool

Called by

proc~~dyn_mpas_get_pool_pointer~~CalledByGraph proc~dyn_mpas_get_pool_pointer mpas_dynamical_core_type%dyn_mpas_get_pool_pointer proc~dyn_mpas_compute_unit_vector mpas_dynamical_core_type%dyn_mpas_compute_unit_vector proc~dyn_mpas_compute_unit_vector->proc~dyn_mpas_get_pool_pointer none~get_variable_pointer mpas_dynamical_core_type%get_variable_pointer proc~dyn_mpas_compute_unit_vector->none~get_variable_pointer proc~dyn_mpas_define_scalar mpas_dynamical_core_type%dyn_mpas_define_scalar proc~dyn_mpas_define_scalar->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_c0 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_c0 proc~dyn_mpas_get_variable_pointer_c0->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_c1 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_c1 proc~dyn_mpas_get_variable_pointer_c1->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_i0 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_i0 proc~dyn_mpas_get_variable_pointer_i0->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_i1 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_i1 proc~dyn_mpas_get_variable_pointer_i1->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_i2 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_i2 proc~dyn_mpas_get_variable_pointer_i2->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_i3 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_i3 proc~dyn_mpas_get_variable_pointer_i3->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_l0 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_l0 proc~dyn_mpas_get_variable_pointer_l0->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_r0 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_r0 proc~dyn_mpas_get_variable_pointer_r0->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_r1 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_r1 proc~dyn_mpas_get_variable_pointer_r1->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_r2 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_r2 proc~dyn_mpas_get_variable_pointer_r2->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_r3 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_r3 proc~dyn_mpas_get_variable_pointer_r3->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_r4 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_r4 proc~dyn_mpas_get_variable_pointer_r4->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_get_variable_pointer_r5 mpas_dynamical_core_type%dyn_mpas_get_variable_pointer_r5 proc~dyn_mpas_get_variable_pointer_r5->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_init_phase3 mpas_dynamical_core_type%dyn_mpas_init_phase3 proc~dyn_mpas_init_phase3->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_init_phase4 mpas_dynamical_core_type%dyn_mpas_init_phase4 proc~dyn_mpas_init_phase4->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_init_phase4->none~get_variable_pointer proc~dyn_mpas_run mpas_dynamical_core_type%dyn_mpas_run proc~dyn_mpas_run->proc~dyn_mpas_get_pool_pointer proc~dyn_mpas_run->none~get_variable_pointer none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_c0 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_c1 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_i0 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_i1 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_i2 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_i3 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_l0 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_r0 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_r1 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_r2 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_r3 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_r4 none~get_variable_pointer->proc~dyn_mpas_get_variable_pointer_r5 proc~dyn_init dyn_init proc~dyn_init->proc~dyn_mpas_define_scalar proc~dyn_init->proc~dyn_mpas_init_phase4 proc~check_topography_data check_topography_data proc~dyn_init->proc~check_topography_data proc~dyn_exchange_constituent_states dyn_exchange_constituent_states proc~dyn_init->proc~dyn_exchange_constituent_states proc~set_analytic_initial_condition set_analytic_initial_condition proc~dyn_init->proc~set_analytic_initial_condition proc~dyn_run dyn_run proc~dyn_run->proc~dyn_mpas_run proc~model_grid_init model_grid_init proc~model_grid_init->proc~dyn_mpas_compute_unit_vector proc~model_grid_init->proc~dyn_mpas_init_phase3 proc~define_cam_grid define_cam_grid proc~model_grid_init->proc~define_cam_grid proc~init_physics_grid init_physics_grid proc~model_grid_init->proc~init_physics_grid proc~init_reference_pressure init_reference_pressure proc~model_grid_init->proc~init_reference_pressure proc~dyn_inquire_mesh_dimensions dyn_inquire_mesh_dimensions proc~model_grid_init->proc~dyn_inquire_mesh_dimensions none~init_shared_variables init_shared_variables none~init_shared_variables->none~get_variable_pointer none~init_shared_variables~2 init_shared_variables none~init_shared_variables~2->none~get_variable_pointer none~init_shared_variables~3 init_shared_variables none~init_shared_variables~3->none~get_variable_pointer none~set_mpas_physics_tendency_rho set_mpas_physics_tendency_rho none~set_mpas_physics_tendency_rho->none~get_variable_pointer none~set_mpas_physics_tendency_rtheta set_mpas_physics_tendency_rtheta none~set_mpas_physics_tendency_rtheta->none~get_variable_pointer none~set_mpas_physics_tendency_ru set_mpas_physics_tendency_ru none~set_mpas_physics_tendency_ru->none~get_variable_pointer proc~dyn_mpas_compute_edge_wind mpas_dynamical_core_type%dyn_mpas_compute_edge_wind none~set_mpas_physics_tendency_ru->proc~dyn_mpas_compute_edge_wind none~set_mpas_state_rho_base_theta_base set_mpas_state_rho_base_theta_base none~set_mpas_state_rho_base_theta_base->none~get_variable_pointer none~set_mpas_state_rho_theta set_mpas_state_rho_theta none~set_mpas_state_rho_theta->none~get_variable_pointer none~set_mpas_state_scalars set_mpas_state_scalars none~set_mpas_state_scalars->none~get_variable_pointer none~set_mpas_state_u set_mpas_state_u none~set_mpas_state_u->none~get_variable_pointer none~set_mpas_state_u->proc~dyn_mpas_compute_edge_wind none~set_mpas_state_w set_mpas_state_w none~set_mpas_state_w->none~get_variable_pointer proc~check_topography_data->none~get_variable_pointer proc~define_cam_grid->none~get_variable_pointer proc~dyn_exchange_constituent_states->none~get_variable_pointer proc~dyn_mpas_compute_edge_wind->none~get_variable_pointer proc~dyn_mpas_get_global_mesh_dimension mpas_dynamical_core_type%dyn_mpas_get_global_mesh_dimension proc~dyn_mpas_get_global_mesh_dimension->none~get_variable_pointer proc~dyn_mpas_get_local_mesh_dimension mpas_dynamical_core_type%dyn_mpas_get_local_mesh_dimension proc~dyn_mpas_get_local_mesh_dimension->none~get_variable_pointer proc~dyn_mpas_get_variable_value_c0 mpas_dynamical_core_type%dyn_mpas_get_variable_value_c0 proc~dyn_mpas_get_variable_value_c0->none~get_variable_pointer proc~dyn_mpas_get_variable_value_c1 mpas_dynamical_core_type%dyn_mpas_get_variable_value_c1 proc~dyn_mpas_get_variable_value_c1->none~get_variable_pointer proc~dyn_mpas_get_variable_value_i0 mpas_dynamical_core_type%dyn_mpas_get_variable_value_i0 proc~dyn_mpas_get_variable_value_i0->none~get_variable_pointer proc~dyn_mpas_get_variable_value_i1 mpas_dynamical_core_type%dyn_mpas_get_variable_value_i1 proc~dyn_mpas_get_variable_value_i1->none~get_variable_pointer proc~dyn_mpas_get_variable_value_i2 mpas_dynamical_core_type%dyn_mpas_get_variable_value_i2 proc~dyn_mpas_get_variable_value_i2->none~get_variable_pointer proc~dyn_mpas_get_variable_value_i3 mpas_dynamical_core_type%dyn_mpas_get_variable_value_i3 proc~dyn_mpas_get_variable_value_i3->none~get_variable_pointer proc~dyn_mpas_get_variable_value_l0 mpas_dynamical_core_type%dyn_mpas_get_variable_value_l0 proc~dyn_mpas_get_variable_value_l0->none~get_variable_pointer proc~dyn_mpas_get_variable_value_r0 mpas_dynamical_core_type%dyn_mpas_get_variable_value_r0 proc~dyn_mpas_get_variable_value_r0->none~get_variable_pointer proc~dyn_mpas_get_variable_value_r1 mpas_dynamical_core_type%dyn_mpas_get_variable_value_r1 proc~dyn_mpas_get_variable_value_r1->none~get_variable_pointer proc~dyn_mpas_get_variable_value_r2 mpas_dynamical_core_type%dyn_mpas_get_variable_value_r2 proc~dyn_mpas_get_variable_value_r2->none~get_variable_pointer proc~dyn_mpas_get_variable_value_r3 mpas_dynamical_core_type%dyn_mpas_get_variable_value_r3 proc~dyn_mpas_get_variable_value_r3->none~get_variable_pointer proc~dyn_mpas_get_variable_value_r4 mpas_dynamical_core_type%dyn_mpas_get_variable_value_r4 proc~dyn_mpas_get_variable_value_r4->none~get_variable_pointer proc~dyn_mpas_get_variable_value_r5 mpas_dynamical_core_type%dyn_mpas_get_variable_value_r5 proc~dyn_mpas_get_variable_value_r5->none~get_variable_pointer proc~dyn_mpas_read_namelist mpas_dynamical_core_type%dyn_mpas_read_namelist proc~dyn_mpas_read_namelist->none~get_variable_pointer proc~dyn_variable_dump dyn_variable_dump proc~dyn_variable_dump->none~get_variable_pointer proc~init_physics_grid->none~get_variable_pointer proc~init_reference_pressure->none~get_variable_pointer proc~stepon_run3 stepon_run3 proc~stepon_run3->proc~dyn_run none~set_physics_state_external set_physics_state_external none~set_physics_state_external->proc~dyn_exchange_constituent_states proc~dyn_final dyn_final proc~dyn_final->proc~dyn_variable_dump proc~dyn_inquire_mesh_dimensions->proc~dyn_mpas_get_global_mesh_dimension proc~dyn_inquire_mesh_dimensions->proc~dyn_mpas_get_local_mesh_dimension proc~dyn_readnl dyn_readnl proc~dyn_readnl->proc~dyn_mpas_read_namelist proc~dynamics_to_physics_coupling dynamics_to_physics_coupling proc~dynamics_to_physics_coupling->none~init_shared_variables~2 proc~dynamics_to_physics_coupling->proc~dyn_exchange_constituent_states proc~dynamics_to_physics_coupling->none~set_physics_state_external proc~physics_to_dynamics_coupling physics_to_dynamics_coupling proc~physics_to_dynamics_coupling->none~init_shared_variables~3 proc~physics_to_dynamics_coupling->none~set_mpas_physics_tendency_rho proc~physics_to_dynamics_coupling->none~set_mpas_physics_tendency_rtheta proc~physics_to_dynamics_coupling->none~set_mpas_physics_tendency_ru proc~physics_to_dynamics_coupling->proc~dyn_exchange_constituent_states proc~set_analytic_initial_condition->none~init_shared_variables proc~set_analytic_initial_condition->none~set_mpas_state_rho_base_theta_base proc~set_analytic_initial_condition->none~set_mpas_state_rho_theta proc~set_analytic_initial_condition->none~set_mpas_state_scalars proc~set_analytic_initial_condition->none~set_mpas_state_u proc~set_analytic_initial_condition->none~set_mpas_state_w proc~stepon_final stepon_final proc~stepon_final->proc~dyn_final proc~stepon_run2 stepon_run2 proc~stepon_run2->proc~physics_to_dynamics_coupling proc~stepon_timestep_init stepon_timestep_init proc~stepon_timestep_init->proc~dynamics_to_physics_coupling

Variables

Type Visibility Attributes Name Initial
character(len=*), private, parameter :: subname = 'dyn_mpas_subdriver::dyn_mpas_get_pool_pointer'

Source Code

    subroutine dyn_mpas_get_pool_pointer(self, pool_pointer, pool_name)
        ! Module(s) from MPAS.
        use mpas_derived_types, only: mpas_pool_type
        use mpas_pool_routines, only: mpas_pool_get_subpool

        class(mpas_dynamical_core_type), intent(in) :: self
        type(mpas_pool_type), pointer, intent(out) :: pool_pointer
        character(*), intent(in) :: pool_name

        character(*), parameter :: subname = 'dyn_mpas_subdriver::dyn_mpas_get_pool_pointer'

        nullify(pool_pointer)

        select case (trim(adjustl(pool_name)))
            case ('all')
                pool_pointer => self % domain_ptr % blocklist % allfields
            case ('cfg')
                pool_pointer => self % domain_ptr % configs
            case ('dim')
                pool_pointer => self % domain_ptr % blocklist % dimensions
            case ('diag', 'mesh', 'state', 'tend', 'tend_physics')
                call mpas_pool_get_subpool(self % domain_ptr % blocklist % allstructs, trim(adjustl(pool_name)), pool_pointer)
            case default
                call self % model_error('Unsupported pool name "' // trim(adjustl(pool_name)) // '"', subname, __LINE__)
        end select

        if (.not. associated(pool_pointer)) then
            call self % model_error('Failed to find pool "' // trim(adjustl(pool_name)) // '"', subname, __LINE__)
        end if
    end subroutine dyn_mpas_get_pool_pointer