4 |
|
|
5 |
contains |
contains |
6 |
|
|
7 |
SUBROUTINE interfsurf_hq(itime, dtime, jour, rmu0, klon, iim, jjm, & |
SUBROUTINE interfsurf_hq(itime, dtime, jour, rmu0, iim, jjm, nisurf, knon, & |
8 |
nisurf, knon, knindex, pctsrf, rlat, debut, & |
knindex, pctsrf, rlat, debut, ok_veget, soil_model, nsoilmx, tsoil, & |
9 |
ok_veget, soil_model, nsoilmx, tsoil, qsol, u1_lay, v1_lay, & |
qsol, u1_lay, v1_lay, temp_air, spechum, tq_cdrag, petAcoef, peqAcoef, & |
10 |
temp_air, spechum, tq_cdrag, petAcoef, peqAcoef, & |
petBcoef, peqBcoef, precip_rain, precip_snow, fder, rugos, rugoro, & |
11 |
petBcoef, peqBcoef, precip_rain, precip_snow, & |
snow, qsurf, tsurf, p1lay, ps, radsol, ocean, evap, fluxsens, fluxlat, & |
12 |
fder, rugos, rugoro, snow, qsurf, & |
dflux_l, dflux_s, tsurf_new, alb_new, alblw, z0_new, pctsrf_new, & |
13 |
tsurf, p1lay, ps, radsol, ocean, evap, fluxsens, & |
agesno, fqcalving, ffonte, run_off_lic_0, flux_o, flux_g, tslab, seaice) |
|
fluxlat, dflux_l, dflux_s, tsurf_new, alb_new, alblw, & |
|
|
z0_new, pctsrf_new, agesno, fqcalving, ffonte, & |
|
|
run_off_lic_0, flux_o, flux_g, tslab, seaice) |
|
14 |
|
|
15 |
! Cette routine sert d'aiguillage entre l'atmosphère et la surface |
! Cette routine sert d'aiguillage entre l'atmosphère et la surface |
16 |
! en général (sols continentaux, océans, glaces) pour les flux de |
! en général (sols continentaux, océans, glaces) pour les flux de |
17 |
! chaleur et d'humidité. En pratique l'interface se fait entre la |
! chaleur et d'humidité. |
|
! couche limite du modèle atmosphérique ("clmain.F") et les |
|
|
! routines de surface ("sechiba", "oasis"...). |
|
18 |
|
|
19 |
! Laurent Fairhead 02/2000 |
! Laurent Fairhead, 02/2000 |
20 |
|
|
21 |
USE abort_gcm_m, ONLY: abort_gcm |
USE abort_gcm_m, ONLY: abort_gcm |
22 |
USE albsno_m, ONLY: albsno |
USE albsno_m, ONLY: albsno |
23 |
USE calcul_fluxs_m, ONLY: calcul_fluxs |
USE calcul_fluxs_m, ONLY: calcul_fluxs |
24 |
|
USE dimphy, ONLY: klon |
25 |
USE fonte_neige_m, ONLY: fonte_neige |
USE fonte_neige_m, ONLY: fonte_neige |
26 |
USE gath_cpl, ONLY: gath2cpl |
USE gath_cpl, ONLY: gath2cpl |
27 |
USE indicesol, ONLY: epsfra, is_lic, is_oce, is_sic, is_ter, nbsrf |
USE indicesol, ONLY: epsfra, is_lic, is_oce, is_sic, is_ter, nbsrf |
34 |
|
|
35 |
! Parametres d'entree |
! Parametres d'entree |
36 |
! input: |
! input: |
|
! klon nombre total de points de grille |
|
37 |
! iim, jjm nbres de pts de grille |
! iim, jjm nbres de pts de grille |
38 |
! dtime pas de temps de la physique (en s) |
! dtime pas de temps de la physique (en s) |
39 |
! jour jour dans l'annee en cours, |
! jour jour dans l'annee en cours, |
71 |
! run_off_lic_0 runoff glacier du pas de temps precedent |
! run_off_lic_0 runoff glacier du pas de temps precedent |
72 |
integer, intent(IN):: itime ! numero du pas de temps |
integer, intent(IN):: itime ! numero du pas de temps |
73 |
integer, intent(IN):: iim, jjm |
integer, intent(IN):: iim, jjm |
|
integer, intent(IN):: klon |
|
74 |
real, intent(IN):: dtime |
real, intent(IN):: dtime |
75 |
integer, intent(IN):: jour |
integer, intent(IN):: jour |
76 |
real, intent(IN):: rmu0(klon) |
real, intent(IN):: rmu0(klon) |
275 |
! Aiguillage vers les differents schemas de surface |
! Aiguillage vers les differents schemas de surface |
276 |
|
|
277 |
if (nisurf == is_ter) then |
if (nisurf == is_ter) then |
|
|
|
278 |
! Surface "terre" appel a l'interface avec les sols continentaux |
! Surface "terre" appel a l'interface avec les sols continentaux |
279 |
|
|
280 |
! allocation du run-off |
! allocation du run-off |
298 |
run_off=0.0 |
run_off=0.0 |
299 |
!cym |
!cym |
300 |
|
|
|
!!$PB |
|
301 |
ALLOCATE (tmp_rriv(iim, jjm+1), stat=error) |
ALLOCATE (tmp_rriv(iim, jjm+1), stat=error) |
302 |
if (error /= 0) then |
if (error /= 0) then |
303 |
abort_message='Pb allocation tmp_rriv' |
abort_message='Pb allocation tmp_rriv' |
316 |
tmp_rriv = 0.0 |
tmp_rriv = 0.0 |
317 |
tmp_rcoa = 0.0 |
tmp_rcoa = 0.0 |
318 |
tmp_rlic = 0.0 |
tmp_rlic = 0.0 |
|
|
|
|
!!$ |
|
319 |
else if (size(coastalflow) /= knon) then |
else if (size(coastalflow) /= knon) then |
320 |
write(*, *)'Bizarre, le nombre de points continentaux' |
write(*, *)'Bizarre, le nombre de points continentaux' |
321 |
write(*, *)'a change entre deux appels. J''arrete ...' |
write(*, *)'a change entre deux appels. J''arrete ...' |
330 |
if (.not. ok_veget) then |
if (.not. ok_veget) then |
331 |
! calcul albedo: lecture albedo fichier boundary conditions |
! calcul albedo: lecture albedo fichier boundary conditions |
332 |
! puis ajout albedo neige |
! puis ajout albedo neige |
333 |
call interfsur_lim(itime, dtime, jour, klon, nisurf, knon, knindex, & |
call interfsur_lim(itime, dtime, jour, nisurf, knon, knindex, & |
334 |
debut, alb_new, z0_new) |
debut, alb_new, z0_new) |
335 |
|
|
336 |
! calcul snow et qsurf, hydrol adapté |
! calcul snow et qsurf, hydrol adapté |