source: lmdz_wrf/README @ 4

Last change on this file since 4 was 4, checked in by lfita, 10 years ago

Fixing tiny typos...

File size: 3.0 KB
Line 
1**** Coupling WRF and LMDZ
2* L.Fita, Laboratoire de Meteorologie Dynamique, CNRS, UPMC-Jussieu, Paris, FRANCE
3* July 2014
4
5*** Compilation instructions ***
6
71.- Extraction of the source code:
8  $ svn co http://svn.lmd.jussieu.fr/LMDZ_WRF LMDZ_WRF
9
102.- Copy (not int the repository folder...) folder 'WRFV3' to the desired spatial resolution (F77 legacy). As example one for 80x90x39
11  $ cp -R WRFV3 ${WORKDIR}/WRFV3_80x90x39
12
133.- Go to the ${WORKDIR} and compile there
14  $ cd ${WORKDIR}/WRFV3_80x90x39
15
164.- Define domain size for LMDZ editing file lmdz/dimensions.h (see documentation for more details)
17  $ cat lmdz/dimensions.h
18       INTEGER iim,jjm,llm,ndm,wiim,wjjm,wbdym
19
20       PARAMETER (iim= 1, jjm=7031, llm=38,ndm=1,wiim=79,wjjm=89,wbdym=5)
21
22    jjm = (dimx-1) * (dimy -1)
23    llm = (dimz - 1)
24    wiim = dimx - 1
25    wjjm = dimy - 1
26    wbdym = 5 (up to now, mandatory to run WRF with 5 grid points in the sponge zone)
27
285.- run script 'tools/prepare_compilation.bash' ('-h', for help. copy netCDF libraries and other staff not automatized)
29  $ ./prepare_compilation.bash [WRF_LMDZsrc] [NETCDFhome] ${WORKDIR}/WRFV3_80x90x39
30
316.1- prepare compilation (ready for 'lmd' machines in serial) if not, edit
32  6.1.a: $ ./configure
33  6.1.b: add pre-compiler flag' -DLMDZ after -DNETCDF (inside configure.wrf)
34  6.1.c: modify 'lmdz/Makefile with that values from the 'configure.wrf'
356.2- prepare compilation modifying Registry files (already done, have a look just in case):
36  6.2.a $ ls -lrta Registry/Registry.EM
37    Registry/Registry.EM -> Registry.EM.LMDZ
38  6.2.b $ ls -lrta Registry/registry.dimspec -> registry.dimspec.lmdz
39
407.- Compile as usual
41  $ compile em_real >& compile.log
42
438.- Compile manually a lmdz subroutine (not working, not  knowing why). Example with gfortran serial in lmdz machines
44  $ cd lmdz
45  $ gfortran -O3 -ftree-vectorize -ftree-loop-linear -funroll-loops -w -ffree-form -ffree-line-length-none -fconvert=big-endian -frecord-marker=4   -fconvert=big-endian -frecord-marker=4 -O3 -ftree-vectorize -ftree-loop-linear -funroll-loops  -w -ffree-form -ffree-line-length-none -fconvert=big-endian -frecord-marker=4 -g -O0 -fbacktrace -Wall -fbounds-check -c -L/u/lflmd/bin/gcc_netcdf-4.3.0/lib  -lnetcdf -lnetcdff  -I/u/lflmd/bin/gcc_netcdf-4.3.0/include lmdz_wrf_variables_mod.f90
46  $ cd ..
47
489.- run script for second time 'tools/prepare_compilation.bash'
49  $ ./prepare_compilation.bash [WRF_LMDZsrc] [NETCDFhome] ${WORKDIR}/WRFV3_80x90x39
50
5110.- Recompile as usual
52  $ compile em_real >& compile.log
53
5411.- Checking compilation (empty outputs)
55  $ cat -n compile.log | grep Error
56  $ cat -n compile.log | grep Erreur (just in case you are in a French speaking computer)
57
5812.- Running simulation
59  11.a: Run all the steps 'WPS' and 'real.exe' as usual
60  11.b: folder 'WRFV3/run' is not completed (no binaries in repository!), thus get a copy of the right WRF version and use the original source
61  11.c: Edit and modify 'namelist.input' and all the LMDZ *def files provided in 'run' folder: 'config.def', 'gcm.def', 'physiq.def', 'run.def', 'traceur.def'
62
6312.- You're done, Have fun!
Note: See TracBrowser for help on using the repository browser.