Ignore:
Timestamp:
Nov 29, 2021, 3:29:39 PM (3 years ago)
Author:
idelkadi
Message:

Corrections in the LMDZ-ECRAN interface:

  • gas concentrations in VMR instead of MMR
  • use of a constant value for each gas instead of a table of values
  • specify in the 14 SW bands of ECRAD those corresponding to the 6 SW bands for diffuse and direct albedo in LMDZ
  • passage of all processing of input fields for Ecrad (conversions, calculations, ...) from radiation.F90 to radlw.F90
File:
1 edited

Legend:

Unmodified
Added
Removed
  • LMDZ6/trunk/libf/phylmd/ecrad/radiation_scheme.F90

    r3946 r4031  
    2222     &  PPRESSURE, PTEMPERATURE, &
    2323     &  PPRESSURE_H, PTEMPERATURE_H, PQ, PQSAT, &
    24      &  PCO2, PCH4, PN2O, PNO2, PCFC11, PCFC12, PHCFC22, PCCL4, PO3_DP, &
     24     &  PCO2, PCH4, PN2O, PNO2, PCFC11, PCFC12, PHCFC22, &
     25     &  PCCL4, PO3, PO2, &
    2526     &  PCLOUD_FRAC, PQ_LIQUID, PQ_ICE, PQ_RAIN, PQ_SNOW, &
    2627     &  ZRE_LIQUID_UM, ZRE_ICE_UM, &
     
    151152! AI
    152153REAL(KIND=JPRB),   INTENT(IN) :: PQSAT(KLON,KLEV)
    153 REAL(KIND=JPRB),   INTENT(IN) :: PCO2(KLON,KLEV)
    154 REAL(KIND=JPRB),   INTENT(IN) :: PCH4(KLON,KLEV)
    155 REAL(KIND=JPRB),   INTENT(IN) :: PN2O(KLON,KLEV)
    156 REAL(KIND=JPRB),   INTENT(IN) :: PNO2(KLON,KLEV)
    157 REAL(KIND=JPRB),   INTENT(IN) :: PCFC11(KLON,KLEV)
    158 REAL(KIND=JPRB),   INTENT(IN) :: PCFC12(KLON,KLEV)
    159 REAL(KIND=JPRB),   INTENT(IN) :: PHCFC22(KLON,KLEV)
    160 REAL(KIND=JPRB),   INTENT(IN) :: PCCL4(KLON,KLEV)
    161 REAL(KIND=JPRB),   INTENT(IN) :: PO3_DP(KLON,KLEV) ! AI (kg/kg) ATTENTION (Pa*kg/kg)
     154REAL(KIND=JPRB),   INTENT(IN) :: PCO2
     155REAL(KIND=JPRB),   INTENT(IN) :: PCH4
     156REAL(KIND=JPRB),   INTENT(IN) :: PN2O
     157REAL(KIND=JPRB),   INTENT(IN) :: PNO2
     158REAL(KIND=JPRB),   INTENT(IN) :: PCFC11
     159REAL(KIND=JPRB),   INTENT(IN) :: PCFC12
     160REAL(KIND=JPRB),   INTENT(IN) :: PHCFC22
     161REAL(KIND=JPRB),   INTENT(IN) :: PCCL4
     162REAL(KIND=JPRB),   INTENT(IN) :: PO3(KLON,KLEV) ! AI (kg/kg) ATTENTION (Pa*kg/kg)
     163REAL(KIND=JPRB),   INTENT(IN) :: PO2
    162164
    163165! *** Cloud fraction and hydrometeor mass mixing ratios
     
    326328  print*,'PCO2, PCH4, PN2O, PNO2, PCFC11, PCFC12, PHCFC22, PCCL4 =', &
    327329        PCO2, PCH4, PN2O, PNO2, PCFC11, PCFC12, PHCFC22, PCCL4
    328   print*,'PO3_DP =',PO3_DP
     330  print*,'PO3 =',PO3
    329331  print*,'PCLOUD_FRAC, PQ_LIQUID, PQ_ICE, PQ_RAIN, PQ_SNOW =', &
    330332        PCLOUD_FRAC, PQ_LIQUID, PQ_ICE, PQ_RAIN, PQ_SNOW
     
    345347! AI appel radiation_setup
    346348call SETUP_RADIATION_SCHEME(loutput)
     349!! Les 6 bandes SW pour l'albedo :
     350!! 0.185-0.25, 0.25-0.4, 0.4-0.69 , 0.69-1.19, 1.19-2.38, 2.38-4.00 micro-metre
     351  call rad_config%define_sw_albedo_intervals(6, &
     352             &  (/ 0.25e-6_jprb, 0.44e-6_jprb, 1.19e-6_jprb, &
     353             &     2.38e-6_jprb, 4.00e-6_jprb /),  (/ 1,2,3,4,5,6 /))
    347354
    348355if (lprint_config) then
     
    372379  print*,'rad_config%i_emiss_from_band_lw =', rad_config%i_emiss_from_band_lw
    373380endif
    374 !stop
    375 ! A EFFACER
    376 !print*,'n_g_lw, n_g_sw =', rad_config%n_g_lw, rad_config%n_g_sw
    377 !print*,'use_canopy_full_spectrum_lw = ', rad_config%use_canopy_full_spectrum_lw
    378 !print*,'rad_config%i_band_from_reordered_g_lw =', &
    379 !       rad_config%i_band_from_reordered_g_lw
    380 !print*,'use_canopy_full_spectrum_lw =', rad_config%use_canopy_full_spectrum_lw
    381 !rad_config%use_canopy_full_spectrum_lw = .TRUE.
    382 ! AI ATTENTION
    383 !rad_config%i_band_from_reordered_g_lw = 1
    384 !rad_config%use_spectral_solar_scaling = .true.
    385 !endif
    386 ! AI ATTENTION test
    387 !rad_config%i_gas_model = IGasModelMonochromatic
    388381
    389382! AI ATTENTION
    390383! Allocate memory in radiation objects
    391 CALL single_level%allocate(KLON, NSW, 2, &
     384CALL single_level%allocate(KLON, NSW, 1, &
    392385     &                     use_sw_albedo_direct=.TRUE.)
    393386
     
    420413! temperature at the half-level corresponding to the surface as
    421414! follows:
    422 thermodynamics%temperature_hl(KIDIA:KFDIA,KLEV+1) &
    423      &  = PTEMPERATURE(KIDIA:KFDIA,KLEV) &
    424      &  + 0.5_JPRB * (PTEMPERATURE_H(KIDIA:KFDIA,KLEV+1) &
    425      &               -PTEMPERATURE_H(KIDIA:KFDIA,KLEV))
     415!thermodynamics%temperature_hl(KIDIA:KFDIA,KLEV+1) &
     416!     &  = PTEMPERATURE(KIDIA:KFDIA,KLEV) &
     417!     &  + 0.5_JPRB * (PTEMPERATURE_H(KIDIA:KFDIA,KLEV+1) &
     418!     &               -PTEMPERATURE_H(KIDIA:KFDIA,KLEV))
    426419
    427420! Alternatively we respect the model's atmospheric temperature in the
     
    461454!single_level%lw_emissivity(KIDIA:KFDIA,1)  = 1.0_JPRB
    462455single_level%lw_emissivity(KIDIA:KFDIA,1)  = PEMIS(KIDIA:KFDIA)
    463 single_level%lw_emissivity(KIDIA:KFDIA,2)  = PEMIS_WINDOW(KIDIA:KFDIA)
     456!single_level%lw_emissivity(KIDIA:KFDIA,2)  = PEMIS_WINDOW(KIDIA:KFDIA)
    464457
    465458! Create the relevant seed from date and time get the starting day
     
    499492!     &  PLAND_SEA_MASK, PCCN_LAND, PCCN_SEA, &
    500493!     &  ZRE_LIQUID_UM)
    501 cloud%re_liq(KIDIA:KFDIA,:) = ZRE_LIQUID_UM(KIDIA:KFDIA,:) * 1.0e-6_JPRB
     494cloud%re_liq(KIDIA:KFDIA,:) = ZRE_LIQUID_UM(KIDIA:KFDIA,:)
    502495
    503496!CALL ICE_EFFECTIVE_RADIUS(KIDIA, KFDIA, KLON, KLEV, &
    504497!     &  PPRESSURE, PTEMPERATURE, PCLOUD_FRAC, PQ_ICE, PQ_SNOW, PGEMU, &
    505498!     &  ZRE_ICE_UM)
    506 cloud%re_ice(KIDIA:KFDIA,:) = ZRE_ICE_UM(KIDIA:KFDIA,:) * 1.0e-6_JPRB
     499cloud%re_ice(KIDIA:KFDIA,:) = ZRE_ICE_UM(KIDIA:KFDIA,:)
    507500
    508501! Get the cloud overlap decorrelation length (for cloud boundaries),
     
    539532  ENDDO
    540533ENDDO
     534!AI ATTENTION meme traitement dans le version offline
     535!call cloud%create_inv_cloud_effective_size_eta(ncol, nlev, &
     536!               &  thermodynamics%pressure_hl, &
     537!               &  low_inv_effective_size, &
     538!               &  middle_inv_effective_size, &
     539!               &  high_inv_effective_size, 0.8_jprb, 0.45_jprb)     
    541540
    542541print*,'******** AEROSOLS (allocate + input) **************************************'
     
    608607!  ENDDO
    609608!ENDDO
    610 ZO3 = PO3_DP
    611609
    612610!  Insert gas mixing ratios
    613611print*,'Insert gas mixing ratios'
    614612CALL gas%put(IH2O,    IMassMixingRatio, PQ)
    615 CALL gas%put(ICO2,    IMassMixingRatio, PCO2)
    616 CALL gas%put(ICH4,    IMassMixingRatio, PCH4)
    617 CALL gas%put(IN2O,    IMassMixingRatio, PN2O)
    618 CALL gas%put(ICFC11,  IMassMixingRatio, PCFC11)
    619 CALL gas%put(ICFC12,  IMassMixingRatio, PCFC12)
    620 CALL gas%put(IHCFC22, IMassMixingRatio, PHCFC22)
    621 CALL gas%put(ICCL4,   IMassMixingRatio, PCCL4)
    622 CALL gas%put(IO3,     IMassMixingRatio, ZO3)
    623 CALL gas%put_well_mixed(IO2, IVolumeMixingRatio, 0.20944_JPRB)
     613CALL gas%put(IO3,     IMassMixingRatio, PO3)
     614CALL gas%put_well_mixed(ICO2,    IVolumeMixingRatio, PCO2)
     615CALL gas%put_well_mixed(ICH4,    IVolumeMixingRatio, PCH4)
     616CALL gas%put_well_mixed(IN2O,    IVolumeMixingRatio, PN2O)
     617CALL gas%put_well_mixed(ICFC11,  IVolumeMixingRatio, PCFC11)
     618CALL gas%put_well_mixed(ICFC12,  IVolumeMixingRatio, PCFC12)
     619CALL gas%put_well_mixed(IHCFC22, IVolumeMixingRatio, PHCFC22)
     620CALL gas%put_well_mixed(ICCL4,   IVolumeMixingRatio, PCCL4)
     621CALL gas%put_well_mixed(IO2,     IVolumeMixingRatio, PO2)
    624622! Ensure the units of the gas mixing ratios are what is required by
    625623! the gas absorption model
Note: See TracChangeset for help on using the changeset viewer.