NICAM tutorial page  Index  Search  Changes  RSS  Login

NICAM tutorial page

DOWNLOAD

Please download the data HERE (current for global simulation only)

TERMS AND CONDITIONS

-Do not distribute the NICAM codes to any third party.

-Please report any bugs you have found.

-Please give us a feedback on the usability of NICAM so as to improve it.

-Please let us know the achievements you made with NICAM, so that we can make a list on the NICAM website (http://www.nicam.jp/hiki/?NICAM+Papers).

-When you present or publish the results obtained with NICAM, please cite the publications of NICAM. The relevant publications for the NICAM researches can be found in the codes or on the NICAM website.

-If a NICAM team member is heavily involved with your project, please acknowledge appropriate members or consider adding him or her as a co-author.

0. FLOW CHART

GLOBAL NICAM TEST RUN FOR GL05RL01 ˇ˘Flowchart.jpg

Basic Settings

  ### MACHINE: nicamcluster @ JAMSTEC
  ### RESOLUTION: Glevel 05; Rlevel 01
  ### PROCESSOR SETTING: PRC_NUM=8
  ### ALL USED FILES SAVED: /work02/yingwen/NICAM_TEST_FILE
  ### NICAM SOURCE CODE: /work02/yingwen/NICAM _TEST_FILE/NICAM
  ### MKINCLUDE FILE: Mkinclude.nicamcluster
  ### TUTORIAL PROVIDE by Prof. M. Satoh, M. Hara, Dr. C. Kodama
  ### Document made by Ying-Wen Chen

Main Flow of Compiling Porcess

  1) COMPILE NICAM SOURCE CODE (Both 201307 and 2009 version)
  2) ENVIRONMENT SETTING
  3) BOUNDARY CONDITION PREPARING/SETTING
  4) INITIAL CONDITION MAKING: COMMAND PREPARING
  5) INITIAL CONDITION MAKING: DATA MAKING
  6) INITIAL CONDITION MAKING: GENERATE NUDGING DATA
  7) INITIAL CONDITION MAKING: GENERATE THE REFERENCE STATE OF THE ATMOSPHERE
  8) RUNNING NICAM

1) Compile NICAM Source Code (201307 Version)

The setting of $TOPPATH is not necessary in the new version. Instead of that, the environment variable settings is needed before compiling.

Before compiling, set the environment variable $NICAM_SYS, set $NICAM_SYS = <the version that you are using>.

 $ export NICAM_SYS=<the version that you are using>

If necessary, add the option:

 $ export ENABLE_OPENMP=T # only for tool program
 $ export ENABLE_NETCDF=T # only for tool program

Go to the directory where the NICAM source code stored and compile.

 $ cd <the directory where the NICAN source code stored> 
 $ make

1) Compile NICAM Source Code (2009 Version)

  • Main working directory: /work02/yingwen/NICAM_TEST_FILE/NICAM/
  • A) make link:
    • Edit: $TOPPATH=/work02/yingwen/NICAM_TEST_FILE/NICAM (where the NICAM source codes stored)
$ ln -s Mkinclude.nicamcluster Mkinclude
$ vi Mkinclude
  • B) compile:
    • The compiling output information of make stored in the log file, make.log.
    • This process takes lots of time, about 40 minutes on nicamcluster.
    • Excusable commands will be created in the directory, $TOPPATH/bin.
$ make >& make.log

2) Environment Setting

  • A) environment setting
    • Edit: $NICAM_TOPDIR=/work02/yingwen/NICAM_TEST_FILE/NICAM (where the NICAM source code saved).
    • NOTE: glevel/rlevel settings, processor number setting and other setting for each testing can be found in the end of this shell, through L82 to L108, check and edit them if necessary.
$ vi set_env.sh

3) Boundary Condition Preparing and Setting

To get to initial condition data, please download the data from the link: DATA DOWNLOAD (current for global simulation only)

Main working directory: /work02/yingwen/NICAM_TEST_FILE/global_nicam_gl05_rl01/

SPECIAL RULE: <command> and <command.cnf> must be in the same directory, otherwise the parameters settings for <command> can not be read/found

  • A) make basic information
    • working directory: ./mnkinfo/
    • edit file: mkmnginfo.cnf
    • NOTE1: rlevel setting and processor number setting must be matched to set_env.sh
    • NOTE2: output information file: rl01-prc000008_TEST_20130411.info
  $ ln -s ../../NICAM/bin/mkmnginfo   # make link for mkmnginfo
  $ mkmnginfo
  • B) make horizontal grid information (the case of the uniform grid)
    • working directory: ./grid/hgrid/

1) generating spring grid (mkgrid)

  • edit file: mkgrid.cnf
  • NOTE: check the glevel/rlevel setting and the readin file name, rl01-prc000008_TEST_20130411.info
  $ ln -s ../../../NICAM/bin/mkgrid   # make link for mkgrid
  $ mkgrid
  $ mpirun -np 8 mkgrid               # OUTPUT FILES: dummy.XXXX, _grid.XXXX

2) convert gcgrid (mkgcgrid)

  • edit file: mkcgrid.cnf
  • NOTE: check the glevel/rlevel setting and the readin file name, rl01-prc000008_TEST_20130411.info
  $ ln -s ../../../NICAM/bin/mkcgrid   # make link for mkgrid
  $ mpirun -np 8 mkcgrid               # OUTPUT FILES: grid.XXXX

3) make map information

    • working directory: ./grid/llmap/
    • edit file: mkllmap.cnf

NOTE: size (imax*jmax) of output products is set in this file; in this case, imax=160 and jmax=80

   $ ln -s ../../../NICAM/bin/mkllmap     # make link for mkllmap
   $ mpirun -np 8 mkcgrid                 # OUTPUT FILES: llmap.XXXX

4) make vertical grid information

    • working directory: ./grid/vgrid/
    • edit file: mkvlayer.cnf
    • NOTE: vertical layer is set here, num_of_layer, in this case the number of vertical layers is set to be 40
   $ ln -s ../../../NICAM/bin/mkvlayer   # make link for mkllmap
   $ ./mkvlayer                          # working without mpirun
                                         # OUTPUT FILE: vgrid40.dat (binary file)

5) make topographic information

    • working directory: ./exeternal_data/MATSIRO/
    • edit file: mklanddata2.cnf
   $ ln -s ../../../NICAM/bin/mklanddata2     # make topography data
   $ mpirun -np 8 mklanddata2                 # OUTPUT FILES: grid.XXXX

6) make ozone information

    • working directory: ./exeternal_data/O3/
    • edit file: mko3.cnf
   $ ln -s ../../../NICAM/bin/mko3   # make topography data
   $ mpirun -np 8 mko3               # OUTPUT FILES: aimp2o3.XXXX

4) Initial Condition Making: Command Preparing

main working directory: /work02/yingwen/NICAM_TEST_FILE/global_nicam_gl05_rl01/local/

  • A) prepare the command
    • work directory: ./src/
    • edit file: Makefile
    • setting the NICAM_TOPDIR: /work02/yingwen/NICAM_TEST_FILE_NICAM
  • B) making new directory
    • working directory: ./
  $ mkdir bin
  • C) make file
    • working directory: ./
  $ make      # make new command for making initial condition in the directory ˇČbinˇÉ
  

5) Initial Condition Making: Data Making

  • main working directory: /work02/yingwen/NICAM_TEST_FILE/global_nicam_gl05_rl01/initial_data
  • A) untar FNL data
  $ tar -vxzf FNL-20091113.tar.gz
  • B) convert the FNL atmospheric data to NICAM format
    • working directory:./
  $ sh mk_atm.sh ../../FNL/fnl_20090701_00_00_c   #output file: atm.dat
  • C) convert the atmospheric data
    • working directory: ./ATM/
  $ sh mk_atm.sh ../../FNL/fnl_20090701_00_00_c   #output file: atm.dat
  • D) generate the atmosphere initial data
    • working directory: ./ATM/
  $ ln -s ../../../NICAM/bin/mkinit_atm_new
  $ ./mkinit_atm_new                                  #output files: init_atm.XXXX
  • E) convert the FNL ocean data to NICAM format
    • working directory: ./
  $ sh mk_ocn.sh ../../FNL/fnl_20090701_00_00_c      #output file: ocn.dat
  • F) generate the ocean initial data
    • working directory: ./OCN/
  $ ln -s ../../../NICAM/bin/mkinit_ocn
  $ ./mkinit_ocn                                     #output files: init_ocn.XXXX
  • G) convert the FNL land data to NICAM format
    • working directory: ./
  $ sh mk_lnd.sh ../../FNL/fnl_20090701_00_00_c      #output file: lnd.dat
  • H) generate the land initial data
    • working directory: ./LND/
  $ ln -s ../../../NICAM/bin/mkinit_lnd
  $ ./mkinit_lnd                                     #output files: init_lnd.XXXX

6) Initial Condition Making: Nudging Data Generating

  • main working directory: /work02/yingwen/NICAM_TEST_FILE/global_nicam_gl05_rl01/nudging_data
  • A) convert ocean data for NICAM format
    • working directory: ./
  $ sh mk_sst.sh ../../FNL/fnl_20090       #output file: fnlXXX.sst.dat
  • B) convert sea surface temperature data
    • working directory: ./OCN
    • edit file: mkgisst.cnf #edit the path of rgnmngfname
  $ ln -s ../../../NICAM/bin/mkgisst
  $ mpirun -np 8 mkgisst                   # output files: sst.XXXX
  • C) convert climate snow and sea ice data
    • working directory: ./OCM_CLM
    • edit file: mkgisst.cnf # edit the path of rgnmngfnam
  $ ln -s ../../../NICAM/bin/mkgisst
  $ mpirun -np 8 mkgisst                   # output files: cmip3ice1979-1999_clm.XXXX, 
                                             cmip3snw1979-1999_clm.XXXX, hadsst1979-1999_clm.XXXX

7) Initial Condition making: Reference State of the Atmosphere Generating

Main working directory: /work02/yingwen/NICAM_TEST_FILE/global_nicam_gl05_rl01/nudging_ data/refstate

  $ ln -s ../../NICAM/bin/mkbsstate
  $ ./mkbsstate                              # output file: vgrid40_ref.dat

= END OF THE PREPARING TASKS FOR RUNNING NICAM!!! =

8) Running NICAM

main working directory: /work02/yingwen/NICAM_TEST_FILE/global_nicam_gl05_rl01/run/

  • A) edit the configuration file for NICAM
    • edit file: nhm_driver.cnf
    • edit the path: rgnmngfname
 check the start time; start_year, start_month, start_day, start_hour
 check the time step: DTL (sec), LSTEP_MAX (STEP), and the integrate time= DTL*LSTEP_MAX [unit: seconds]
  • B) run NICAM
  $ mpirun -np 8 ${TOPPATH}/bin/nhm_driver

Other Information

If you need other information, please check the previous version of NICAM tutorial

Last modified:2014/02/05 12:00:59
Keyword(s):
References: