Changeset 1590
- Timestamp:
- Aug 30, 2016, 3:04:29 PM (9 years ago)
- Location:
- trunk
- Files:
-
- 5 added
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified trunk/LMDZ.MARS/libf/phymars/comm_wrf.F90 ¶
r1236 r1590 3 3 !! 4 4 !! This module is useful to output fields in WRF style 5 !! -- useful for diagnostics that are not already in modules 5 6 !! 6 7 … … 23 24 integer,intent(in) :: ngrid ! number of atmospheric columns 24 25 integer,intent(in) :: nlayer ! number of atmospheric layers 25 allocate(comm_HR_SW(ngrid,nlayer))26 allocate(comm_HR_LW(ngrid,nlayer))27 allocate(comm_SWDOWNZ(ngrid))28 allocate(comm_TAU_DUST(ngrid))29 allocate(comm_RDUST(ngrid,nlayer))30 allocate(comm_QSURFDUST(ngrid))31 allocate(comm_MTOT(ngrid))32 allocate(comm_ICETOT(ngrid))33 allocate(comm_VMR_ICE(ngrid,nlayer))34 allocate(comm_TAU_ICE(ngrid))35 allocate(comm_RICE(ngrid,nlayer))26 if (.not.allocated(comm_HR_SW)) allocate(comm_HR_SW(ngrid,nlayer)) 27 if (.not.allocated(comm_HR_LW)) allocate(comm_HR_LW(ngrid,nlayer)) 28 if (.not.allocated(comm_SWDOWNZ)) allocate(comm_SWDOWNZ(ngrid)) 29 if (.not.allocated(comm_TAU_DUST)) allocate(comm_TAU_DUST(ngrid)) 30 if (.not.allocated(comm_RDUST)) allocate(comm_RDUST(ngrid,nlayer)) 31 if (.not.allocated(comm_QSURFDUST)) allocate(comm_QSURFDUST(ngrid)) 32 if (.not.allocated(comm_MTOT)) allocate(comm_MTOT(ngrid)) 33 if (.not.allocated(comm_ICETOT)) allocate(comm_ICETOT(ngrid)) 34 if (.not.allocated(comm_VMR_ICE)) allocate(comm_VMR_ICE(ngrid,nlayer)) 35 if (.not.allocated(comm_TAU_ICE)) allocate(comm_TAU_ICE(ngrid)) 36 if (.not.allocated(comm_RICE)) allocate(comm_RICE(ngrid,nlayer)) 36 37 end subroutine allocate_comm_wrf 37 38 -
TabularUnified trunk/LMDZ.MARS/libf/phymars/physiq_mod.F ¶
r1579 r1590 1993 1993 !! --> example : hfmax_th, zmax_th 1994 1994 1995 CALL allocate_comm_wrf(ngrid,nlayer) 1996 1995 1997 !state real HR_SW ikj misc 1 - h "HR_SW" "HEATING RATE SW" "K/s" 1996 1998 comm_HR_SW(1:ngrid,1:nlayer) = zdtsw(1:ngrid,1:nlayer) -
TabularUnified trunk/MESOSCALE/LMD_MM_MARS/SRC/LES/modif_mars/module_first_rk_step_part1.F ¶
r1586 r1590 644 644 & ,KM_OPT=config_flags%km_opt & 645 645 & ,HISTORY_INTERVAL=model_config_rec%history_interval(1) & 646 #ifndef NOPHYS647 646 !------------------! 648 647 ! OUTPUT VARIABLES ! … … 667 666 #include "module_lmd_driver_output4.inc" 668 667 #endif 669 #endif670 668 & ,SLPX=grid%slpx,SLPY=grid%slpy,RESTART=config_flags%restart) 671 669 ENDIF -
TabularUnified trunk/MESOSCALE/LMD_MM_MARS/SRC/SCRIPTS/copy_model ¶
r1588 r1590 47 47 ln -sf $WRFSRC/WRFV2/call_meso_inifis?.inc . 48 48 ln -sf $WRFSRC/WRFV2/call_meso_physiq?.inc . 49 50 sed s+"YORGLYORGL"+"$laphysiq"+g $WRFSRC/WRFV2/physics.sed > physics.sed51 49 52 50 #\rm meso_dimphys.h … … 139 137 mkdir external/io_mcel 140 138 ln -sf $WRFSRC/WRFV2/external/io_mcel/* external/io_mcel/ 141 mkdir $laphysiq142 mkdir $laphysiq/libf143 ln -sf $WRFSRC/WRFV2/$laphysiq/makegcm* $laphysiq/144 ln -sf $WRFSRC/WRFV2/$laphysiq/meso_dimphys.h* $laphysiq/145 ln -sf $WRFSRC/WRFV2/$laphysiq/create_make_gcm $laphysiq/146 #ln -sf $WRFSRC/WRFV2/$laphysiq/makefile $laphysiq/147 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/duplicate* $laphysiq/libf/148 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/generate* $laphysiq/libf/149 139 150 mkdir $laphysiq/libf/grid 151 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/grid/* $laphysiq/libf/grid/ 152 mkdir $laphysiq/libf/phymars 153 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/phymars/* $laphysiq/libf/phymars/ 154 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/phy_common/* $laphysiq/libf/phymars/ 155 mkdir $laphysiq/libf/dyn3d 156 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/dyn3d/* $laphysiq/libf/dyn3d/ 157 mkdir $laphysiq/libf/aeronomars 158 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/aeronomars/* $laphysiq/libf/aeronomars/ 159 mkdir $laphysiq/libf/bibio 160 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/bibio/* $laphysiq/libf/bibio/ 161 mkdir $laphysiq/libo 162 #touch $laphysiq/makefile 140 if [[ "${laphysiq}" == *"void"* ]] 141 then 142 143 ## case with no physics 144 rm -f physics.sed 145 touch physics.sed 146 147 else 148 149 ## case with physics 150 mkdir $laphysiq 151 mkdir $laphysiq/libf 152 ln -sf $WRFSRC/WRFV2/$laphysiq/makegcm* $laphysiq/ 153 ln -sf $WRFSRC/WRFV2/$laphysiq/meso_dimphys.h* $laphysiq/ 154 ln -sf $WRFSRC/WRFV2/$laphysiq/create_make_gcm $laphysiq/ 155 #ln -sf $WRFSRC/WRFV2/$laphysiq/makefile $laphysiq/ 156 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/duplicate* $laphysiq/libf/ 157 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/generate* $laphysiq/libf/ 158 159 mkdir $laphysiq/libf/grid 160 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/grid/* $laphysiq/libf/grid/ 161 mkdir $laphysiq/libf/phymars 162 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/phymars/* $laphysiq/libf/phymars/ 163 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/phy_common/* $laphysiq/libf/phymars/ 164 mkdir $laphysiq/libf/dyn3d 165 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/dyn3d/* $laphysiq/libf/dyn3d/ 166 mkdir $laphysiq/libf/aeronomars 167 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/aeronomars/* $laphysiq/libf/aeronomars/ 168 mkdir $laphysiq/libf/bibio 169 ln -sf $WRFSRC/WRFV2/$laphysiq/libf/bibio/* $laphysiq/libf/bibio/ 170 mkdir $laphysiq/libo 171 #touch $laphysiq/makefile 172 173 \rm $laphysiq/libf/phymars/dimphys.h 174 175 sed s+"YORGLYORGL"+"$laphysiq"+g $WRFSRC/WRFV2/physics.sed > physics.sed 176 fi 163 177 164 178 mkdir test … … 167 181 ln -sf $WRFSRC/WRFV2/test/em_real/* test/em_real/ 168 182 169 cd $laphysiq/libf/phymars/170 \rm dimphys.h171 #ln -sf ../../../meso_dimphys.h dimphys.h172 cd ../../..173 174 183 echo '*** end' 175 184 -
TabularUnified trunk/MESOSCALE/LMD_MM_MARS/SRC/WRFV2/dyn_em/solve_em.F ¶
r1584 r1590 886 886 & ,KM_OPT=config_flags%km_opt & 887 887 & ,HISTORY_INTERVAL=model_config_rec%history_interval(1) & 888 #ifndef NOPHYS889 888 !------------------! 890 889 ! OUTPUT VARIABLES ! … … 908 907 #else 909 908 #include "module_lmd_driver_output4.inc" 910 #endif911 909 #endif 912 910 & ,SLPX=grid%slpx,SLPY=grid%slpy,RESTART=config_flags%restart) -
TabularUnified trunk/MESOSCALE/LMD_MM_MARS/SRC/WRFV2/phys/dynphy_wrf_mars_lmd_new/update_outputs_physiq_mod.F ¶
r1582 r1590 153 153 END SUBROUTINE update_outputs_physiq_turb 154 154 155 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! 156 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! 157 SUBROUTINE update_outputs_physiq_diag( & 158 ims,ime,jms,jme,kms,kme,& 159 ips,ipe,jps,jpe,kps,kpe,& 160 SWDOWNZ,TAU_DUST,QSURFDUST,& 161 MTOT,ICETOT,TAU_ICE,& 162 HR_SW,HR_LW,& 163 RDUST,VMR_ICE,RICE) 164 165 USE comm_wrf !! to get fields to be written from physiq 166 167 INTEGER, INTENT(IN) :: ims,ime,jms,jme,kms,kme 168 INTEGER, INTENT(IN) :: ips,ipe,jps,jpe,kps,kpe 169 REAL, DIMENSION( ims:ime, jms:jme ), INTENT(INOUT) :: & 170 SWDOWNZ,TAU_DUST,QSURFDUST,& 171 MTOT,ICETOT,TAU_ICE 172 REAL, DIMENSION( ims:ime, kms:kme, jms:jme ), INTENT(INOUT ) :: & 173 HR_SW,HR_LW,RDUST,VMR_ICE,RICE 174 INTEGER :: i,j,subs 175 176 DO j = jps,jpe 177 DO i = ips,ipe 178 179 !-----------------------------------! 180 ! 1D subscript for physics "cursor" ! 181 !-----------------------------------! 182 subs = (j-jps)*(ipe-ips+1)+(i-ips+1) 183 184 !! get diagnostics from physics 185 SWDOWNZ(i,j) = comm_SWDOWNZ(subs) 186 TAU_DUST(i,j) = comm_TAU_DUST(subs) 187 QSURFDUST(i,j) = comm_QSURFDUST(subs) 188 MTOT(i,j) = comm_MTOT(subs) 189 ICETOT(i,j) = comm_ICETOT(subs) 190 TAU_ICE(i,j) = comm_TAU_ICE(subs) 191 HR_SW(i,kps:kpe,j) = comm_HR_SW(subs,kps:kpe) 192 HR_LW(i,kps:kpe,j) = comm_HR_LW(subs,kps:kpe) 193 RDUST(i,kps:kpe,j) = comm_RDUST(subs,kps:kpe) 194 VMR_ICE(i,kps:kpe,j) = comm_VMR_ICE(subs,kps:kpe) 195 RICE(i,kps:kpe,j) = comm_RICE(subs,kps:kpe) 196 197 ENDDO 198 ENDDO 199 200 CALL deallocate_comm_wrf 201 202 END SUBROUTINE update_outputs_physiq_diag 203 155 204 END MODULE update_outputs_physiq_mod 156 205 -
TabularUnified trunk/MESOSCALE/LMD_MM_MARS/SRC/WRFV2/phys/module_lmd_driver.F.new ¶
r1584 r1590 40 40 isfflx, diff_opt, km_opt, & 41 41 HISTORY_INTERVAL, & 42 ! sert a rien ce NOPHYS. il le faudrait sur tout.43 #ifndef NOPHYS44 42 HR_SW,HR_LW,SWDOWNZ,& 45 43 TAU_DUST,RDUST,QSURFDUST,& … … 47 45 HFMAX,ZMAX,& 48 46 USTM,HFX,& 49 #endif50 47 SLPX,SLPY,RESTART) 51 48 ! NB: module_lmd_driver_output1.inc : output arguments generated from Registry … … 60 57 USE module_model_constants 61 58 USE module_wrf_error 62 #ifndef NOPHYS 59 !!!!!!!! interface modules 63 60 USE update_inputs_physiq_mod !! to set inputs for physiq 64 61 USE update_outputs_physiq_mod !! to get outputs from physiq 65 USE comm_wrf !! to get fields to be written from physiq66 62 USE iniphysiq_mod !! to get iniphysiq subroutine 67 63 USE callphysiq_mod !! to call the LMD physics 68 #endif 64 !!!!!!!! interface modules 69 65 70 66 !================================================================== … … 414 410 !----------! 415 411 ! inputs ... 416 #ifndef NOPHYS417 CALL allocate_comm_wrf(ngrid,nlayer)418 #endif419 412 ALLOCATE(pplev(ngrid,nlayer+1)) !!!!! 420 413 ALLOCATE(pplay(ngrid,nlayer)) !!!!! … … 447 440 !!!!!!!!!!!!!!!!!!!!!!!!!!!! 448 441 449 #ifndef NOPHYS450 442 !! INITIALIZE AND ALLOCATE EVERYTHING !! here, only firstcall 451 443 allocation_firstcall: IF (firstcall .EQV. .true.) THEN … … 470 462 1./reradius,g,r_d,cp,1) 471 463 ENDIF allocation_firstcall 472 #endif473 464 474 465 !!*****************************!! … … 657 648 pdt(:,:)=0. 658 649 pdq(:,:,:)=0. 659 #ifndef NOPHYS660 650 print *, '** ',planet_type,'** CALL TO LMD PHYSICS' 661 651 !!! … … 676 666 pdu,pdv,pdt,pdq,pdpsrf) 677 667 !!! 678 #endif679 668 680 669 !! specific scenario. necessary to add the right amount of dust. … … 745 734 M_Q2,M_WSTAR,& 746 735 HFMAX,ZMAX,USTM,HFX) 747 748 DO j = jps,jpe 749 DO i = ips,ipe 750 751 subs = (j-jps)*(ipe-ips+1)+(i-ips+1) 752 753 !! output only (cf comm_wrf) 754 SWDOWNZ(i,j) = comm_SWDOWNZ(subs) 755 TAU_DUST(i,j) = comm_TAU_DUST(subs) 756 QSURFDUST(i,j) = comm_QSURFDUST(subs) 757 MTOT(i,j) = comm_MTOT(subs) 758 ICETOT(i,j) = comm_ICETOT(subs) 759 TAU_ICE(i,j) = comm_TAU_ICE(subs) 760 HR_SW(i,kps:kpe,j) = comm_HR_SW(subs,kps:kpe) 761 HR_LW(i,kps:kpe,j) = comm_HR_LW(subs,kps:kpe) 762 RDUST(i,kps:kpe,j) = comm_RDUST(subs,kps:kpe) 763 VMR_ICE(i,kps:kpe,j) = comm_VMR_ICE(subs,kps:kpe) 764 RICE(i,kps:kpe,j) = comm_RICE(subs,kps:kpe) 765 766 ENDDO 767 ENDDO 768 769 CALL deallocate_comm_wrf 770 736 !!! 737 CALL update_outputs_physiq_diag( & 738 ims,ime,jms,jme,kms,kme,& 739 ips,ipe,jps,jpe,kps,kpe,& 740 SWDOWNZ,TAU_DUST,QSURFDUST,& 741 MTOT,ICETOT,TAU_ICE,& 742 HR_SW,HR_LW,& 743 RDUST,VMR_ICE,RICE) 744 !!! 771 745 ENDIF call_physics 772 746 -
TabularUnified trunk/MESOSCALE/LMD_MM_MARS/makemeso ¶
r1588 r1590 49 49 e ) from_scratch=1;; ## a fresh start with a completely new folder 50 50 s ) scenario="${OPTARG}";; ## a specific scenario (with precompiling flags) 51 x ) donotcompile=1;phys=" nophys_";donotcompilephys=1;; ## a case with no LMD physics included51 x ) donotcompile=1;phys="void_lmd_new";donotcompilephys=1;; ## a case with no LMD physics included 52 52 h ) echo " 53 53 # Use: … … 130 130 esac 131 131 # number of processors 132 if [[ "${phys}" == *"new"* ]] || [[ "${phys}" == "nophys_" ]]132 if [[ "${phys}" == *"new"* ]] #|| [[ "${phys}" == "nophys_" ]] 133 133 then 134 134 numproc=999 … … 183 183 \rm what_folder 2> /dev/null 184 184 echo ${conf_wrf} > what_folder 185 if [ ${donotcompile} -eq 1]185 if [ ${donotcompile} -eq 0 ] 186 186 then 187 # \rm what_folder 2> /dev/null188 # echo '**********************'189 # echo '*** Your folder is ...'190 # echo '**********************'191 # echo ${conf_wrf} | tee what_folder192 # cat what_folder193 # echo ${conf_wrf} > what_folder194 # echo ${reply} > what_compilo195 # echo ${numproc} > what_numproc196 if [[ "${phys}" != "nophys_" ]]197 then198 exit199 fi200 else187 ##\rm what_folder 2> /dev/null 188 ##echo '**********************' 189 ##echo '*** Your folder is ...' 190 ##echo '**********************' 191 ##echo ${conf_wrf} | tee what_folder 192 ##cat what_folder 193 ##echo ${conf_wrf} > what_folder 194 ##echo ${reply} > what_compilo 195 ##echo ${numproc} > what_numproc 196 #if [[ "${phys}" != "nophys_" ]] 197 #then 198 # exit 199 #fi 200 #else 201 201 # tracers: now dynamically set in newphys 09/2013 202 202 if [[ "${phys}" == *"new"* ]] … … 602 602 603 603 ################ 604 if [[ "${phys}" == "nophys_" ]]605 then606 if [[ "${config}" == "les" ]] ### LES is different because of WRFV3607 then608 sed s+"ARCH_LOCAL = "+"ARCH_LOCAL = -DNOPHYS "+g configure.wrf > yeah ; mv -f yeah configure.wrf609 sed s+"-L../$phys/libo -llmd"+""+g configure.wrf > yeah ; mv -f yeah configure.wrf610 else611 ### not tested yet but should be working612 echo CAUTION CAUTION CAUTION NOT FULLY TESTED613 sed s+"ARCHFLAGS = "+"ARCHFLAGS = -DNOPHYS "+g configure.wrf > yeah ; mv -f yeah configure.wrf614 sed s+"-L../$phys/libo -llmd"+""+g configure.wrf > yeah ; mv -f yeah configure.wrf615 fi616 fi604 #if [[ "${phys}" == "nophys_" ]] 605 #then 606 # if [[ "${config}" == "les" ]] ### LES is different because of WRFV3 607 # then 608 # sed s+"ARCH_LOCAL = "+"ARCH_LOCAL = -DNOPHYS "+g configure.wrf > yeah ; mv -f yeah configure.wrf 609 # sed s+"-L../$phys/libo -llmd"+""+g configure.wrf > yeah ; mv -f yeah configure.wrf 610 # else 611 # ### not tested yet but should be working 612 # echo CAUTION CAUTION CAUTION NOT FULLY TESTED 613 # sed s+"ARCHFLAGS = "+"ARCHFLAGS = -DNOPHYS "+g configure.wrf > yeah ; mv -f yeah configure.wrf 614 # sed s+"-L../$phys/libo -llmd"+""+g configure.wrf > yeah ; mv -f yeah configure.wrf 615 # fi 616 #fi 617 617 ################ 618 618 … … 792 792 echo 2. compiling WRF dynamical core ... 793 793 794 if [[ "${phys}" == "nophys_" ]]795 then796 echo 'NO LMD PHYSICS included'797 else798 if [[ ! ( -f "call_meso_physiq.inc" ) ]]799 then800 echo 'did you compile the physics ? no call_meso_physiq.inc !'801 exit802 fi803 fi794 #if [[ "${phys}" == "nophys_" ]] 795 #then 796 # echo 'NO LMD PHYSICS included' 797 #else 798 # if [[ ! ( -f "call_meso_physiq.inc" ) ]] 799 # then 800 # echo 'did you compile the physics ? no call_meso_physiq.inc !' 801 # exit 802 # fi 803 #fi 804 804 805 805 # be sure to compile with the most recent physics
Note: See TracChangeset
for help on using the changeset viewer.