!$Id: nitrates.F90 104 2008-12-23 10:28:51Z acosce $ !! ========================================================================= !! INCA - INteraction with Chemistry and Aerosols !! !! Copyright Laboratoire des Sciences du Climat et de l'Environnement (LSCE) !! Unite mixte CEA-CNRS-UVSQ !! !! Contributors to this INCA subroutine: !! !! Didier Hauglustaine, LSCE, hauglustaine@cea.fr !! !! This software is a computer program whose purpose is to simulate the !! atmospheric gas phase and aerosol composition. The model is designed to be !! used within a transport model or a general circulation model. This version !! of INCA was designed to be coupled to the LMDz GCM. LMDz-INCA accounts !! for emissions, transport (resolved and sub-grid scale), photochemical !! transformations, and scavenging (dry deposition and washout) of chemical !! species and aerosols interactively in the GCM. Several versions of the INCA !! model are currently used depending on the envisaged applications with the !! chemistry-climate model. !! !! This software is governed by the CeCILL license under French law and !! abiding by the rules of distribution of free software. You can use, !! modify and/ or redistribute the software under the terms of the CeCILL !! license as circulated by CEA, CNRS and INRIA at the following URL !! "http://www.cecill.info". !! !! As a counterpart to the access to the source code and rights to copy, !! modify and redistribute granted by the license, users are provided only !! with a limited warranty and the software's author, the holder of the !! economic rights, and the successive licensors have only limited !! liability. !! !! In this respect, the user's attention is drawn to the risks associated !! with loading, using, modifying and/or developing or reproducing the !! software by the user in light of its specific status of free software, !! that may mean that it is complicated to manipulate, and that also !! therefore means that it is reserved for developers and experienced !! professionals having in-depth computer knowledge. Users are therefore !! encouraged to load and test the software's suitability as regards their !! requirements in conditions enabling the security of their systems and/or !! data to be ensured and, more generally, to use and operate it in the !! same conditions as regards security. !! !! The fact that you are presently reading this means that you have had !! knowledge of the CeCILL license and that you accept its terms. !! ========================================================================= #include #ifdef AER #ifndef DUSS SUBROUTINE AERTHERM (& delt ,& temp ,& relhum ,& pmid ,& hnm ,& asno3m_p_nh3hno3 ,& asnh4m_p_nh3hno3 ,& hno3_p_nh3hno3 ,& nh3_p_nh3hno3 ,& mmr ,& vmr ) USE INCA_DIM USE CONST_MOD USE AEROSOL_DIAG USE AEROSOL_MOD USE SPECIES_NAMES USE CHEM_MODS, ONLY : invariants USE PRINT_INCA USE RATE_INDEX_MOD IMPLICIT NONE !----------------------------------------------------------------- ! ... Dummy arguments !----------------------------------------------------------------- REAL, INTENT(in) :: delt ! timestep in seconds REAL, INTENT(in) :: temp(PLON,PLEV) ! temperature REAL, INTENT(in) :: pmid(PLON,PLEV) ! midpoint pressure in Pa REAL, INTENT(in) :: hnm(PLON,PLEV) ! total concentration REAL, INTENT(inout) :: vmr(PLON,PLEV,PCNST) ! xported species ( vmr ) REAL, INTENT(inout) :: mmr(PLON,PLEV,PCNST) ! xported species ( mmr ) REAL, INTENT(inout) :: relhum(PLON,PLEV) ! relative humidity REAL, INTENT(inout) :: asno3m_p_nh3hno3(PLON,PLEV) ! for diagnostics REAL, INTENT(inout) :: asnh4m_p_nh3hno3(PLON,PLEV) ! for diagnostics REAL, INTENT(inout) :: hno3_p_nh3hno3(PLON,PLEV) ! for diagnostics REAL, INTENT(inout) :: nh3_p_nh3hno3(PLON,PLEV) ! for diagnostics !----------------------------------------------------------------- ! ... Local variables !----------------------------------------------------------------- INTEGER :: i, j, k REAL, DIMENSION(PLON,PLEV) :: tinv REAL, DIMENSION(PLON,PLEV) :: relhumloc, relhum1 REAL, DIMENSION(PLON,PLEV) :: hno3, nh3, nh4p, no3m, so42m, nh4pini REAL, DIMENSION(PLON,PLEV) :: tn, ta, tadisp, taini, tnta, ts REAL, DIMENSION(PLON,PLEV) :: tam, tsm REAL, DIMENSION(PLON,PLEV) :: drh !0 to 1 as relhum REAL, DIMENSION(PLON,PLEV) :: kps, kpl, kpl1, kpl2, kpl3 REAL, DIMENSION(PLON,PLEV) :: zrho REAL, DIMENSION(PLON,PLEV) :: vmr0_no3m,vmr0_nh4p,vmr0_nh3,vmr0_hno3 REAL, PARAMETER :: mwnh3 = 17.e-3 !Kg/mol REAL, PARAMETER :: mwhno3 = 63.e-3 REAL, PARAMETER :: mwnh4 = 18.e-3 REAL, PARAMETER :: mwno3 = 62.e-3 REAL, PARAMETER :: mwso4 = 96.e-3 REAL, PARAMETER :: mwa = 29.e-3 REAL :: zso4 REAL :: wrk1, wrk2 REAL :: tfac, tautot, hno3eq, nh3eq zrho(:,:) = pmid(:,:)/(temp(:,:)*287.04) tinv(:,:) = 1. / temp(:,:) relhumloc = relhum WHERE( relhumloc < 0.e0 ) relhumloc = 0.e0 END WHERE WHERE( relhumloc > 0.98) relhumloc = 0.98 END WHERE relhum1(:,:) = 1. - relhumloc(:,:) !Equilibrium constant based on Mozurkewich, 1993 drh(:,:) = EXP(723.7*tinv(:,:)+1.6954) * 1.e-2 kps(:,:) = EXP(118.87-24084.*tinv(:,:)-6.025*LOG(temp(:,:))) kpl1(:,:) = EXP(-135.94+8763.*tinv(:,:)+19.12*LOG(temp(:,:))) kpl2(:,:) = EXP(-122.65+9969.*tinv(:,:)+16.22*LOG(temp(:,:))) kpl3(:,:) = EXP(-182.61+13875.*tinv(:,:)+24.46*LOG(temp(:,:))) DO i = 1, PLON DO j = 1, PLEV kpl(i,j) = kps(i,j) IF ( relhumloc(i,j) >= drh(i,j) ) THEN kpl(i,j) = (kpl1(i,j)-kpl2(i,j)*relhum1(i,j)+kpl3(i,j)*relhum1(i,j)**2.)& * relhum1(i,j)**1.75*kpl(i,j) ENDIF ENDDO ENDDO !Initial mixing ratio for diagnostics purpose vmr0_no3m(:,:) = vmr(:,:,id_ASNO3M) vmr0_nh4p(:,:) = vmr(:,:,id_ASNH4M) vmr0_hno3(:,:) = vmr(:,:,id_HNO3) vmr0_nh3(:,:) = vmr(:,:,id_NH3) !Volume mixing ratios hno3(:,:) = vmr(:,:,id_HNO3)*1.e9 no3m(:,:) = vmr(:,:,id_ASNO3M)*1.e9 nh4p(:,:) = vmr(:,:,id_ASNH4M)*1.e9 so42m(:,:) = vmr(:,:,id_ASSO4M)*1.e9 nh3(:,:) = vmr(:,:,id_NH3)*1.e9 !Total in moles tn(:,:) = hno3(:,:) + no3m(:,:) ta(:,:) = nh3(:,:) + nh4p(:,:) ts(:,:) = so42m(:,:) tam(:,:) = mmr(:,:,id_ASNH4M)*1.e9 + mmr(:,:,id_NH3)*1.e9 tsm(:,:) = mmr(:,:,id_ASSO4M)*1.e9 DO i = 1, PLON DO j = 1, PLEV !Sulfate state. Metzger et al. 2002 zso4 = 2.0 IF (tsm(i,j)> 0.5*tam(i,j)) zso4 = 1.5 IF (tsm(i,j)> tam(i,j)) zso4 = 1.0 so4state(i,j) = zso4 tadisp(i,j) = MAX((ta(i,j)-zso4*so42m(i,j)),0.) tnta(i,j) = tn(i,j)*tadisp(i,j) nh4pini(i,j) = MIN(ta(i,j),zso4*so42m(i,j)) !Step 1: Equilibrium concentrations IF ( tnta(i,j) > kpl(i,j) ) THEN wrk1 = (tadisp(i,j)+tn(i,j))**2. - 4.*(tnta(i,j)-kpl(i,j)) wrk1 = MAX(wrk1,0.) wrk2 = 0.5*(tadisp(i,j)+tn(i,j)-SQRT(wrk1)) wrk2 = MAX(wrk2,0.) wrk2 = MIN(wrk2,tn(i,j)) wrk2 = MIN(wrk2,tadisp(i,j)) hno3eq = MAX(tn(i,j)-wrk2,0.) nh3eq = MAX(tadisp(i,j)-wrk2,0.) !Step 2a: Time dependence -time constants (tau and delt in sec) !This needs to be calculated explicitely based on Wexler and Seinfeld (1990) and Ackermann et al(1995) !for now use the value provided by Ackermann et al. for alpha=0.5 and Radius=0.1um. This should be calculated explicitely but little effect. tautot = 2.05*60. tfac = 1.-EXP(-delt/tautot) !Step 2b: Time dependence -gas phase concentrations hno3(i,j) = MAX((hno3(i,j) - tfac * (hno3(i,j)-hno3eq)),0.) nh3(i,j) = MAX((nh3(i,j) - tfac * (nh3(i,j)-nh3eq)), 0.) !Step 3: Update aerosol phase no3m(i,j) = MAX((tn(i,j)-hno3(i,j)),0.) nh4p(i,j) = MAX((tadisp(i,j)-nh3(i,j)),0.) vmr(i,j,id_HNO3) = hno3(i,j) * 1.e-9 vmr(i,j,id_NH3) = nh3(i,j) * 1.e-9 vmr(i,j,id_ASNO3M) = no3m(i,j) * 1.e-9 vmr(i,j,id_ASNH4M) = nh4p(i,j) * 1.e-9 ELSE vmr(i,j,id_HNO3) = tn(i,j) * 1.e-9 vmr(i,j,id_NH3) = tadisp(i,j) * 1.e-9 vmr(i,j,id_ASNH4M) = 1.e-19 vmr(i,j,id_ASNO3M) = 1.e-19 ENDIF !Add back the ammonium sulfate vmr(i,j,id_ASNH4M) = vmr(i,j,id_ASNH4M) + nh4pini(i,j) * 1.e-9 END DO END DO !Store changes for diagnostics (molec/cm3/s) asno3m_p_nh3hno3(:,:) = (vmr(:,:,id_ASNO3M)-vmr0_no3m(:,:)) * hnm(:,:)/delt asnh4m_p_nh3hno3(:,:) = (vmr(:,:,id_ASNH4M)-vmr0_nh4p(:,:)) * hnm(:,:)/delt #ifdef NMHC hno3_p_nh3hno3(:,:) = (vmr(:,:,id_HNO3)-vmr0_hno3(:,:)) * hnm(:,:)/delt #endif nh3_p_nh3hno3(:,:) = (vmr(:,:,id_NH3)-vmr0_nh3(:,:)) * hnm(:,:)/delt END SUBROUTINE AERTHERM #endif #endif