Changeset 3995 for trunk


Ignore:
Timestamp:
Jan 5, 2026, 5:00:27 PM (3 weeks ago)
Author:
emillour
Message:

Generic PCM:
Enable using XIOS with rcm1d. This implies compiling with MPI (makelmdz_fcm ...
-parallel mpi -io xios ... rcm1d) and having adequate xml files at hand.
While at it cleaned up turbdiff_mod.F90 to use write_output() instead of
calls to writediagfi() and updated reference field_def_physics.xml
EM

Location:
trunk/LMDZ.GENERIC
Files:
2 added
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.GENERIC/changelog.txt

    r3990 r3995  
    21512151by the master thread). While at it turned ave_stelspec and setspv into modules.
    21522152
     2153== 05/01/2026 == EM
     2154Enable using XIOS with rcm1d. This implies compiling with MPI (makelmdz_fcm ...
     2155-parallel mpi -io xios ... rcm1d) and having adequate xml files at hand.
     2156While at it cleaned up turbdiff_mod.F90 to use write_output() instead of
     2157calls to writediagfi() and updated reference field_def_physics.xml
  • trunk/LMDZ.GENERIC/deftank/xios/field_def_physics.xml

    r3614 r3995  
    308308                   long_name="latent heat flux"
    309309                   unit="w.m^-2" />
     310           
     311            <!-- diagnostics from turbdiff-->
     312            <field id="beta"
     313                   long_name="Dryness coefficient"
     314                   unit=" " />
     315            <field id="evap_surf_flux"
     316                   long_name="surface latent heat flux"
     317                   unit="W.m-2" />
     318            <field id="fluxsurf_rad"
     319                   long_name="total IR and VIS surface flux"
     320                   unit="W.m-2" />
     321           
    310322        </field_group>
    311323
     
    451463                   unit="K" />
    452464
    453 
     465            <!-- diagnostics from turbdiff-->
     466            <field id="dqevap"
     467                   long_name="evaporated water vapor specific concentration"
     468                   unit="s-1" />
     469 
    454470            <!--Tracers-->
    455471            <field id="h2o_vap"
  • trunk/LMDZ.GENERIC/libf/phystd/dyn1d/rcm1d.F

    r3893 r3995  
    4646      !use inichim_1D_mod, only: inichim_1D
    4747      !use initracer_1D_mod, only: initracer_1D
     48#ifdef CPP_XIOS
     49      use mod_const_mpi, only: init_const_mpi
     50      use parallel_lmdz, only: init_parallel
     51#endif
    4852
    4953      implicit none
     
    202206        call system("echo 'INCLUDEDEF=rcm1d.def' >> run.def")
    203207      endif
     208
     209#ifdef CPP_XIOS
     210      CALL init_const_mpi
     211      CALL init_parallel
     212#endif
    204213
    205214! Check restart
  • trunk/LMDZ.GENERIC/libf/phystd/turbdiff_mod.F90

    r3236 r3995  
    2020      use callkeys_mod, only: water,tracer,nosurf,kmixmin
    2121      use turb_mod, only : ustar
     22      use write_output_mod, only: write_output
    2223#ifdef MESOSCALE
    2324      use comm_wrf, only : comm_LATENT_HF
     
    744745      if(water)then
    745746#ifndef MESOSCALE
    746          call writediagfi(ngrid,'beta','Dryness coefficient',' ',2,dryness)
     747         call write_output('beta','Dryness coefficient',' ',dryness)
    747748#endif
    748749         if (tracer) then
    749750#ifndef MESOSCALE
    750             call writediagfi(ngrid,'evap_surf_flux','surface latent heat flux','W.m-2',2,RLVTT*dqsdif_total/ptimestep)
    751             call writediagfi(ngrid,'fluxsurf_rad','total IR and VIS surface flux','W.m-2',2,pfluxsrf)
    752             call writediagfi(ngrid,'dqevap','evaporated water vapor specific concentration','s-1',3,pdqevap)
     751            call write_output('evap_surf_flux','surface latent heat flux','W.m-2',RLVTT*dqsdif_total/ptimestep)
     752            call write_output('fluxsurf_rad','total IR and VIS surface flux','W.m-2',pfluxsrf)
     753            call write_output('dqevap','evaporated water vapor specific concentration','s-1',pdqevap)
    753754#else
    754755            comm_LATENT_HF(:)=0.0
  • trunk/LMDZ.GENERIC/libf/phystd/writediagfi.F

    r3928 r3995  
    334334        if (dim.eq.3) then
    335335
     336          IF (klon_glo>1) THEN ! General case
    336337#ifdef CPP_PARA
    337338          ! Gather field on a "global" (without redundant longitude) array
     
    349350!         Passage variable physique -->  variable dynamique
    350351!         recast (copy) variable from physics grid to dynamics grid
    351           IF (klon_glo>1) THEN ! General case
    352352           DO l=1,nbp_lev
    353353             DO i=1,nbp_lon+1
     
    363363             ENDDO
    364364           ENDDO
     365#endif
    365366          ELSE ! 1D model case
    366367           dx3_1d(1,1:nbp_lev)=px(1,1:nbp_lev)
    367368          ENDIF
    368 #endif
    369369!         Ecriture du champs
    370370
     
    438438        else if (dim.eq.2) then
    439439
     440          IF (klon_glo>1) THEN ! General case
    440441#ifdef CPP_PARA
    441442          ! Gather field on a "global" (without redundant longitude) array
     
    455456!         Passage variable physique -->  physique dynamique
    456457!         recast (copy) variable from physics grid to dynamics grid
    457           IF (klon_glo>1) THEN ! General case
    458458             DO i=1,nbp_lon+1
    459459                dx2(i,1)=px(1,1)
     
    467467                dx2(nbp_lon+1,j)=dx2(1,j)
    468468             ENDDO
     469#endif
    469470          ELSE ! 1D model case
    470471            dx2_1d=px(1,1)
    471472          ENDIF
    472 #endif
    473473
    474474          if (is_master) then
  • trunk/LMDZ.GENERIC/libf/phystd/wstats_mod.F90

    r2958 r3995  
    174174  if (is_mpi_root) then
    175175    call Grid1Dto2D_glo(px3_glop,px3_glo)
    176     ! copy dx3_glo() to dx3(:) and add redundant longitude
    177     dx3(1:nbp_lon,:,:)=px3_glo(1:nbp_lon,:,:)
    178     dx3(nbp_lon+1,:,:)=dx3(1,:,:)
     176    if (klon_glo>1) then ! general case (unless in 1D)
     177     ! copy dx3_glo() to dx3(:) and add redundant longitude
     178     dx3(1:nbp_lon,:,:)=px3_glo(1:nbp_lon,:,:)
     179     dx3(nbp_lon+1,:,:)=dx3(1,:,:)
     180    endif
    179181  endif
    180182!$OMP END MASTER
     
    187189          if (is_mpi_root) then
    188190            call Grid1Dto2D_glo(px2_glop,px2_glo)
    189             ! copy px2_glo() to dx2(:) and add redundant longitude
    190             dx2(1:nbp_lon,:)=px2_glo(1:nbp_lon,:)
    191             dx2(nbp_lon+1,:)=dx2(1,:)
     191            if (klon_glo>1) then ! general case (unless in 1D)
     192             ! copy px2_glo() to dx2(:) and add redundant longitude
     193             dx2(1:nbp_lon,:)=px2_glo(1:nbp_lon,:)
     194             dx2(nbp_lon+1,:)=dx2(1,:)
     195            endif
    192196          endif
    193197!$OMP END MASTER
Note: See TracChangeset for help on using the changeset viewer.