Ignore:
Timestamp:
Jul 21, 2017, 4:07:38 PM (8 years ago)
Author:
mlefevre
Message:

Add of Venus mesoscale structure + update of Venus LES

Location:
trunk/MESOSCALE/LMD_MM_MARS/SRC/LES/modif_mars
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/MESOSCALE/LMD_MM_MARS/SRC/LES/modif_mars/Registry.EM

    r1236 r1724  
    9999state  real  RICE      ikj  misc  1  -  rd   "RICE"      "ICE RADIUS"                      "m"       #SAVEMARS3 rice
    100100state  real  PDTZ      ikj  misc  1  -  rd   "PDT"       "TEMP TENDENCY"                   "K s-1"   #SAVEMARS3 pdt
     101state  real  HR_SW     ikj   misc  1  -  -  "HR_SW"     "HEATING RATE SW"                 "K/s"
     102state  real  HR_LW     ikj   misc  1  -  -  "HR_LW"     "HEATING RATE LW"                 "K/s"
     103state  real  HR_DYN     ikj   misc  1  -  -  "HR_DYN"     "HEATING RATE DYN"                 "K/s"
     104state  real  DDT     ikj   misc  1  -  -  "DDT"     "TEMPERATURE TENDENCY"                 "K/s"
     105state  real  DT_RAD     ikj   misc  1  -  -  "DT_RAD"     "RADIATIVE TEMPERATURE TENDENCY"                 "K/s"
     106state  real  DT_VDF     ikj   misc  1  -  -  "DT_VDF"     "PBL CLMAIN TEMPERATURE TENDENCY"                 "K/s"
     107state  real  DT_AJS     ikj   misc  1  -  -  "DT_AJS"     "AJUSTEMENT SEC TEMPERATURE TENDENCY"                 "K/s"
    101108####
    102109####
  • trunk/MESOSCALE/LMD_MM_MARS/SRC/LES/modif_mars/Registry.EM.newphys

    r1586 r1724  
    8282state  real  HR_SW     ikj   misc  1  -  -  "HR_SW"     "HEATING RATE SW"                 "K/s"
    8383state  real  HR_LW     ikj   misc  1  -  -  "HR_LW"     "HEATING RATE LW"                 "K/s"
     84state  real  HR_DYN     ikj   misc  1  -  -  "HR_DYN"     "HEATING RATE DYN"                 "K/s"
     85state  real  DDT     ikj   misc  1  -  -  "DDT"     "TEMPERATURE TENDENCY"                 "K/s"
     86state  real  DT_RAD     ikj   misc  1  -  -  "DT_RAD"     "RADIATIVE TEMPERATURE TENDENCY"                 "K/s"
     87state  real  DT_VDF     ikj   misc  1  -  -  "DT_VDF"     "PBL CLMAIN TEMPERATURE TENDENCY"                 "K/s"
     88state  real  DT_AJS     ikj   misc  1  -  -  "DT_AJS"     "AJUSTEMENT SEC TEMPERATURE TENDENCY"                 "K/s"
     89
    8490state  real  SWDOWNZ    ij   misc  1  -  -  "SWDOWNZ"   "DOWNWARD SW FLUX AT SURFACE"     "W m-2"
    8591#### DUST CYCLE
     
    96102state  real  ZMAX       ij   misc  1  -  -  "ZMAX"      "MAXIMUM LEVEL THERMALS"          "m"
    97103state  real  HFMAX      ij   misc  1  -  -  "HFMAX"     "MAXIMUM PBL HEAT FLUX"           "m.K/s"
     104
    98105####
    99106####
     
    303310state    real   t_save         ikj     dyn_em      1         -               "t_save"
    304311#                                               
    305 
     312state    real   tz_init        ikj     dyn_em      1         -      ir       "tz_init" "initial potential temperature" "K"
    306313
    307314# Mass
  • trunk/MESOSCALE/LMD_MM_MARS/SRC/LES/modif_mars/module_big_step_utilities_em.F

    r34 r1724  
    1414
    1515   USE module_domain, ONLY : domain
     16   USE module_configure
    1617   USE module_model_constants
    1718   USE module_state_description
     
    44754476      p_phy(i,k,j) = p(i,k,j) + pb(i,k,j)
    44764477      pi_phy(i,k,j) = (p_phy(i,k,j)/p1000mb)**rcp
    4477       t_phy(i,k,j) = th_phy(i,k,j)*pi_phy(i,k,j)
     4478      IF (planet.eq. "venus" ) THEN
     4479      !call tpot2t(1,th_phy(i,k,j), t_phy(i,k,j), pi_phy(i,k,j))
     4480        t_phy(i,k,j)= (th_phy(i,k,j)**nu - nu*(TT00**nu)*log((p1000mb/p_phy(i,k,j))**rcp))**(1/nu)
     4481      ELSE
     4482        t_phy(i,k,j) = th_phy(i,k,j)*pi_phy(i,k,j)
     4483      ENDIF
    44784484      rho(i,k,j) = 1./alt(i,k,j)*(1.+moist(i,k,j,P_QV))
    44794485      mu_3d(i,k,j) = mu(i,j)
  • trunk/MESOSCALE/LMD_MM_MARS/SRC/LES/modif_mars/module_first_rk_step_part1.F

    r1590 r1724  
    650650     &       ,HR_SW=grid%HR_SW   &
    651651     &       ,HR_LW=grid%HR_LW   &
     652     &       ,HR_DYN=grid%HR_DYN   &
     653     &       ,DDT=grid%DDT  &
     654     &       ,DT_RAD=grid%DT_RAD  &
     655     &       ,DT_VDF=grid%DT_VDF  &
     656     &       ,DT_AJS=grid%DT_AJS  &
    652657     &       ,SWDOWNZ=grid%SWDOWNZ   &
    653658     &       ,TAU_DUST=grid%TAU_DUST   &
  • trunk/MESOSCALE/LMD_MM_MARS/SRC/LES/modif_mars/module_initialize_les.F

    r1608 r1724  
    8686
    8787   INTEGER, PARAMETER :: nl_max = 1000
    88    REAL, DIMENSION(nl_max) :: zk, p_in, theta, rho, u, v, qv, pd_in
     88   REAL, DIMENSION(nl_max) :: zk, p_in, theta, Tz, rho, u, v, qv, pd_in
    8989   INTEGER :: nl_in
    9090
     
    116116 ! for mode 3
    117117 REAL, DIMENSION(nl_max) :: profdustq,profdustn
    118  REAL, DIMENSION(nl_max) :: prescribed_sw,prescribed_lw
     118 REAL, DIMENSION(nl_max) :: hrsw,hrlw,hrdyn
     119 REAL, DIMENSION(nl_max) :: trac
     120 REAL, DIMENSION(nl_max) :: prescribed_sw,prescribed_lw,prescribed_dyn
     121 REAL, DIMENSION(nl_max) :: venus_hrdyn
     122 REAL, DIMENSION(nl_max) :: altitude
    119123!!MARS
    120124
     
    123127      !INTEGER :: hypsometric_opt = 2 ! Wee et al. 2012 correction
    124128
    125 character(len=10) :: planet
    126129
    127130#ifdef DM_PARALLEL
    128131#    include <data_calls.inc>
    129132#endif
    130  
    131    call init_planet_constants
    132133
    133134   SELECT CASE ( model_data_order )
     
    172173
    173174
    174    !stretch_grid = .false.
     175   stretch_grid = .false.
    175176!  FOR LES, set stretch to false
    176    stretch_grid = .true.
     177   !stretch_grid = .true.
    177178   delt = 3.
    178179!   z_scale = .50
    179180!   z_scale = .10
    180181!   z_scale = .25
    181 !   z_scale = .15
     182!   z_scale = .1
    182183   pi = 2.*asin(1.0)
    183184   write(6,*) ' pi is ',pi
     
    302303   grid%rdx = 1./config_flags%dx
    303304   grid%rdy = 1./config_flags%dy
    304 
    305305!  get the sounding from the ascii sounding file, first get dry sounding and
    306306!  calculate base state
     
    310310  write(6,*) ' getting dry sounding for base state '
    311311
    312   CALL get_sounding( zk, p_in, pd_in, theta, rho, u, v, qv, dry_sounding, nl_max, nl_in )
     312  CALL get_sounding( zk, p_in, pd_in, theta, Tz, rho, u, v, qv, dry_sounding, nl_max, nl_in )
    313313  ENDIF
    314314  CALL wrf_dm_bcast_real( zk , nl_max )
     
    316316  CALL wrf_dm_bcast_real( pd_in , nl_max )
    317317  CALL wrf_dm_bcast_real( theta , nl_max )
     318  CALL wrf_dm_bcast_real( Tz , nl_max )
    318319  CALL wrf_dm_bcast_real( rho , nl_max )
    319320  CALL wrf_dm_bcast_real( u , nl_max )
     
    384385  ENDDO
    385386
    386   xs=ide/2 -3
    387   xs=ids   -3
    388   xe=xs + 6
    389   ys=jde/2 -3
    390   ye=ys + 6
    391   mtn_ht = 500
     387  xs=ide/2 -25
     388  !xs=ids   -3
     389  !xe=xs + 6
     390  xe=xs + 25
     391  !ys=jde/2 -3
     392  ys=jde/2 -25
     393  !ye=ys + 6
     394  ye=ys + 25
     395  mtn_ht = 1000
    392396#ifdef MTN
    393397  DO j=max(ys,jds),min(ye,jde-1)
    394398  DO i=max(xs,ids),min(xe,ide-1)
    395      grid%ht(i,j) = mtn_ht * 0.25 * &
     399     grid%ht(i,j) = alt_input + mtn_ht * 0.25 * &
    396400               ( 1. + COS ( 2*pi/(xe-xs) * ( i-xs ) + pi ) ) * &
    397401               ( 1. + COS ( 2*pi/(ye-ys) * ( j-ys ) + pi ) )
     
    434438      p_level = grid%znu(k)*(p_surf - grid%p_top) + grid%p_top
    435439      grid%pb(i,k,j) = p_level
    436       grid%t_init(i,k,j) = interp_0( theta, p_in, p_level, nl_in ) - t0
     440      grid%t_init(i,k,j) = interp_0_log( theta, p_in, p_level, nl_in ) - t0
     441      grid%tz_init(i,k,j) = interp_0_log( Tz, p_in, p_level, nl_in )
    437442      grid%alb(i,k,j) = (r_d/p1000mb)*(grid%t_init(i,k,j)+t0)*(grid%pb(i,k,j)/p1000mb)**cvpm
    438443    ENDDO
     
    458463  ENDDO
    459464  ENDDO
    460 
    461465  IF ( wrf_dm_on_monitor() ) THEN
    462466    write(6,*) ' ptop is ',grid%p_top
     
    468472  write(6,*) ' getting moist sounding for full state '
    469473  dry_sounding = .false.
    470   CALL get_sounding( zk, p_in, pd_in, theta, rho, u, v, qv, dry_sounding, nl_max, nl_in )
     474  CALL get_sounding( zk, p_in, pd_in, theta, Tz, rho, u, v, qv, dry_sounding, nl_max, nl_in )
    471475
    472476  DO J = jts, min(jde-1,jte)
     
    491495      p_level = grid%znu(k)*(pd_surf - grid%p_top) + grid%p_top
    492496
    493       moist(i,k,j,P_QV) = interp_0( qv, pd_in, p_level, nl_in )
    494       grid%t_1(i,k,j)          = interp_0( theta, pd_in, p_level, nl_in ) - t0
     497      moist(i,k,j,P_QV) = interp_0_log( qv, pd_in, p_level, nl_in )
     498      grid%t_1(i,k,j)          = interp_0_log( theta, pd_in, p_level, nl_in ) - t0
    495499      grid%t_2(i,k,j)          = grid%t_1(i,k,j)
    496500     
     
    694698    DO K = 1, kte-1
    695699      p_level = grid%znu(k)*(p_surf - grid%p_top) + grid%p_top
    696       grid%v_1(i,k,j) = interp_0( v, p_in, p_level, nl_in )
     700      grid%v_1(i,k,j) = interp_0_log( v, p_in, p_level, nl_in )
    697701      grid%v_2(i,k,j) = grid%v_1(i,k,j)
    698702    ENDDO
     
    718722    DO K = 1, kte-1
    719723      p_level = grid%znu(k)*(p_surf - grid%p_top) + grid%p_top
    720       grid%u_1(i,k,j) = interp_0( u, p_in, p_level, nl_in )
     724      grid%u_1(i,k,j) = interp_0_log( u, p_in, p_level, nl_in )
    721725      grid%u_2(i,k,j) = grid%u_1(i,k,j)
    722726    ENDDO
     
    847851      DO k=1,kte-1
    848852         p_level = grid%znu(k)*(pd_surf - grid%p_top) + grid%p_top
    849          scalar(its:ite,k,jts:jte,2) = interp_0( qv, pd_in, p_level, nl_in )
     853         scalar(its:ite,k,jts:jte,2) = interp_0_log( qv, pd_in, p_level, nl_in )
    850854         scalar(its:ite,k,jts:jte,3) = 0.
    851855           !! water ice is set to 0 (was put into water vapor when building prof from MCD)
     
    862866      DO k=1,kte-1
    863867         p_level = grid%znu(k)*(pd_surf - grid%p_top) + grid%p_top
    864          scalar(its:ite,k,jts:jte,4) = interp_0( profdustq, pd_in, p_level, nl_in )
    865          scalar(its:ite,k,jts:jte,5) = interp_0( profdustn, pd_in, p_level, nl_in )
     868         scalar(its:ite,k,jts:jte,4) = interp_0_log( profdustq, pd_in, p_level, nl_in )
     869         scalar(its:ite,k,jts:jte,5) = interp_0_log( profdustn, pd_in, p_level, nl_in )
    866870      ENDDO
    867871      print *, "DUST Q", scalar(its,:,jts,4)
     
    882886       DO i = its, ite
    883887         !!! we use Q2 as a vehicle for heating rates! sick!
    884          grid%m_q2(i,k,j) = interp_0( profdustq, pd_in, p_level, nl_in ) &
    885                           + interp_0( profdustn, pd_in, p_level, nl_in )
     888         grid%m_q2(i,k,j) = interp_0_log( profdustq, pd_in, p_level, nl_in ) &
     889                          + interp_0_log( profdustn, pd_in, p_level, nl_in )
    886890       ENDDO
    887891       ENDDO
     
    889893       !print*,k,grid%m_q2(1,k,1)
    890894    ENDDO
    891     print*,'planet',planet   
     895
    892896    IF (planet.eq."prescribed") Then
    893       call read_hr(profdustq,profdustn,nl_in)
     897      call read_hr(hrsw,hrlw,hrdyn,nl_in)
    894898      open(unit=17,file="prescribed_sw.txt",action="write")
    895899      open(unit=18,file="prescribed_lw.txt",action="write")
     900      open(unit=19,file="prescribed_dyn.txt",action="write")
    896901      DO k=1,kte!-1
    897902        p_level = grid%znu(k)*(pd_surf - grid%p_top) + grid%p_top
    898         prescribed_sw(k) = interp_0( profdustq, pd_in, p_level, nl_in )
    899         prescribed_lw(k) = interp_0( profdustn, pd_in, p_level, nl_in )
     903        prescribed_sw(k) = interp_0_log( hrsw, pd_in, p_level, nl_in )
     904        prescribed_lw(k) = interp_0_log( hrlw, pd_in, p_level, nl_in )
     905        prescribed_dyn(k) = interp_0_log( hrdyn, pd_in, p_level, nl_in )
    900906        write (17,*) prescribed_sw(k)
    901907        write (18,*) prescribed_lw(k)
     908        write (19,*) prescribed_dyn(k)
    902909      ENDDO
     910      close(unit=19)
     911      close(unit=18)
    903912      close(unit=17)
    904       close(unit=18)
    905913    ENDIF
     914   
     915    IF (planet.eq."venus") Then
     916      call read_hr(hrsw,hrlw,hrdyn,nl_in)
     917      open(unit=20,file="venus_hrdyn.txt",action="write")
     918      DO k=1,kte!-1
     919        p_level = grid%znu(k)*(pd_surf - grid%p_top) + grid%p_top
     920        venus_hrdyn(k) = interp_0_log( hrdyn, pd_in, p_level, nl_in )
     921        write (20,*) venus_hrdyn(k)
     922      ENDDO
     923      close(unit=20)
     924    ENDIF
     925
     926    open(unit=21,file="altitude.txt",action="write")
     927    DO k=1,kte!-1
     928      p_level = grid%znu(k)*(pd_surf - grid%p_top) + grid%p_top
     929      altitude(k) = interp_0_log( zk, pd_in, p_level, nl_in )
     930      write (21,*) altitude(k)
     931    ENDDO
     932    close(unit=21)
    906933
    907934!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
     
    941968!---------------------------------------------------------------------------
    942969
    943       subroutine get_sounding( zk, p, p_dry, theta, rho, &
     970      subroutine get_sounding( zk, p, p_dry, theta, Tz, rho, &
    944971                               u, v, qv, dry, nl_max, nl_in )
    945972      implicit none
     
    947974      integer nl_max, nl_in
    948975      real zk(nl_max), p(nl_max), theta(nl_max), rho(nl_max), &
    949            u(nl_max), v(nl_max), qv(nl_max), p_dry(nl_max)
     976           u(nl_max), v(nl_max), qv(nl_max), p_dry(nl_max),Tz(nl_max)
    950977      logical dry
    951978
     
    11121139          v(k) = v_input(k)
    11131140          qv(k) = qv_input(k)
     1141          Tz(k) = t_therm(k)
    11141142
    11151143        enddo
     
    11981226      implicit none
    11991227      integer n
    1200       real pdustq(n),pdustn(n)
     1228      real pdustq(n+1),pdustn(n+1)
    12011229      logical end_of_file
    12021230
     
    12231251      end subroutine read_dust
    12241252!!cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc
    1225       subroutine read_hr(hr_sw,hr_lw,n)
     1253      subroutine read_hr(hr_sw,hr_lw,hr_dyn,n)
    12261254      implicit none
    12271255      integer n
    1228       real hr_sw(n),hr_lw(n)
     1256      real hr_sw(n+1),hr_lw(n+1),hr_dyn(n+1)
    12291257      logical end_of_file
    12301258
     
    12391267      do while (.not. end_of_file)
    12401268
    1241         read(11,*,end=103) hr_sw(k+1),hr_lw(k+1)
    1242         write(*,*) k,hr_sw(k+1),hr_lw(k+1)
     1269        read(11,*,end=103) hr_sw(k+1),hr_lw(k+1),hr_dyn(k+1)
     1270        write(*,*) k,hr_sw(k+1),hr_lw(k+1),hr_dyn(k+1)
    12431271        k = k+1
    1244         go to 113
     1272        go to 114
    12451273 103    end_of_file = .true.
    12461274 114    continue
Note: See TracChangeset for help on using the changeset viewer.