Changeset 1017 for trunk/LMDZ.COMMON/libf/dyn3d
- Timestamp:
- Aug 22, 2013, 4:02:07 PM (11 years ago)
- Location:
- trunk/LMDZ.COMMON/libf/dyn3d
- Files:
-
- 1 added
- 6 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.COMMON/libf/dyn3d/bilan_dyn.F
r97 r1017 20 20 21 21 USE control_mod, ONLY: planet_type 22 USE cpdet_mod, only: tpot2t 22 23 23 24 IMPLICIT NONE -
trunk/LMDZ.COMMON/libf/dyn3d/calfis.F
r849 r1017 31 31 USE infotrac 32 32 USE control_mod 33 33 USE cpdet_mod, only: t2tpot,tpot2t 34 34 35 35 IMPLICIT NONE -
trunk/LMDZ.COMMON/libf/dyn3d/conf_gcm.F
r1012 r1017 15 15 USE infotrac, ONLY : type_trac 16 16 use assert_m, only: assert 17 use sponge_mod, only: callsponge,mode_sponge,nsponge,tetasponge 17 18 18 19 IMPLICIT NONE … … 361 362 tau_top_bound=1.e-5 362 363 CALL getin('tau_top_bound',tau_top_bound) 364 365 ! the other possible sponge layer (sponge_mod) 366 callsponge=.false. ! default value; don't use the sponge 367 call getin("callsponge",callsponge) 368 ! check that user is not trying to use both sponge models 369 if ((iflag_top_bound.ge.1).and.callsponge) then 370 write(lunout,*)'Bad choice of options:' 371 write(lunout,*)' iflag_top_bound=',iflag_top_bound 372 write(lunout,*)' and callsponge=.true.' 373 write(lunout,*)'But both sponge models should not be', 374 & ' used simultaneously!' 375 stop 376 endif 377 378 ! nsponge: number of atmospheric layers over which the sponge extends 379 nsponge=3 ! default value 380 call getin("nsponge",nsponge) 381 382 ! mode_sponge: (quenching is towards ... over the upper nsponge layers) 383 ! 0: (h=hmean,u=v=0) 384 ! 1: (h=hmean,u=umean,v=0) 385 ! 2: (h=hmean,u=umean,v=vmean)" 386 mode_sponge=2 ! default value 387 call getin("mode_sponge",mode_sponge) 388 389 ! tetasponge: characteristic time scale (seconds) at topmost layer 390 ! (time scale then doubles with decreasing layer index)." 391 tetasponge=50000.0 392 call getin("tetasponge",tetasponge) 363 393 364 394 ! FOR TITAN: tidal forces -
trunk/LMDZ.COMMON/libf/dyn3d/cpdet_mod.F90
r1016 r1017 1 ! ADAPTATION GCM POUR CP(T) 2 c====================================================================== 3 c S. Lebonnois, 10/2010 4 c 5 c Cp doit être calculé par cpdet(t) pour être valable partout 6 c 7 c La fonction d'Exner reste pk = RCPD*(play/pref)**RKAPPA 8 c (RCPD=cpp, RKAPPA=kappa) 9 c 10 c On passe de T a teta (temperature potentielle) par t2tpot(t,teta,pk) 11 c On passe de teta a T par tpot2t(teta,t,pk) 12 c 13 c====================================================================== 1 module cpdet_mod 2 3 implicit none 4 5 ! ADAPTATION OF GCM TO CP(T) 6 !====================================================================== 7 ! S. Lebonnois, 10/2010 8 ! 9 ! Cp must be computed using cpdet(t) to be valid 10 ! 11 ! The Exner function is still pk = RCPD*(play/pref)**RKAPPA 12 ! (RCPD=cpp, RKAPPA=kappa) 13 ! 14 ! One goes from T to teta (potential temperature) using t2tpot(t,teta,pk) 15 ! One goes from teta to T using tpot2t(teta,t,pk) 16 ! 17 !====================================================================== 18 19 contains 14 20 15 21 SUBROUTINE ini_cpdet … … 17 23 USE control_mod, ONLY: planet_type 18 24 IMPLICIT none 19 c======================================================================20 c Initialisation de nu_venus ett0_venus21 c======================================================================25 !====================================================================== 26 ! Initialization of nu_venus and t0_venus 27 !====================================================================== 22 28 23 29 ! for cpp, nu_venus and t0_venus: … … 33 39 34 40 return 35 end 41 end subroutine ini_cpdet 36 42 37 c======================================================================38 c======================================================================43 !====================================================================== 44 !====================================================================== 39 45 40 46 FUNCTION cpdet(t) … … 46 52 #include "comconst.h" 47 53 48 real cpdet,t 54 real,intent(in) :: t 55 real cpdet 49 56 50 57 if (planet_type.eq."venus") then … … 55 62 56 63 return 57 end 64 end function cpdet 58 65 59 c======================================================================60 c======================================================================66 !====================================================================== 67 !====================================================================== 61 68 62 69 SUBROUTINE t2tpot(npoints, yt, yteta, ypk) 63 c======================================================================64 cArguments:65 c 66 cyt --------input-R- Temperature67 cyteta-------output-R- Temperature potentielle68 cypk --------input-R- Fonction d'Exner: RCPD*(pplay/pref)**RKAPPA69 c 70 c======================================================================70 !====================================================================== 71 ! Arguments: 72 ! 73 ! yt --------input-R- Temperature 74 ! yteta-------output-R- Temperature potentielle 75 ! ypk --------input-R- Fonction d'Exner: RCPD*(pplay/pref)**RKAPPA 76 ! 77 !====================================================================== 71 78 72 79 USE control_mod, ONLY: planet_type … … 76 83 #include "comconst.h" 77 84 78 integer npoints 79 REAL yt(npoints), yteta(npoints), ypk(npoints) 85 integer,intent(in) :: npoints 86 REAL,intent(in) :: yt(npoints), ypk(npoints) 87 REAL,intent(out) :: yteta(npoints) 80 88 81 89 if (planet_type.eq."venus") then … … 88 96 89 97 return 90 end 98 end subroutine t2tpot 91 99 92 c======================================================================93 c======================================================================100 !====================================================================== 101 !====================================================================== 94 102 95 103 SUBROUTINE tpot2t(npoints,yteta, yt, ypk) 96 c======================================================================97 cArguments:98 c 99 cyteta--------input-R- Temperature potentielle100 cyt -------output-R- Temperature101 cypk --------input-R- Fonction d'Exner: RCPD*(pplay/pref)**RKAPPA102 c 103 c======================================================================104 !====================================================================== 105 ! Arguments: 106 ! 107 ! yteta--------input-R- Temperature potentielle 108 ! yt -------output-R- Temperature 109 ! ypk --------input-R- Fonction d'Exner: RCPD*(pplay/pref)**RKAPPA 110 ! 111 !====================================================================== 104 112 105 113 USE control_mod, ONLY: planet_type … … 109 117 #include "comconst.h" 110 118 111 integer npoints 112 REAL yt(npoints), yteta(npoints), ypk(npoints) 119 integer,intent(in) :: npoints 120 REAL,intent(in) :: yteta(npoints), ypk(npoints) 121 REAL,intent(out) :: yt(npoints) 113 122 114 123 if (planet_type.eq."venus") then … … 121 130 122 131 return 123 end 132 end subroutine tpot2t 124 133 125 c====================================================================== 126 c====================================================================== 127 c 128 c ATTENTION 129 c 130 c Si un jour on a besoin, il faudra coder les routines 131 c dt2dtpot / dtpto2dt 132 c 133 c====================================================================== 134 c====================================================================== 134 !====================================================================== 135 !====================================================================== 136 ! 137 ! ATTENTION 138 ! 139 ! Si un jour on a besoin, il faudra coder les routines 140 ! dt2dtpot / dtpto2dt 141 ! 142 !====================================================================== 143 !====================================================================== 144 end module cpdet_mod -
trunk/LMDZ.COMMON/libf/dyn3d/gcm.F
r979 r1017 16 16 USE infotrac 17 17 USE control_mod 18 use cpdet_mod, only: ini_cpdet 18 19 19 20 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -
trunk/LMDZ.COMMON/libf/dyn3d/leapfrog.F
r1012 r1017 16 16 USE write_field 17 17 USE control_mod 18 use cpdet_mod, only: cpdet,tpot2t,t2tpot 19 use sponge_mod, only: callsponge,mode_sponge,sponge 18 20 IMPLICIT NONE 19 21 … … 197 199 ! for CP(T) 198 200 real :: dtec 199 real,external :: cpdet200 201 real :: ztetaec(ip1jmp1,llm) 201 202 202 203 c dummy: sinon cette routine n'est jamais compilee... 203 204 if(1.eq.0) then 205 #ifdef CPP_PHYS 204 206 CALL init_phys_lmdz(iim,jjp1,llm,1,(/(jjm-1)*iim+2/)) 207 #endif 205 208 endif 206 209 … … 562 565 IF(apdiss) THEN 563 566 567 ! sponge layer 568 if (callsponge) then 569 CALL sponge(ucov,vcov,teta,ps,dtdiss,mode_sponge) 570 endif 564 571 565 572 c calcul de l'energie cinetique avant dissipation -
trunk/LMDZ.COMMON/libf/dyn3d/vlspltqs.F
r109 r1017 22 22 c pk exner au milieu des couches necessaire pour calculer Qsat 23 23 c -------------------------------------------------------------------- 24 use cpdet_mod, only: tpot2t 24 25 IMPLICIT NONE 25 26 c
Note: See TracChangeset
for help on using the changeset viewer.