- Timestamp:
- Apr 2, 2026, 9:15:00 AM (12 days ago)
- File:
-
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.GENERIC/libf/phygeneric/pcm_thermodynamics_mod.F90
r4163 r4164 1 module thermo_mod1 module pcm_thermodynamics_mod 2 2 3 3 use comcstfi_mod, only: cppd_ref,cppv_ref,rd_ref, rcp_ref, mugaz_ref … … 12 12 contains 13 13 14 subroutine thermodynamics (thermo_phy, pplay, pplev, t, ngrid, nlayer, nq, q, iq, zh, zpopsk)15 CHARACTER( 64), INTENT(IN) :: thermo_phy ! flag16 REAL, INTENT(IN) :: pplay(ngrid,nlayer) ! pressure (Pa)17 REAL, INTENT(IN) :: pplev(ngrid,nlayer ) ! pressure (Pa)14 subroutine thermodynamics_update(thermo_phy, pplay, pplev, t, ngrid, nlayer, nq, q, iq, zh, zpopsk) 15 CHARACTER(LEN=*), INTENT(IN) :: thermo_phy ! flag 16 REAL, INTENT(IN) :: pplay(ngrid,nlayer) ! pressure (Pa) at mid-layer 17 REAL, INTENT(IN) :: pplev(ngrid,nlayer+1) ! pressure (Pa) at layer interfaces 18 18 REAL, INTENT(IN) :: t(ngrid,nlayer) ! temperature (K) 19 19 INTEGER, INTENT(IN) :: ngrid, nlayer,nq ! Number of cells, vertical layers and tracers … … 27 27 logical, save :: firstcall=.true. 28 28 !$OMP THREADPRIVATE(firstcall) 29 character(len=80),parameter :: myname = "thermodynamics_update" 29 30 30 31 if (firstcall) then … … 32 33 ALLOCATE(cpp(ngrid,nlayer)) 33 34 ALLOCATE(rcp(ngrid,nlayer)) 35 36 SELECT CASE (TRIM(thermo_phy)) 37 CASE('thermo_uni_ideal') 38 ! Ideal gas, homogeneous 39 r(:,:) = rd_ref 40 cpp(:,:) = cppd_ref 41 rcp(:,:) = rcp_ref 42 CASE DEFAULT 43 write(*,*) 'Bad selector for thermodynamics mod: <', TRIM(thermo_phy), '>' 44 call abort_physic(trim(myname),'Bad selector for thermodynamics mod!',1) 45 END SELECT 46 34 47 firstcall=.false. 35 endif 48 endif ! of if (firstcall) 36 49 37 50 SELECT CASE (TRIM(thermo_phy)) … … 39 52 CASE('thermo_uni_ideal') 40 53 ! Ideal gas 41 r(:,:) = rd_ref42 cpp(:,:) = cppd_ref43 rcp(:,:) = rcp_ref44 54 do l=1,nlayer 45 55 do ig=1,ngrid … … 51 61 write(*,*) 'Bad selector for thermodynamics mod: <', TRIM(thermo_phy), '>' 52 62 write(*,*) 'Option is <thermo_uni_ideal>' 53 call abort 63 call abort_physic(trim(myname),'Bad selector for thermodynamics mod!',1) 54 64 END SELECT 55 65 56 end subroutine thermodynamics 66 end subroutine thermodynamics_update 57 67 58 end module thermo_mod68 end module pcm_thermodynamics_mod
Note: See TracChangeset
for help on using the changeset viewer.
