SICOPOLIS V3.2
 All Classes Files Functions Variables Macros
calc_temp_bas.F90
Go to the documentation of this file.
1 !+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
2 !
3 ! Subroutine : c a l c _ t e m p _ b a s
4 !
5 !> @file
6 !!
7 !! Computation of the basal temperatures.
8 !!
9 !! @section Copyright
10 !!
11 !! Copyright 2009-2016 Ralf Greve
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 
32 !-------------------------------------------------------------------------------
33 !> Computation of the basal temperatures.
34 !<------------------------------------------------------------------------------
35 subroutine calc_temp_bas()
36 
37 use sico_types
39 use sico_vars
40 
41 implicit none
42 integer(i4b) :: i, j
43 
44 !-------- Computation of the basal temperatures --------
45 
46 do i=0, imax
47 do j=0, jmax
48 
49  if ( (maske(j,i) == 0).or.(maske(j,i) == 3) ) then
50  ! glaciated land or floating ice
51 
52  if (n_cts(j,i) == -1) then ! cold ice base
53 
54  temp_b(j,i) = temp_c(0,j,i)
55  temph_b(j,i) = temp_c(0,j,i) - temp_c_m(0,j,i)
56  ! relative to the pressure melting point
57 
58  else ! n_cts(j,i) == 0 or 1, temperate ice base
59 
60  temp_b(j,i) = temp_t_m(0,j,i)
61  temph_b(j,i) = 0.0_dp
62  ! relative to the pressure melting point
63 
64  end if
65 
66  else ! maske(j,i) == 1 or 2, ice-free land or sea
67 
68  temp_b(j,i) = temp_c(0,j,i)
69  temph_b(j,i) = temp_c(0,j,i) - temp_c_m(0,j,i)
70  ! relative to the pressure melting point
71 
72  end if
73 
74 end do
75 end do
76 
77 end subroutine calc_temp_bas
78 !
subroutine calc_temp_bas()
Computation of the basal temperatures.
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
Declarations of global variables for SICOPOLIS.