Ignore:
Timestamp:
Feb 10, 2012, 4:42:26 PM (12 years ago)
Author:
Ehouarn Millour
Message:

Introducing "phydev", the minimal physics package.
makegcm and makelmdz_fcm script have been updated to add CPP_PHYS preprocessing key when building with physics and CPP_EARTH for Earth (LMD physics) related routines or instructions in the dynamics.
Checked (on Vargas) that "dev" physics package compiles and runs well in all (seq/mpi/omp/mpi_omp) modes and that introduced changes do not modify results when using the "lmd" physics package.
EM + FH

Location:
LMDZ5/trunk/libf/dyn3d
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • LMDZ5/trunk/libf/dyn3d/calfis.F

    r1407 r1615  
    434434c
    435435      if (planet_type=="earth") then
    436 #ifdef CPP_EARTH
    437436cIM calcul PV a teta=350, 380, 405K
    438437      CALL PVtheta(ngridmx,llm,pucov,pvcov,pteta,
    439438     $           ztfi,zplay,zplev,
    440439     $           ntetaSTD,rtetaSTD,PVteta)
    441 #endif
    442440      endif
    443441c
     
    450448
    451449
    452       if (planet_type=="earth") then
    453 #ifdef CPP_EARTH
    454450
    455451!      write(lunout,*) 'PHYSIQUE AVEC NSPLIT_PHYS=',nsplit_phys
     
    460456      zdqfic(:,:,:)=0.
    461457
    462       do isplit=1,nsplit_phys
     458      if (planet_type=="earth") then
     459#ifdef CPP_PHYS
     460
     461       do isplit=1,nsplit_phys
    463462
    464463         jH_cur_split=jH_cur+(isplit-1) * dtvr / (daysec *nsplit_phys)
     
    503502         zdqfic(:,:,:)=zdqfic(:,:,:)+zdqfi(:,:,:)
    504503
    505       enddo
     504       enddo ! of do isplit=1,nsplit_phys
     505
     506#endif
     507! of #ifdef CPP_PHYS
     508      endif ! of if (planet_type=="earth")
     509
    506510      zdufi(:,:)=zdufic(:,:)/nsplit_phys
    507511      zdvfi(:,:)=zdvfic(:,:)/nsplit_phys
     
    509513      zdqfi(:,:,:)=zdqfic(:,:,:)/nsplit_phys
    510514
    511 #endif
    512       endif !of if (planet_type=="earth")
    513515
    514516500   CONTINUE
  • LMDZ5/trunk/libf/dyn3d/ce0l.F90

    r1563 r1615  
    2828  IMPLICIT NONE
    2929#ifndef CPP_EARTH
     30#include "iniprint.h"
    3031  WRITE(lunout,*)'limit_netcdf: Earth-specific routine, needs Earth physics'
    3132#else
  • LMDZ5/trunk/libf/dyn3d/gcm.F

    r1592 r1615  
    2121! A nettoyer. On ne veut qu'une ou deux routines d'interface
    2222! dynamique -> physique pour l'initialisation
    23 ! Ehouarn: for now these only apply to Earth:
    24 #ifdef CPP_EARTH
     23#ifdef CPP_PHYS
    2524      USE dimphy
    2625      USE comgeomphy
     
    180179! A nettoyer. On ne veut qu'une ou deux routines d'interface
    181180! dynamique -> physique pour l'initialisation
    182 ! Ehouarn : temporarily (?) keep this only for Earth
    183       if (planet_type.eq."earth") then
    184 #ifdef CPP_EARTH
     181#ifdef CPP_PHYS
    185182      CALL Init_Phys_lmdz(iim,jjp1,llm,1,(/(jjm-1)*iim+2/))
    186183      call InitComgeomphy
    187184#endif
    188       endif
    189185!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    190186c-----------------------------------------------------------------------
     
    435431         WRITE(lunout,*)
    436432     .       'GCM: WARNING!!! vitesse verticale nulle dans la physique'
    437 ! Earth:
    438          if (planet_type.eq."earth") then
    439 #ifdef CPP_EARTH
     433! Physics:
     434#ifdef CPP_PHYS
    440435         CALL iniphysiq(ngridmx,llm,daysec,day_ini,dtphys/nsplit_phys ,
    441436     ,                latfi,lonfi,airefi,zcufi,zcvfi,rad,g,r,cpp     )
    442437#endif
    443          endif ! of if (planet_type.eq."earth")
    444438         call_iniphys=.false.
    445439      ENDIF ! of IF (call_iniphys.and.(iflag_phys.eq.1))
    446 !#endif
    447440
    448441c  numero de stockage pour les fichiers de redemarrage:
     
    466459#endif
    467460
    468 #ifdef CPP_EARTH
     461#ifdef CPP_PHYS
    469462! Create start file (startphy.nc) and boundary conditions (limit.nc)
    470463! for the Earth verstion
  • LMDZ5/trunk/libf/dyn3d/leapfrog.F

    r1614 r1615  
    403403! Ehouarn: be careful, diagedyn is Earth-specific (includes ../phylmd/..)!
    404404           IF (planet_type.eq."earth") THEN
     405#ifdef CPP_EARTH
    405406            CALL diagedyn(ztit,2,1,1,dtphys
    406407     &    , ucov    , vcov , ps, p ,pk , teta , q(:,:,1), q(:,:,2))
     408#endif
    407409           ENDIF
    408410         ENDIF ! of IF (ip_ebil_dyn.ge.1 )
Note: See TracChangeset for help on using the changeset viewer.