SICOPOLIS V3.2
 All Classes Files Functions Variables Macros
calc_vxy_b_sia.F90
Go to the documentation of this file.
1 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
2 !
3 ! Subroutine : c a l c _ v x y _ b _s i a
4 !
5 !> @file
6 !!
7 !! Computation of the basal horizontal velocity vx_b, vy_b in the shallow ice
8 !! approximation.
9 !!
10 !! @section Copyright
11 !!
12 !! Copyright 2009-2016 Ralf Greve
13 !!
14 !! @section License
15 !!
16 !! This file is part of SICOPOLIS.
17 !!
18 !! SICOPOLIS is free software: you can redistribute it and/or modify
19 !! it under the terms of the GNU General Public License as published by
20 !! the Free Software Foundation, either version 3 of the License, or
21 !! (at your option) any later version.
22 !!
23 !! SICOPOLIS is distributed in the hope that it will be useful,
24 !! but WITHOUT ANY WARRANTY; without even the implied warranty of
25 !! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
26 !! GNU General Public License for more details.
27 !!
28 !! You should have received a copy of the GNU General Public License
29 !! along with SICOPOLIS. If not, see <http://www.gnu.org/licenses/>.
30 !<
31 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
32 
33 !-------------------------------------------------------------------------------
34 !> Computation of the basal horizontal velocity vx_b, vy_b in the shallow ice
35 !! approximation.
36 !<------------------------------------------------------------------------------
37 subroutine calc_vxy_b_sia(time, z_sl)
38 
39 use sico_types
41 use sico_vars
42 
43 implicit none
44 
45 real(dp), intent(in) :: time, z_sl
46 
47 integer(i4b) :: i, j
48 integer(i4b) :: r_smw_1, s_smw_1, r_smw_2, s_smw_2
49 real(dp), dimension(0:JMAX,0:IMAX) :: gamma_slide_inv
50 real(dp) :: gamma_slide_inv_1, gamma_slide_inv_2
51 real(dp) :: smw_coeff_1, smw_coeff_2
52 real(dp), dimension(0:JMAX,0:IMAX) :: p_b, p_b_red, tau_b
53 real(dp) :: cvxy1, cvxy1a, ctau1, ctau1a
54 real(dp) :: temp_diff
55 real(dp) :: vh_max
56 real(dp) :: year_sec_inv
57 logical, dimension(0:JMAX,0:IMAX) :: sub_melt_flag
58 
59 !-------- Sliding-law coefficients --------
60 
61 year_sec_inv = 1.0_dp/year_sec
62 
63 #if (defined(ANT) && (!defined(SEDI_SLIDE) || SEDI_SLIDE==1))
64  ! Antarctica without soft sediment,
65  ! one sliding law for the entire modelling domain
66 
67 gamma_slide_inv_1 = 1.0_dp/max(gamma_slide, eps)
68 
69 do i=0, imax
70 do j=0, jmax
71  c_slide(j,i) = c_slide*year_sec_inv
72  p_weert(j,i) = p_weert
73  q_weert(j,i) = q_weert
74  gamma_slide_inv(j,i) = gamma_slide_inv_1
75  sub_melt_flag(j,i) = (gamma_slide >= eps)
76 end do
77 end do
78 
79 #elif (defined(ANT) && SEDI_SLIDE==2)
80  ! Antarctica with soft sediment,
81  ! different sliding laws for hard rock and soft sediment
82 
83 gamma_slide_inv_1 = 1.0_dp/max(gamma_slide, eps)
84 gamma_slide_inv_2 = 1.0_dp/max(gamma_slide_sedi, eps)
85 
86 do i=0, imax
87 do j=0, jmax
88 
89  if (maske_sedi(j,i) /= 7) then ! no soft sediment
90 
91 #if (defined(TRANS_LENGTH_SL))
92  c_slide(j,i) = ( (1.0_dp-r_mask_sedi(j,i))*c_slide &
93  +r_mask_sedi(j,i) *c_slide_sedi ) &
94  *year_sec_inv
95 #else
96  c_slide(j,i) = c_slide*year_sec_inv
97 #endif
98 
99  p_weert(j,i) = p_weert
100  q_weert(j,i) = q_weert
101  gamma_slide_inv(j,i) = gamma_slide_inv_1
102  sub_melt_flag(j,i) = (gamma_slide >= eps)
103 
104  else ! maske_sedi(j,i) == 7, soft sediment
105 
106 #if (defined(TRANS_LENGTH_SL))
107  c_slide(j,i) = ( (1.0_dp-r_mask_sedi(j,i))*c_slide &
108  +r_mask_sedi(j,i) *c_slide_sedi ) &
109  *year_sec_inv
110 #else
111  c_slide(j,i) = c_slide_sedi*year_sec_inv
112 #endif
113 
114  p_weert(j,i) = p_weert_sedi
115  q_weert(j,i) = q_weert_sedi
116  gamma_slide_inv(j,i) = gamma_slide_inv_2
117  sub_melt_flag(j,i) = (gamma_slide_sedi >= eps)
118 
119  end if
120 
121 end do
122 end do
123 
124 #elif (defined(GRL) && ICE_STREAM==1 \
125  || defined(asf) && ice_stream==1)
126  ! Greenland or Austfonna without ice streams,
127  ! one sliding law for the entire modelling domain,
128  ! with surface meltwater effect
129 
130 gamma_slide_inv_1 = 1.0_dp/max(gamma_slide, eps)
131 
132 r_smw_1 = r_smw
133 s_smw_1 = s_smw
134 smw_coeff_1 = smw_coeff*year_sec**s_smw_1
135 
136 do i=0, imax
137 do j=0, jmax
138  c_slide(j,i) = c_slide*year_sec_inv &
139  *(1.0_dp+smw_coeff_1*runoff(j,i)**s_smw_1 &
140  /max((h_c(j,i)+h_t(j,i))**r_smw_1, eps))
141  p_weert(j,i) = p_weert
142  q_weert(j,i) = q_weert
143  gamma_slide_inv(j,i) = gamma_slide_inv_1
144  sub_melt_flag(j,i) = (gamma_slide >= eps)
145 end do
146 end do
147 
148 #elif (defined(GRL) && ICE_STREAM==2 \
149  || defined(asf) && ice_stream==2)
150  ! Greenland or Austfonna with ice streams,
151  ! different sliding laws for hard rock and ice streams
152 
153 gamma_slide_inv_1 = 1.0_dp/max(gamma_slide, eps)
154 gamma_slide_inv_2 = 1.0_dp/max(gamma_slide_sedi, eps)
155 
156 r_smw_1 = r_smw
157 s_smw_1 = s_smw
158 smw_coeff_1 = smw_coeff *year_sec**s_smw_1
159 r_smw_2 = r_smw_sedi
160 s_smw_2 = s_smw_sedi
161 smw_coeff_2 = smw_coeff_sedi*year_sec**s_smw_2
162 
163 do i=0, imax
164 do j=0, jmax
165 
166  if (maske_sedi(j,i) /= 7) then ! no ice stream
167  c_slide(j,i) = c_slide*year_sec_inv &
168  *(1.0_dp+smw_coeff_1*runoff(j,i)**s_smw_1 &
169  /max((h_c(j,i)+h_t(j,i))**r_smw_1, eps))
170  p_weert(j,i) = p_weert
171  q_weert(j,i) = q_weert
172  gamma_slide_inv(j,i) = gamma_slide_inv_1
173  sub_melt_flag(j,i) = (gamma_slide >= eps)
174  else ! maske_sedi(j,i) == 7, ice stream
175  c_slide(j,i) = c_slide_sedi*year_sec_inv &
176  *(1.0_dp+smw_coeff_2*runoff(j,i)**s_smw_2 &
177  /max((h_c(j,i)+h_t(j,i))**r_smw_2, eps))
178  p_weert(j,i) = p_weert_sedi
179  q_weert(j,i) = q_weert_sedi
180  gamma_slide_inv(j,i) = gamma_slide_inv_2
181  sub_melt_flag(j,i) = (gamma_slide_sedi >= eps)
182  end if
183 
184 end do
185 end do
186 
187 #elif (defined(XYZ) && defined(HEINO))
188  ! ISMIP HEINO,
189  ! different sliding laws for hard rock and soft sediment
190 
191 gamma_slide_inv_1 = 1.0_dp/max(gamma_slide, eps)
192 gamma_slide_inv_2 = 1.0_dp/max(gamma_slide_sedi, eps)
193 
194 do i=0, imax
195 do j=0, jmax
196 
197  if (maske_sedi(j,i) /= 7) then ! no soft sediment
198  c_slide(j,i) = c_slide*year_sec_inv
199  p_weert(j,i) = p_weert
200  q_weert(j,i) = q_weert
201  gamma_slide_inv(j,i) = gamma_slide_inv_1
202  sub_melt_flag(j,i) = (gamma_slide >= eps)
203  else ! maske_sedi(j,i) == 7, soft sediment
204  c_slide(j,i) = c_slide_sedi*year_sec_inv
205  p_weert(j,i) = p_weert_sedi
206  q_weert(j,i) = q_weert_sedi
207  gamma_slide_inv(j,i) = gamma_slide_inv_2
208  sub_melt_flag(j,i) = (gamma_slide_sedi >= eps)
209  end if
210 
211 end do
212 end do
213 
214 #elif (defined(SCAND) \
215  || defined(nhem) \
216  || defined(tibet) \
217  || defined(nmars) \
218  || defined(smars) \
219  || defined(emtp2sge) \
220  || defined(xyz))
221  ! one sliding law for the entire modelling domain
222 
223 gamma_slide_inv_1 = 1.0_dp/max(gamma_slide, eps)
224 
225 do i=0, imax
226 do j=0, jmax
227  c_slide(j,i) = c_slide*year_sec_inv
228  p_weert(j,i) = p_weert
229  q_weert(j,i) = q_weert
230  gamma_slide_inv(j,i) = gamma_slide_inv_1
231  sub_melt_flag(j,i) = (gamma_slide >= eps)
232 end do
233 end do
234 
235 #else
236 
237 stop ' calc_vxy_b_sia: No valid domain specified!'
238 
239 #endif
240 
241 do i=0, imax
242 do j=0, jmax
243  p_weert_inv(j,i) = 1.0_dp/max(real(p_weert(j,i),dp), eps)
244 end do
245 end do
246 
247 !-------- Computation of basal stresses --------
248 
249 ! ------ Basal pressure p_b, basal water pressure p_b_w,
250 ! reduced pressure p_b_red
251 
252 do i=0, imax
253 do j=0, jmax
254 
255  if ((maske(j,i) == 0).or.flag_grounding_line_2(j,i)) then
256  ! grounded ice, or floating ice at the grounding line
257 
258  p_b(j,i) = rho*g*(h_c(j,i)+h_t(j,i))
259  p_b_w(j,i) = rho_sw*g*max((z_sl-zb(j,i)), 0.0_dp)
260  p_b_red(j,i) = p_b(j,i)-p_b_w(j,i)
261  p_b_red(j,i) = max(p_b_red(j,i), red_pres_limit_fact*p_b(j,i))
262  ! in order to avoid very small values, which may lead to
263  ! huge sliding velocities
264 
265  else ! maske(j,i) == 1, 2 or 3 away from the grounding line
266 
267  p_b(j,i) = 0.0_dp
268  p_b_w(j,i) = 0.0_dp
269  p_b_red(j,i) = 0.0_dp
270 
271  end if
272 
273 end do
274 end do
275 
276 ! ------ Absolute value of the basal shear stress, tau_b
277 
278 do i=0, imax
279 do j=0, jmax
280  tau_b(j,i) = p_b(j,i)*(dzs_dxi_g(j,i)**2+dzs_deta_g(j,i)**2)**0.5_dp
281 end do
282 end do
283 
284 !-------- Computation of d_help_b (defined on the grid points (i,j)) --------
285 
286 do i=0, imax
287 do j=0, jmax
288 
289  if ((maske(j,i) == 0).or.flag_grounding_line_2(j,i)) then
290  ! grounded ice, or floating ice at the grounding line
291 
292 ! ------ Abbreviations
293 
294 #if (SLIDE_LAW==1)
295  cvxy1 = c_slide(j,i) &
296  * (tau_b(j,i)**(p_weert(j,i)-1)/p_b(j,i)**q_weert(j,i)) &
297  * p_b(j,i)
298  ctau1 = 1.0_dp/c_slide(j,i)**p_weert_inv(j,i) &
299  * p_b(j,i)**(q_weert(j,i)*p_weert_inv(j,i))
300  ! Basal sliding at pressure melting
301 #elif (SLIDE_LAW==2)
302  cvxy1 = c_slide(j,i) &
303  * (tau_b(j,i)**(p_weert(j,i)-1)/p_b_red(j,i)**q_weert(j,i)) &
304  * p_b(j,i)
305  ctau1 = 1.0_dp/c_slide(j,i)**p_weert_inv(j,i) &
306  * p_b_red(j,i)**(q_weert(j,i)*p_weert_inv(j,i))
307  ! Basal sliding at pressure melting
308 #endif
309 
310 ! ------ d_help_b, c_drag
311 
312  if (n_cts(j,i) == -1) then ! cold ice base
313 
314  if (sub_melt_flag(j,i)) then
315  temp_diff = max((temp_c_m(0,j,i)-temp_c(0,j,i)), 0.0_dp)
316  cvxy1a = exp(-gamma_slide_inv(j,i)*temp_diff) ! sub-melt sliding
317  ctau1a = 1.0_dp/cvxy1a**p_weert_inv(j,i)
318  else
319  cvxy1a = 0.0_dp ! no sub-melt sliding
320  ctau1a = 1.0_dp/eps**p_weert_inv(j,i) ! dummy value
321  end if
322 
323  d_help_b(j,i) = cvxy1*cvxy1a
324  c_drag(j,i) = ctau1*ctau1a
325 
326  else if (n_cts(j,i) == 0) then ! temperate ice base
327 
328  d_help_b(j,i) = cvxy1 ! basal sliding
329  c_drag(j,i) = ctau1 ! (pressure-melting conditions)
330 
331  else ! n_cts(j,i) == 1, temperate ice layer
332 
333  d_help_b(j,i) = cvxy1 ! basal sliding
334  c_drag(j,i) = ctau1 ! (pressure-melting conditions)
335 
336  end if
337 
338  else ! maske(j,i) == 1, 2 or 3 away from the grounding line
339 
340  d_help_b(j,i) = 0.0_dp
341  c_drag(j,i) = 0.0_dp
342 
343  end if
344 
345 end do
346 end do
347 
348 !-------- Computation of vx_b (defined at (i+1/2,j)) --------
349 
350 do i=0, imax-1
351 do j=1, jmax-1
352  vx_b(j,i) = -0.5_dp*(d_help_b(j,i)+d_help_b(j,i+1))*dzs_dxi(j,i)
353 end do
354 end do
355 
356 !-------- Computation of vy_b (defined at (i,j+1/2)) --------
357 
358 do i=1, imax-1
359 do j=0, jmax-1
360  vy_b(j,i) = -0.5_dp*(d_help_b(j,i)+d_help_b(j+1,i))*dzs_deta(j,i)
361 end do
362 end do
363 
364 !-------- Computation of vx_b_g and vy_b_g (defined at (i,j)) --------
365 
366 do i=0, imax
367 do j=0, jmax
368  vx_b_g(j,i) = -d_help_b(j,i)*dzs_dxi_g(j,i)
369  vy_b_g(j,i) = -d_help_b(j,i)*dzs_deta_g(j,i)
370 end do
371 end do
372 
373 !-------- Limitation of computed vx_b, vy_b, vx_b_g, vy_b_g to the interval
374 ! [-VH_MAX, VH_MAX] --------
375 
376 vh_max = vh_max/year_sec
377 
378 do i=0, imax
379 do j=0, jmax
380  vx_b(j,i) = max(vx_b(j,i), -vh_max)
381  vx_b(j,i) = min(vx_b(j,i), vh_max)
382  vy_b(j,i) = max(vy_b(j,i), -vh_max)
383  vy_b(j,i) = min(vy_b(j,i), vh_max)
384  vx_b_g(j,i) = max(vx_b_g(j,i), -vh_max)
385  vx_b_g(j,i) = min(vx_b_g(j,i), vh_max)
386  vy_b_g(j,i) = max(vy_b_g(j,i), -vh_max)
387  vy_b_g(j,i) = min(vy_b_g(j,i), vh_max)
388 end do
389 end do
390 
391 end subroutine calc_vxy_b_sia
392 !
Declarations of kind types for SICOPOLIS.
Definition: sico_types.F90:35
Declarations of global variables for SICOPOLIS (for the ANT domain).
Definition: sico_vars.F90:35
subroutine calc_vxy_b_sia(time, z_sl)
Computation of the basal horizontal velocity vx_b, vy_b in the shallow ice approximation.
Declarations of global variables for SICOPOLIS.