15 |
! Pour Van-Leer plus vapeur d'eau saturée : iadv(1)=4 |
! Pour Van-Leer plus vapeur d'eau saturée : iadv(1)=4 |
16 |
! Pour Van-Leer : iadv=10 |
! Pour Van-Leer : iadv=10 |
17 |
|
|
18 |
USE IOIPSL, only: ioconf_calendar |
USE IOIPSL, only: ioconf_calendar, histclo |
19 |
use dimens_m, only: iim, jjm, llm, nqmx |
use dimens_m, only: iim, jjm, llm, nqmx |
20 |
use dimphy, only: klon |
use dimphy, only: klon |
21 |
use paramet_m, only: ip1jm, ip1jmp1 |
use paramet_m, only: ip1jm, ip1jmp1 |
39 |
use grid_change, only: dyn_phy, init_dyn_phy |
use grid_change, only: dyn_phy, init_dyn_phy |
40 |
use advtrac_m, only: iniadvtrac |
use advtrac_m, only: iniadvtrac |
41 |
use leapfrog_m, only: leapfrog |
use leapfrog_m, only: leapfrog |
42 |
|
use dynredem0_m, only: dynredem0 |
43 |
|
|
44 |
IMPLICIT NONE |
IMPLICIT NONE |
45 |
|
|
53 |
REAL ps(ip1jmp1) ! pression au sol (Pa) |
REAL ps(ip1jmp1) ! pression au sol (Pa) |
54 |
|
|
55 |
REAL masse(ip1jmp1, llm) ! masse d'air |
REAL masse(ip1jmp1, llm) ! masse d'air |
56 |
REAL phis(ip1jmp1) ! géopotentiel au sol |
REAL phis(iim + 1, jjm + 1) ! géopotentiel au sol |
57 |
|
|
58 |
! Variables pour le fichier histoire : |
! Variables pour le fichier histoire : |
59 |
REAL time_0 |
REAL time_0 |
100 |
|
|
101 |
! Lecture du fichier "start.nc" : |
! Lecture du fichier "start.nc" : |
102 |
CALL dynetat0(vcov, ucov, teta, q, masse, ps, phis, time_0) |
CALL dynetat0(vcov, ucov, teta, q, masse, ps, phis, time_0) |
|
! Begin special experiment |
|
|
!!$ print *, "This is a special experiment." |
|
|
!!$ print *, "We are setting:" |
|
|
!!$ print *, "ucov = vcov = 0, q = 0, ps = 101325" |
|
|
!!$ print *, "We are averaging 'teta' horizontally." |
|
|
!!$ ucov = 0. |
|
|
!!$ vcov = 0. |
|
|
!!$ q = 0. |
|
|
!!$ ps = 101325. |
|
|
! Average teta over all longitudes and latitudes: |
|
|
!!$ forall(i = 1:llm) teta(:,i) = sum(teta(:,i)) / ip1jmp1 |
|
|
! (it would be better to weight each element with an associated |
|
|
! surface area) |
|
|
! End special experiment |
|
103 |
|
|
104 |
! Lecture des paramètres de contrôle pour la simulation : |
! Lecture des paramètres de contrôle pour la simulation : |
105 |
! on recalcule éventuellement le pas de temps |
! on recalcule éventuellement le pas de temps |
191 |
print *, "day_ini = ", day_ini |
print *, "day_ini = ", day_ini |
192 |
print *, "day_end = ", day_end |
print *, "day_end = ", day_end |
193 |
|
|
194 |
CALL dynredem0("restart.nc", day_end, phis, nqmx) |
CALL dynredem0("restart.nc", day_end, phis) |
195 |
CALL inithist(day_ref, annee_ref, zdtvr, nqmx, histid, histvid, & |
CALL inithist(day_ref, annee_ref, zdtvr, nqmx, histid, histvid, & |
196 |
infile="dyn_hist.nc", t_ops = iecri * daysec, t_wrt = iecri * daysec) |
infile="dyn_hist.nc", t_ops = iecri * daysec, t_wrt = iecri * daysec) |
197 |
CALL initdynav(day_ref, annee_ref, zdtvr, nqmx, histaveid, & |
CALL initdynav(day_ref, annee_ref, zdtvr, nqmx, histaveid, & |
205 |
! Intégration temporelle du modèle : |
! Intégration temporelle du modèle : |
206 |
CALL leapfrog(ucov, vcov, teta, ps, masse, phis, nq, q, clesphy0, time_0) |
CALL leapfrog(ucov, vcov, teta, ps, masse, phis, nq, q, clesphy0, time_0) |
207 |
|
|
208 |
|
call histclo |
209 |
|
print *, 'Simulation finished' |
210 |
|
print *, 'Everything is cool' |
211 |
|
|
212 |
END PROGRAM gcm |
END PROGRAM gcm |