Ignore:
Timestamp:
Feb 24, 2017, 7:50:33 PM (7 years ago)
Author:
jyg
Message:

New diagnostics to verify energy conservation.
Some corrections to improve energy conservation.
Some bug correction.

New output variables and new flags are

introduced:

(1)New variables: d_xx_col is the budget over

each column of variable "xx".

(2) fl_ebil: 0 -> no diag; 1 -> diags activated
(3) fl_cor_ebil: 0 -> no correction ensuring

energy conservation; 1 -> first set of
corrections.

+ ok_bad_ecmwf_thermo: if true, a bug setting

RVTMP2 to 0 is fixed; for backward compatibility
the default is "false".

File:
1 edited

Legend:

Unmodified
Added
Removed
  • LMDZ5/trunk/libf/phylmd/phys_output_var_mod.F90

    r2752 r2799  
    2424  REAL, SAVE, ALLOCATABLE :: bils_latent(:) ! bilan de chaleur au sol
    2525  !$OMP THREADPRIVATE(bils_ec,bils_ech,bils_tke,bils_diss,bils_kinetic,bils_enthalp,bils_latent)
     26  ! output variables for energy conservation tests, computed in add_phys_tend
     27  REAL, SAVE, ALLOCATABLE :: d_qw_col(:)      ! watter vapour mass budget for each column (kg/m2/s)
     28  REAL, SAVE, ALLOCATABLE :: d_ql_col(:)      ! liquid watter mass budget for each column (kg/m2/s)
     29  REAL, SAVE, ALLOCATABLE :: d_qs_col(:)      ! solid watter mass budget for each column (kg/m2/s)
     30  REAL, SAVE, ALLOCATABLE :: d_qt_col(:)      ! total watter mass budget for each column (kg/m2/s)
     31  REAL, SAVE, ALLOCATABLE :: d_ek_col(:)      ! kinetic energy budget for each column (W/m2)
     32  REAL, SAVE, ALLOCATABLE :: d_h_dair_col(:)  ! enthalpy budget of dry air for each column (W/m2)
     33  REAL, SAVE, ALLOCATABLE :: d_h_qw_col(:)    ! enthalpy budget of watter vapour for each column (W/m2)
     34  REAL, SAVE, ALLOCATABLE :: d_h_ql_col(:)    ! enthalpy budget of liquid watter for each column (W/m2)
     35  REAL, SAVE, ALLOCATABLE :: d_h_qs_col(:)    ! enthalpy budget of solid watter  for each column (W/m2)
     36  REAL, SAVE, ALLOCATABLE :: d_h_col(:)       ! total enthalpy budget for each column (W/m2)
     37  !$OMP THREADPRIVATE(d_qw_col, d_ql_col, d_qs_col, d_qt_col, d_ek_col, d_h_dair_col)
     38  !$OMP THREADPRIVATE(d_h_qw_col, d_h_ql_col, d_h_qs_col, d_h_col
    2639
    2740! Marine
     
    121134
    122135    allocate (bils_ec(klon),bils_ech(klon),bils_tke(klon),bils_diss(klon),bils_kinetic(klon),bils_enthalp(klon),bils_latent(klon))
     136    allocate (d_qw_col(klon), d_ql_col(klon), d_qs_col(klon), d_qt_col(klon), d_ek_col(klon), d_h_dair_col(klon) &
     137  &         , d_h_qw_col(klon), d_h_ql_col(klon), d_h_qs_col(klon), d_h_col(klon))
     138    d_qw_col=0. ; d_ql_col=0. ; d_qs_col=0. ; d_qt_col=0. ; d_ek_col=0. ; d_h_dair_col =0.
     139    d_h_qw_col=0. ; d_h_ql_col=0. ; d_h_qs_col=0. ; d_h_col=0.
    123140
    124141! Marine
     
    155172    deallocate(snow_o,zfra_o,itau_con)
    156173    deallocate (bils_ec,bils_ech,bils_tke,bils_diss,bils_kinetic,bils_enthalp,bils_latent)
     174    deallocate (d_qw_col, d_ql_col, d_qs_col, d_qt_col, d_ek_col, d_h_dair_col &
     175  &           , d_h_qw_col, d_h_ql_col, d_h_qs_col, d_h_col)
    157176
    158177! Marine
Note: See TracChangeset for help on using the changeset viewer.