source: trunk/LMDZ.MARS/libf/phymars/tcondco2.F90 @ 2351

Last change on this file since 2351 was 2351, checked in by aslmd, 4 years ago

tcondco2.F90 : clean

File size: 713 bytes
Line 
1SUBROUTINE tcondco2(ngrid,nlay,p,q,tcond)
2       USE comcstfi_h
3       use conc_mod, only: mmean
4
5IMPLICIT NONE
6
7!---------------------------------------------------
8! Condensation temperature for co2 ice; based on
9! the saturation in co2sat.F JA17
10!--------------------------------------------------
11
12integer, intent(in) :: ngrid,nlay
13real, intent(in), dimension(ngrid,nlay):: p,q
14double precision, intent(out), dimension(ngrid,nlay):: tcond ! CO2 condensation temperature     (atm)
15double precision:: A,B,pco2
16real :: qco2
17integer:: ig,l
18
19A=dlog(1.382d12)
20B=-3182.48
21qco2=0.
22DO l=1,nlay
23   DO ig=1,ngrid
24      pco2 = q(ig,l) * (mmean(ig,l)/44.01) * p(ig,l)
25      tcond(ig,l)=B/(dlog(pco2)-A)
26    enddo
27enddo
28
29end
Note: See TracBrowser for help on using the repository browser.