SURFEX  V8_0
Surfex V8_0 release
 All Classes Files Functions Variables
read_surf_atm_conf.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 read_surf_atm_conf(HPROGRAM)
7 ! #######################################################
8 !
9 !!**** *READ_SURF_ATM_CONF* - reads the general configuration for surface
10 !!
11 !! PURPOSE
12 !! -------
13 !!
14 !!** METHOD
15 !! ------
16 !!
17 !! EXTERNAL
18 !! --------
19 !!
20 !!
21 !! IMPLICIT ARGUMENTS
22 !! ------------------
23 !!
24 !! REFERENCE
25 !! ---------
26 !!
27 !!
28 !! AUTHOR
29 !! ------
30 !! V. Masson *Meteo France*
31 !!
32 !! MODIFICATIONS
33 !! -------------
34 !! Original 01/2003
35 !! B. Decharme 06/2013 CIMPLICIT_WIND is now in NAM_SURF_REPROD_OPER
36 !-------------------------------------------------------------------------------
37 !
38 !* 0. DECLARATIONS
39 ! ------------
40 !
41 USE modi_get_luout
42 USE modi_open_namelist
43 USE modi_close_namelist
44 USE mode_pos_surf
45 !
47 USE modn_surf_atm
49 !
50 !
51 USE yomhook ,ONLY : lhook, dr_hook
52 USE parkind1 ,ONLY : jprb
53 !
54 IMPLICIT NONE
55 !
56 !* 0.1 Declarations of arguments
57 ! -------------------------
58 !
59  CHARACTER(LEN=6), INTENT(IN) :: hprogram ! program calling GROUND
60 !
61 !* 0.2 Declarations of local variables
62 ! -------------------------------
63 !
64 !
65 LOGICAL :: gfound ! Return code when searching namelist
66 INTEGER :: iluout ! logical unit of output file
67 INTEGER :: inam ! logical unit of namelist file
68 REAL(KIND=JPRB) :: zhook_handle
69 !-------------------------------------------------------------------------------
70 !
71 !* get output listing file logical unit
72 !
73 IF (lhook) CALL dr_hook('READ_SURF_ATM_CONF',0,zhook_handle)
74  CALL get_luout(hprogram,iluout)
75 !
76 !* open namelist file
77 !
78  CALL open_namelist(hprogram,inam)
79 !
80 !* reading of namelist
81 ! -------------------
82 !
83  CALL posnam(inam,'NAM_CHS_ORILAM',gfound,iluout)
84 IF (gfound) READ(unit=inam,nml=nam_chs_orilam)
85 !
86  CALL posnam(inam,'NAM_SURF_ATM',gfound,iluout)
87 IF (gfound) READ(unit=inam,nml=nam_surf_atm)
88 !
89  CALL posnam(inam,'NAM_WRITE_SURF_ATM',gfound,iluout)
90 IF (gfound) READ(unit=inam,nml=nam_write_surf_atm)
91 !
92 !
93 !* close namelist file
94 !
95  CALL close_namelist(hprogram,inam)
96 IF (lhook) CALL dr_hook('READ_SURF_ATM_CONF',1,zhook_handle)
97 !
98 !-------------------------------------------------------------------------------
99 !
100 END SUBROUTINE read_surf_atm_conf
subroutine close_namelist(HPROGRAM, KLUNAM)
subroutine posnam(KULNAM, HDNAML, OFOUND, KLUOUT)
subroutine get_luout(HPROGRAM, KLUOUT)
Definition: get_luout.F90:6
subroutine read_surf_atm_conf(HPROGRAM)
subroutine open_namelist(HPROGRAM, KLUNAM, HFILE)