SCALE-RM
Functions/Subroutines
mod_copytopo Module Reference

module Copy topography More...

Functions/Subroutines

subroutine, public copytopo (TOPO_child)
 Setup and Main. More...
 

Detailed Description

module Copy topography

Description
subroutines for preparing topography data (copy from parent domain)
Author
Team SCALE
NAMELIST
  • PARAM_COPYTOPO
    nametypedefault valuecomment
    COPYTOPO_IN_BASENAME character(len=H_LONG) ''
    COPYTOPO_TRANSITION_DX real(RP) -1.0_RP thickness of transition region [m]: x
    COPYTOPO_TRANSITION_DY real(RP) -1.0_RP thickness of transition region [m]: y
    COPYTOPO_FRACX real(RP) 1.0_RP fraction of transition region (x) (0-1)
    COPYTOPO_FRACY real(RP) 1.0_RP fraction of transition region (y) (0-1)
    COPYTOPO_TAUX real(RP) 1.0_RP maximum value for mixing tau (x) [s]
    COPYTOPO_TAUY real(RP) 1.0_RP maximum value for mixing tau (y) [s]
    COPYTOPO_ENTIRE_REGION logical .false. copy parent topo over an entire region
    COPYTOPO_LINEAR_H logical .true. linear or non-linear profile of relax region
    COPYTOPO_EXP_H real(RP) 2.0_RP factor of non-linear profile of relax region
    COPYTOPO_FILTER_ORDER integer 2
    COPYTOPO_FILTER_NITER integer 20

History Output
No history output

Function/Subroutine Documentation

◆ copytopo()

subroutine, public mod_copytopo::copytopo ( real(rp), dimension(:,:), intent(inout)  TOPO_child)

Setup and Main.

Parameters
[in,out]topo_childtopography of child domain

Definition at line 68 of file mod_copytopo.F90.

References scale_atmos_grid_cartesc::atmos_grid_cartesc_cbfxg, scale_atmos_grid_cartesc::atmos_grid_cartesc_cbfyg, scale_atmos_grid_cartesc::atmos_grid_cartesc_cxg, scale_atmos_grid_cartesc::atmos_grid_cartesc_cyg, scale_atmos_grid_cartesc::atmos_grid_cartesc_fxg, scale_atmos_grid_cartesc::atmos_grid_cartesc_fyg, scale_atmos_grid_cartesc_real::atmos_grid_cartesc_real_lat, scale_atmos_grid_cartesc_real::atmos_grid_cartesc_real_lon, scale_comm_cartesc_nest::comm_cartesc_nest_domain_shape(), scale_comm_cartesc_nest::comm_cartesc_nest_interp_level, scale_comm_cartesc_nest::comm_cartesc_nest_tile_id, scale_comm_cartesc_nest::comm_cartesc_nest_tile_num_x, scale_comm_cartesc_nest::comm_cartesc_nest_tile_num_y, scale_const::const_d2r, scale_const::const_eps, scale_file::file_close(), scale_file::file_open(), scale_atmos_grid_cartesc_index::ia, scale_atmos_grid_cartesc_index::iag, scale_atmos_grid_cartesc_index::ie, scale_atmos_grid_cartesc_index::ihalo, scale_atmos_grid_cartesc_index::imax, scale_interp::interp_domain_compatibility(), scale_interp::interp_factor2d(), scale_interp::interp_interp2d(), scale_io::io_fid_conf, scale_atmos_grid_cartesc_index::is, scale_atmos_grid_cartesc_index::ja, scale_atmos_grid_cartesc_index::jag, scale_atmos_grid_cartesc_index::je, scale_atmos_grid_cartesc_index::jhalo, scale_atmos_grid_cartesc_index::jmax, scale_atmos_grid_cartesc_index::js, scale_landuse::landuse_fact_ocean, scale_comm_cartesc_nest::parent_imax, scale_comm_cartesc_nest::parent_jmax, scale_prc_cartesc::prc_2drank, scale_prc::prc_abort(), and scale_prc::prc_myrank.

Referenced by mod_cnvtopo::cnvtopo().

68  use scale_prc, only: &
69  prc_abort
70  implicit none
71 
72  real(RP), intent(inout) :: topo_child(:,:)
73 
74  real(RP) :: ctrx (ia)
75  real(RP) :: ctry (ja)
76  real(RP) :: alpha (ia,ja)
77  real(RP) :: topo_parent(ia,ja)
78 
79  namelist / param_copytopo / &
80  copytopo_in_basename, &
81  copytopo_transition_dx, &
82  copytopo_transition_dy, &
83  copytopo_fracx, &
84  copytopo_fracy, &
85  copytopo_taux, &
86  copytopo_tauy, &
87  copytopo_entire_region, &
88  copytopo_linear_h, &
89  copytopo_exp_h, &
90  copytopo_filter_order, &
91  copytopo_filter_niter
92 
93  integer :: ierr
94  !---------------------------------------------------------------------------
95 
96  log_newline
97  log_info("COPYTOPO",*) 'Setup'
98 
99  !--- read namelist
100  rewind(io_fid_conf)
101  read(io_fid_conf,nml=param_copytopo,iostat=ierr)
102  if( ierr < 0 ) then !--- missing
103  log_info("COPYTOPO",*) 'Not found namelist. Default used.'
104  elseif( ierr > 0 ) then !--- fatal error
105  log_error("COPYTOPO",*) 'Not appropriate names in namelist PARAM_COPYTOPO. Check!'
106  call prc_abort
107  endif
108  log_nml(param_copytopo)
109 
110  ! copy topography from parent domain to transition region
111 
112  call copytopo_transgrid( ctrx(:), ctry(:) ) ! [OUT]
113 
114  call copytopo_setalpha ( ctrx(:), ctry(:), & ! [IN]
115  alpha(:,:) ) ! [OUT]
116 
117  call copytopo_input_data( topo_parent(:,:) ) ! [OUT]
118 
119  call copytopo_mix_data( topo_parent(:,:), & ! [IN]
120  alpha(:,:), & ! [IN]
121  topo_child(:,:) ) ! [INOUT]
122 
123  return
integer, public io_fid_conf
Config file ID.
Definition: scale_io.F90:55
module PROCESS
Definition: scale_prc.F90:11
subroutine, public prc_abort
Abort Process.
Definition: scale_prc.F90:338
Here is the call graph for this function:
Here is the caller graph for this function: