Ignore:
Timestamp:
Nov 8, 2024, 4:59:55 PM (13 days ago)
Author:
jbclement
Message:

Dynamic + Mars PCM:
Addition of the description for the 'controle' array in the "start.nc" and "startfi.nc" files. It is given by the variable 'controle_descriptor' whose the element 'controle_descriptor(i)' explains 'controle(i)'.
JBC

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.MARS/libf/phymars/phyredem.F90

    r3338 r3509  
    2121  use dimradmars_mod, only: tauvis
    2222  use iostart, only : open_restartphy, close_restartphy, &
    23                       put_var, put_field, length
     23                      put_var, put_field, length, ldscrpt, ndscrpt
    2424  use mod_grid_phy_lmdz, only : klon_glo
    2525  use planete_h, only: aphelie, emin_turb, lmixmin, obliquit, &
     
    4848  real, intent(in) :: subslope_dist(ngrid,nslope) !undermesh statistics
    4949
    50   real :: tab_cntrl(length) ! nb "length=100" defined in iostart module
    51   integer :: ig
    52   real :: watercaptag_tmp(ngrid)
     50  character(ndscrpt), dimension(ldscrpt), parameter :: dscrpt_tab_cntrl = (/ &
     51      "(1)  Total number of nodes on physics grid        ", &
     52      "(2)  Number of atmospheric layers                 ", &
     53      "(3)  Initial day                                  ", &
     54      "(4)  Initial time of day                          ", &
     55      "(5)  Radius of Mars (m) ~3397200                  ", &
     56      "(6)  Rotation rate (rad.s-1)                      ", &
     57      "(7)  Gravity (m.s-2) ~3.72                        ", &
     58      "(8)  Molar mass of the atmosphere (g.mol-1) ~43.49", &
     59      "(9)  = r/Cp ~0.256793 (=kappa in the dynamics)    ", &
     60      "(10) Length of a sol (s) ~88775                   ", &
     61      "(11) Time step in the physics                     ", &
     62      "(12) -                                            ", &
     63      "(13) -                                            ", &
     64      "(14) Length of year (sols) ~668.6                 ", &
     65      "(15) Min. Sun-Mars distance (Mkm) ~206.66         ", &
     66      "(16) Max. Sun-Mars distance (Mkm) ~249.22         ", &
     67      "(17) Date of perihelion (sols since N. spring)    ", &
     68      "(18) Obliquity of the planet (deg) ~23.98         ", &
     69      "(19) Default surface roughness (m) ~0.01          ", &
     70      "(20) Mixing length ~100                           ", &
     71      "(21) Minimal energy ~1.e-8                        ", &
     72      "(22) Albedo of northern cap ~0.5                  ", &
     73      "(23) Albedo of southern cap ~0.5                  ", &
     74      "(24) Emissivity of northern cap ~0.95             ", &
     75      "(25) Emissivity of southern cap ~0.95             ", &
     76      "(26) Emissivity of martian soil ~.95              ", &
     77      "(27) Mean visible optical depth                   ", &
     78      "(28) -                                            ", &
     79      "(29) -                                            ", &
     80      "(30) -                                            ", &
     81      "(31) Mean scat radius of CO2 snow (north)         ", &
     82      "(32) Mean scat radius of CO2 snow (south)         ", &
     83      "(33) Time scale for snow metamorphism (north)     ", &
     84      "(34) Time scale for snow metamorphism (south)     ", &
     85      "(35) Soil volumetric heat capacity                "/)
     86  real, dimension(length) :: tab_cntrl ! nb "length=100" defined in iostart module
     87  integer                 :: ig
     88  real, dimension(ngrid)  :: watercaptag_tmp
    5389
    5490  ! Create physics start file
    5591  call open_restartphy(filename)
    56  
     92
    5793  ! Build tab_cntrl(:) array
    5894  tab_cntrl(:)=0.0
     
    6197  !cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc
    6298  ! Informations on the physics grid
    63   tab_cntrl(1) = float(klon_glo)  ! total number of nodes on physics grid
    64   tab_cntrl(2) = float(nlay) ! number of atmospheric layers
    65   tab_cntrl(3) = day_ini + int(time)      ! initial day
    66   tab_cntrl(4) = time -int(time)          ! initial time of day
     99  tab_cntrl(1) = float(klon_glo)     ! Total number of nodes on physics grid
     100  tab_cntrl(2) = float(nlay)         ! Number of atmospheric layers
     101  tab_cntrl(3) = day_ini + int(time) ! Initial day
     102  tab_cntrl(4) = time -int(time)     ! Initial time of day
    67103
    68104  ! Informations about Mars, used by dynamics and physics
    69   tab_cntrl(5) = rad      ! radius of Mars (m) ~3397200
    70   tab_cntrl(6) = omeg     ! rotation rate (rad.s-1)
    71   tab_cntrl(7) = g        ! gravity (m.s-2) ~3.72
     105  tab_cntrl(5) = rad      ! Radius of Mars (m) ~3397200
     106  tab_cntrl(6) = omeg     ! Rotation rate (rad.s-1)
     107  tab_cntrl(7) = g        ! Gravity (m.s-2) ~3.72
    72108  tab_cntrl(8) = mugaz    ! Molar mass of the atmosphere (g.mol-1) ~43.49
    73   tab_cntrl(9) = rcp      !  = r/cp  ~0.256793 (=kappa dans dynamique)
    74   tab_cntrl(10) = daysec  ! length of a sol (s)  ~88775
    75 
    76   tab_cntrl(11) = phystep  ! time step in the physics
    77   tab_cntrl(12) = 0.
    78   tab_cntrl(13) = 0.
     109  tab_cntrl(9) = rcp      ! = r/cp  ~0.256793 (=kappa dans dynamique)
     110  tab_cntrl(10) = daysec  ! Length of a sol (s) ~88775
     111  tab_cntrl(11) = phystep ! Time step in the physics
    79112
    80113  ! Informations about Mars, only for physics
    81   tab_cntrl(14) = year_day  ! length of year (sols) ~668.6
    82   tab_cntrl(15) = periheli  ! min. Sun-Mars distance (Mkm) ~206.66
    83   tab_cntrl(16) = aphelie   ! max. SUn-Mars distance (Mkm) ~249.22
    84   tab_cntrl(17) = peri_day  ! date of perihelion (sols since N. spring)
     114  tab_cntrl(14) = year_day  ! Length of year (sols) ~668.6
     115  tab_cntrl(15) = periheli  ! Min. Sun-Mars distance (Mkm) ~206.66
     116  tab_cntrl(16) = aphelie   ! Max. SUn-Mars distance (Mkm) ~249.22
     117  tab_cntrl(17) = peri_day  ! Date of perihelion (sols since N. spring)
    85118  tab_cntrl(18) = obliquit  ! Obliquity of the planet (deg) ~23.98
    86119
    87120  ! Boundary layer and turbulence
    88   tab_cntrl(19) = z0_default   ! default surface roughness (m) ~0.01
    89   tab_cntrl(20) = lmixmin   ! mixing length ~100
    90   tab_cntrl(21) = emin_turb ! minimal energy ~1.e-8
     121  tab_cntrl(19) = z0_default ! Default surface roughness (m) ~0.01
     122  tab_cntrl(20) = lmixmin    ! Mixing length ~100
     123  tab_cntrl(21) = emin_turb  ! Minimal energy ~1.e-8
    91124
    92125  ! Optical properties of polar caps and ground emissivity
     
    96129  tab_cntrl(25) = emisice(2)   ! Emissivity of southern cap ~0.95
    97130  tab_cntrl(26) = emissiv      ! Emissivity of martian soil ~.95
    98   tab_cntrl(31) = iceradius(1) ! mean scat radius of CO2 snow (north)
    99   tab_cntrl(32) = iceradius(2) ! mean scat radius of CO2 snow (south)
    100   tab_cntrl(33) = dtemisice(1) ! time scale for snow metamorphism (north)
    101   tab_cntrl(34) = dtemisice(2) ! time scale for snow metamorphism (south)
     131  tab_cntrl(31) = iceradius(1) ! Mean scat radius of CO2 snow (north)
     132  tab_cntrl(32) = iceradius(2) ! Mean scat radius of CO2 snow (south)
     133  tab_cntrl(33) = dtemisice(1) ! Time scale for snow metamorphism (north)
     134  tab_cntrl(34) = dtemisice(2) ! Time scale for snow metamorphism (south)
    102135
    103136  ! dust aerosol properties
    104   tab_cntrl(27) = tauvis      ! mean visible optical depth
     137  tab_cntrl(27) = tauvis ! Mean visible optical depth
    105138
    106139  ! Soil properties:
    107   tab_cntrl(35) = volcapa ! soil volumetric heat capacity
     140  tab_cntrl(35) = volcapa ! Soil volumetric heat capacity
    108141
    109142  ! Write the controle array
    110143  call put_var("controle","Control parameters",tab_cntrl)
     144
     145  ! Write the controle array descriptor
     146  call put_var("controle_descriptor","Description of control parameters",dscrpt_tab_cntrl)
    111147 
    112148  ! Write the mid-layer depths
Note: See TracChangeset for help on using the changeset viewer.