SURFEX  V8_0
Surfex V8_0 release
 All Classes Files Functions Variables
prep_isba_unif.F90
Go to the documentation of this file.
1 !SFX_LIC Copyright 1994-2014 CNRS, Meteo-France and Universite Paul Sabatier
2 !SFX_LIC This is part of the SURFEX software governed by the CeCILL-C licence
3 !SFX_LIC version 1. See LICENSE, CeCILL-C_V1-en.txt and CeCILL-C_V1-fr.txt
4 !SFX_LIC for details. version 1.
5 ! #########
6 SUBROUTINE prep_isba_unif(KLUOUT,HSURF,PFIELD)
7 ! #################################################################################
8 !
9 !!**** *PREP_ISBA_UNIF* - prepares ISBA field from prescribed values
10 !!
11 !! PURPOSE
12 !! -------
13 !
14 !!** METHOD
15 !! ------
16 !!
17 !! REFERENCE
18 !! ---------
19 !!
20 !!
21 !! AUTHOR
22 !! ------
23 !! V. Masson
24 !!
25 !! MODIFICATIONS
26 !! -------------
27 !! Original 01/2004
28 !! P. Samuelsson 02/2012 MEB
29 !!------------------------------------------------------------------
30 !
31 !
32 USE modd_prep, ONLY : cinterp_type
33 USE modd_surf_par, ONLY : xundef
34 USE modd_prep_isba, ONLY : xhug_surf, xhug_root, xhug_deep, &
35  xtg_surf, xtg_root, xtg_deep, &
36  xwr_def, xwrv_def, xwrvn_def, &
37  xqc_def, &
38  xhugi_surf, xhugi_root, xhugi_deep
39 !
40 USE modi_abor1_sfx
41 !
42 USE yomhook ,ONLY : lhook, dr_hook
43 USE parkind1 ,ONLY : jprb
44 !
45 IMPLICIT NONE
46 !
47 !* 0.1 declarations of arguments
48 !
49 INTEGER, INTENT(IN) :: kluout ! output listing logical unit
50  CHARACTER(LEN=7), INTENT(IN) :: hsurf ! type of field
51 REAL, POINTER, DIMENSION(:,:,:) :: pfield ! field to interpolate horizontally
52 !
53 !* 0.2 declarations of local variables
54 !
55 REAL(KIND=JPRB) :: zhook_handle
56 !
57 !-------------------------------------------------------------------------------------
58 !
59 IF (lhook) CALL dr_hook('PREP_ISBA_UNIF',0,zhook_handle)
60 !
61 SELECT CASE(hsurf)
62 !
63 !* 3.0 Orography
64 !
65  CASE('ZS ')
66  ALLOCATE(pfield(1,1,1))
67  pfield = 0.
68 
69 !
70 !* 3.1 Profile of soil relative humidity
71 !
72  CASE('WG ')
73  ALLOCATE(pfield(1,3,1))
74  pfield(:,1,1) = xhug_surf
75  pfield(:,2,1) = xhug_root
76  pfield(:,3,1) = xhug_deep
77 
78 !* 3.2 Profile of soil humidity for ice
79 
80  CASE('WGI ')
81  ALLOCATE(pfield(1,3,1))
82  pfield(:,1,1) = xhugi_surf
83  pfield(:,2,1) = xhugi_root
84  pfield(:,3,1) = xhugi_deep
85 
86 !* 3.3 Profile of temperatures
87 
88  CASE('TG ')
89  ALLOCATE(pfield(1,3,1))
90  pfield(:,1,1) = xtg_surf
91  pfield(:,2,1) = xtg_root
92  pfield(:,3,1) = xtg_deep
93 
94 !* 3.4 Other quantities
95 
96  CASE('WR ')
97  ALLOCATE(pfield(1,1,1))
98  pfield = xwr_def
99 
100  CASE('WRL ')
101  ALLOCATE(pfield(1,1,1))
102  pfield = xwrv_def
103 
104  CASE('WRLI ')
105  ALLOCATE(pfield(1,1,1))
106  pfield = xwrv_def
107 
108  CASE('WRVN ')
109  ALLOCATE(pfield(1,1,1))
110  pfield = xwrvn_def
111 
112  CASE('TV ')
113  ALLOCATE(pfield(1,1,1))
114  pfield = xtg_surf
115 
116  CASE('TL ')
117  ALLOCATE(pfield(1,1,1))
118  pfield = xtg_surf
119 
120  CASE('TC ')
121  ALLOCATE(pfield(1,1,1))
122  pfield = xtg_surf
123 
124  CASE('QC ')
125  ALLOCATE(pfield(1,1,1))
126  pfield = xqc_def
127 
128  CASE('LAI ')
129  ALLOCATE(pfield(1,1,1))
130  pfield = xundef
131 
132  CASE('ICE_STO')
133  ALLOCATE(pfield(1,1,1))
134  pfield = 0.0
135 !
136  CASE default
137  CALL abor1_sfx('PREP_ISBA_UNIF: '//trim(hsurf)//" initialization not implemented !")
138 !
139 END SELECT
140 !
141 !* 4. Interpolation method
142 ! --------------------
143 !
144  cinterp_type='UNIF '
145 !
146 IF (lhook) CALL dr_hook('PREP_ISBA_UNIF',1,zhook_handle)
147 !
148 !-------------------------------------------------------------------------------------
149 END SUBROUTINE prep_isba_unif
subroutine abor1_sfx(YTEXT)
Definition: abor1_sfx.F90:6
subroutine prep_isba_unif(KLUOUT, HSURF, PFIELD)