Ignore:
Timestamp:
Oct 21, 2011, 11:31:28 AM (13 years ago)
Author:
aslmd
Message:

MESOSCALE : Preparatory commit for the ultimate option mars=42 which

would allow mesoscale modeling with photochemistry.

[see r76 method to add 'mars' options]
Modified module_lmd_driver.F and Registry.EM and runmeso
Modified readmeteo.F90 and introduced an option -DPHOTOCHEM
...
Transparent to the casual user
Option mars=42 not yet finished though -- so do not use!

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/MESOSCALE/LMD_MM_MARS/SRC/WRFV2/phys/module_lmd_driver.F

    r315 r324  
    650650
    651651SELECT CASE (MARS_MODE) !! ONLY ALLOW FOR MODES DEFINED IN Registry.EM
    652    CASE(4-10,12-19,22:)      !! -- CHANGE THIS if YOU ADDED CASES in REGISTRY.EM
     652   CASE(4-10,12-19,22-41,43:)      !! -- CHANGE THIS if YOU ADDED CASES in REGISTRY.EM
    653653   PRINT *, 'NOT SUPPORTED, to be done'
    654654   STOP
     
    662662!package   radioac      mars==20                     -              scalar:qtrac1
    663663!package   radioac2     mars==21                     -              scalar:upward,downward
     664!package   photochem    mars==42                     -              scalar:qco2,chem_co,chem_o,chem_o1d,chem_o2,chem_o3,chem_h,chem_h2,chem_oh,chem_ho2,chem_h2o2,chem_ch4,chem_n2,chem_ar,qh2o_ice,qh2o,qdust,qdustn
    664665!!!!!!!!!!!!!!!!!!! FOR REFERENCE
    665666
     
    672673      wtnom(nq) = 'co2'
    673674    CASE(1)
    674       wtnom(1)  = 'h2o_vap'     
    675       wtnom(2)  = 'h2o_ice'    
     675      wtnom(1)  = 'h2o_vap'
     676      wtnom(2)  = 'h2o_ice'
    676677    CASE(2)
    677678      wtnom(1)  = 'dust01'     
    678679    CASE(3)
    679680      wtnom(1)  = 'dust_mass'
    680       wtnom(2)  = 'dust_number'
     681      wtnom(2)  = 'dust_number' 
    681682    CASE(11)
    682683      wtnom(1)  = 'h2o_vap'
    683       wtnom(2)  = 'h2o_ice'
     684      wtnom(2)  = 'h2o_ice' 
    684685      wtnom(3)  = 'dust_mass'
    685686      wtnom(4)  = 'dust_number'
     
    688689    CASE(21)
    689690      wtnom(1) = 'upward'
    690       wtnom(2) = 'downward'
     691      wtnom(2) = 'downward'
     692    CASE(42)
     693      wtnom(1)  = 'co2'
     694      wtnom(2)  = 'co'
     695      wtnom(3)  = 'o'
     696      wtnom(4)  = 'o1d'
     697      wtnom(5)  = 'o2'
     698      wtnom(6)  = 'o3'
     699      wtnom(7)  = 'h'
     700      wtnom(8)  = 'h2'
     701      wtnom(9)  = 'oh'
     702      wtnom(10)  = 'ho2'
     703      wtnom(11)  = 'h2o2'
     704      wtnom(12)  = 'ch4'
     705      wtnom(13)  = 'n2'
     706      wtnom(14)  = 'ar'
     707      wtnom(15)  = 'h2o_ice'
     708      wtnom(16)  = 'h2o_vap'
     709      wtnom(17)  = 'dust_mass'
     710      wtnom(18)  = 'dust_number'
    691711END SELECT
    692712#endif
     
    729749q_prof(:,1:nq) = SCALAR(i,kps:kpe,j,2:nq+1)  !! the names were set above !! one dummy tracer in WRF
    730750  !!! CAS DU CO2
    731 DO iii=1,nq
    732  IF ( wtnom(iii) .eq. 'co2' ) q_prof(:,iii) = 0.95
    733 ENDDO
    734 
    735 IF ((MARS_MODE .EQ. 20) .OR. (MARS_MODE .EQ. 21)) THEN
     751  DO iii=1,nq
     752   IF ( wtnom(iii) .eq. 'co2' ) q_prof(:,iii) = 0.95
     753  ENDDO
     754  IF ((MARS_MODE .EQ. 20) .OR. (MARS_MODE .EQ. 21)) THEN
    736755   IF (firstcall .EQV. .true.) THEN
    737756      q_prof(:,:) = 0.95
    738757   ENDIF
    739 ENDIF
    740 
     758  ENDIF
    741759#else
    742760SELECT CASE (MARS_MODE)
     
    841859!!!! ADDITIONAL SECURITY. THIS MIGHT HAPPEN WITH OLD INIT FILES.
    842860IF (z0_val == 0.) THEN
    843    PRINT *, 'WELL, z0 is 0, this is no good. Setting to old defaults value 0.01 m'
     861   IF ( (i == ips) .AND. (j == jps) ) PRINT *, 'WELL, z0 is 0, this is no good. Setting to old defaults value 0.01 m'
    844862   z0_val = 0.01
    845863ENDIF
Note: See TracChangeset for help on using the changeset viewer.