SICOPOLIS V5-dev  Revision 1420
sico_main_loop_wrapper_m.F90
Go to the documentation of this file.
1 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
2 !
3 ! Module : s i c o _ m a i n _ l o o p _ w r a p p e r _ m
4 !
5 !> @file
6 !!
7 !! A catch-all module for openad-related subroutines.
8 !!
9 !! @section Copyright
10 !!
11 !! Copyright 2017-2018 ...
12 !!
13 !! @section License
14 !!
15 !! This file is part of SICOPOLIS.
16 !!
17 !! SICOPOLIS is free software: you can redistribute it and/or modify
18 !! it under the terms of the GNU General Public License as published by
19 !! the Free Software Foundation, either version 3 of the License, or
20 !! (at your option) any later version.
21 !!
22 !! SICOPOLIS is distributed in the hope that it will be useful,
23 !! but WITHOUT ANY WARRANTY; without even the implied warranty of
24 !! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25 !! GNU General Public License for more details.
26 !!
27 !! You should have received a copy of the GNU General Public License
28 !! along with SICOPOLIS. If not, see <http://www.gnu.org/licenses/>.
29 !<
30 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
31 
33 
34  implicit none
35 
36  public
37 
38 contains
39 
40 !-------------------------------------------------------------------------------
41 !> Calls sico_main_loop_iter_m. Necessarily decoupled from time loop due to use
42 !! of revolve.
43 !<------------------------------------------------------------------------------
44  subroutine sico_main_loop_wrapper(delta_ts, glac_index, &
45  mean_accum, &
46  dtime, dtime_temp, dtime_wss, dtime_out, dtime_ser, &
47  time, time_init, time_end, time_output, &
48  dxi, deta, dzeta_c, dzeta_t, dzeta_r, &
49  z_sl, dzsl_dtau, z_mar, &
50  ndat2d, ndat3d, n_output, &
51  runname, &
52  itercount_max,iter_temp,iter_wss,iter_ser,&
53  iter_out,iter_output)
54 
55 !$openad xxx template ad_revolve_template.F
56  use sico_types_m
58  use sico_vars_m
59  use boundary_m
60 #if (defined(GRL) && DISC>0)
62 #endif
63 #if (CALCMOD==0 || CALCMOD==1 || CALCMOD==-1)
64  use calc_temp_m
65 #elif (CALCMOD==2 || CALCMOD==3)
67 #endif
68 
69  use calc_enhance_m
71  use calc_vxy_m
72  use calc_vz_m
73  use calc_dxyz_m
74  use calc_gia_m
75  use calc_thk_m
77  use calc_bas_melt_m
80  use ctrl_m, only: myfloor
81 
82  implicit none
83 
84  integer(i4b), intent(inout) :: n_output
85  real(dp), intent(inout) :: mean_accum
86  real(dp), intent(inout) :: dtime, dtime_temp, dtime_wss, &
87  dtime_out, dtime_ser
88  real(dp), intent(inout) :: time_init, time_end, time_output(100)
89  real(dp), intent(inout) :: dxi, deta, dzeta_c, dzeta_t, dzeta_r
90  character(len=100), intent(inout) :: runname
91 
92  integer(i4b), intent(inout) :: ndat2d, ndat3d
93  real(dp), intent(inout) :: delta_ts, glac_index
94  real(dp), intent(inout) :: time
95  real(dp), intent(inout) :: z_sl, dzsl_dtau, z_mar
96 
97  integer(i4b) :: i, j, kc, kt, kr, n
98  integer(i4b) :: itercount
99  integer(i4b), intent(inout) :: itercount_max, iter_temp, iter_wss
100  integer(i4b), intent(inout) :: iter_ser, iter_out, iter_output(100)
101  real(dp) :: dtime_temp_inv
102  logical :: flag_3d_output
103 
104  real(dp) :: tmp, valmod
105  integer(i4b) :: valmodint
106 
107  main_loop : do itercount=1, itercount_max
108  call sico_main_loop_iter(delta_ts, glac_index, &
109  mean_accum, &
110  dtime, dtime_temp, dtime_wss, dtime_out, dtime_ser, &
111  time, time_init, time_end, time_output, &
112  dxi, deta, dzeta_c, dzeta_t, dzeta_r, &
113  z_sl, dzsl_dtau, z_mar, &
114  ndat2d, ndat3d, n_output, &
115  runname, &
116  itercount,iter_temp,iter_wss,iter_ser,&
117  iter_out,iter_output)
118  end do main_loop ! End of main loop
119 
120  end subroutine sico_main_loop_wrapper
121 
122 end module sico_main_loop_wrapper_m
Computation of the ice thickness.
Definition: calc_thk_m.F90:35
Update of the flags for the land-terminating grounded front, marine-terminating grounded front...
Definition: ctrl_m.F90:9
Computation of the thickness of the water column under the ice base.
Computation of all components of the strain-rate tensor, the full effective strain rate and the shear...
Definition: calc_dxyz_m.F90:37
Declarations of global variables for SICOPOLIS (for the ANT domain).
Definition: sico_vars_m.F90:35
Computation of the flow enhancement factor.
Computation of the horizontal velocity vx, vy.
Definition: calc_vxy_m.F90:36
Declarations of kind types for SICOPOLIS.
subroutine sico_main_loop_iter(delta_ts, glac_index, mean_accum, dtime, dtime_temp, dtime_wss, dtime_out, dtime_ser, time, time_init, time_end, time_output, dxi, deta, dzeta_c, dzeta_t, dzeta_r, z_sl, dzsl_dtau, z_mar, ndat2d, ndat3d, n_output, runname, itercount, iter_temp, iter_wss, iter_ser, iter_out, iter_output)
The interior of subroutine sico_main_loop. If new subroutines / modules are introduced into the main ...
Computation of temperature, water content and age.
Definition: calc_temp_m.F90:35
Computation of the melting and basal temperatures.
subroutine sico_main_loop_wrapper(delta_ts, glac_index, mean_accum, dtime, dtime_temp, dtime_wss, dtime_out, dtime_ser, time, time_init, time_end, time_output, dxi, deta, dzeta_c, dzeta_t, dzeta_r, z_sl, dzsl_dtau, z_mar, ndat2d, ndat3d, n_output, runname, itercount_max, iter_temp, iter_wss, iter_ser, iter_out, iter_output)
Calls sico_main_loop_iter_m. Necessarily decoupled from time loop due to use of revolve.
Computation of the vertical velocity vz.
Definition: calc_vz_m.F90:35
Computation of temperature, water content and age with the enthalpy method.
Computation of the basal melting rate.
Computation of the surface temperature (must be less than 0 deg C!) and of the accumulation-ablation ...
Definition: boundary_m.F90:37
Ice discharge parameterization for the Greenland ice sheet.
Computation of the glacial isostatic adjustment of the lithosphere surface.
Definition: calc_gia_m.F90:36
Declarations of global variables for SICOPOLIS.