Ignore:
Timestamp:
Jul 1, 2021, 8:36:13 AM (4 years ago)
Author:
emillour
Message:

Mars GCM:
Add possibility of additional tests (NaNs?, but also of unrealistic values) of
fields at the begining of physics (i.e. coming from the dynamics) and at the
end of the physics integration. These are respectively triggered by seting
flags "check_physics_inputs" and "check_physics_outputs" to .true.
EM

Location:
trunk/LMDZ.MARS/libf/phymars
Files:
1 added
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.MARS/libf/phymars/physiq_mod.F

    r2538 r2541  
    7474      use compute_dtau_mod, only: compute_dtau
    7575      use nonoro_gwd_ran_mod, only: nonoro_gwd_ran
     76      use check_fields_mod, only: check_physics_fields
    7677#ifdef MESOSCALE
    7778      use comsoil_h, only: mlayer,layer
     
    9697#endif
    9798      USE mod_grid_phy_lmdz, ONLY: grid_type, unstructured
     99      use ioipsl_getin_p_mod, only: getin_p
    98100
    99101      IMPLICIT NONE
     
    507509      integer iloop
    508510
    509 !      LOGICAL startphy_file
     511      ! flags to trigger extra sanity checks
     512      logical,save :: check_physics_inputs=.false.
     513      logical,save :: check_physics_outputs=.false.
    510514
    511515c=======================================================================
     
    519523
    520524      IF (firstcall) THEN
     525
     526         call getin_p("check_physics_inputs",check_physics_inputs)
     527         call getin_p("check_physics_outputs",check_physics_outputs)
    521528
    522529c        variables set to 0
     
    735742      ENDIF        !  (end of "if firstcall")
    736743
     744      if (check_physics_inputs) then
     745        ! Check the validity of input fields coming from the dynamics
     746        call check_physics_fields("begin physiq:",pt,pu,pv,pplev)
     747      endif
     748
    737749c ---------------------------------------------------
    738750c 1.2   Initializations done at every physical timestep:
     
    38883900#endif
    38893901
     3902      if (check_physics_outputs) then
     3903        ! Check the validity of updated fields at the end of the physics step
     3904        call check_physics_fields("end of physiq:",zt,zu,zv,zplev)
     3905      endif
    38903906
    38913907      icount=icount+1
Note: See TracChangeset for help on using the changeset viewer.