Home
User Manual for the LMD Generic Climate Model
Contents
1. t 1 t 1 ucov 3 L co2ice C VCOV 3 C tsurf 5 tsoil 1 C j AS 7 12 t 2 ucov co2ice C vcov tsurf P h C tsoil D K 3 C z 3 3 l 3 1 ucov P i coZice am EN VCOV js N tsurf P GENE Eh ED e tsoil Figure 7 2 Organization of NetCDF files rlonv title rlatv rlatv rlatv title Longitudes des points V loat Latitudes des points V loat ap interlayer ap title Coef A hybrid pressure levels loat bp interlayer bp title Coef B hybrid sigma levels loat aps altitude aps title Coef AS hybrid pressure at midlayers loat bps altitude bps title Coef BS hybrid sigma at midlayers loat presnivs altitude latitude latitude latitude units degrees north latitude long name North latitude longitude longitude longitude long name East longitude longitude units degrees east altitude altitude altitude long name loat loat loat pseudo alt 41 3 loat loat loat loat loat loat loat loat loat loat loat loat altitude units km altitude positive up cu latitude rlonu cu title Coefficient de passage pour U cv rlatv longitude cv title Coefficient de passage pour V aire latitude longitude aire title Aires de chaque maille phisinit latitude longitude phisinit title Geopot
2. Tracer and aerosol options Fixed aerosol distributions 38 aerofixed false Varying H20 cloud fraction CLFvarying false H20 cloud fraction CLFfixval 0 5 number mixing ratio of CO2 ice particles Nmix_co2 100000 number mixing ratio of water ice particles Nmix_h2o 100000 Water options 7777777777777 Model water cycle water o true Model water cloud formation watercond true Model water precipitation including coagulation etc waterrain true WATER Precipitation threshold simple scheme only rainthreshold 0 0011 Include hydrology hydrology true H20 snow and ice albedo 7 albedosnow 0 5 Maximum sea ice thickness maxicethick 0 05 Freezing point of seawater degrees C Tsaldiff 0 0 CO2 options gas is non ideal CO2 nonideal false call CO2 condensation co2cond true Set initial temperature profile to 1 K above CO2 condensation everywhere nearco2cond false 7 2 3 traceur def Tracers in input start nc and startfi nc and output files restart nc and restartfi nc are stored using individual tracer names e g co2 for CO2 gas h20 vap for water vapour h20 ice for water ice The first line of the traceur def file an ASCII file must contain the number of tracers to load and use this number should be the same as given to the t option of the makegcm script when the GCM was co
3. rayleigh true Characteristic planetary equilibrium black body temperature This is used only in the aerosol radiative transfer setup see aerave F tplanet 215 Output spectral OLR in 1D 3D specOLR false Output global radiative balance in file rad bal out slow for 1D meanOLR enue Variable gas species Radiatively active varactive true Variable gas species Fixed vertical distribution varfixed false Variable gas species Saturation percentage value at ground satval 0 0 Star type doc startype 1 Bom HR eee The choices are startype 1 Sol G2V class main sequence startype 2 Ad Leo M class synthetic startype 3 GJ644 startype 4 HD128167 RE EEE Stellar flux at 1 AU Examples 1366 0 W m 2 Sol today 1024 5 W m 2 Sol today x 0 75 weak early Sun 18 462 W m 2 The feeble G1581 19 960 W m 2 G1581 with e 0 38 orbital average FatlAU 1024 5 Tracer and aerosol options Lo agp EQ Se ey E PU E Gravitational sedimentation of tracers KEEP FALSE FOR NOW sedimentation false Other physics options ur ATR SM EE E NE call turbulent vertical diffusion calldifv true call convective adjustment calladj true call thermal conduction in the soil callsoil true HEE EE HE TE FE HH FE TE EE HE HE FE FE HE EEE EE HE HE HE E H E E E E extra specific options for Early Mars HEE HE HE TE FE E FE FE FE FE HE TE HE EEE H E E E E
4. traceur def controls the tracer names this file may not be present as long as you run without tracers option tracer false incallphys def run def controls the 1D run parameters and initializations this is actually file run def 1d the deftank directory which must be renamed run def to be read by the program The last file is different from the 3D GCM s run def input file as it contains options specific to the 1D model as shown in the example below 54 Time integration parameters Initial date in martian sols 0 at Ls 0 day0 0 Initial local time in hours between 0 and 24 time 0 Number of time steps per sol day_step 48 Number of sols to run ndt 400 Physical parameters Surface pressure Pa psurf 7000 Gravity ms 2 g 3 72 Molar mass of atmosphere g mugaz 43 49 Specific heat capacity of atmosphere cpp 744 5 latitude in degrees latitude 0 0 orbital distance at perihelion AU periastr 1 558 orbital distance at aphelion AU apoastr 1 558 obliquity degrees obliquit 0 0 Solar zenith angle degrees szangle 60 0 Albedo of bare ground albedo 0 2 Emissivity of bare ground emis 1 0 Soil thermal inertia SI inertia 400 zonal eastward component of the geostrophic wind m s u 10 meridional northward component of the geostrophic wind m s v 0 Initial CO2 ice on the surface kg m 2 co2ice 0 hybrid vertical coordinat
5. Latitudes at v nodes float aps altitude aps title hybrid pressure at midlayers aps units Pa float bps altitude bps title hybrid sigma at midlayers bps units uM float ap interlayer ap title hybrid pressure at interlayers ap units Pa float bp interlayer bp title hybrid sigma at interlayers bp units float soildepth subsurface layers Soildepth long name Soil mid layer depth soildepth units m soildepth positive down 46 float cu latitude rlonu cu title Conversion coefficients cov natural float cv rlatv longitude cv title Conversion coefficients cov natural float aire latitude longitude aire title Mesh area float phisinit latitude longitude phisinit title Geopotential at the surface float emis Time latitude longitude emis title Surface emissivity emis units w m 1 float tsurf Time latitude longitude tsurf title Surface temperature tsurf units K float ps Time latitude longitude ps title surface pressure ps units Pa float co2ice Time latitude longitude co2ice title co2 ice thickness co2ice units kg m 2 float mtot Time latitude longitude mtot title total mass of water vapor mtot units kg m2 float icetot Time latitude longitude icetot title total mass of water ice icetot units kg m2 float tauTES Time latitude longitude tauTES titl
6. dump and ncgen To ensure that during compilation the model can find the NetCDF library and in clude files you must declare environment variables NCDF LIB and NCDFINC NCDFLIB must contain the path to the directory containing the object library Libnetcdf a and NCDF INC must contain the path to the directory containing the include files netcdf inc As for LMDGCM variable these variables can be declared by changing the right line in makegcm setenv NCDFINC wherever is netcdf include setenv NCDFLIB wherever is netcdf lib For example if working at LMD and with ifort the path is setenv NCDFINC donnees emlmd netcdf64 4 0 1 ifort include setenv NCDFLIB donnees emlmd netcdf64 4 0 1 ifort lib e Install software for loading and displaying NetCDF files such as GrAdS http grads iges org grads Ferret http ferret wrc noaa gov Ferret or Python Some visualization scripts es pecially for Python can be found in the UTIL directory and will be described later 20 Finally make sure that you have access to all the executables needed for building and using the model and remember to set environment variables to the correct corre sponding pathes note that if you do not want to have to redefine these every session you should put the definitions in the corresponding cshrc or bashrc files UNIX function make a Fortran compiler ncdump grads or ferret 5 2 Installing the model without SVN Create an alias s
7. files file h In general variables are passed from subroutine to subroutine as arguments and never as COMMON blocks In some parts of the code for historical reasons the following rule is sometimes used in the subroutine the variables ex name passed as an argument by the calling program are given the prefix p ex pname while the local variables are given the prefix z ex zname As a result several variables change their prefix and thus their name when passing from a calling subroutine to a called subroutine We re trying to eliminate this as the code is developed 6 3 Model organization Figure 6 1 describes the main subroutines called by physiq F OBSOLETE FOR MARS ONLY 6 4 Compiling the model Technically the model is compiled using the Unix utility make The file makefile which describes the code dependencies and requirements is created automatically by the script create make gcm This utility script recreates the makefile file when necessary for example when a source file has been added or removed since the last compilation None of this is visible to the user To compile the model just run the command makegcm with adequate options e g makegcm d 62x48x32 p mars gom as discussed below and described in section 5 3 The makegcm command compiles the model gcm and related utilities newstart start2archive testphys1d A detailed description of how to use it and of the various parameters that c
8. The output is identical to that in option c except for the fact that the coordinated variable values are not included ncdump v varl varn diagfi nc The output includes the specific variable values as well as all the dimensions variables and attributes More that one variable can be specified in the list following this option The list must be a simple argument for the command and must not contain any spaces If no variable is specified the command displays all the values of the variables in the file by default 33 90N 60N 30N i707 30S 60S MET 120W 60W 0 60E 120E 180 Figure 7 1 Example of temperature data in this case for present day Mars at a given time using GrADS visualization 7 1 2 Graphic visualization of the NetCDF files using GrAds GrAdS The Grid Analysis and Display System is a graphic software developed by Brian Doty at the Center for Ocean Land Atmosphere COLA One of its functions is to enable data stored in NetCDF format to be visualized directly In figure 7 1 for example we can see the GrADS visualization of the temperature data at a given moment However unlike NetCDF GrADS only recognizes files where all the variables are stored on the same horizontal grid These variables can be in 1 2 3 or 4 dimensions X Y Z and t GrADS can also be obtained on the WWWhttp grads iges org grads 7 2 Input and parameter files The 3D version of the GCM requ
9. They can of course be modified depending on blackbody temperatures and the tradeoff required between model speed and accuracy the examples given provide accurate results for planets around Sun like or M class stars with surface temperatures in the 200 350 K range postkspect rum moves the LBL database to the DWORK DIR directory along with the script run kmatrix When run kmatrix is submitted in batch mode it calls generate kmatrix exe automatically for both the visible and the infrared Correlated k conversion is much quicker than the LBL calculation for this database on current 2011 systems it should take only a few hours 11 3 Implementing the absorption data in the GCM To use our new correlated k coefficients we symbolically link the correlated k folder to the datagcm directory defined in the GCM file phystd datafile h it s best to avoid copying the data directly due to space considerations All that is left is to change corrkdir in callphys def to the correct name CO2 H20Ovar in this example Provided that we compile the GCM with the correct number of bands e g makegcm d 32x32x20 t 1 b 32x36 p std gcm it will run automatically with the new radiative transfer The GCM checks the radiative transfer data on initialization vs the values given in gases def to verify that thermo dynamic values e g Hgas Cp match the correlated k data in the model 61 Bibliography
10. a new file SLMDGCM libf grid dimension dimensions im jm lm tntrac f the file does not exist already it is created by the script SLMDGCM libf grid dimension makdim p PHYS Selects the set of physical parameterizations you want to compile the model with The model is then compiled using the physical parameterization sources in directory SLMDGCM libf phyPHYS 31 g grille Selects the grid type This option overwrites file SLMDGCM libf grid fxyprim h with file LMDGCM libf grid fxy grille h the grid can take the following values 1 reg the regular grid 2 sin to obtain equidistant points in terms of sin latitude 3 new to zoom into a part of the globe O compilation options set of fortran compilation options to use include path Used if the subroutines contain include files ccp that are located in directories that are not referenced by default adjnt Compiles the adjoint model to the dynamical code filtre filter To select the longitudinal filter in the polar regions filter corresponds to the name of a directory located in SLMDGCM libf The standard filter for the model is filtrez which can be used for a regular grid and for a grid with longitudinal zoom link Ldirl lfilel Ldir2 lfile2 Adds a link to FORTRAN libraries libfilel a libfile2 a located in directories dirl dir2 respectively If dirn is a directory with an automatic path usr lib for example there is no need to spe
11. au laboratoire par Ali Harzallah 12 N th Surface Figure 3 2 Disposition des variables dans la grille du LMD les trois composantes du flux de masse X Vs HS Ge i da U p w V ps vet W PaT ANEC T E 3 2 le facteur de Coriolis multipli par l aire de la maille f 20 sin oc cc o Q est la vitesse de rotation de la plan te la vorticit potentielle absolue F x y f XY Ps Z 3 3 l nergie cin tique 1 X Y K 5 si 0 3 4 La notation 6X signifie simplement qu on effectue la diff rence entre deux points cons cutifs suivant la direction X La notation G signifie qu on prend la moyenne arithm tique de la quantit a suivant la direction X F est un filtre longitudinale appliqu dans les r gions polaires Les quations discr tis es sont crites sous la forme suivante quations du mouvement O vx S 2 V 8xF 9 K 50 5xF ps FX Z om ie WTA x y SG Ds 070 Ds zc 3 5 o est la composante zonale covariante du vecteur vent absolu tg c a cos et Y Z x zXX Y W XX Y _y zW Z A eZ U by F K 4 58 byF p P 4 Y X Ds zo Ps zo ENDE 3 6 13 quation thermodynamique Z S ee F bx 6 0 o 8 v EU S 3 7 quation hydrostatique m z p 0 ozs 3 8 quations de continuit Ops x F 620 xU
12. dynamical grid cu cv only in the dynamical header and finally the grid box areas aire for the dynamical part area for the physical part Surface conditions The surface conditions are mostly given in the physical NetCDF files by variables phisfi for the initial state of surface geopotential albedodat for the bare ground albedo inertiedat for the surface thermal inertia zmea zstd zsig zgam and zthe for the subgrid scale topography For the dynamics physinit for the initial state of surface geopotential Remark variables phisfi and physinit contain the same information surface geopotential but phisfi gives the geopotential values on the physical grid while physinit give the values on the dynamical grid Physical and dynamical state variables To save disk space the initialization files store the variables used by the model rather than the natural variables For the dynamics 43 ucov and vcov the covariant winds These variables are linked to the natural winds by ucov cu uandvcov cv v teta the potential temperature K or more precisely the potential enthalpy linked to temperature T by 0 T pi the tracers ps surface pressure masse the atmosphere mass in each grid box Vectorial variables ucov and vcov are stored on staggered grids u and v respectively in the dynamics see section 2 2 Scalar variables h q tracers ps masse are st
13. hereafter called makegcm where mycompiler is the compiler that you want to use There are two important environment variables concerning source files that are initialized by makegcm and that we need to set properly 1 LMDGCM the path to the source files By default the line setenv LMDGCM readlink f scriptdir allows makegcm to assume that it is executed in the root source directory so that this should work without any change If makegcm does not find the source you can enter manually the path by changing the above line by setenv LMDGCM path to source directory LMDZ GENERIC 2 LIBOGCM the path to the compilation directory where all object files will be kept By default the line setenv LIBOGCM LMDGCM libo specifies that source will be kept in a 1 ibo directory created in LMDZ GENERIC You can also change that if needed e Install NetCDF http www unidata ucar edu packages netcdf INS TALL html and set en vironment variables NCDF INC and NCDFLIB The latest version of the NetCDF package is available on the web at the following address http www unidata ucar edu software netcdf along with instructions for building or downloading precompiled binaries of the library Once the NetCDF library has been compiled or downloaded you should have access to the library 1ibnetcdf a itself the various files netcd inc netcdf mod to include in programs and basic NetCDF software nc
14. inertia to reference suface values Program newstart e creates files restart nc and restartfi nc that you gen erally need to rename for instance rename them in startO nc and startfi0 nc if you want to use runO or run mcd starting with season 0 rename them start nc and startfi nc if you just want to perform one run with gcm e 5 9 Creating the initial start archive nc file Archive file start archive nc is created from files start nc and startfi nc by program start2archive Program start2archive compiles to the same grid resolution as the start nc and startfi nc grid resolution For example makegcm d 32x32x20 p std start2archive Thenrun start2archive e Younowhavea start_archive nc file for one season that you can use with newstart If you want to gather other states obtained at other times of year rerun start2archive e with the start nc and startfi nc corresponding to these These additional initial states will automatically be added to the start archive nc file present in the direc tory 5 9 3 Changing the horizontal or vertical grid resolution To run at a different grid resolution than available initial conditions files one needs to use tools newstart and start2archive For example to create initial states at grid resolution 32x24 x25 from NetCDF files start and startfi at grid resolution 64x48x32 e Create file start archive nc with start2archive e compiled at grid resolu tion 64x48 x25 using old file z2sig def use
15. lw Time latitude longitude fluxtop_lw title Thermal IR radiative flux to space fluxtop_lw units W m 2 float fluxtop lw sd Time latitude longitude ps sd title Surface pressure total standard deviation over th tsurf sd title Surface temperature total standard deviation o co2ice sd title CO2 ice cover total standard deviation over t fluxsurf lw title Thermal IR radiative flux to surface fluxsurf lw sd title Thermal IR radiative flux to surface tot fluxsurf sw sd title Solar radiative flux to surface total st fluxtop lw sd title Thermal IR radiative flux to space total standard deviation over the season fluxtop lw sd units W m 2 48 float float ard deviation float float the season float float fluxtop sw Time latitude longitude fluxtop sw title Solar radiative flux to space fluxtop sw units W m 2 fluxtop sw sd Time latitude longitude fluxtop sw sd title Solar radiative flux to space total stand over the season fluxtop sw sd units W m 2 dod Time latitude longitude dod title Dust optical depth dod units dod_sd Time latitude longitude dod_sd title Dust optical depth total standard deviation over dod sd units temp Time altitude latitude longitude temp title Atmospheric temperature temp units K temp sd Time altitude latitude longitude temp sd title Atmospheric temperatu
16. script i e set the value of nummax e Copy start files start nc startfi nc over and rename them start0 nc startfi0 nc e Run script Cun U run runs a series of simulations that generate the indexed output files e g start1 startfil diagfil etc including files 1run1 lrun2 etc containing the redi rection of the display and the information about the run NOTE to restart a series of simulations after a first series for example starting from start5 and startfi5 just write the index of the initial files e g 5 in the file named num run If num run exists the model will start from the index written in num run If not it will start from start0 and startfi O0 NOTE A script is available for performing annual runs with 12 seasons at 30 solar longitude as it is in the database script run_mcd also found in directory de tank This script functions with script runO Just set the number of simulations to 1 in run0 Then copy run def into run def ref and set nday to 9999 in this file To start from startN c edit the file run mcd and comment with a the N months already created and describe N in num run Then run run mcd 5 9 Creating and modifying initial states 5 9 1 Using program newstart When working with the generic model it is common to start with simple initial conditions e g isothermal motionless atmosphere For this we create an initial state using newstart In practice we usually take an old initial sta
17. the time step used for the dissipation dissipation is computed and added every idissip dynamical time step If idissip is too short the model waste time in these calculations But if idissip is too long the dissipation will not be parametrized correctly and the model will be more likely to diverge A check must be made so that idissip lt tetagdivxdaystep 86400 same rule for tet adrot and tetatemp This is tested automatically during the run e iphysiq is the time step used for the physics physical tendencies are computed every iphysig dynamical time step In practice we usually set the physical time step to be of the order of half an hour We thus generally set iphysiq day_step 48 Example of run def file Nombre de jours d integration nday 669 nombre de pas par jour multiple de iperiod ici pour dt 1 min 35 day step 960 periode pour le pas Matsuno en pas iperiod 5 periode de sortie des variables de controle en pas iconser 120 periode d ecriture du fichier histoire en jour iecri 100 periode de stockage fichier histmoy en jour periodav 60 periode de la dissipation en pas idissip 5 choix de l operateur de dissipation star ou non star lstardis true avec ou sans coordonnee hybrides hybrid true nombre d iterations de l operateur de dissipation gradiv nitergdiv 1 nombre d iterations de l operateur de dissipation nxgradrot nitergrot 2 nombre d iterati
18. the traceur def file is not impor tant Run Same as usual Just make sure that your start files contains the initial states for water with an initial state for water vapour ice in the atmosphere and ice liquid on the surface 53 Chapter 9 1D version of the generic model The physical part of the model can be used to run 1D radiative convective simulations one atmospheric column globally averaged climate In practice the simulation is controlled from a main program called rcmid F which after initialization then calls the master subroutine of the physics physiq F90 described in the previous chapters 9 1 Compilation For example to compile the generic model in 1D with 25 layers type in compliance with the makegcm function manual described in section 6 4 makegcm d 25 t 1 b 32x36 p std rcmld You can find executable rem1d e the compiled model in the directory from which you ran the makegcm command 9 2 1 D runs and input files The 1D model does not use an initial state file the simulation must be long enough to obtain a balanced state Thus to generate a simulation simply type gt rcmid e The following example files are available in the deftank directory copy them into your working directory first callphys def controls the options in the physics just like for the 3D GCM Z2sig def controls the vertical discretization no change needed in general func tions as with the 3D GCM
19. typically called at the end of subroutine physiq Example of a call to subroutine writegld requesting temperature output ngrid horizontal point nlayer layers variable pt called T in K units CALL writegld ngrid nlayer pt T K 56 Chapter 10 Zoomed simulations The LMD GCM can use a zoom to enhance the resolution locally In practice one can increase the latitudinal resolution on the one hand and the longitudinal resolution on the other hand 10 1 To define the zoomed area The zoom is defined in run def Here are the variables that you want to set e East longitude in degrees of zoom center clon e latitude in degrees of zoom center clat zooming factors along longitude grossismx Typically 1 5 2 or even 3 see be low zooming factors along latitude grossismy Typically 1 5 2 or even 3 see below fxyhypb must be set to T for a zoom whereas it must be F otherwise extention in longitude of zoomed area dzoomx This is the total longitudinal exten sion of the zoomed region degree It is recommended that grossismx x dzoomx 200 extention in latitude of the zoomed region dzoomy This is the total latitudinal extension of the zoomed region degree It is recommended that grossismy x dzoomy 100 stiffness of the zoom along longitudes taux 2 is for a smooth transition in longi tude more means sharper transition stiffness of the zoom along latitudes taux 2 is for a smooth transiti
20. A title Relief mean relief float ZSTD physical points ZSTD title Relief standard deviation float ZSIG physical points ZSIG title Relief sigma parameter float ZGAM physical points ZGAM title Relief gamma parameter float ZTHE physical points 42 ZTHE title Relief theta parameter float co2ice physical points co2_ice title CO2 ice cover float inertiedat subsurface layers physical points inertiedat title Soil thermal inertia float tsurf physical points tsurf title Surface temperature float tsoil subsurface layers physical points tsoil title Soil temperature float emis physical points emis title Surface emissivity float q2 nlayer_plus_l physical points q2 title pbl wind variance float h20 ice physical points h20 ice title tracer on surface global attributes title Physics start file Physical and dynamical headers There are two types of headers one for the physical headers and one for the dynamical headers The headers always begin with a control variable described below that is allocated differently in the physical and dynamical parts The other variables in the header concern the physical and dynamical grids They are the following the horizontal coordinates rlonu rlatu rlonv rlatv for the dynamical part lati long for the physical part the coefficients for passing from the physical grid to the
21. M v j o Figure 2 2 Dynamical and physical grids for a 6 x 7 horizontal resolution In the dynam ics but not in the physics winds u and v are on specific staggered grids Other dynamical variables are on the dynamical scalar grid The physics uses the same scalar grid for all the variables except that nodes are indexed in a single vector containing NGRID 2 JM 1 xIM points when counting from the north pole N B In the Fortran program the fol lowing variables are used iim IM iipl IM 1 jjm JM jjp1 JM 1 On the dynamical grid values at i 1 are the same as at i IM 1 as the latter node is a redundant point due to the periodicity in longitude these two nodes are actualy located at the same place Similarly the extreme j 1 and j JM 1 nodes on the dynamical grid respectively corresponding to North and South poles are duplicated IM 1 times In contrast the physical grid does not contain redundant points only one value for each pole and no extra point along longitudes as shown in figure 2 2 In practice computa tions relative to the physics are made for a series of ngrid atmospheric columns where NGRID IMX JM 1 2 2 3 2 Vertical grids hybrid coordinates set to false hybrid coordinates set to true 25 layers 25 layers f i E a E T 1 T T T T E z H log palayer pref km H log p layer pref km z Figure 2 3 Sketch illu
22. ONE a we SE en Due 1 252 callphys defu 44 s hi m eeu Roe Gada eke me 6 4 ae 4 2 5 traceur del 4 uoo ese Ue eA ei ETE ASDA 22s18 def sg URBEM B RR OUR dps 7 2 5 Initialization files start and startfi len 1 32 Output MES ses v QR Su X E petes GTR es 7 3 1 NetCDF restart files restart nc and restartfinc 7 3 2 NetCDF file diagfinc 7 35 TStats MES a gt 2 voe ene mere es pos em re UEM SIRVE Water Cycle Simulation 1D version of the generic model 9 1 C mpilatiofi used Bis TE NE a R Bk e ROB AD S S 9 2 Drunsandinputfiles 9 3 Qutputdat 2 gees cmd Les Lies he BRE ee RA RUE EISE s Zoomed simulations 10 1 To define the zoomed area 10 2 Making a zoomed initial state 10 3 Running a zoomed simulation and stability issue Changing the radiative transfer properties 11 1 Producing the high resolution data 11 2 Performing the correlated k conversion 11 3 Implementing the absorption data in the GCM 28 28 29 29 29 51 54 54 54 56 57 57 57 58 Chapter 1 Introduction This document is a user manual for the Generic Climate Model developed by the Labora toire de M t orologie Dynamique of the CNRS in Paris It corresponds to the version of the model available since January 2011 that inclu
23. User Manual for the LMD Generic Climate Model E Millour F Forget J Leconte R Wordsworth November 23 2012 Contents Introduction Main features of the model 2 1 Basic principles s i s x vasca t EU uem Re RE Sts ee Res 2 2 Dynamical Physical separation 2 3 Grid DOXeS a Se Ries oco ee a re aom E a Ghee Be dettes 2 3 1 Horizontal grids 2 32 Nerticabgnds isse ee RUE S ah Mans OR Pere es 2 4 Variables used in the model 24 1 Dynamical variables 2 42 Physical vatiableS 508 im reos besote eee ew lO 243 Tracers 9 die bbe Eb vw 4 due RS en AA 3D Dynamical Code 3 Discretisation of the dynamical equations 32 Highla tudefilters 3 3 Dissipation 4 aos e a er REN ack eA uU be RI Sw Spongelayer exu woe ates Aet usce ven CAR VE Ye RD tox Ara Physical parameterizations of the generic model some references 4 General 25542 oue Reim UR Ae Ru RORIS 42 Radiative transfer s o yok nuc o s e RR Uds 4 2 1 Absorption emission and diffusion by dust 4 3 Subgridatmospheric dynamical processes 4 3 1 Turbulent diffusion in the upper layer 4 3 2 Conyectiom kory qd uo a a Qu a So a Een We 4 4 Surface thermal conduction 4 5 CO Condensation 4 6 Tracer tran
24. aerofixed false Varying H20 cloud fraction CLFvarying false H20 cloud fraction LF fixval 1 0 number mixing ratio of CO2 ice particles Nmix co2 100000 number mixing ratio of water ice particles Nmix_h2o 100000 Q Model water cycle water true Model water cloud formation watercond true Model water precipitation waterrain true WATER Precipitation threshold rainthreshold 0 0011 including coagulation etc simple scheme only 52 Include hydrology hydrology true H20 snow and ice albedo albedosnow 0 5 Maximum sea ice thickness maxicethick 0 05 Freezing point of seawater degrees C Tsaldiff 0 0 Evolve surface water sources sourceevol true CO2 options gas is non ideal CO2 nonideal false call CO2 condensation co2cond true Set initial temperature profile to 1 K above CO2 condensation everywhere nearco2cond false You need to compile with at least 2 tracers If you don t have CO2 clouds dust or other tracers compilation is done with the command lines makegcm d 64x48x20 t 2 p std b 32x36 newstart makegcm d 64x48x20 t 2 p std b 32x36 gcm Of course you will also need an appropriate traceur def file indicating you will use tracers h2o_vap and h20o ice if you only run with 2 tracers then the contents of the traceur def file should be 2 h20o ice h20_vap Note that the order in which tracers are set in
25. an be supplied is given in the help manual below which will also be given 29 physiq F 1 5 D 10 12 14 19 8 5 Tnitialisation phyeta0 F surfini F iniorbit F initracer F solarlong F Calculation of mean mass and cp R and thermal conduction coeff concentration F Calculation of the radiative tendencies radiative transfer longwave and shortwave for CO2 and dust dustopacity F and callradite F Gravity wave and subgrid scale topography drag calldrag_noro F Vertical diffusion turbulent mixing vidfc F Convective adjustment convadj F Condensation and sublimation of carbon dioxide newcondens F TRACERS 6a water and water icc watercloud F 6b call for photochemistry when tracers are chemical species callchim F 6c other scheme for tracer dust transport lifting sedimentation dustdevil F callsedim F 6d updates CO2 pressure variations surface budget Thermosphere thermosphere F Surface and sub surface temperature calculations soil F Writing output files startfi histfi if it s time physdem1 F saving statistics if callstats true wstats F dumping eof if calleofdump true eofdump F output any needed variables in diagfi writediagfi F Figure 6 1 Organigram of subroutine function physiq F90 30 by the makegcm h command Note that before compiling the GCM with makegcm you should have set the environment variable LIBOGCM to a p
26. ath where intermediate objects and libraries will be generated If using Csh setenv LIBOGCM where you want objects to go libo If using Bash export LIBOGCM where you want objects to go libo Help manual for the makegcm script makegcm Options prog The makegcm script 1 compiles a series of subroutines located in the S LMDGCM libf sub directories The objects are then stored in the libraries in LIBOGCM 2 then makegcm compiles program prog f located by default in S LMDGCM libf dyn3d and makes the link with the libraries Environment Variables LMDGCM and S LIBOGCM must be set as environment variables or directly in the makegcm file The makegcm command is used to control the different versions of the model in parallel compiled using the compilation options and the various dimensions without having to recompile the whole model The FORTRAN libraries are stored in directory S LIBOGCM OPTIONS The following options can either be defined by default by editing the makegcm script or in interactive mode d imxjmxlm where im jm and lm are the number of longitudes latitudes and vertical layers respectively t ntrac Selects the number of tracers present in the model Options d and t overwrite file SLMDGCM libf grid dimensions h which contains the 3 dimensions of the horizontal grid im jm lm plus the number of tracers passively advected by the dynamics ntrac in 4 PARAMETER FORTRAN format with
27. bout surface conditions on the planet a time variable giving the values of the different instants at which the temporal variables are stored a single time value t 0 for start as it describes the dynamical initial states and no time values for startfi as it describes only a physical state To visualize the contents of a start nc file using the ncdump command ncdump h start nc netcdf start dimensions index 100 lonu 33 atitude 25 ongitude 33 latv 24 ltitude 18 nterlayer 19 ime UNLIMITED 1 currently variables loat controle index controle title Parametres de controle float rlonu rlonu rlonu title float rlatu latitude rlatu title Latitudes des points U float rlonv longitude r 1 1 a ak T S f Longitudes des points U 40 DYNAMIQUE ex start Ent te PHYSIQUE ex startfi Ent te 1 controle tab cntrl 2 rlonu 2 hor coor 3 rlatu Informations 3 vert coor Informations 4 rlonv sur la 4 vert2 coor sur la grille grille 1_ controle tab cntrl Conditions de surface Conditions de surface phisinit 1_ phisfi 2 albedodat 4 zmea temps temps Valeur des instants auxquels sont stock es les variables Valeur des instants auxquels sont stock es les variables Stockage des variables temporelles Stockage des variables temporelles
28. cify Ldirn 32 Chapter 7 Input Output 7 1 NetCDF format GCM input output data are written in NetCDF format Network Common Data Form NetCDF is an interface used to store and access geophysical data and a library that pro vides an implementation of this interface The NetCDF library also defines a machine independent format for representing scientific data Together the interface library and format support the creation access and sharing of scientific data NetCDF was developed at the Unidata Program Center in Boulder Colorado The freely available source can be obtained from the Unidata websitehttp www unidata ucar edu software netcdf A data set in NetCDF format is a single file as it is self descriptive 7 1 4 NetCDF file editor ncdump The editor is included in the NetCDF library By default it generates an ASCII representa tion as standard output from the NetCDF file specified at the input Main commands for ncdump ncdump diagfi nc dump contents of NetCDF file diagfi nc to standard output i e the screen ncdump c diagfi nc Displays the coordinate variable values variables which are also dimensions as well as the declarations variables and attribute values The values of the non coordinate variable data are not displayed at the output ncdump h diagfi nc Shows only the informative header of the file which is the declaration of the dimensions variables and attributes but not the values of these variables
29. d from Forget et al 1999 In the upper levels a sponge layer is also used in both models in an attempt to reduce spurious reflections of vertically propagating waves from the model top Unlike the tra ditional Rayleigh friction formulation this operates as a linear drag solely on the eddy components of the vorticity and divergence fields and is not scale selective The timescales on which it operates are typically half a day 1 day and 2 days at the three uppermost levels respectively Note the sponge layer timescale values and their extensions in altitude are ad justable and prescribed at the beginning of each run in run definition file run def cf 7 2 1 15 Chapter 4 Physical parameterizations of the generic model some references 4 1 General The Generic Climate Model uses a large number of physical parameterizations based on various scientific theories Some also use specific numerical methods A list of these parameterizations is given below along with the most appropriate references for each one Most of these documents can be found at http www lmd jussieu fr mars html General references No documents attempt to give a complete scientific description of the current version of the GCM Here s a reference to a Mars GCM description e Forget et al 1999 article published in the JGR e Updated Detailed Design Document for the Model ESA contract Work Package 6 1999 available on the web which is simply a c
30. d previously e Create files newstart nc and newstartfi nc with newstart e compiled at grid resolution 32x24x25 using new file z2sig def NOT RELEVANT If you want to create starts files with tracers for 50 layers using a start_archive nc obtained for 32 layers do not forget to use the ini q option in newstart in order to correctly initialize tracers value for layer 33 to layer 50 You just have to answer yes to the question on thermosphere initialization if you want to initialize the thermosphere part only 1233 to 1 50 and no if you want to initialize tracers for all layers 1 0 to 1250 27 Chapter 6 Program organization and compilation script All the elements of the LMD model are in the LMDZ GENERIC directory and subdi rectories As explained in Section 5 this directory should be associated with environment variable LMDGCM If using Csh setenv LMDGCM where you put the model LMDZ GENERIC If using Bash export LMDGCM where you put the model LMDZ GENERIC Here is a brief description of the LMDZ GENERIC directory contents libf All the model FORTRAN Sources F or F90 and include files h organised in sub directories physics phystd dynamics dyn3d filters filtrez deftank A collection of examples of parameter files required to run the GCM run def callphys def makegcm Script that should be used to compile the GCM as well as related utilities newstart star
31. deftank directory are for various configurations e g model resolution planet type copy and eventually rename these files to match the generic names to the directory where you will run the model Copy initial condition files start nc and startfi nc described in section 7 2 to the same directory You can extract such files from start archive banks of initial states i e files which con tain collections of initial states from stndard scenarios and which can thus be used to check if the model is installed correctly stored on the LMD website at http www lmd jussieu fr forget datagcm Starts See section 5 9 for a description of how to proceed to extract start files from start archives NOTE WITH THE GENERIC MODEL WE ALMOST ALWAYS START FROM startplanet FILES 5 5 Running the model Once you have the program gcm e input files start nc startfi nc and parameter files run def callphys def gases def traceur def and z2sig def in the same directory sim ply execute the program to run a simulation 22 Creation of the initial state start archive nc run def callphys def Z2sig def surface nc V start nc startfi nc run def callphys def Z2sig def Simulation 1 diagfine L restart nc restartfi nc stats nc nne L EX run def Simulation 2 0 GCM ou allphys def a NC 7 Z2sig def Figure 5 1 Input outpu
32. des the new dynamic code Imdz3 3 and input and output data in NetCDF format The physical part includes generalized correlated k radiative transfer generalized tracer transport and a water cycle that includes water vapour and ice transport radiative and thermodynamic effects and simple hydrology Chapter 2 of this document to be read before any of the others describes the main features of the model The model is divided into two relatively independent parts 1 The hydrodynamic code which integrates the fluid mechanical primitive equations in time over the globe and 2 the physical parameterizations which include the radiative transfer tracer transport evolution and surface atmosphere interaction It is followed by a list of references for anyone requiring a detailed description of the physics and the numerical formulation of the parameterizations Chapter 4 For your first contact with the model Chapter 5 guides the user through a practice simulation choosing the initial states and parameters and visualizing the output files The document then describes the code used for the model including a user computer manual for compiling and running it Chapter 6 Chapter 7 describes the input output data of the model The input files are the files needed to initialize the model state of the atmosphere at instant 0 as well as a dataset of boundary conditions The output files are historical files archives of the atmospheric flow history a
33. din Laboratoire de M t orologie Dynamique to be translated when I get the time Le mod le climatique du LMD est b ti comme tous les mod les de circulation g n rale atmosph rique sur la r solution num rique des quations primitives de la m t orologie d crites dans de nombreux ouvrages L analyse pr sent e ici a t men e sur la nouvelle version de la dynamique du LMD crite par Phu Le Van sur une formulation de Robert Sadourny Cette formulation diff re de l ancienne essentiellement par deux points dans la nouvelle formulation la r partition des points en longitude et en latitude peut tre chang e arbitrairement L autre modification porte sur la r partition des points aux p les La coordonn e verticale du mod le est la pression normalis e par sa valeur la surface c p p On utilise en fait aux niveaux inter couches et s c au milieu des couches On note X et Y les coordonn es horizontales X resp Y est une fonction biunivoque de la longitude resp de la latitude 4 Ces deux fonctions peuvent tre choisies de facon arbitraire dans le mod le LMDZ ce qui permet d effectuer un zoom sur une r gion du globe particuli re Une grille de ce type est montr e sur la Figure 3 1 Les variables scalaires temp rature potentielle 0 c T p g opotentiel et pression de surface ps sont valu es aux points correspondant des couples de valeurs enti res X Y i j Les variables dynamiq
34. dpoints together was necessary to avoid numerical instability In practice the following technique is used in the subroutine called groupeun F e The points are grouped in packets of 2 8 P at the poles e g ngroup 3 packets of 8 then gngroup 1 gngroup 2 etc in the lower latitudes moving away from the pole e The higher ngroup is the more efficient the smoothing is and the more stable the model e BUT iim must be divisible by 2 TOUP 11 3 3 Dissipation Extract adapted from Forget et al 1999 14 In the LMD grid point model nonlinear interactions between explicitly resolved scales and subgrid scale processes are parameterized by applying a scale selective horizontal dis sipation operator based on an n time iterated Laplacian A For the grid point model for instance this can be written 0q 0t 1 rai 0x A q where dx is the smallest horizontal distance represented in the model and 7yiss is the dissipation timescale for a st ructure of scale dx These operators are necessary to ensure the grid point model numerical stability In practice the operator is separately applied to 1 potential temperature 2 the divergence of the flow and 3 its vorticity We respectively use n 2 n 1 and n 2 in the grid point model Note In practice values of n and irs are adjustable and prescribed at the beginning of each run in run definition file run def cf 7 2 1 3 4 Sponge layer Extract adapte
35. e true for hybrid and false for sigma levels hybrid false autocompute vertical discretisation useful for exoplanet runs autozlevs false o pressure ceiling pceil 40 0 Initial atmospheric temperature profile Type of initial temperature profile ichoice 1 Constant Temperature T tref ichoice 2 Savidjari profile as Seiff but with dT dz cte ichoice 3 Lindner polar profile ichoice 4 inversion ichoice 5 Seiff standard profile based on Viking entry ichoice 6 constant T gaussian perturbation levels ichoice 7 constant T gaussian perturbation km ichoice 8 Read in an ascii file profile ichoice 5 Reference temperature tref K tref 200 Add a perturbation to profile if isin 1 isin 0 55 peak of gaussian perturbation for ichoice 6 or 7 pic 26 522 width of the gaussian perturbation for ichoice 6 or 7 largeur 10 height of the gaussian perturbation for ichoice 6 or 7 hauteur 30 some definitions for the physics in file callphys def INCLUDEDEF callphys def Note that just as for the 3D GCM run def file input parameters may be given in any order or even not given at all in which case default values are used by the program 9 3 Output data During the entire 1D simulation you can obtain output data for any variable from any phys ical subroutine by using subroutine writegld This subroutine creates file gld nc that can be read by GRADS This subroutine is
36. e tau abs 825 cm 1 tauTES units float h20o ice s Time latitude longitude h20 ice s title surface h2o ice h20 ice s units kg m 2 The structure of the file is thus as follows the dimensions variable time containing the time of the timestep stored in the file in Martian days since the beginning of the run variable control containing many parameters as described above from rhonu to phisinit a list of data describing the geometrical coordinates of the data file plus the surface topography finally all the 2D or 3D data stored in the run 7 3 3 Stats files As an option stats must be set to true in callphys def the model can accu mulate any variable from any subroutine of the physics by calling subroutine wstat This save is performed at regular intervals 12 times a day An average of the daily evo lutions over the whole run is calculated for example for a 10 day run the averages of the variable values at OhTU 2hTU 4hTU 24hTU are calculated along with RMS standard deviations of the variables This ouput is given in file stats nc Illustrative example of the contents of a stats nc file using ncdump ncdump h stats nc netcdf stats dimensions 47 latitude 49 longitude 65 altitude 25 limpl 26 Time UNLIMITED 12 currently variables float Time Time Time title Time Time units days since 0000 00 0 00 00 00 floa
37. e number of tracers YY is the number of scatterers that will be taken into account in the radiative code and IRxVI is the number of spectral bands in the thermal emission and stellar part of the radiative code The option debug is available with most compilers The code runs much more slowly but can output more user friendly bug report messages Example 1 Compiling the generic model at grid resolution 64x48x20 for example type in compliance with the manual for the makegcm function given in section 6 4 makegcm d 64x48x20 p std gcm You can find executable gem e the compiled model in the directory where you ran the makegcm command Example 2 Compiling the generic model with 2 tracers e g water vapour and ice to simulate the water cycle makegcm d 32x32x20 t 2 p std gcm Example 3 Compiling the the generic model to check for and trace errors with ifort compiler useful for debugging warning the model then runs very slowly makegcm d 32x32x20 p std O g fpe0 traceback gcm 5 4 Input files initial states and def files In directory LMDZ GENERIC deftank you will find some examples of run parameter files def files which the model needs at runtime The four files the model requires they must be in the same directory as the executable gcm e are run def described in section 7 2 callphys def see section 7 2 2 gases def z2sig def and traceur def The example def files given in the
38. e thermal conduction soil Thesis of Fr d ric Hourdin LMD Universit Paris 7 1992 section 3 3 equations and Appendix A Numerical scheme 4 5 CO Condensation In Forget et al 1998 article published in Icarus Numerical method for calculating the condensation and sublimation levels at the surface and in the atmosphere newcondens explained in the appendix Description of the numerical scheme for calculating the evolution of CO snow emissivity co2snow explained in section 4 1 4 6 Tracer transport and sources e Van Leer transport scheme used in the dynamical part tracvl and vlsplt in the dynamical part Hourdin and Armengaud 1999 17 e Transport by turbulent diffusion in vdifc convection in convadj sedi mentation sedim dust lifting by winds dust lift see note Preliminary design of dust lifting and transport in the Model ESA contract Work Package 4 1998 available on the web e Watercycle see Montmessin et al 2004 18 Chapter 5 Running the model a practice simulation This chapter is meant for first time users of the LMD model As the best introduction to the model is surely to run a simulation here we explain how to go about it All you will need are files necessary to build the GCM all are in the LMDZ GENERIC directory as well as some initial states to initiate simulations see below Once you have followed the example given below you can then go on to cha
39. e to the first stored value ga query dims indicates the fixed values for the 4 dimensions Shortcut q dims ga display temp displays the temperature card for the 5th layer and for the first time value stored Shortcut d T ga clear clears the display Shortcut c ga set gxout shaded nota contour plot but a shaded one ga display temp ga set gxout contour returns to contour mode to display the levels ga display temp superimposes the contours if the clear command is not used 24 5 7 Resuming a simulation At the end of a simulation the model generates restart files files restart nc and restartfi nc which contain the final state of the model As shown in figure 5 1 these files which are of the same format as the start files can later be used as initial states for a new simulation The restart files just need to be renamed mv restart nc start nc mv restartfi nc startfi nc and running a simulation with these will in fact resume the simulation from where the previous run ended 5 8 Chain simulations In practice we recommend running a chain of simulations lasting several days or longer or hundreds of days at low resolution To do this a script named run0O is available in LMDZ GENERIC deftank which should be used as follows e Set the length of each simulation in run def i e set the value of nday e Set the maximum number of simulations at the beginning of the run0
40. efficients afterward These scripts require three environment variables to be defined DWORK DIR KSPEC DIR and BANDS DIR In the following example we create a database with a mixed CO H5O atmosphere where CO is the dominant gas First the three environment variables are set as DWORK DIR san home rdword corrk data CO2 H20var KSPEC DIR san home rdword kspectrum kspec 1 BANDS DIR 32x36 We then create a directory that includes files Q dat p dat and T dat to define the number of gaseous species and pressure and temperature gridpoints For each file the first number gives the number of points species See the folder corrk example in utilities for the example we will describe here Typing prekspectrum results in the following prompt Name of atmosphere planet The planet name is for reference only and does not affect the results After this the values of the temperature pressure and variable gas H20 grids are displayed and you are asked for the CO2 mixing ratio 59 Correlated k temperature grid 1 100 0 K 2 150 0 K 3 200 0 K 4 250 0 K 5 300 0 K 6 350 0 K 7 400 0 K Correlated k pressure grid mBar 14 x 10 3 mBar 2 x 10 2 mBar 3 x 10 1 mBar 4 x 10 0 mBar 55 x 10 1 mBar 6 x 10 2 mBar Ta x 10 3 mBar 8 x 10 4 mBar 9 x 10 5 mBar nmolec 2 Temperature layers 7 Pressure layers 9 ixing ratio layers 7 Total 441 Please enter vmr o
41. entiel au sol Time Time Time title Temps de simulation Time units days since 1 01 01 00 00 00 ucov Time altitude latitude rlonu ucov title Vitesse U vcov Time altitude rlatv longitude vcov title Vitesse V teta Time altitude latitude longitude teta title Temperature h2o_ice Time altitude latitude longitude h20_ice title Traceur h2o ice h2o_vap Time altitude latitude longitude h2o_vap title Traceur h2o vap masse Time altitude latitude longitude masse title C est quoi ps Time latitude longitude ps title Pression au sol global attributes title Dynamic start file List of contents of a startfi nc file ncdump h startfi nc netcdf startfi dimensions index 100 physical points 738 subsurface layers 18 nlayer plus 1 19 number of advected fields 3 variables float controle index controle title Control parameters float soildepth subsurface layers soildepth title Soil mid layer depth float longitude physical points longitude title Longitudes of physics grid float latitude physical points latitude title Latitudes of physics grid float area physical points area title Mesh area float phisfi physical points phisfi title Geopotential at the surface float albedodat physical points albedodat title Albedo of bare ground float ZMEA physical points ZME
42. erature surface pressure winds and tracer concentrations In practice the formulation selected to solve the equations in the dynamics is optimised using the following less natural variables potential temperature 0 teta in the code linked to temperature T by 0 T P Pref with x R C note that is called kappa in the dynamical code and rcp in the physical code We take Pref 610 Pa on Mars surface pressure ps in the code mass the atmosphere mass in each grid box masse in the code the covariant meridional and zonal winds ucov and vcov These variables are linked to the natural winds by ucov cu x uandvcov cv x v where cu and cv are constants that only depend on the latitude mixing ratio of tracers in the atmosphere typically expressed in kg kg array q in the code ucov and vcov vectorial variables are stored on scalari grids u and v respec tively in the dynamics see section 2 2 teta q ps masse scalar variables are stored on the scalar grid of the dynamics 2 4 2 Physical variables In the physics the state variables of the dynamics are transmitted via an interface that interpolates the winds on the scalar grid that corresponds to the physical grid and trans forms the dynamical variables into more natural variables Thus we have winds u and v m s 1 temperature T K pressure at the middle of the layers play Pa and at interlayers plev Pa tracers q
43. etc kg kg on the same grid Furthermore the physics also handle the evolution of the purely physical state variables tsurf surface temperature K tsoil temperature at different layers under the surface K emis surface emissivity alb surface albedo q2 wind variance or more precisely the square root of the turbulent kinetic energy qsurf tracer on the surface kg m rnat surface type 0 ocean 1 continent beta surface wetness 0 1 implies dry saturated anything else 2 4 3 Tracers The model may include different types of tracers condensed species e g CO2 H20 dust chemically active species in principle only at the moment radiatively active gases e g water vapor In the code all tracers are stored in one three dimensional array q the third index of which corresponds to each individual tracer In input and output files start nc startfi nc see Section 5 tracers are stored separately using their individual names Loading specific tracers requires that the approriate tracer names are set in the traceur def file see Sec tion 7 2 3 and specific computations for given tracers e g computing the water or CO2 cycles is controlled by setting the corresponding options in the callphys def file see Section 7 2 2 10 Chapter 3 3D Dynamical Code 3 1 Discretisation of the dynamical equations Extrait de la note de Robert Sadourny Phu Le Van et Fr d ric Hour
44. eterized phenomena 2 2 Dynamical Physical separation In practice the 3D model operates in two parts a dynamical part containing the numerical solution of the general equations for atmo spheric circulation This part including the programming is common to all terrestrial type atmospheres and applicable in certain cases to the upper atmospheres of gas giant planets a physical part that is specific to the planet in question and which calculates the circula tion forcing and climatic details at each point The calculations for the dynamical part are made on a 3D grid with horizontal ex changes between the grid boxes whereas the physical part can be seen as a juxtaposition of atmosphere columns that do not interact with each other see diagram 2 1 The dynamical and physical parts deal with variables of different natures and operate on grids that are differently constructed The temporal integration of the variables is based on different numerical schemes simple such as the one above for the physical part and more complicated the Matsuno Leapfrog scheme for the dynamical part The timesteps are also different The physical timestep is iphysiq times longer than the dynamical Dynamics Physics Dynamical tendencies TG TG gl ae Tendencies due to radiative transfer condensation subgrid dynamics Physical fields Figure 2 1 Physical dynamical
45. f CO2 We chose 1 0 as there are no other gases the mixing ratio is automatically changed to take into account the variable gas After prekspect rum exits we can view the resulting composition in file stored in the data directory of kspect rum Atmospheric composition input data file for planet Zarmina Number of atmospheric levels 441 Number of molecules 2 z km P atm T K x CO2 x H20 0 000000000E 00 0 986923267E 06 0 100E 03 0 99999E 00 0 10000E 06 0 000000000E 00 0 986923267E 06 0 150E 03 0 99999E 00 0 10000E 06 0 000000000E 00 0 986923267E 06 0 200E 03 0 99999E 00 0 10000E 06 Typing run kspectrumin the kspect rum directory then submits the process as a batch job Beware calculating LBL coefficients for multiple gases and several hundred p T values can take several weeks at current processing speeds 11 2 Performing the correlated k conversion Once the LBL data is calculated it s time to convert it to correlated k format We do this using a program generate kmatrix F90 which is also stored in the utilities folder and is called by post kspect rum In addition to the data generated by kspect rum and the original dat files it requires definition of the spectral bands to be used in the GCM In this example we use a folder 32x36 containing files narrowbands_VI in and narrowbands IR in These files define the number and widths all all bands in the 60 visible and infrared respectively
46. fault built in value Additionally one may use a specific keyword INCLUDEDEF to specify another text file in which to also read values of parameters e g INCLUDEDEF callphys def Here are some details about some of the parameters which may be set in run def e day step the number of dynamical steps per day to use for the time integration This needs to be large enough for the model to remain stable this is related to the CFL sta bility criterion which essentially depends on the horizontal resolution of the model On Mars in theory the GCM can run with day step 480 using the 64x48 grid but model stability improves when this number is higher day st ep 960 is recom mended when using the 64x48 grid According to the CFL criterion day_step should vary in proportion with the resolution for example day_step 480 using the 32x24 horizontal resolution Note that day step must also be divisible by iperiod For other planets FINISH e tetagdiv tetagrot tetatemp control the dissipation intensity It is better to limit the dissipation intensity tetagdiv tetagrot tetatemp should not be too low However the model diverges if tetagdiv tetagrot tetatemp are too high especially if there is a lot of dust in the atmosphere Example used with nitergdiv 1 and nitergrot niterh 2 using the 32x24 grid tetagdiv 6000 s tetagrot tetatemp 30000 s using the 64x 48 grid tetagdiv 3000 s tetagrot tetatemp 9000 s e idissip is
47. interface timestep as the solution of the dynamic equations requires a shorter timestep than the forced calculation for the physical part In practice the main program that handles the whole model gcm F is located in the dynamical part When the temporal evolution is being calculated at each timestep the program calls the following 1 Call to the subroutine that handles the total tendency calculation 2X arising from t the dynamical part caldyn F 2 Integration of these dynamical tendencies to calculate the evolution of the variables at the following timesteps subroutine integrd F 3 Every iphysig dynamical timestep a call to the interface subroutine calfis F with the physical model physiq F90 that calculates the evolution of some of the purely physical variables e g surface temperature t surf and returns the tenden Ox cies 57 arising from the physical part 4 Integration of the physical variables subroutine addfi F 5 Similarly calculation and integration of tendencies due to the horizontal dissipation and the sponge layer is done every idissip dynamical time step Remark The physical part can be run separately for a 1 D calculation for a single column using program xcmld F 2 3 Grid boxes Examples of typical grid values are 64x48x25 64x48x32 or 32x24x25 in longitudexlati tudexaltitude Grid box size depends on the planetary radius for Mars radius 3400 km for example a 64x48 horizonta
48. ires the input of two initialization files in NetCDF for mat start nc contains the initial states of the dynamical variables startfi nc contains the initial states of the physical variables Note that collections of initial states can be retreived at http www lmd jussieu fr forget datagcom Starts Extracting start nc and startfi nc from these archived requires using program newstart as described in section 5 9 To run the GCM also requires the four following parameter files ascii text files run def the parameters of the dynamical part of the program and the temporal integration of the model callphys def the parameters for calling the physical part traceur def the names of the tracer to use Z2sig def the vertical distribution of the atmospheric layers Examples of these parameter files can be found in the LMDZ MARS deftank directory 34 7 2 1 run def A typical run def file is given as an example below The choice of variables to be set is simple e g nday number of modeled days to run while the others do not need to be changed for normal use The format of the run def file is quite straightforward and flexible values given to parameters must be given as parameter value Any blank line or line beginning with symbol is a comment and instruction lines may be written in any order Moreover not specifying a parameter value set e g deleting it or commenting it out means you want the GCM to use a de
49. ith the LMD Generic Model e In callphys def set tracer to true tracer true In the radiative trans fer sub section chose an appropriate correlated k database that includes the effect of water vapour e g corrkdir CO2H20var and set varactive true varfixed false Inthe water cycle sub section you can chose various pa rameters see below for a standard example Orbit general options K Run with or without tracer transport 7 tracer s ETUS Diurnal cycle if diurnal false diurnally averaged solar heating diurnal true Seasonal cycle if season false Ls stays constant to value set in start season true Tidally resonant orbit must have diurnal false correct rotation rate in newstart tlocked false Tidal resonance ratio ratio T_orbit to T_rotation nres 10 Write some more output on the screen lwrite false Save statistics in file stats nc callstats true Test energy conservation of model physics enertest true Radiative transfer options i a PSE ERR E ee call radiative transfer callrad true the rad transfer is computed every iradia physical timestep iradia 4 call multilayer correlated k radiative transfer corrk true folder in which correlated k data is stored corrkdir CO2 H20var call visible gaseous absorption in radiative transfer callgasvis true Include Rayleigh scattering in the visible rayleigh true Characteristic planetary e
50. km hsponge 90 Sponge tetasponge secondes tetasponge 50000 some definitions for the physics in file callphys def INCLUDEDEF callphys def 7 2 2 callphys def The callphys def file along the same format as the run def file contains parame ter value sets for the physics Example of callphys def file Orbit general options pape PETI ELLO LO edi RTE T Run with or without tracer transport tracer true Diurnal cycle if diurnal false diurnally averaged solar heating diurnal true Seasonal cycle if season false Ls stays constant to value set in start season true Tidally resonant orbit must have diurnal false correct rotation rate in newstart tlocked false Tidal resonance ratio ratio T_orbit to T_rotation nres 10 Write some more output on the screen lwrite false Save statistics in file stats nc callstats true Test energy conservation of model physics enertest true 37 Radiative transfer options dd 7777707707707 0707070070070 070007007 call radiative transfer callrad true the rad transfer is computed every iradia physical timestep iradia 4 call multilayer correlated k radiative transfer corrk gt Crue folder in which correlated k data is stored corrkdir CO2 H20var call visible gaseous absorption in radiative transfer callgasvis true Include Rayleigh scattering in the visible
51. l grid corresponds to grid boxes of the order of 330x220 kilometers near the equator 2 3 1 Horizontal grids Dynamics and physics use different grids Figure 2 2 shows the correspondence and in dexing of the physical and dynamical grids as well as the different locations of variables on these grids To identify the coordinates of a variable at one grid point up down right or left we use coordinates rlonu rlatu rlonv rlatv longitudes and latitudes in radians e grille scalaire de la dynamique Exemple IM 6 JM 4 grille physique IM IM 1 99 1 2 3 4 5 6 H 1 2 3 JM 4 JM 1 5 1 e O e u u u u u u u Vi VL VL VL vi VL VL 2 3 4 SHE 6 7 e g i g L O e u u U Ge u u u u Vi Vi Vil V VL VL Vi 8 9 1 1 I I g T g T e T ii T ial T O u L u Vi Vi Vil VL VL VL VL va 1 1 IE 1 I 5 e T e m 9j m e u e u e u vi vi vi vL vL v v lt rlaty 20 e e e e e e e lt atc u u u u u U U 7 A e boite grille scalaire rlonv TY D rlonu 1 IM 1 rlonu Tj rlonv 1 IM 1 e e e rlatu 1 JM 1 u i 1 j u i j rlatv 1 J
52. lcapa soil volumetric heat capacity 45 7 3 Output files 7 3 1 NetCDF restart files restart nc and restartfi nc These files are of the exact same format as start nc and startfi nc 7 3 2 NetCDF file diagfi nc NetCDF file diagfi nc stores the instantaneous physical variables throughout the sim ulation at regular intervals set by the value of parameter ecritphy in parameter file run def note that ecritphy should be a multiple of iphysiq as well as a divisor of day step Any variable from any sub routine of the physics can be stored by calling subroutine writediagfi Illustrative example of the contents of a diagfi nc file using ncdump ncdump h diagfi nc netcdf diagfi dimensions Time UNLIMITED 12 currently index 100 rlonu 65 latitude 49 longitude 65 rlatv 48 interlayer 26 altitude 25 subsurface layers 18 variables float Time Time Time long name Time Time units days since 0000 00 0 00 00 00 float controle index controle title Control parameters float rlonu rlonu rlonu title Longitudes at u nodes float latitude latitude latitude units degrees north latitude long name North latitude float longitude longitude longitude long name East longitude longitude units degrees east float altitude altitude altitude long name pseudo alt altitude units km altitude positive up float rlatv rlatv rlatv title
53. mpiled followed by the tracer names one per line Note that if the corresponding tracers are not found in input files start nc and startfi no then the tracer is initialized to zero Example of a traceur def file with water vapour and ice tracers 2 h2o_ice h2o_vap 7 2 4 z2sig def The z2sig def file contains the pseudo altitudes in km at which the user wants to set the vertical levels Note that levels should be unevenly spread with a higher resolution near the surface in or der to capture the rapid variations of variables there It is recommended to use the altitude 39 levels as set in the z2sig def file provided in the de tank directory Example of z2sig def file 10 00000 H atmospheric scale height km used as a reference only 0040 Typical pseudo altitude m for lst layer z H xlog sigma 018 NP on Apt Py p Myr rr rk au 2nd Mayer EGL 0400 1000 228200 460400 907000 73630 19040 54010 97780 13 5138 18 9666 25 0626 31 5527 38 4369 45 4369 52 4369 GH LT P 7 2 5 Initialization files start and startfi Files start nc and startfi nc like all the NetCDF files of the GCM are constructed on the same model see NetCDF file composition figure 7 2 They contain a header with a control variable followed by a series of variables defining the physical and dynamical grids a series of non temporal variables that give information a
54. nge the control parameters and the initial states as you wish A more detailed description of the model s organization as well as associated inputs and outputs are given in sections 6 and 7 5 1 Installing the model from SVN The first thing is to download the model from our SVN server If you cannot use SVN just find an old school way to get a copy of the basic model directory LMDZ GENERIC and all the other source files needed for visualization and download it to your account Then start directly from the fifth point e Go to the directory where you want to download the model Not that only one directory the root directory will be added in the current directory e If svn is installed on your system set up the root directory by tipping svn co http svn lmd jussieu fr Planeto trunk N Name of root directory cd Name of root directory e You can now download one of the LMDZ models for Generic Mars Venus Titan by tipping svn update LMDZ MODEL YOU WANT For the Generic model just tipe svn update LMDZ GNERIC The contents of the directory that has been created are described in Chapter 6 e For visualization of the simulations yo will need some utilities that we might as well download now by doing 19 svn update UTIL e Now we must set up the makegcm script that will perform the compilation of the model Go into the LMDZ GENERIC directory and edit the appropriate makegcm_mycompiler
55. o that the compilation script makegcm is available from anywhere more convinient than having to type the full path to the script or copying it over where you want to run it The makegcm script is in the LMDZ GENERIC directory which is referenced by the LMDGCM variable so If using Csh alias makegcm LMDGCM makegcm if using Bash alias makegcm LMDGCM makegcm 5 3 Compiling the model Two options exist to compile the model 1 Create an alias so that the compilation script makegcm is available from anywhere If using Csh alias makegcm path to LMDZ GENERIC makegcm if using Bash alias makegcm path to LMDZ GENERIC makegom Then the compilation is done by tipping makegcm options gcm This solution can be convenient but is less flexible if you want to compile the model in many different configurations and keep track of it 2 Create and edit an executable script that we will call compile in the directory where you will want to run the model Put the line path to the model I use makegcm options gcm 21 The advantage of this option is that the compile is present in all of the working directories where the model is ran allowing you to keep track of the options used Just remains to choose the options The basic options are as follows makegcm d LONxLATXALT p std t XX s YY b IRxVI gcm where LONxLATxALT are the number of grid cells in longitude latitude and altitude XX is th
56. ompilation of the preceding article with a few additions that were published separately 4 2 Radiative transfer The radiative transfer parameterizations are used to calculate the heating and cooling ratios in the atmosphere and the radiative flux at the surface TO WRITE IMPORTANT SECTION REFERENCES HERE ARE FOR MARS ONLY 4 2 1 Absorption emission and diffusion by dust Dust spatial distribution dustopacity e Vertical distribution and description of MGS and Viking scenarios in the ESA re port Mars Climate Database V3 0 Detailed Design Document by Lewis et al 2001 available on the web e For the MY24 scenario dust distribution obtained from assimilation of TES data is used and read via the readtesassim routine 16 Thermal IR radiation lwmain e Numerical method Toon et al 1989 e Optical properties of dust Forget 1998 Solar radiation swmain e Numerical method Fouquart and Bonel 1980 e Optical properties of dust see the discussion in Forget et al 1999 which quotes Ockert Bell et al 1997 and Clancy and Lee 1991 4 3 Subgrid atmospheric dynamical processes 4 3 1 Turbulent diffusion in the upper layer vdifc e Implicit numerical scheme in the vertical see the thesis of Laurent Li LMD Uni versit Paris 7 1990 Appendix C2 e Calculation of the turbulent diffusion coefficients Forget et al 1999 4 3 2 Convection convadj See Hourdin et al 1993 4 4 Surfac
57. on q2 sd units m2 s 2 vmr h2ovapor Time altitude latitude longitude vmr_h2ovapor title H20 vapor volume mixing ratio vmr h2ovapor units mol mol vmr h2ovapor sd Time altitude latitude longitude vmr_h2ovapor_sd title H20 vapor volume mixing ratio total sta n over the season vmr h2ovapor sd units mol mol vmr_h2oice Time altitude latitude longitude vmr_h2oice title H20 ice volume mixing ratio vmr h20ice units mol mol vmr h20ice sd Time altitude latitude longitude 49 vmr h20ice sd title H20 ice volume mixing ratio total standar d deviation over the season vmr h20ice sd units mol mol float mtot Time latitude longitude mtot title total mass of water vapor mtot units kg m2 float mtot sd Time latitude longitude mtot sd title total mass of water vapor total standard deviat ion over the season mtot sd units kg m2 float icetot Time latitude longitude icetot title total mass of water ice icetot units kg m2 float icetot sd Time latitude longitude icetot sd title total mass of water ice total standard deviat ion over the season icetot sd units kg m2 The structure of the file is simillar to the diagfi noc file except that as stated before the average of variables are given for 12 times of the day and that RMS standard deviation are also provided 50 Chapter 8 Water Cycle Simulation To simulate the water cycle w
58. on in latitude more means sharper transition 10 2 Making a zoomed initial state One must start from an initial state archive start archive nc obtained from a previ ous simulation see section 5 9 Then compile and run newstart e using the run def file designed for the zoom After running newstart e The zoomed grid may be visualized using grads for instance Here is a grads script that can be used to map the grid above a topography map 57 set mpdraw off set grid off sdfopen restart nc set gxout grid set digsiz 0 set lon 180 180 d ps close 1 replace the path to surface nc in the following line sdfopen u forget WWW datagcm datafile surface nc set lon 180 180 set gxout contour set clab off set cint 3 d zMOL 10 3 Running a zoomed simulation and stability issue e dynamical timestep Because of their higher resolution zoomed simulation requires a higher timestep Therefore in run def the number of dynamical timestep per day day step must be increased by more than grossismx or grossismy twice that if necessary However you can keep the same physical timestep 48 sol and thus increase iphysiq accordingly iphysiq day step 48 e It has been found that when zooming in longitude on must set ngroup 1 in dyn3d groupeun F Otherwise the run is less stable e The very first initial state made with newstart e can be noisy and dynamically unstable It may be necessary to strongly increase the intensity of
59. ons de l operateur de dissipation divgrad niterh 2 temps de dissipation des plus petites long d ondes pour u v gradiv tetagdiv 10000 temps de dissipation des plus petites long d ondes pour u v nxgradrot tetagrot 10000 temps de dissipation des plus petites long d ondes pour h divgrad tetatemp 10000 coefficient pour gamdissip coefdis 0 choix du shema d integration temporelle Matsuno ou Matsuno leapfrog purmats false avec ou sans physique physic true periode de la physique en pas iphysiq 20 choix d une grille reguliere grireg true frequence en pas de l ecriture du fichier diagfi ecritphy 1920 longitude en degres du centre du zoom clon 63 latitude en degres du centre du zoom clat 0 facteur de grossissement du zoom selon longitude grossismx 1 36 facteur de grossissement du zoom selon latitude grossismy l Fonction f y hyperbolique si true sinon sinusoidale fxyhypb false extension en longitude de la zone du zoom fraction de la zone totale dzoomx 0 extension en latitude de la zone du zoom fraction de la zone totale dzoomy 0 raideur du zoom en X taux 2 raideur du zoom en Y tauy 2 Fonction f y avec y Sin latit si TRUE Sinon y latit ysinus false Avec sponge layer callsponge true Sponge mode0O u v 0 model u umoy v 0 mode2 u umoy v vmoy mode_sponge 2 Sponge hauteur de sponge
60. ored on the scalar grid of the dynamical part For the physics co2ice surface dry ice tsurf surface temperature tsoil temperatures at different layers under the surface emis surface emissivity q2 wind variance or more precisely the square root of the turbulent kinetic energy the surface tracer budget kg m All these variables are stored on the physical grid see section 2 2 The control array Both physical and dynamical headers of the GCM NetCDF files start with a controle variable This variable is an array of 100 reals the vector called tab_cntr1 in the program which contains the program control parameters Parameters differ between the physical and dynamical sections and examples of both are listed below The contents of table tab cntr1 can also be checked with the command ncdump ff v controle The control array in the header of a dynamical NetCDF file start tab cntrl 1 FLOAT iim number of nodes along longitude tab cntrl1 2 FLOAT jjm number of nodes along latitude tab cntrl 3 FLOAT llm number of atmospheric layers tab cntrl 4 FLOAT idayref initial day tab cntrl 5 rad radius of the planet tab cntrl 6 omeg rotation of the planet rad s tab cntrl 7 g gravity m s2 3 72 for Mars tab cntrl1 8 cpp tab cntrl 9 kappa r cp tab cntrl1 10 daysec lenght of a sol s 88775 tab cntrl 11 dtvr dynamical time step s tab cn
61. p llm 1 0 KCkckckckckckckckckckckckckckckckckckckckckckckckck kk p ev nlayer 1 0 aps llm bps 11m Da ELIS Pr fet sets St sia nlayer play nlayer ap llm bp 11m FORK ROK RK kK plev nlayer aps llm 1 bps llm 1 2s MEL e iie nlayer 1 play nlayer 1 ap llm 1 bp llm 1 Ck kck ck ck ck IKK RK KKK KKK plev unlayer 1 aps 2 bps 2 ERAN L quede ren 2 play 2 ap 2 bp 2 Ek kckck KR OK KKK KKK KKK plev 2 aps 1 bps 1 suec lex b DpDPd 1 play 1 ap 1 1 bp 1 0 o eee surface x plev 1 Ps Figure 2 4 Vertical grid description of the 11m or nlayer atmospheric layers in the programming code 11m is the variable used in the dynamical part and nlayer is used in the physical part Variables ap bp and aps bps indicate the hybrid levels at the interlayer levels and at middle of the layers respectively Pressure at the interlayer is Plev l ap l bp l x Ps and pressure in the middle of the layer is defined by Play l aps l bps l x Ps where Ps is surface pressure Sigma coordinates are merely a specific case of hybrid coordinates such that aps 0 and bps P Ps Note that for the hybrid coordinates bps 0 above 50 km leading to purely pressure levels The user can choose whether to run the model using hybrid coordinates or not by setting variable hybrid in run def to True or False 2 4 Variables used in the model 2 4 1 Dynamical variables The dynamical state variables are the atmospheric temp
62. quilibrium black body temperature This is used only in the aerosol radiative transfer setup see aerave F tplanet 215 Output spectral OLR in 1D 3D specOLR false Output global radiative balance in file rad bal out slow for 1D 51 meanOLR true Variable gas species varactive true Variable gas species varfixed false Variable gas species Radiatively active Fixed vertical distribution Saturation percentage value at ground satval 0 0 Star type The choices are startype 1 Sol G2V class main sequence startype 2 Ad Leo M class synthetic startype 3 GJ644 startype 4 HD128167 Stellar flux at 1 AU Examples 1366 0 W m 2 Sol today 1024 5 W m 2 Sol today x 0 75 weak early Sun 18 462 W m 2 The feeble G1581 19 960 W m 2 G1581 with e 0 38 orbital average FatlAU 1024 5 Tracer and aerosol options Gravitational sedimentation of tracers sedimentation false just H20 ice for now Other physics options E call turbulent vertical diffusion calldifv true call convective adjustment calladj true call thermal conduction in the soil callsoil true HEHEHE AE FE FE E EEE HEE HEE EEE FE FE FE EEE EEE ERE EHH HE EE EE EEE EEE HE EERE BRE extra non standard definitions for Early Mars Hae aE AE HE FE FE a A E E EE EH EE FE aE EE EE EEE aE FE aE EEE FE FE FE EEE EEE EE EEE EE EH HH Tracer and aerosol options Fixed aerosol distributions
63. re total standard deviatio n over the season float float er the season float float tion over the float float temp sd units K u Time altitude latitude longitude u title Zonal East West wind u units m s 1 u sd Time altitude latitude longitude u sd title Zonal East West wind total standard deviation ov u sd units m s 1 v Time altitude latitude longitude vititle Meridional North South wind v units m s 1 v sd Time altitude latitude longitude v Sd title Meridional North South wind total standard devia season v Sd units m s 1 w Time altitude latitude longitude w title Vertical down up wind w units m s 1 w sd Time altitude latitude longitude w Sd title Vertical down up wind total standard deviation o ver the season float float r the season float float deviation ove float float ndard deviatio float float w Sd units m s 1 rho Time altitude latitude longitude rho title Atmospheric density rho units none rho sd Time altitude latitude longitude rho sd title Atmospheric density total standard deviation ove rho sd units none q2 Time altitude latitude longitude q2 title Boundary layer eddy kinetic energy q2 units m2 s 2 q2 sd Time altitude latitude longitude q2 sd title Boundary layer eddy kinetic energy total standard r the seas
64. s simulated by the model the diagfi files the stats files the daily aver ages and so on Common ways of editing or visualizing these files editor ncdump and the graphics software grads are also explained Chapter 8 explains how to run a simula tion that includes the water cycle Finally Chapter 9 will help you to use a 1 dimensional version of the model which may be a simpler tool for some analysis work Chapter 2 Main features of the model 2 1 Basic principles The General Circulation Model GCM calculates the temporal evolution of the different variables listed below that control or describe the planetary meteorology and climate at different points of a 3D grid see below that covers the entire atmosphere From an initial state the model calculates the evolution of these variables timestep by timestep e At instant t we know variable X temperature for example at one point in the atmosphere e We calculate the evolution the tendencies 9 etc arising from each physical phenomenon calculated by a parameterization of each of these phe nomenon for example heating due to absorption of solar radiation e At the next time step t t we can calculate X 5 from X and 2x This is the integration of the variables in time For example X 5 X t ox t 2 5 The main task of the model is to calculate these tendencies 23 arising from the t different param
65. sport and sources Running the model a practice simulation 5 1 Installing the model from SVN 5 2 Installing the model without SVN 5 3 Compiling the model 5 4 Input files initial states and def files 5 5 Running the model 5 6 Visualizing the output files 5 6 1 Using GrAds to visualize outputs 5 7 Resuming a simulation 5 8 Chain simulations 5 9 Creating and modifying initial states 5 9 1 Using program newstart 11 11 14 14 15 16 16 16 16 17 17 17 17 17 17 6 10 11 5 9 2 Creating the initial startarchive nc file 5 9 3 Changing the horizontal or vertical grid resolution Program organization and compilation script 6 1 Organization of the model source files lle 6 2 Programming R E es Le boh ee y R K 6 3 Model organization 64 Compiling the model Input Output 7T NetCDF format 2 x Du he ds ISS su done coute Di AH Ve me 7 1 1 NetCDF file editor ncdump 7 1 2 Graphic visualization of the NetCDF files using GrAds 7 2 Input and parameter files 7 2 17 TUNEL 4 xo e M
66. strating the difference between hybrid and non hybrid coordinates The GCM was initially programmed using sigma coordinates 7 p ps atmospheric pressure over surface pressure ratio which had the advantage of using a constant domain c 1 at the surface and 0 at the top of the atmosphere whatever the underlying topography However it is obvious that these coordinates significantly disturb the strato spheric dynamical representation as the topography is propagated to the top of the model by the coordinate system This problem can elegantly be solved by using a hybrid sigma P sigma pressure hybrid coordinate which is equivalent to using c coordinates near the surface and gradually shifting to purely pressure p coordinates with increasing altitude Figure 2 3 illustrates the importance of using these hybrid coordinates compared to simple o coordinates The distribution of the vertical layers is irregular to enable greater precision at ground level In general we use 25 levels to describe the atmosphere to a height of 80 km 32 levels for simulations up to 120 km or 50 levels to rise up to thermosphere The first layer describes the first few meters above the ground whereas the upper layers span several kilometers Figure 2 4 describes the vertical grid representation and associated variables DYNAMICS PHYSICS coordinates ap bp pressures ap llm 1 0 b
67. t data 23 gcm e You might also want to keep all messages and diagnostics written to standard output i e the screen You should then redirect the standard output and error to some file e g gcm out If using Csh gcm e gt gcm out If using Bash gcm e gt gocm out 2 gt amp 1 5 6 Visualizing the output files As the model runs it generates output files diagfi nc and stats nc files The former contains instantaneous values of various fields and the later statistics over the whole run of some variables 5 6 1 Using GrAds to visualize outputs If you have never used the graphic software GrAds we strongly recommend spending half an hour to familiarize yourself with it by following the demonstration provided for that purpose The demo is fast and easy to follow and you will learn the basic commands To do this read file distrib local grads sample For example to visualize files diagfi ncand stats nc NetCDF files diagfi nc and stats nc can be accessed directly using GrAdS thanks to utility program gradsnc the user does not need to intervene To visualize the temperature in the 5th layer using file diagfi nc for example GrAdS session grads return return opens a landscape window ga gt sdfopen diagfi nc ga query file displays info about the open file including the name of the stored variables Shortcut q file ga set z 5 fixes the altitude to the 5th layer ga set t 1 fixes the tim
68. t latitude latitude latitude title latitude latitude units degrees north float longitude longitude longitude title East longitude longitude units degrees east float altitude altitude altitude long name altitude altitude units km altitude positive up float aps altitude aps title hybrid pressure at midlayers aps units float bps altitude bps title hybrid sigma at midlayers bps units float ps Time latitude longitude ps title Surface pressure ps units Pa float ps_sd Time latitude longitude e season ps sd units Pa float tsurf Time latitude longitude tsurf title Surface temperature tsurf units K float tsurf sd Time latitude longitude ver the season tsurf sd units K float co2ice Time latitude longitude co2ice title CO2 ice cover co2ice units kg m 2 float co2ice sd Time latitude longitude he season co2ice sd units kg m 2 float fluxsurf lw Time latitude longitude fluxsurf lw units W m 2 float fluxsurf lw sd Time latitude longitude al standard deviation over the season fluxsurf lw sd units W m 2 float fluxsurf sw Time latitude longitude fluxsurf sw title Solar radiative flux to surface fluxsurf sw units W m 2 float fluxsurf sw sd Time latitude longitude andard deviation over the season fluxsurf sw sd units W m 2 float fluxtop
69. t2archive testphysld create make gom Executable used to create the makefil This command is run automatically by makegcm see below 6 1 Organization of the model source files The model source files are stored in various sub directories in directory libf These sub directories correspond to the different parts of the model grid mainly made up of dimensions h file which contains the parameters that define the model grid i e the number of points in longitude IIM latitude JJM and altitude LLM as well as the number of tracers NQMX dyn3d contains the dynamical subroutines 28 bibio contains some generic subroutines not specifically related to physics or dynamics but used by either or both phymars contains the physics routines filtrez contains the longitudinal filter sources applied in the upper latitudes where the Courant Friedrich Levy stability criterion is violated 6 2 Programming The model is written in Fortran 77 and Fortran 90 e The program sources are written in file F or file F90 files The extension F is the standard extension for fixed form Fortran and the extension F90 is for free form Fortran These files must be preprocessed by aC preprocessor such as cpp before compilation this behaviour is for most compilers implicitly obtained but using a capital F in the extention of the file names Constants are placed in COMMON declarations located in the common include
70. te and simply modify it Like the GCM the program newstart must be compiled using the makegocm script to the required grid resolution For example 25 makegcm d 32x32x20 p std newstart Then run newstart e The program then gives you two options From which kind of files do you want to create newstart and startfi files 0 from a file start archive 1 from files start and startfi e Option 1 allows you to read and modify the information needed to create a new initial state from the files start nc startfi nc e Option 0 allows you to read and modify the information needed to create a new initial statefrom file start archive nc whateverthe start archive nc grid resolution is If you use tracers make sure that they are taken into account in your start files either start or start archive Then answer to the various questions in the scroll menu These questions allow you to modify the initial state for the following parameters First set of questions Change values in tab cntrl Current values given above 3 day ini Initial day 0 at Ls 0 19 z0 surface roughness m 21 emin_turb minimal energy PBL 20 lmixmin mixing length PBL 26 emissiv ground emissivity 24 et 25 emisice CO2 ice max emissivity 22 et 23 albedice CO2 ice cap albedos 31 et 32 iceradius mean scat radius of CO2 snow 33 et 34 dtemisice time scale for snow metamorphism 27 tauvis mean dust
71. th of a sol s 788775 tab cntrl 11 phystep time step in the physics tab cntr1 12 0 tab cntrl 13 0 c Informations about Mars only for physics tab cntrl 14 year day length of year sols 668 6 tab cntrl 15 periheli min Sun Mars distance Mkm 206 66 tab cntrl 16 aphelie max SUn Mars distance Mkm 249 22 tab cntrl 17 peri day date of perihelion sols since N spring tab cntrl1 18 obliquit Obliquity of the planet deg 23 98 c Boundary layer and turbulence tab cntrl 19 z0 surface roughness m 0 01 tab cntr1 20 lmixmin mixing length 100 tab cntrl1 21 emin turb minimal energy 1 e 8 c Optical properties of polar caps and ground emissivity tab cntr1 22 albedice 1 Albedo of northern cap 0 5 tab cntr1 23 albedice 2 Albedo of southern cap 0 5 tab cntrl1 24 emisice 1 Emissivity of northern cap 0 95 tab cntrl1 25 emisice 2 Emissivity of southern cap 70 95 tab cntr1 26 emissiv Emissivity of martian soil 95 tab cntrl 31 iceradius 1 mean scat radius of CO2 snow north tab cntrl 32 iceradius 2 mean scat radius of CO2 snow south tab cntrl 33 dtemisice 1 time scale for snow metamorphism north tab cntrl 34 dtemisice 2 time scale for snow metamorphism south c dust aerosol properties tab cntrl 27 tauvis mean visible optical depth tab cntrl1 28 0 tab cntrl 29 0 tab cntrl1 30 0 Soil properties tab cntrl 35 vo
72. the dissipation and increase day_step in run def for 1 to 3 sols and then use less strict values e If the run remains very unstable and requires too much dissipation or a too small timestep a good tip to help stabilize the model is to decrease the vertical extension of your run and the number of layer one generally zoom to study near surface process so 20 to 22 layers and a vertical extension up to 60 or 80 km is usually enough 58 Chapter 11 Changing the radiative transfer properties One of the key advantages of the LMD generic model is the ability to work with arbi trary gas and aerosol mixtures in the radiative transfer In this chapter we describe how to produce new correlated k absorption coefficients and implement them in the GCM 11 1 Producing the high resolution data We use the open source software kspect rum to produce line by line LBL absorption coefficients Kspect rum is freely available online at http code google com p kspectrum See its user manual for general information on installation and basic usage To produce LBL data on a grid of pressure and temperature suitable for the GCM the program make composition F 90 is used available in the utilities folder of the main GCM directory This may be compiled with the script compile in the same folder Once this has been done the two scripts prekspectrumand postkspectrum are used to feed kspect rum the correct inputs and convert the LBL data to correlated k co
73. trl 12 etotO total energy tab cntrl 13 ptotO total pressure tab cntrl 14 ztotO0 total enstrophy tab cntrl 15 stotO total enthalpy 44 tab cntrl 16 angO total angular momentum tab cntrl 17 pa tab cntrl 18 preff reference pressure Pa tab cntrl 19 clon longitude of center of zoom tab cntrl 20 clat latitude of center of zoom tab cntrl 21 grossismx zooming factor along longitude tab cntrl1 22 grossismy zooming factor along latitude tab cntrl 24 dzoomx extention in longitude of zoom tab cntrl1 25 dzoomy extention in latitude of zoom tab cntrl 27 taux stiffness factor of zoom in longitude tab cntr1 28 tauy stiffness factor of zoom in latitude The controle array in the header of a physical NetCDF file c Informations on t tab cntrl 1 tab cntrl 2 tab cntrl 3 tab cntrl 4 physics grid float ngridmx i float nlayermx day ini int time time int time 1 he startfi nc number of nodes on physics grid number of atmospheric layers initial day initiale time of day c Informations about Mars used by dynamics and physics tab cntrl 5 rad radius of Mars m 73397200 tab cntrl 6 omeg rotation rate rad s 1 tab cntrl 7 g gravity m s 2 3 72 tab cntrl 8 mugaz Molar mass of the atmosphere g mol 1 43 49 tab cntrl1 9 rcp r cp 0 256793 kappa dans dynamique tab cntrl1 10 daysec leng
74. ues sont d cal es par rapport aux variables scalaires en utilisant une grille C dans la d finition de Arakawa le vent zonal est calcul aux points X Y i 1 2 j et le vent m ridien aux points X Y i j 1 2 La disposition des variables sur la grille est illustr e sur la Fig ure 3 2 On utilise en fait les composantes covariantes et et contravariantes et du vent d finies par Cu et Cyv et u c avec c acoso dA dX v Cy avec Cy a dp dY 3 1 ot Egi Sven ou u et v sont les composantes physiques du vecteur vent horizontal On introduit galement la pression extensive p pression au sol multipli e par l aire de la maille Aux p les sont calcul s le vent m ridien dans l ancienne formulation et les variables scalaires dans la nou velle 11 LATITUDE 180 120 60 0 60 120 18C LONGITUDE DU S PX LE 4d It 4 2 WV h l ES L 50 CR du Td e E A ae In MES K Z 404 i j PIS fal 5 E HERE HH N U 30 P mer L J 20 T TT mih T T T TTT T 1T 30 20 10 0 10 20 30 LONGITUDE Figure 3 1 Grille obtenue avec 96 points en longitude et 73 en latitude et un zoom d un facteur 3 centr sur la m dit rann e grille utilis e
75. vis reference opacity 35 volcapa soil volumetric heat capacity 18 obliquit planet obliquity deg 17 peri day periastron date sols since Ls 0 15 periastr min star planet dist Mkm 16 apoastr max star planet Mkm 14 year day length of year in sols 5 rad radius of the planet m 6 omeg planet rotation rate rad s 7 g gravity m s2 8 mugaz molecular mass of the atmosphere g mol 9 rcp r Cp 10 daysec length of a sol s Second set of questions flat no topography aquaplanet bilball uniform albedo and thermal inertia coldspole cold subsurface and high albedo at S pole qname change tracer name q 0 ALL tracer zero q x give a specific uniform value to one tracer ini q tracers initialisation for chemistry water and ice 26 ini q H20 tracers initialisation for chemistry and ice ini q iceH20 tracers initialisation for chemistry only noglacier Remove tropical H20 ice if lat lt 45 watercapn H20 ice on permanent N polar cap watercaps H20 ice on permanent S polar cap oborealis H20 ice across Vastitas Borealis iceball Thick ice layer all over surface wetstart start with a wet atmosphere isotherm Isothermal Temperatures wind set to zero radequi Earth like rad eq temperature profile and winds set to zero co2ice 0 remove CO2 polar cap ptot change total pressure emis change surface emissivity therm ini s Set soil thermal
76. y V 3 9 Ops zW zc F xU y V ot 3 10 On a not les termes sources dans les diff rentes quations Dans ces termes sources on distingue 1 d une part les param trisations physiques mentionn es plus haut et qui font intervenir pour une maille donn e du mod le tous les points situ s sur une m me verticale mais ceux l seulement 2 les op rateurs de dissipation horizontale cens s rendre compte des changes entre chelles explicitement repr sent es dans le mod le et chelles sous mailles Ces op rateurs ont la structure de Laplaciens agissant sur des plans horizontaux c est dire qu il font intervenir un voisin de chaque c t dans les deux directions horizon tales Cet op rateur est g n ralement it r pour le rendre plus s lectif en chelle plus on it re un laplacien et plus son effet sur les petites chelles devient important relativement 3 2 High latitude filters Extract adapted from Forget et al 1999 At high latitude a filter is applied near the singularity in the grid at the pole in order to satisfy the Courant Friedrichs Lewy numerical stability criterion without going to an ex cessively small timestep In the original version of the dynamical code a classical Fourier filter was used but we found that because the Martian polar atmosphere appears to be much more dynamically unstable than the Earth s polar atmosphere a more efficient formulation based on the grouping of adjacent gri
Download Pdf Manuals
Related Search
Related Contents
Husqvarna T300 User's Manual Port Designs BERLIN Manufacturer`s FSN 第3章 共助による地域除雪に関する実証実験 L1710S K183取扱説明書を見る control board mc102 JVC HR-S7300 S 取扱説明書 - カワムラサイクル “スコッチ”印 ハイパーソフト放熱材 Copyright © All rights reserved.
Failed to retrieve file