SURFEX  V8_0
Surfex V8_0 release
 All Classes Files Functions Variables
write_inland_watern.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 write_inland_water_n (DTCO, DGU, U, WM, FM, &
7  hprogram,hwrite)
8 ! ####################################
9 !
10 !!**** *WRITE_INLAND_WATER_n* - routine to write surface variables in their respective files
11 !!
12 !! PURPOSE
13 !! -------
14 !!
15 !!** METHOD
16 !! ------
17 !!
18 !! EXTERNAL
19 !! --------
20 !!
21 !!
22 !! IMPLICIT ARGUMENTS
23 !! ------------------
24 !!
25 !! REFERENCE
26 !! ---------
27 !!
28 !!
29 !! AUTHOR
30 !! ------
31 !! V. Masson *Meteo France*
32 !!
33 !! MODIFICATIONS
34 !! -------------
35 !! Original 01/2003
36 !-------------------------------------------------------------------------------
37 !
38 !* 0. DECLARATIONS
39 ! ------------
40 !
41 !
42 USE modd_surfex_n, ONLY : flake_model_t
44 !
47 USE modd_surf_atm_n, ONLY : surf_atm_t
48 !
49 USE modi_write_watflux_n
50 USE modi_write_flake_n
51 !
52 !
53 USE yomhook ,ONLY : lhook, dr_hook
54 USE parkind1 ,ONLY : jprb
55 !
56 IMPLICIT NONE
57 !
58 !* 0.1 Declarations of arguments
59 ! -------------------------
60 !
61 !
62 TYPE(data_cover_t), INTENT(INOUT) :: dtco
63 TYPE(diag_surf_atm_t), INTENT(INOUT) :: dgu
64 TYPE(surf_atm_t), INTENT(INOUT) :: u
65 TYPE(watflux_model_t), INTENT(INOUT) :: wm
66 TYPE(flake_model_t), INTENT(INOUT) :: fm
67 !
68  CHARACTER(LEN=6), INTENT(IN) :: hprogram ! program calling surf. schemes
69  CHARACTER(LEN=3), INTENT(IN) :: hwrite ! 'PREP' : does not write SBL XUNDEF fields
70 ! ! 'ALL' : all fields are written
71 !* 0.2 Declarations of local variables
72 ! -------------------------------
73 !
74 REAL(KIND=JPRB) :: zhook_handle
75 !-------------------------------------------------------------------------------
76 !
77 !* 1. Selection of surface scheme
78 ! ---------------------------
79 !
80 IF (lhook) CALL dr_hook('WRITE_INLAND_WATER_N',0,zhook_handle)
81 IF (u%CWATER=='WATFLX') THEN
82  CALL write_watflux_n(dtco, dgu, u, wm, &
83  hprogram,hwrite)
84 ELSE IF (u%CWATER=='FLAKE ') THEN
85  CALL write_flake_n(dtco, dgu, u, fm, &
86  hprogram,hwrite)
87 END IF
88 IF (lhook) CALL dr_hook('WRITE_INLAND_WATER_N',1,zhook_handle)
89 !
90 !-------------------------------------------------------------------------------
91 !
92 END SUBROUTINE write_inland_water_n
subroutine write_watflux_n(DTCO, DGU, U, WM, HPROGRAM, HWRITE)
subroutine write_inland_water_n(DTCO, DGU, U, WM, FM, HPROGRAM, HWRITE)
subroutine write_flake_n(DTCO, DGU, U, FM, HPROGRAM, HWRITE)
Definition: write_flaken.F90:6