Chapter 3. Adding New Resolutions or New Files to the build-namelist Database

Table of Contents
Adding Resolution Names
Adding or Changing Default Filenames

In the last chapter we gave the details on how to create new files for input into CLM. These files could be either global resolutions, regional-grids or even a single grid point. If you want to easily have these files available for continued use in your development you will then want to include them in the build-namelist database so that build-namelist can easily find them for you. You can deal with them, just by editing your namelist by hand (or using a user_nl_clm namelist file), or by using CLM_USRDAT_NAME. Another way to deal with them is to enter them into the database for build-namelist, so that build-namelist can find them for you. This keeps one central database for all your files, rather than having multiple locations to keep track of files. If you have a LOT of files to keep track of it also might be easier than keeping track by hand, especially if you have to periodically update your files. If you just have a few quick experiments to try, for a short time period you might be best off using the other methods mentioned above.

There are two parts to adding files to the build-namelist database. The first part is adding new resolution names which is done in the models/lnd/clm/bld/namelist_files/namelist_definition.xml file. The second part is actually adding the new filenames which is done in the models/lnd/clm/bld/namelist_files/namelist_defaults_clm.xml file. If you aren't adding any new resolutions, and you are just changing the files for existing resolutions, you don't need to edit the namelist_definition file.

Adding Resolution Names

If you are adding files for new resolutions which aren't covered in the namelist_definition file -- you'll need to add them in. The list of valid resolutions is in the id="res" entry in the models/lnd/clm/bld/namelist_files/namelist_definition.xml file. You need to choose a name for your new resolution and simply add it to the comma delimited list of valid_values for the id="res" entry. The convention for global Gaussian grids is number_of_latitudes x number_of_longitudes. The convention for global finite volume grids is latitude_grid_size x longitude_grid_size where latitude and longitude is measured in degrees. For regional or single-point datasets the names have a grid size number_of_latitudes x number_of_longitudes followed by an underscore and then a descriptive name such as a City name followed by an abbreviation for the Country in caps. The only hard requirement is that names be unique for different grid files. Here's what the entry for resolutions looks like in the file:


<entry id="res" type="char*30" category="default_settings"
       group="default_settings"  
       valid_values=
"360x720,128x256,64x128,48x96,32x64,8x16,94x192,0.23x0.31,0.47x0.63,
0.9x1.25,1x1.25,1.9x2.5,2x2.5,2.5x3.33,2.65x3.33,4x5,10x15,5x5_amazon,
1x1_tropicAtl,1x1_camdenNJ,1x1_vancouverCAN,1x1_mexicocityMEX,
1x1_asphaltjungleNJ,1x1_brazil,1x1_urbanc_alpha">
Horizontal resolutions
</entry>
As you can see you just add your new resolution names to the end of the valid_values list.