Ignore:
Timestamp:
Jul 11, 2014, 12:34:45 PM (11 years ago)
Author:
emillour
Message:

Mars GCM: corrections wrt previous commit (physiq.F is in fixed form!).
EM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.MARS/libf/phymars/physiq.F

    r1312 r1313  
    280280      REAL ztime_fin
    281281      REAL zdh(ngrid,nlayer)
     282      REAL zh(ngrid,nlayer)      ! potential temperature (K)
    282283      REAL pw(ngrid,nlayer) ! vertical velocity (m/s) (>0 when downwards)
    283284      INTEGER length
     
    578579#endif
    579580
    580      ! Compute vertical velocity (m/s) from vertical mass flux
    581      ! w = F / (rho*area) and rho = r*T/P
    582      ! but first linearly interpolate mass flux to mid-layers
    583      do l=1,nlayer-1
     581      ! Compute vertical velocity (m/s) from vertical mass flux
     582      ! w = F / (rho*area) and rho = r*T/P
     583      ! but first linearly interpolate mass flux to mid-layers
     584      do l=1,nlayer-1
    584585       pw(1:ngrid,l)=0.5*(flxw(1:ngrid,l)+flxw(1:ngrid,l+1))
    585      enddo
    586      pw(1:ngrid,nlayer)=0.5*flxw(1:ngrid,nlayer) ! since flxw(nlayer+1)=0
    587      do l=1,nlayer
    588        pw(1:ngrid,l)=(pw(1:ngrid,l)*pplay(1:ngrid,l)) /  &
    589                      (r*pt(1:ngrid,l)*area(1:ngrid))
     586      enddo
     587      pw(1:ngrid,nlayer)=0.5*flxw(1:ngrid,nlayer) ! since flxw(nlayer+1)=0
     588      do l=1,nlayer
     589       pw(1:ngrid,l)=(pw(1:ngrid,l)*pplay(1:ngrid,l)) /
     590     &               (r*pt(1:ngrid,l)*area(1:ngrid))
    590591       ! NB: here we use r and nor rnew since this diagnostic comes
    591592       ! from the dynamics
    592      enddo
     593      enddo
    593594
    594595c-----------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.