SURFEX  V8_0
Surfex V8_0 release
 All Classes Files Functions Variables
writesurf_sson.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 writesurf_sso_n (DGU, U, &
7  uss, &
8  hprogram)
9 ! #################################
10 !
11 !!**** *WRITESURF_SSO_n* - writes orographic fields
12 !!
13 !! PURPOSE
14 !! -------
15 !!
16 !!
17 !!
18 !!** METHOD
19 !! ------
20 !!
21 !!
22 !! REFERENCE
23 !! ---------
24 !!
25 !!
26 !! AUTHOR
27 !! ------
28 !! V. Masson *Meteo France*
29 !!
30 !! MODIFICATIONS
31 !! -------------
32 !! Original 01/2003
33 !-------------------------------------------------------------------------------
34 !
35 !* 0. DECLARATIONS
36 ! ------------
37 !
38 !
39 !
40 !
41 !
43 USE modd_surf_atm_n, ONLY : surf_atm_t
44 !
46 !
48 !
49 !
50 USE yomhook ,ONLY : lhook, dr_hook
51 USE parkind1 ,ONLY : jprb
52 !
53 IMPLICIT NONE
54 !
55 !* 0.1 Declarations of arguments
56 ! -------------------------
57 !
58 !
59 !
60 TYPE(diag_surf_atm_t), INTENT(INOUT) :: dgu
61 TYPE(surf_atm_t), INTENT(INOUT) :: u
62 !
63 TYPE(surf_atm_sso_t), INTENT(INOUT) :: uss
64 !
65  CHARACTER(LEN=6), INTENT(IN) :: hprogram ! program calling
66 !
67 !* 0.2 Declarations of local variables
68 ! -------------------------------
69 !
70 INTEGER :: iresp ! IRESP : return-code if a problem appears
71  CHARACTER(LEN=12) :: yrecfm ! Name of the article to be read
72  CHARACTER(LEN=100):: ycomment ! Comment string
73 REAL(KIND=JPRB) :: zhook_handle
74 !
75 !-------------------------------------------------------------------------------
76 !
77 !* 1. Orography :
78 ! ---------
79 !
80 !
81 IF (lhook) CALL dr_hook('WRITESURF_SSO_N',0,zhook_handle)
82 yrecfm='AVG_ZS'
83 ycomment='X_Y_AVG_ZS (M)'
84  CALL write_surf(dgu, u, &
85  hprogram,yrecfm,uss%XAVG_ZS(:),iresp,hcomment=ycomment)
86 !
87 yrecfm='SIL_ZS'
88 ycomment='X_Y_SIL_ZS (M)'
89  CALL write_surf(dgu, u, &
90  hprogram,yrecfm,uss%XSIL_ZS(:),iresp,hcomment=ycomment)
91 !
92 !-------------------------------------------------------------------------------
93 !
94 !* 2. Subgrid Orography :
95 ! -----------------
96 !
97 yrecfm='SSO_STDEV'
98 ycomment='X_Y_SSO_STDEV (M)'
99  CALL write_surf(dgu, u, &
100  hprogram,yrecfm,uss%XSSO_STDEV(:),iresp,hcomment=ycomment)
101 !
102 !
103 yrecfm='MIN_ZS'
104 ycomment='X_Y_MIN_ZS (M)'
105  CALL write_surf(dgu, u, &
106  hprogram,yrecfm,uss%XMIN_ZS(:),iresp,hcomment=ycomment)
107 !
108 yrecfm='MAX_ZS'
109 ycomment='X_Y_MAX_ZS (M)'
110  CALL write_surf(dgu, u, &
111  hprogram,yrecfm,uss%XMAX_ZS(:),iresp,hcomment=ycomment)
112 !
113 yrecfm='SSO_ANIS'
114 ycomment='X_Y_SSO_ANIS (-)'
115  CALL write_surf(dgu, u, &
116  hprogram,yrecfm,uss%XSSO_ANIS(:),iresp,hcomment=ycomment)
117 !
118 yrecfm='SSO_DIR'
119 ycomment='X_Y_SSO_DIR (DEG)'
120  CALL write_surf(dgu, u, &
121  hprogram,yrecfm,uss%XSSO_DIR(:),iresp,hcomment=ycomment)
122 !
123 yrecfm='SSO_SLOPE'
124 ycomment='X_Y_SSO_SLOPE (-)'
125  CALL write_surf(dgu, u, &
126  hprogram,yrecfm,uss%XSSO_SLOPE(:),iresp,hcomment=ycomment)
127 !
128 !-------------------------------------------------------------------------------
129 !
130 !* 3. Subgrid Orography roughness:
131 ! ---------------------------
132 !
133 !
134 yrecfm='HO2IP'
135 ycomment='X_Y_HO2IP (M)'
136  CALL write_surf(dgu, u, &
137  hprogram,yrecfm,uss%XHO2IP(:),iresp,hcomment=ycomment)
138 !
139 yrecfm='HO2JP'
140 ycomment='X_Y_HO2JP (M)'
141  CALL write_surf(dgu, u, &
142  hprogram,yrecfm,uss%XHO2JP(:),iresp,hcomment=ycomment)
143 !
144 yrecfm='HO2IM'
145 ycomment='X_Y_HO2IM (M)'
146  CALL write_surf(dgu, u, &
147  hprogram,yrecfm,uss%XHO2IM(:),iresp,hcomment=ycomment)
148 !
149 yrecfm='HO2JM'
150 ycomment='X_Y_HO2JM (M)'
151  CALL write_surf(dgu, u, &
152  hprogram,yrecfm,uss%XHO2JM(:),iresp,hcomment=ycomment)
153 !
154 yrecfm='AOSIP'
155 ycomment='X_Y_AOSIP (-)'
156  CALL write_surf(dgu, u, &
157  hprogram,yrecfm,uss%XAOSIP(:),iresp,hcomment=ycomment)
158 !
159 yrecfm='AOSJP'
160 ycomment='X_Y_AOSJP (-)'
161  CALL write_surf(dgu, u, &
162  hprogram,yrecfm,uss%XAOSJP(:),iresp,hcomment=ycomment)
163 !
164 yrecfm='AOSIM'
165 ycomment='X_Y_AOSIM (-)'
166  CALL write_surf(dgu, u, &
167  hprogram,yrecfm,uss%XAOSIM(:),iresp,hcomment=ycomment)
168 !
169 yrecfm='AOSJM'
170 ycomment='X_Y_AOSJM (-)'
171  CALL write_surf(dgu, u, &
172  hprogram,yrecfm,uss%XAOSJM(:),iresp,hcomment=ycomment)
173 IF (lhook) CALL dr_hook('WRITESURF_SSO_N',1,zhook_handle)
174 !
175 !-------------------------------------------------------------------------------
176 !
177 END SUBROUTINE writesurf_sso_n
subroutine writesurf_sso_n(DGU, U, USS, HPROGRAM)