WORC tutorial The WRF-ORCHIDEE Coupling (WORC) has been developped as a part of the development of the MORCE platform. It consists of fully interactive coupling between the WRF atmospheric and ORCHIDEE dynamical vegetation models. The WRF atmospheric model solves the fully compressible euler and non-hydrostatic equations of motion including the full Coriolis terms, but a run-time hydrostatic option is available. The model WRF was developed in cooperation of several US-American research and forecast institutions. It aims at meso-scale climate dynamics and suits at the same time applications for weather forecasts and research modelling. ORCHIDEE is a dynamical vegetation model, which computes the hydrological and energy budget as a classical land surface scheme. It additionnaly takes into account the vegetation dynamics, leaf phenology and carbon cycle. ORCHIDEE was developed at IPSL and includes three sub-models. All three components can be combined individually: SECHIBA, which calculates energy and water exchanges, STOMATE, which calculates the phenology and Carbon dynamics and LPJ, which calculates vegetation dynamics on larger time scales. The source files are available online : 1. WRF 3.6.1.: http://www2.mmm.ucar.edu/wrf/users/download/get_source.html. You need to first register as a WRF user, and then download the version 3.6.1. 2. ORCHIDEE 2031 : http://forge.ipsl.jussieu.fr/orchidee/wiki/sourcecode 3. OASIS-MCT 2.0 : https://verc.enes.org/oasis/download/oasis-registration-form A Compiling WORC Compilation is required in the following order : OASIS, ORCHIDEE, WRF and then WPS. The following instructions are valid on climserv. 1. Uncompress the different source files (tar xfvz WORC.tgz). 2. Copy the files contained in WORC.tgz in their relative model directories (see Figure 1). 3. To compile OASIS-MCT: module load oasis3-mct/2.0-pgf2013 (command only for climserv!!) or Compiling OASIS3-MCT can be done in directory oasis3-mct/util/make_dir make realclean -f TopMakefileOasis3 / compiles all OASIS3-MCT libraries mct, scrip and psmile. make -f TopMakefileOasis3 / removes all OASIS3-MCT compiled sources and librairies. Makefile TopMakefileOasis3 which must be completed with a header file make.your_platform specific to the compiling platform used and specified in
oasis3-mct/util/make dir/make.inc. 4. To compile ORCHIDEE: Go into directory Trunk/modipsl/modeles/ORCHIDEE Link the header files arch.fcm and arch.path with your specific system settings (in arch directory). Modify MAKE_DIR in Trunk/modipsl/modeles/IOIPSL/src/Makefile Compilation./makeorchidee_fcm -driver The executable orchidee_ol is available in the directory Trunk/modipsl/bin/. 5. WRF requires to be compiled in 2 steps, the first one as a stand alone mode and the second as a OASIS coupled model: Go into directory WRFV3/ module load pgi/2013 (command only for climserv!!) module load netcdf4/4.2.1.1-pgf2011 (command only for climserv!!) module load openmpi/1.6.5-pgf2013 (command only for climserv!!) export NETCDF='/opt/netcdf42/pgf95' export WRFIO_NCD_LARGE_FILE_SUPPORT=1 export MPI_LIB=''./configure and choose the correct compiler configuration. For climserv, choose option #58 (pgi, gcc f90 with dmpar), and then slighly modify configure.wrf, from: DM_FC = mpif90 -f90=pgf90 DM_CC = mpicc -cc=gcc to : DM_FC = mpif90 DM_CC = mpicc -DMPI2_SUPPORT./compile em_real save the executable for wrf stand alone mode../mkdir./main/save/ then mv./main/*exe./main/save/ Modify the configure.wrf file to include the OASIS library. cp configure.wrf.oasis./configure.wrf Use the command «touch» for each with OASIS content (and the two files: main/module_wrf_top.f and module_dm.f ; see list in annex)../compile wrf 6. To compile WPS: Go into directory WPSV3/./configure and choose the correct compiler configuration. For climserv, choose option 7 (Linux x86_64, PGI compiler (dmpar)
./compile Figure 1: Scheme illustrating the coupled model components and sourcce files. B Running WORC The model run is separated in different steps which are described briefly in the following. First of all, the geogrid step initiates static field variables and defines the grid domain. The following ungrib step decodes the external analysis and the forecast data before the metgrib step interpolates horizontally the data. These three steps make up the preprocessing which is necessary to prepare the actual model run. The model run then is initiated by the real step which creates initial and boundary conditions. Finally, the model WRF itself can be run. (see also Figure 2). Figure 2: Scheme illustrating the WRF pre-processsing components. The WRF Preprocessing System (WPS) is a set of three programs whose collective role is to prepare input to the real program for real-data simulations. Each of the programs performs one stage
of the preparation: geogrid defines model domains and interpolates static geographical data to the grids; ungrib extracts meteorological fields from GRIB-formatted files; and metgrid horizontally interpolates the meteorological fields extracted by ungrib to the model grids defined by geogrid. The work of vertically interpolating meteorological fields to WRF eta levels is performed within the real program. 1. Geogrid Modify namelist.wps Modify geog_data_path as «/data/workspace/mstefano/geog» Type «./geogrid.exe» To easily define and localize geographical domains, the WRF Domain Wizard, a graphical user interface (GUI) can be used. It enables users to easily define and localize domains (cases) by selecting a region of the Earth and choosing a. Users can also define map projection, nests using the nests editor, edit namelist.input, run the WPS programs (geogrid, ungrib, and metgrid) through the GUI, and visualize the NetCDF output. WRF Domain Wizard stores its information in namelist.wps, namelist.input 2. Ungrib Link the ECMWF Vtable into the current directory with the following command «ln -sf Vtable./ungrib/Variable_Tables/Vtable.ECMWF Link the grib file into the current directory with the script link_grib.csh Type «./ungrib.exe» 3. Metgrid Check you updated METGRID.TBL.ARW with file in WORC archive. Type «./metgrid.exe» or execute the run_metgrid.pbs script with the qsub command 4. Real Go into directory WRFV3./run Link the met_em files from the WPS directory into the current directory. Modify the namelist.input./real.exe 5. WRF-ORCHIDEE Modify the run.def (ORCHIDEE namelist). Modify the namcouple (OASIS namelist). Type «./wrf.exe» or execute the run_wrf.pbs script with the qsub command C Postprocessing There are a number of postprocessing tools available to display WRF data. The ARWpost package reads in WRF model data and creates GrADS output files and provide
several diagnostics (cape,cin, maximum reflectivity,low/middle and high cloud fraction, geopotential, lifting condensation level and level of free convection) p_interp interpolates WRF netcdf output files to user-specified pressure levels. Diagnostics fields are pressure, temperature, geopotential and relative humidity. D Chained simulations Decadal simulations are often split into monthly simulations in order to provide frequent restarts and better fit the cluster architecture in terms of CPUs access and disk storage. Several script files are available to easily create all the files required (Figure 3). Figure 3: Scheme illustrating the different scripts all over the simulation process. Before starting a simulation, you need to configure the files written in green. Appendix Modified ORCHIDEE Files : driver2oasis.f90 orchideeoasis.f90
orchoasis_tools.f90 globgrd.f90 forcing_tools.f90 stomate_io.f90 (when_growthinit initialized by large_value instead of zero) Modified WRF Files : METGRID.TBL.ARW (WPS) configure.wrf.oasis Registry.EM_COMMON module_cpl.f module_cpl_oasis3.f module_dm.f module_radiation_driver.f module_surface_driver.f module_first_rk_step1.f module_wrf_top.f module_integrate.f Main flag into ORCHIDEE namelist (run.def) Flag GRID_FILE CPL_WRF TIME_STEP STOMATE_OK_STOMATE STOMATE_OK_DGVM STOMATE_OK_CO2 OUTPUT_FILE STOMATE_OUTPUT_FILE SECHIBA_HISTLEVEL STOMATE_HISTLEVEL Description Path towards land/sea mask. geo_em.nc in coupled mode with WRF. Set to True if coupled to wrf. Timestep for atmospheric coupling (seconds). Set to TRUE if STOMATE is to be activated. (Interactive phenology). Set to TRUE if Dynamic Vegetation DGVM is to be activated.. Set to TRUE if photosynthesis is to be activated (always set to true). Name of file in which sechiba's output is going to be written. Name of file in which stomate's output is going to be written. sechiba history output level. Choose the list of variables in the history file. Values between 0: nothing is written; 10: everything. stomate history output level. Choose the list of variables in the history file. Values between 0: nothing is written; 10: everything
WRITE_STEP STOMATE_HIST_DT HYDROL_CWRR FORCING_FILE VEGETATION_FILE LAND_USE Frequency in seconds at which to write sechiba's output Frequency in days at which to write stomate's output. Switch on the multilayer hydrology of CWRR. By default the Choisnel hydrology is used. Name of file containing the forcing data in ORCHIDEE stand alone mode. Name of the file to be opened to read the vegetation map. Read a PFT map. Main flag into WRF namelist (namelist.input) time_step interval_seconds e_ws, e_sn, e_vert dx, dy num_metgrid_levels num_metgrid_soil_levels eta_levels restart_interval sf_surface_physics history_interval frames_per_outfile model time step. input data interval for boundary conditions domain dimensions in west-east, south-north and vertical model grid distance in meters number of incoming data levels (can be found by using the ncdump command on the met_em.* file). number of incoming soil data levels. model eta levels from 1 to 0, if you choose to do so. If not, real will compute a nice set of eta levels. The computed eta levels have 7 half levels in the lowest 1 km or so, and stretches to constant dz. restart output file interval in minutes. land-surface option (set to 9 for ORCHIDEE). history output file interval in minutes (integer only) number of output times bulked into each history file; used to split output files into smaller pieces
io_form_* the format in which the history output file will be (2=netCDF). Bibliography Drobinski, P., A. Anav, C. Lebeaupin Brossier, G. Samson, M. Stéfanon, S. Bastin, M. Baklouti, K.Béranger, J. Beuvier, R. Bourdallé-Badie, L. Coquart, F. D'Andrea, N. De Noblet-Ducoudré, FDiaz, J. C. Dutay, C. Ethe, A. M. Foujols, D. Khvorostyanov, G. Madec, M. Mancip, S. Masson, L.Menut, J. Palmieri, J. Polcher, S. Turquety, S. Valcke, and N. Viovy, Model of the regional coupled earth system (morce): application to process and climate studies in vulnerable regions, Soft, 35,1#18, 2012. Krinner, G., N. Viovy, N. de Noblet-Ducoudré, J. Ogeé, J. Polcher, P. Friedlingstein, P. Ciais, S. Sitch, and I. Colin Prentice, A dynamic global vegetation model for studies of the coupled atmosphere-biosphere system, Global Biogeochem Cy, 19, GB1015, doi:10.1029/2003gb002199, 2005. Skamarock, W. C., J. B. Klemp, J. Dudhia, D. O. Gill, D. M. Barker, M. G. Duda, X.-Y. Huang, W. Wang, and J. G. Powers, A description of the advanced research wrf version 3, Tech. rep., NCAR,2008. User s Guide for the Advanced Research WRF (ARW) Modeling System Version 3.4 available at :http://www.mmm.ucar.edu/wrf/users/docs/user_guide_v3/contents.html User s Guide for OASIS-MCT : http://pantar.cerfacs.fr/globc/publication/technicalreport/2012/oasis3mct_userguide.pdf User s Guide for ORCHIDEE : http://forge.ipsl.jussieu.fr/orchidee