New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 9376 for branches/2017/dev_merge_2017/DOC/texfiles/chapters/chap_OBS.tex – NEMO

Ignore:
Timestamp:
2018-03-06T17:12:34+01:00 (6 years ago)
Author:
nicolasmartin
Message:

Global reorganisation of DOC directory: refactoring & cleaning of TeX source code for readability

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2017/dev_merge_2017/DOC/texfiles/chapters/chap_OBS.tex

    r9373 r9376  
    6565 
    6666\item Download some EN4 data from  
    67 \href{http://www.metoffice.gov.uk/hadobs}{http://www.metoffice.gov.uk/hadobs}. Choose observations which are 
     67\href{http://www.metoffice.gov.uk/hadobs}{www.metoffice.gov.uk/hadobs}. Choose observations which are 
    6868valid for the period of your test run because the observation operator compares 
    6969the model and observations for a matching date and time.  
    7070 
    7171\item Compile the OBSTOOLS code using:  
    72 \begin{verbatim} 
     72\begin{shcode} 
    7373./maketools -n OBSTOOLS -m [ARCH]. 
    74 \end{verbatim} 
     74\end{shcode} 
    7575 
    7676\item Convert the EN4 data into feedback format:  
    77 \begin{verbatim} 
     77\begin{shcode} 
    7878enact2fb.exe profiles_01.nc EN.4.1.1.f.profiles.g10.YYYYMM.nc 
    79 \end{verbatim} 
     79\end{shcode} 
    8080 
    8181\item Include the following in the NEMO namelist to run the observation 
     
    8484 
    8585%------------------------------------------namobs_example----------------------------------------------------- 
    86 \namdisplay{namobs_example} 
     86%\fortranfile{namelists/namobs_example} 
    8787%------------------------------------------------------------------------------------------------------------- 
    8888 
     
    114114 
    115115%------------------------------------------namobs-------------------------------------------------------- 
    116 \namdisplay{namobs} 
     116\fortranfile{namelists/namobs} 
    117117%------------------------------------------------------------------------------------------------------------- 
    118118 
     
    126126\subsection{Profile feedback} 
    127127 
    128 \begin{alltt} 
    129 \tiny 
    130 \begin{verbatim} 
     128\begin{ccode} 
    131129netcdf profiles_01 { 
    132130dimensions: 
     
    280278          :Convention = "NEMO unified observation operator output" ; 
    281279} 
    282 \end{verbatim} 
    283 \end{alltt} 
     280\end{ccode} 
    284281 
    285282\subsection{Sea level anomaly feedback} 
    286283 
    287 \begin{alltt} 
    288 \tiny 
    289 \begin{verbatim} 
     284\begin{ccode} 
    290285netcdf sla_01 { 
    291286dimensions: 
     
    407402          :Convention = "NEMO unified observation operator output" ; 
    408403} 
    409 \end{verbatim} 
    410 \end{alltt} 
     404\end{ccode} 
    411405 
    412406The mean dynamic 
     
    416410surface height. Below is an example header for this file (on the ORCA025 grid). 
    417411 
    418 \begin{alltt} 
    419 \tiny 
    420 \begin{verbatim} 
     412\begin{ccode} 
    421413dimensions: 
    422414        x = 1442 ; 
     
    433425                sossheig:units = "metres" ; 
    434426                sossheig:grid = "orca025T" ; 
    435 \end{verbatim} 
    436 \end{alltt} 
     427\end{ccode} 
    437428 
    438429\subsection{Sea surface temperature feedback} 
    439430 
    440 \begin{alltt} 
    441 \tiny 
    442 \begin{verbatim} 
     431\begin{ccode} 
    443432netcdf sst_01 { 
    444433dimensions: 
     
    553542          :Convention = "NEMO unified observation operator output" ; 
    554543} 
    555 \end{verbatim} 
    556 \end{alltt} 
     544\end{ccode} 
    557545 
    558546\section{Theoretical details} 
     
    935923read the second time counter from a single file the namelist would be. 
    936924 
    937 \begin{alltt} 
    938 \tiny 
    939 \begin{verbatim}  
     925\begin{fortrancode} 
    940926!---------------------------------------------------------------------- 
    941927!       namooo Offline obs_oper namelist 
     
    947933   nn_ooo_idx = 2 
    948934/ 
    949 \end{verbatim}  
    950 \end{alltt} 
     935\end{fortrancode} 
    951936 
    952937\subsubsection{Multiple fields per run} 
     
    95694112 hourly fields are to be interpolated in a setup where 288 steps equals 24 hours. 
    957942 
    958 \begin{alltt} 
    959 \tiny 
    960 \begin{verbatim}  
     943\begin{fortrancode} 
    961944!---------------------------------------------------------------------- 
    962945!       namooo Offline obs_oper namelist 
     
    970953   nn_ooo_freq = 144 
    971954/ 
    972 \end{verbatim}  
    973 \end{alltt} 
     955\end{fortrancode} 
    974956 
    975957The above namelist will result in feedback files whose first 12 hours contain 
     
    10791061fields plus an analysis field would be 7 counterparts per observation. 
    10801062 
    1081 \begin{alltt} 
    1082 \tiny 
    1083 \begin{verbatim} 
     1063\begin{fortrancode} 
    10841064   cl4_match_len = 7 
    1085 \end{verbatim} 
    1086 \end{alltt} 
     1065\end{fortrancode} 
    10871066 
    10881067Then to correctly allocate a class 4 file the forecast axis must be defined. This 
    10891068is controlled via \textbf{cl4\_fcst\_len}, which in out above example would be 3. 
    10901069 
    1091 \begin{alltt} 
    1092 \tiny 
    1093 \begin{verbatim} 
     1070\begin{fortrancode} 
    10941071   cl4_fcst_len = 3 
    1095 \end{verbatim} 
    1096 \end{alltt} 
     1072\end{fortrancode} 
    10971073 
    10981074Then for each model field it is necessary to designate what class 4 variable and 
     
    11011077when interpreting the data afterwards.  
    11021078 
    1103 \begin{alltt} 
    1104 \tiny 
    1105 \begin{verbatim} 
     1079\begin{fortrancode} 
    11061080   cl4_vars = "forecast" "forecast" "forecast" "persistence" "persistence" 
    11071081              "persistence" "best_estimate" 
    11081082   cl4_fcst_idx = 1 2 3 1 2 3 1 
    11091083   cl4_leadtime = 12 36 60  
    1110 \end{verbatim} 
    1111 \end{alltt} 
     1084\end{fortrancode} 
    11121085 
    11131086In terms of files and indices of fields inside each file the class 4 approach 
     
    11151088with a single field per file our example inputs will be specified. 
    11161089 
    1117 \begin{alltt} 
    1118 \tiny 
    1119 \begin{verbatim} 
     1090\begin{fortrancode} 
    11201091   ooo_files = "F.1.nc" "F.2.nc" "F.3.nc" "P.1.nc" "P.2.nc" "P.3.nc" "A.1.nc" 
    11211092   nn_ooo_idx = 1 1 1 1 1 1 1 
    1122 \end{verbatim} 
    1123 \end{alltt} 
     1093\end{fortrancode} 
    11241094 
    11251095When we combine all of the naming conventions, global attributes and i/o instructions 
    11261096the class 4 namelist becomes. 
    11271097 
    1128 \begin{alltt} 
    1129 \tiny 
    1130 \begin{verbatim} 
     1098\begin{fortrancode} 
    11311099!---------------------------------------------------------------------- 
    11321100!       namooo Offline obs_oper namelist 
     
    11761144   cl4_inst = "UK Met Office" 
    11771145/ 
    1178 \end{verbatim} 
    1179 \end{alltt} 
     1146\end{fortrancode} 
    11801147 
    11811148\subsubsection{Climatology interpolation} 
     
    12001167operations, 1 per forecast. 
    12011168 
    1202 \begin{alltt} 
    1203 \tiny 
    1204 \begin{verbatim} 
     1169\begin{fortrancode} 
    12051170   ooo_files = "F1.nc" "F1.nc" "F2.nc" "F2.nc" 
    12061171... 
    12071172   cl4_fcst_idx = 1 2 
    1208 \end{verbatim} 
    1209 \end{alltt} 
     1173\end{fortrancode} 
    12101174 
    12111175The above notation reveals the internal split between match up iterators and file 
     
    12391203MPI run of NEMO offline obs\_oper into a single class 4 file. The program is called in the following way: 
    12401204 
    1241 \begin{alltt} 
     1205 
    12421206\footnotesize 
    1243 \begin{verbatim} 
     1207\begin{shcode} 
    12441208c4comb.exe outputfile inputfile1 inputfile2 ... 
    1245 \end{verbatim} 
    1246 \end{alltt} 
     1209\end{shcode} 
    12471210 
    12481211\subsubsection{corio2fb} 
     
    12511214standard feedback format. The program is called in the following way: 
    12521215 
    1253 \begin{alltt} 
    12541216\footnotesize 
    1255 \begin{verbatim} 
     1217\begin{shcode} 
    12561218corio2fb.exe outputfile inputfile1 inputfile2 ... 
    1257 \end{verbatim} 
    1258 \end{alltt} 
     1219\end{shcode} 
    12591220 
    12601221\subsubsection{enact2fb} 
     
    12631224feedback format. The program is called in the following way: 
    12641225 
    1265 \begin{alltt} 
    12661226\footnotesize 
    1267 \begin{verbatim} 
     1227\begin{shcode} 
    12681228enact2fb.exe outputfile inputfile1 inputfile2 ... 
    1269 \end{verbatim} 
    1270 \end{alltt} 
     1229\end{shcode} 
    12711230 
    12721231\subsubsection{fbcomb} 
     
    12751234MPI run of NEMO into a single feedback file. The program is called in the following way: 
    12761235 
    1277 \begin{alltt} 
    12781236\footnotesize 
    1279 \begin{verbatim} 
     1237\begin{shcode} 
    12801238fbcomb.exe outputfile inputfile1 inputfile2 ... 
    1281 \end{verbatim} 
    1282 \end{alltt} 
     1239\end{shcode} 
    12831240 
    12841241\subsubsection{fbmatchup} 
     
    12871244in the following way: 
    12881245 
    1289 \begin{alltt} 
    12901246\footnotesize 
    1291 \begin{verbatim} 
     1247\begin{shcode} 
    12921248fbmatchup.exe outputfile inputfile1 varname1 inputfile2 varname2 ... 
    1293 \end{verbatim} 
    1294 \end{alltt} 
    1295  
     1249\end{shcode} 
    12961250 
    12971251\subsubsection{fbprint} 
     
    13011255following way: 
    13021256 
    1303 \begin{alltt} 
    13041257\footnotesize 
    1305 \begin{verbatim} 
     1258\begin{shcode} 
    13061259fbprint.exe [options] inputfile 
    13071260 
     
    13231276     -D            print depths 
    13241277     -z            use zipped files 
    1325 \end{verbatim} 
    1326 \end{alltt} 
     1278\end{shcode} 
    13271279 
    13281280\subsubsection{fbsel} 
     
    13311283following way: 
    13321284 
    1333 \begin{alltt} 
    13341285\footnotesize 
    1335 \begin{verbatim} 
     1286\begin{shcode} 
    13361287fbsel.exe <input filename> <output filename> 
    1337 \end{verbatim} 
    1338 \end{alltt} 
     1288\end{shcode} 
    13391289 
    13401290\subsubsection{fbstat} 
     
    13431293files. The program is called in the following way: 
    13441294 
    1345 \begin{alltt} 
    13461295\footnotesize 
    1347 \begin{verbatim} 
     1296\begin{shcode} 
    13481297fbstat.exe [-nmlev] <filenames> 
    1349 \end{verbatim} 
    1350 \end{alltt} 
     1298\end{shcode} 
    13511299 
    13521300\subsubsection{fbthin} 
     
    13551303modified to thin to a different resolution. The program is called in the following way: 
    13561304 
    1357 \begin{alltt} 
    13581305\footnotesize 
    1359 \begin{verbatim} 
     1306\begin{shcode} 
    13601307fbthin.exe inputfile outputfile 
    1361 \end{verbatim} 
    1362 \end{alltt} 
     1308\end{shcode} 
    13631309 
    13641310\subsubsection{sla2fb} 
     
    13671313called in the following way: 
    13681314 
    1369 \begin{alltt} 
    13701315\footnotesize 
    1371 \begin{verbatim} 
     1316\begin{shcode} 
    13721317sla2fb.exe [-s type] outputfile inputfile1 inputfile2 ... 
    13731318 
    13741319Option: 
    13751320     -s            Select altimeter data_source 
    1376 \end{verbatim} 
    1377 \end{alltt} 
     1321\end{shcode} 
    13781322 
    13791323\subsubsection{vel2fb} 
     
    13821326is called in the following way: 
    13831327 
    1384 \begin{alltt} 
    13851328\footnotesize 
    1386 \begin{verbatim} 
     1329\begin{shcode} 
    13871330vel2fb.exe outputfile inputfile1 inputfile2 ... 
    1388 \end{verbatim} 
    1389 \end{alltt} 
     1331\end{shcode} 
    13901332 
    13911333\subsection{building the obstools} 
     
    13981340observations and feedback files. It is possible to zoom in, plot individual profiles and 
    13991341calculate some basic statistics. To plot some data run IDL and then: 
    1400 \begin{alltt} 
    14011342\footnotesize 
    1402 \begin{verbatim} 
     1343\begin{minted}{idl} 
    14031344IDL> dataplot, "filename" 
    1404 \end{verbatim} 
    1405 \end{alltt} 
     1345\end{minted} 
    14061346 
    14071347To read multiple files into dataplot, for example multiple feedback files from different 
    14081348processors or from different days, the easiest method is to use the spawn command to generate 
    14091349a list of files which can then be passed to dataplot. 
    1410 \begin{alltt} 
    14111350\footnotesize 
    1412 \begin{verbatim} 
     1351\begin{minted}{idl} 
    14131352IDL> spawn, 'ls profb*.nc', files 
    14141353IDL> dataplot, files 
    1415 \end{verbatim} 
    1416 \end{alltt} 
     1354\end{minted} 
    14171355 
    14181356Fig~\ref{fig:obsdataplotmain} shows the main window which is launched when dataplot starts. 
Note: See TracChangeset for help on using the changeset viewer.