A quick summary of how to download, compile, and run CM1:
(Valid for cm1r11 and later versions)
Part 1: Download the code.
- From the
main web page, click on the "Download the code here" link.
- Read through the disclaimer.
- If you agree to the terms in the disclaimer, then click on the link at the bottom of the page.
- The tar file can be downloaded from this page.
- Place
the tar file on the disk that you will be running the model. Since the
output from CM1 can be large, you should place the file on a disk with
a substantial amount of free space (i.e., several GB of disk space
should be available).
- Place the tar file in an empty directory .... perhaps called "cm1".
- To uncompress and extract the files, type: "gunzip cm1.tar.gz" followed by "tar xvf cm1.tar"
- Proceed to part 2 below.
Part 2: Setup the code for your study.
There are six basic steps to setting up cm1:
- Edit "Makefile"
cd into the "src" directory.
In "Makefile," select the operating system and parallelization method
that is appropriate for your hardware. Compiler flags can also be set
in this file.
- Edit "base.F" (if necessary)
Modify the base
state conditions, as appropriate. There are two sections: one for the
hydrostatic pressure, temperature, and moisture sounding (see "isnd" section); and one for
the initial winds (u and v components) (see "iwnd" section).
- Edit "init3d.F" (if necessary)
In "init3d.F," you can add perturbations to the base state. Several default options are available.
- Edit "param.F" (if necessary)
If you are using terrain, you will have to specify the terrain with the "zs" array in the file "param.F".
- Compile the code
Type "make" within the "src" directory for cm1. On some machines, you may need to use "gmake" instead.
- Edit "namelist.input"
If the code compiled without error, cd into the "run" directory and
edit "namelist.input". See the "README.namelist" file in the root
directory for guidance. Here, you set the domain dimensions, as well as
the number of processors (using "nodex" and "nodey"). See the README
files in the main directory for more information.
Part 3: Run cm1.
- Run the code
Type "./cm1.exe" to run the code. You may need a different command
for some MPI applications ... check the documentation for your
supercomputer for more information. All output is placed in the "run"
directory, by default. You can move the output files to another
directory when the code is finished; running the code again will
overwrite the files if they are not moved.
For more information about running on distributed memory computers (with MPI), see the README.parallel file.