source: LMDZ5/trunk/libf/phylmd/phys_output_var_mod.F90 @ 1761

Last change on this file since 1761 was 1761, checked in by Laurent Fairhead, 11 years ago

New version of Mellor et Yamada pronostic TKE

... based on energy transfer from the mean state.

The new version is yamada_c.
It must be called after vertical diffusion rather than just before
since the source terms u_z w'u' + v_z w'theta' and g/theta w'theta'
are diagnosed from the vertical diffusion (as energy loss from the mean
state) rather than computed as K (u_z2+v_z2) or g/\theta K theta_z
(where _z means vertical derivative).
The call to this version is controled by iflag_pbl.

iflag_pbl = 20 : with TKE computed at interfaces between layers
iflag_pbl = 25 : with TKE computed within the layer
In both cases, the dissipation of turbulence is translated into heat, and
passed to the physics as dtdiss (temperature tendency due to dissipation

of TKE).

The diffusion coefficient being computed after dissipation, it must be
kept for diffusion at the next time step, and thus be stored in the
restartphy file.
This coefficient must be computed and stored for each sub-surface.

A new way of managing subsurface variables is introduced.
For arrays of the form X(:,nbsrf) are extented to X(:,nbsrf+1), where
is_ave=nbsrf+1, is an additional sub-surface which contains the averaged values.

coef_diff_turb_mod.F90 : change of flags.
ener_conserv.F90 : energy conservation must not be applied in those

cases

indicesol.h : definition of is_ave
pbl_surface_mod.F90 : call to yamada_c and changes in the management of

coefh/coefm

physiq.F : Change in the initialisation of pmflxr/s and

modified calls to pbl_surface_mod (introduction
of dtdiss, initialisation
of pbl_tke and coefh in 1D).

phys_local_var_mod.F90 : declaration of d_t_diss
phys_output_mod.F90 : new outputs (bils_tke and bils_diss) and

coefh->coefh(:,:,is_ave)

phys_state_var_mod.F90 : modified declaration for coefh and coefm

(nbsrf -> nbsrf+1)

FH

File size: 1.7 KB
Line 
1!
2! phys_local_var_mod.F90 1327 2010-03-17 15:33:56Z idelkadi $
3
4      MODULE phys_output_var_mod
5
6      use dimphy
7! Variables outputs pour les ecritures des sorties
8!======================================================================
9!
10!
11!======================================================================
12! Declaration des variables
13
14      REAL, SAVE, ALLOCATABLE :: snow_o(:), zfra_o(:)
15!$OMP THREADPRIVATE(snow_o, zfra_o)
16      INTEGER, save, ALLOCATABLE ::  itau_con(:)       ! Nombre de pas ou rflag <= 1
17!$OMP THREADPRIVATE(itau_con)
18      REAL, ALLOCATABLE :: bils_ec(:) ! Contribution of energy conservation
19      REAL, ALLOCATABLE :: bils_tke(:) ! Contribution of energy conservation
20      REAL, ALLOCATABLE :: bils_diss(:) ! Contribution of energy conservation
21      REAL, ALLOCATABLE :: bils_kinetic(:) ! bilan de chaleur au sol, kinetic
22      REAL, ALLOCATABLE :: bils_enthalp(:) ! bilan de chaleur au sol
23      REAL, ALLOCATABLE :: bils_latent(:) ! bilan de chaleur au sol
24!$OMP THREADPRIVATE(bils_ec,bils_tke,bils_diss,bils_kinetic,bils_enthalp,bils_latent)
25
26
27CONTAINS
28
29!======================================================================
30SUBROUTINE phys_output_var_init
31use dimphy
32
33IMPLICIT NONE
34
35      allocate(snow_o(klon), zfra_o(klon))
36      allocate(itau_con(klon))
37      allocate (bils_ec(klon),bils_tke(klon),bils_diss(klon),bils_kinetic(klon),bils_enthalp(klon),bils_latent(klon))
38
39END SUBROUTINE phys_output_var_init
40
41!======================================================================
42SUBROUTINE phys_output_var_end
43use dimphy
44IMPLICIT NONE
45
46      deallocate(snow_o,zfra_o,itau_con)
47      deallocate (bils_ec,bils_tke,bils_diss,bils_kinetic,bils_enthalp,bils_latent)
48
49END SUBROUTINE phys_output_var_end
50
51END MODULE phys_output_var_mod
Note: See TracBrowser for help on using the repository browser.