Index: /palm/trunk/TUTORIAL/SOURCE/basic_equations.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/basic_equations.tex	(revision 944)
+++ /palm/trunk/TUTORIAL/SOURCE/basic_equations.tex	(revision 945)
@@ -4,5 +4,5 @@
 
 \usepackage[utf8]{inputenc}
-\usepackage[T1]{fontenc}
+\usepackage{ngerman}
 \usepackage{pgf}
 \usetheme{Dresden}
@@ -78,5 +78,5 @@
       \item \onslide<5->Continuity equation
       \begin{equation*}
-         \frac{\partial p}{\partial t} = - \frac{\partial \rho u_k}{\partial x_k} 
+         \frac{\partial \rho}{\partial t} = - \frac{\partial \rho u_k}{\partial x_k} 
       \end{equation*}
    \end{itemize}
@@ -86,14 +86,13 @@
 \begin{frame}
    \frametitle{Boussinesq Approximation}
-   \small
+   \footnotesize
    \begin{itemize}
       \item \onslide<2->Splitting thermodynamic variables into a basic state $\psi_0$ and a variation $\psi^{*}$ 
-      \begin{equation*}
-         p(x,y,z,t) = p_0(x,y,z,t) + p^{*}(x,y,z,t)\hspace{22mm}
-      \end{equation*}
-      \begin{equation*}
-         \rho(x,y,z,t) = \rho_0(x,y,z,t) + \rho^{*}(x,y,z,t) ; 
-         \hspace{5mm} \psi^{*} << \psi_0
-      \end{equation*} 
+      \begin{align*}
+         T(x,y,z,t) &= T_0(x,y,z) &+& T^{*}(x,y,z,t)&&\\
+         p(x,y,z,t) &= p_0(x,y,z) &+& p^{*}(x,y,z,t)&&\\
+         \rho(x,y,z,t) &= \rho_0(z) &+& \rho^{*}(x,y,z,t);& &
+         &\psi^{*} << \psi_0&
+      \end{align*} 
       \item \onslide<3->Hydrostatic equilibrium, geostrophic wind (not included in Boussinesq)
       \begin{equation*}
@@ -104,9 +103,9 @@
       \item \onslide<4->Equation of state
       \begin{equation*}
-         p_0 = \rho_0 R T_0 \rightarrow \ln{p_0} = \ln{\rho_0} + \ln{R} + \ln{T_0} \rightarrow \frac{\partial p_0}{p_0} = \frac{\partial \rho_0}{\rho_0} + \frac{\partial T_0}{T_0} 
-      \end{equation*}
-      \begin{equation*}
-         \frac{\Delta p_0}{p_0} \approx \frac{\Delta \rho_0}{\rho_0} + 
-         \frac{\Delta T_0}{T_0} \rightarrow \frac{p^{*}}{p_0} \approx 
+         p = \rho R T \rightarrow \ln{p} = \ln{\rho} + \ln{R} + \ln{T} \rightarrow \frac{d p}{p} = \frac{d \rho}{\rho} + \frac{d T}{T} 
+      \end{equation*}
+      \begin{equation*}
+         \frac{\Delta p}{p_0} \approx \frac{\Delta \rho}{\rho_0} + 
+         \frac{\Delta T}{T_0} \rightarrow \frac{p^{*}}{p_0} \approx 
          \frac{\rho^{*}}{\rho_0} + \frac{T^{*}}{T_0} \hspace{10mm} 
          \frac{\rho^{*}}{\rho_0} \approx - \frac{T^{*}}{T_0} \hspace{10mm}
@@ -339,5 +338,5 @@
       \textbf{Literature:}\\
       \textbf{Sagaut, P., 2001:} Large eddy simulation for incompressible flows: An introduction. Springer Verlag, Berlin/Heidelberg/New York, 319 pp.\\
-      \textbf{Schumann, U., 1975:} Subgrid scale model for finite difference simulations of turbulent flows in plane channels and annuli. J. Comp. Phys., \textbf{18}, 376-404.
+      \textbf{Schumann, U., 1975:} Subgrid scale model for finite difference simulations of turbulent flows in plane channels and annuli. J. Comp. Phys., \textbf{18}, 376-404.\\
    \end{scriptsize}
 \end{frame}
@@ -361,5 +360,5 @@
       \onslide<5->
       \begin{flalign*}
-         &\frac{\partial \overline{\theta}}{\partial t} = - \frac{\partial \overline{u_k}\,\overline{\theta}}{\partial x_k} - \frac{\partial H_k}{\partial x_k} + Q_{\theta}&
+         &\frac{\partial \overline{q}}{\partial t} = - \frac{\partial \overline{u_k}\,\overline{q}}{\partial x_k} - \frac{\partial W_k}{\partial x_k} + Q_{w}&
       \end{flalign*}
       \item<6-> 
@@ -396,6 +395,6 @@
          \end{tiny}
          $\tau_{ki} = \overline{u_k u_i} - \overline{u_k}\,\overline{u_i}$\\
-         $H_{k} = \overline{u_k \theta_k} - \overline{u_k}\,\overline{\theta_i}$\\
-         $W_{k} = \overline{u_k q_k} - \overline{u_k}\,\overline{q_k}$
+         $H_{k} = \overline{u_k \theta} - \overline{u_k}\,\overline{\theta}$\\
+         $W_{k} = \overline{u_k q} - \overline{u_k}\,\overline{q}$
          };
       \end{tikzpicture}
Index: /palm/trunk/TUTORIAL/SOURCE/debugging.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/debugging.tex	(revision 945)
+++ /palm/trunk/TUTORIAL/SOURCE/debugging.tex	(revision 945)
@@ -0,0 +1,299 @@
+% $Id$
+\input{header_tmp.tex}
+%\input{../header_lectures.tex}
+
+\usepackage[utf8]{inputenc}
+\usepackage{ngerman}
+\usepackage{pgf}
+\usetheme{Dresden}
+\usepackage{subfigure}
+\usepackage{units}
+\usepackage{multimedia}
+\usepackage{hyperref}
+\newcommand{\event}[1]{\newcommand{\eventname}{#1}}
+\usepackage{xmpmulti}
+\usepackage{tikz}
+\usetikzlibrary{shapes,arrows,positioning,decorations.pathreplacing}
+\def\Tiny{\fontsize{4pt}{4pt}\selectfont}
+
+%---------- neue Pakete
+\usepackage{amsmath}
+\usepackage{amssymb}
+\usepackage{multicol}
+\usepackage{pdfcomment}
+\usepackage{xcolor}
+
+\institute{Institut fÃŒr Meteorologie und Klimatologie, Leibniz UniversitÃ€t Hannover}
+\date{last update: \today}
+\event{PALM Seminar}
+\setbeamertemplate{navigation symbols}{}
+\setbeamersize{text margin left=.5cm,text margin right=.2cm}
+\setbeamertemplate{footline}
+  {%
+    \begin{beamercolorbox}[rightskip=-0.1cm]&
+     {\includegraphics[height=0.65cm]{imuk_logo.pdf}\hfill \includegraphics[height=0.65cm]{luh_logo.pdf}}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[ht=2.5ex,dp=1.125ex,%
+      leftskip=.3cm,rightskip=0.3cm plus1fil]{title in head/foot}%
+      {\leavevmode{\usebeamerfont{author in head/foot}\insertshortauthor} \hfill \eventname \hfill \insertframenumber \; / \inserttotalframenumber}%
+    \end{beamercolorbox}%
+%    \begin{beamercolorbox}[colsep=1.5pt]{lower separation line foot}%
+%    \end{beamercolorbox}
+  }%\logo{\includegraphics[width=0.3\textwidth]{luhimuk_logo.eps}}
+
+\title[PALM - Debugging]{PALM - Debugging}
+\author{Siegfried Raasch}
+
+% Notes:
+% jede subsection bekommt einen punkt im menu (vertikal ausgerichtet.
+% jeder frame in einer subsection bekommt einen punkt (horizontal ausgerichtet)
+\begin{document}
+% Folie 1
+\begin{frame}
+\titlepage
+\end{frame}
+
+\section{Principal Sources and First Steps}
+\subsection{Principal Sources and First Steps}
+
+% Folie 2
+\begin{frame}
+   \frametitle{Principal Sources of Errors}
+   \small
+   \textbf{PALM runs can give rise to a large variety of errors ...}
+   \par\medskip
+   Some of the main possible reasons for errors are: 
+   \begin{itemize}
+      \item<2->{Missing or wrong options in the {\tt mrun} call}
+      \item<3->{Errors in the configuration file}
+      \item<4->{Errors in the NAMELIST parameter file}
+      \item<5->{Errors in the {\tt ssh}-installation (authentication), if a remote host is used for batch jobs}
+      \item<6->{FORTRAN errors in the user code (user-interface files)} 
+      \item<7->{PALM runtime errors due to}
+      \begin{itemize}
+         \item<7->{wrong parameter settings}
+         \item<8->{errors in the user code}
+         \item<9->{errors in PALMâs default code, which have not been detected so far (e.g. because some parameter combinations have never been tried so far)}
+      \end{itemize}
+   \end{itemize}
+\end{frame}
+
+% Folie 3
+\begin{frame}
+   \frametitle{First Steps of Debugging}
+   \footnotesize
+   \begin{itemize}
+      \item<2->{\textbf{Find out the principal reason of the error(s):}}
+      \begin{itemize}
+         \item<3->{ Carefully analyze the job protocol file (or messages on the terminal, in case of interactive runs) 
+               for any error messages or unexpected behaviour.}
+         \item<4->{In case of batch runs on a remote host, if the job protocol file is missing on the local host, 
+               try if you can find it in {\tt $\sim$/job\_queue} on the remote host.}
+         \item<5->{If the job has run into a time limit, no job protocol files or messages might be created at all (system depending).}
+         \item<6->{Some typical errors which may occur during execution of mrun are automatically detected and displayed 
+               by mrun in the job protocol or on the terminal: \\
+               \par\medskip
+               Respective error messages will begin with "'+++"'.} 
+         \item<7->{Compile and run time error messages will only appear in the job protocol or on the terminal (in case of interactive runs).}        
+      \end{itemize}
+   \end{itemize}
+\end{frame}
+
+\section{Runtime Errors}
+\subsection{Runtime Errors}
+
+% Folie 4
+\begin{frame}
+   \frametitle{Debugging Runtime Errors (I)}
+   \small
+   \begin{itemize}
+      \item{In case of runtime errors, the available information depends on the compiler and on the compiler settings.}
+      \item<2->{The default options for the Intel-compiler ({\tt-O3} for fast execution) give 
+            almost no information, e.g. about the subroutine or the line number of the code where the error occured. 
+            Execution is even continued in case of floating point errors!}
+      \item<3->{Floating point error detection and traceback can be activated with compiler options
+            \par\medskip  
+            {\tt ifort -fpe0 -debug -traceback -O0 ...}}
+      \item<4->{The default {\tt .mrun.config.imuk\_hlrn} file contains an additional block with debug options. It can bei used with mrun-call 
+            \par\medskip
+            {\tt mrun ... -h lcsgih -K parallel trace ...}}
+   \end{itemize}
+\end{frame}
+
+% Folie 5
+\begin{frame}
+   \frametitle{Debugging Runtime Errors (II)}
+   \small
+   \tikzstyle{box} = [rectangle, draw, text width=0.9\textwidth, font=\scriptsize]
+   \begin{itemize}
+      \item{The configuration file {\tt .mrun.config.imuk\_hlrn} looks like this:} 
+   \end{itemize}
+   \uncover<2->{
+   \begin{tikzpicture}      
+      \node[box](box){ \begin{tabbing} 
+         .\\
+         \# The next line is just an example. Add your own line below or replace this line. \\
+         \%host\_identifier \quad myhostname  \textless hi\textgreater \\
+         \# \\
+         \# The next block contains all informations for compiling the PALM code \\
+         \textbf{\# This is the block for the optimized version}
+         . \\
+         \%fopts \qquad \= -openmp:-xS:-fpe0:-O3:-cpp:-r8:... \qquad \textless hi\textgreater parallel \\
+         \%lopts \> -openmp:-xS:-fpe0:-O3:-cpp:-r8:... \qquad \textless hi\textgreater parallel \\
+         . \\
+         . \\
+         \textbf{\# This is the block for the debug version}
+         . \\
+         \%fopts \qquad \= -openmp:-C:-ftrapuv:-xS:-debug:extended:... \qquad \textless hi\textgreater parallel \textbf{trace} \\
+         \%lopts \qquad \> -openmp:-C:-ftrapuv:-xS:-debug:extended:... \qquad \textless hi\textgreater parallel \textbf{trace} \\
+         . \\
+        \end{tabbing}};
+   \end{tikzpicture}}
+\end{frame}
+
+% Folie 6
+\begin{frame}
+   \frametitle{Debugging Runtime Errors (III)}
+   \footnotesize   
+   \tikzstyle{yellow1} = [rectangle, draw, fill=yellow!100, text width=0.2\textwidth, font=\scriptsize]
+   \tikzstyle{green1} = [rectangle, draw, fill=green!75!black, text width=0.1\textwidth, font=\scriptsize]
+   \tikzstyle{green2} = [rectangle, draw, fill=green!75!black, text width=0.15\textwidth, font=\scriptsize]
+   \tikzstyle{green3} = [rectangle, draw, fill=green!75!black, text width=0.35\textwidth, font=\scriptsize]
+   \tikzstyle{green4} = [rectangle, draw, fill=green!75!black, text width=0.4\textwidth, font=\scriptsize]
+   \tikzstyle{line} = [draw, -]
+   \tikzstyle{arrow} = [draw, -latex']
+   \begin{itemize}
+      \item{If you now call mbuild, it will first compile for the optimized version, and then for the debug version.
+            The pre-compiled code will be put into different make depositories, one for each block:} 
+   \end{itemize} 
+   \begin{center}
+   \begin{tikzpicture} [auto]
+      \uncover<2->{
+      \node[yellow1] (currentversion) {current\_version/};
+      \node[green1] (trunk) [right=0.5cm of currentversion] {trunk/};
+      \node[green2] (source) [right=0.7cm of trunk] {SOURCE/};
+      \node[font=\tiny, text width= 4cm] (files) [right=0.3cm of source] {\textbf{Makefile}\\ 
+            \textbf{advec\_particles.f90}\\
+            \textbf{advec\_s\_bc.f90}\\
+            ...};
+      \node[green3](depository_parallel) [below=0.5cm of trunk] [xshift = 2cm] {MAKE\_Depository\_parallel/};}
+      \uncover<3->{
+      \node[green4](depository_parallel_trace) [below=0.5cm of depository_parallel] [xshift = 0.25cm] {MAKE\_Depository\_parallel\_trace/};}
+      
+      \uncover<2->{
+      \path[line] (currentversion) -- (trunk);
+      \path[line] (trunk.east) -- (source.west);
+      \path[line] (trunk.east) -- (source.north west);
+      \path[line] (trunk.east) -- (source.south west);
+      \path[line] (currentversion.east) -- (depository_parallel.west);}
+      \uncover<3->{\path[line] (currentversion.east) -- (depository_parallel_trace.west);}
+      \uncover<2->{
+      \path[line, thick] (7.3,-0.3) -- (7.3,-1.01);
+      \path[arrow, thick] (7.3,-1.01) -- (depository_parallel.east);}
+      \uncover<3->{
+      \path[line, thick] (7.5,-0.3) -- (7.5,-2.02);
+      \path[arrow, thick] (7.5,-2.02) -- (depository_parallel_trace.east);}
+   \end{tikzpicture}
+   \end{center}
+   \begin{itemize}
+      \item<4->{The {\tt mrun} option {\tt -K} defines, which version is used:}      
+   \end{itemize}
+   \uncover<4->{
+   \begin{tabbing}
+      \qquad \={\tt mrun ... -K parallel ...} will use the optimized version \\
+             \> {\tt mrun ... -K "'parallel trace"' ...} will use the debug version
+   \end{tabbing}  }
+   \uncover<5->{\begin{center} \textbf{Enabling debug options slows down the execution speed significantly!} \end{center}}
+\end{frame}
+
+
+% Folie 7
+\begin{frame}
+   \frametitle{Debugging Runtime Errors (IV)}
+   \footnotesize
+   \begin{itemize}
+      \item<2->{There are still some cases, where these options do not help or do not give enough information (e.g. concerning segmentations faults).} 
+      \item<3->{There are two ways of handling these cases:}
+      \begin{itemize}
+         \footnotesize
+         \item<4->{the print/write debugger}
+         \item<5->{debuggers like dbx or GUI-based debuggers like totalview \\(see \textbf{www.totalviewtech.com)}}
+         \item<6->{more detailed informations about using totalview on the HLRN system are given under:
+               \par\medskip 
+               \textbf{http://palm.muk.uni-hannover.de/wiki/doc/app/machine/hlrnII}}
+      \end{itemize}      
+   \end{itemize}
+\end{frame}
+
+\section{Print Statements}
+\subsection{Print Statements}
+
+% Folie 8
+\begin{frame}
+   \frametitle{Debugging With Print Statements (I)}
+   \tikzstyle{yellow1} = [rectangle, draw, fill=yellow!100, text width=0.2\textwidth, font=\scriptsize]
+   \tikzstyle{yellow2} = [rectangle, draw, fill=yellow!100, text width=0.1\textwidth, font=\scriptsize]
+   \tikzstyle{green1} = [rectangle, draw, fill=green!75!black, text width=0.25\textwidth, font=\scriptsize]
+   \tikzstyle{line} = [draw, -]
+   \scriptsize
+   \begin{itemize}
+      \item{ By adding appropriate print statements to the code
+            \begin{center} \begin{scriptsize}           
+            \begin{tabbing} 
+            \qquad\={\tt WRITE(9,*) 'now i am at \#1'} \\
+            \> {\tt CALL local\_flush( 9 )} \\
+            \> {\tt WRITE(9,*) 'now i am at \#2'} \\
+            \> {\tt CALL local\_flush( 9 )} \\
+            \> ...  
+            \end{tabbing}
+            \end{scriptsize} \end{center}
+            you can find the exact position (line number) within the code, where the error occurs.}
+      \par\medskip
+      \item<2->{Output can be found in files {\tt DEBUG\_0000}, {\tt DEBUG\_0001}, etc. in PALM's temporary working directory. You have to keep
+            this directory using  {\tt mrun}-option "'{\tt -B}"', because otherwise, the temporary working directory is deleted at the end of the run!}
+      \par\medskip
+      \item<5->{The name of PALM's temporary working directory is generated from environment variable {\tt tmp\_user\_catalog} (see {\tt .mrun.config}), the username, and a random number:
+            \begin{center} \par\medskip           
+            /\textless {\tt tmp\_user\_catalog}\textgreater/\textless {\tt username}\textgreater .\textless {\tt random number}\textgreater \end{center}}            
+   \end{itemize}   
+   \par\medskip
+   \begin{center}
+   \begin{tikzpicture}[auto]
+      \uncover<3->{
+      \node[yellow2] (home) {\$HOME/};
+      \node[yellow2][right=0.5cm of home] (palm) {palm/};
+      \node[yellow1] (currentversion) [right=0.5cm of palm] {current\_version/};      
+      \node[font=\tiny, text width = 2cm] (working) [below = 0.05cm of currentversion] {\textbf{working directory \\ of PALM user}};}
+      \uncover<4->{
+      \node[green1] (tmp_user) [below left=0.6cm of home] [xshift=0.6cm] {/tmp\_user\_catalog/};
+      \node[font=\tiny, text width = 4cm] (temporary) [right=0.1cm of tmp_user] {\textbf{contains temporary directory created \\ (by {\tt mrun}) for each PALM run}};}
+      
+      \uncover<3->{
+      \path[line] (home) -- (palm);
+      \path[line] (palm) -- (currentversion);}     
+   \end{tikzpicture}
+   \end{center}
+\end{frame}
+
+% Folie 9
+\begin{frame}
+   \frametitle{Debugging With Print Statements (II)}
+   \small
+   \begin{itemize}
+      \item<2->{After having located the position, you can try to find out which variable may have caused the error: \\
+            \par\medskip
+            {\tt WRITE(9,*) ' a=',a,' b=',b, ...}} 
+   \end{itemize}
+   \par\bigskip
+   \uncover<3->{
+   \textbf{Very important:}
+   Every output is buffered, i.e. it will not be directly written on disc. In case of program aborts, the buffer
+   contents are lost, so the output of the last write statements are not available. You have to prevent this problem
+   by flushing the buffer after each print/write statement:   
+   \begin{tabbing}
+      \qquad \={\tt WRITE(9,*) '...'} \\
+      \> {\tt CALL local\_flush( 9 )}
+   \end{tabbing}}   
+\end{frame}
+
+\end{document}
Index: /palm/trunk/TUTORIAL/SOURCE/fundamentals_of_les.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/fundamentals_of_les.tex	(revision 944)
+++ /palm/trunk/TUTORIAL/SOURCE/fundamentals_of_les.tex	(revision 945)
@@ -14,4 +14,5 @@
 \usepackage{xmpmulti}
 \usepackage{tikz}
+\usepackage{pdfcomment}
 \usetikzlibrary{shapes,arrows,positioning}
 \def\Tiny{\fontsize{4pt}{4pt}\selectfont}
Index: /palm/trunk/TUTORIAL/SOURCE/mrun_data_analysis.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/mrun_data_analysis.tex	(revision 945)
+++ /palm/trunk/TUTORIAL/SOURCE/mrun_data_analysis.tex	(revision 945)
@@ -0,0 +1,189 @@
+% $Id$
+\input{header_tmp.tex}
+%\input{../header_lectures.tex}
+
+\usepackage[utf8]{inputenc}
+\usepackage{ngerman}
+\usepackage{pgf}
+\usetheme{Dresden}
+\usepackage{subfigure}
+\usepackage{units}
+\usepackage{multimedia}
+\usepackage{hyperref}
+\newcommand{\event}[1]{\newcommand{\eventname}{#1}}
+\usepackage{xmpmulti}
+\usepackage{tikz}
+\usetikzlibrary{shapes,arrows,positioning}
+\usetikzlibrary{decorations.markings}             %neues paket
+\usetikzlibrary{decorations.pathreplacing}        %neues paket
+\def\Tiny{\fontsize{4pt}{4pt}\selectfont}
+\usepackage{amsmath}
+\usepackage{amssymb}
+\usepackage{multicol}
+\usepackage{pdfcomment}
+\usepackage{graphicx}
+\usepackage{listings}
+\lstset{showspaces=false,language=fortran,basicstyle=
+        \ttfamily,showstringspaces=false,captionpos=b}
+
+\institute{Institut fÃŒr Meteorologie und Klimatologie, Leibniz UniversitÃ€t Hannover}
+\date{last update: \today}
+\event{PALM Seminar}
+\setbeamertemplate{navigation symbols}{}
+
+\setbeamertemplate{footline}
+  {
+    \begin{beamercolorbox}[rightskip=-0.1cm]&
+     {\includegraphics[height=0.65cm]{imuk_logo.pdf}\hfill \includegraphics[height=0.65cm]{luh_logo.pdf}}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[ht=2.5ex,dp=1.125ex,
+      leftskip=.3cm,rightskip=0.3cm plus1fil]{title in head/foot}
+      {\leavevmode{\usebeamerfont{author in head/foot}\insertshortauthor} \hfill \eventname \hfill \insertframenumber \; / \inserttotalframenumber}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[colsep=1.5pt]{lower separation line foot}
+    \end{beamercolorbox}
+  }
+%\logo{\includegraphics[width=0.3\textwidth]{luhimuk_logo.pdf}}
+
+\title[Data Analysis]{Data Analysis}
+\author{Siegfried Raasch}
+
+\begin{document}
+
+% Folie 1
+\begin{frame}
+\titlepage
+\end{frame}
+
+\section{Data Analysis}
+\subsection{Data Analysis}
+
+% Folie 2
+\begin{frame}
+   \frametitle{PALM Data Analysis}
+   
+   \footnotesize
+   PALM  offers different ways of standard output to analyze the simulation data: 
+   \begin{enumerate}
+      \item<2-> Run control informations (for certain timesteps)
+      \item<3-> Mean vertical profiles
+      \begin{itemize}
+         \item[-]<3-> horizontally averaged, instantaneous or time-averaged
+      \end{itemize}
+      \item<4-> Time series
+      \item<5-> Two-dimensional cross sections ($xy$, $xz$, $yz$)
+      \begin{itemize}
+         \item[-]<5-> instantaneous or time-averaged, + averaged along 3rd dimension
+      \end{itemize}
+      \item<6-> Complete three-dimensional data arrays
+      \begin{itemize}
+         \item[-]<6-> instantaneous or time-averaged
+      \end{itemize}
+   \end{enumerate}
+   \quad \onslide<7-> Others (spectra, particle data)\\
+   \vspace{3mm}
+   \onslide<8-> First item is pure ASCII-data to give a short overview of the run. All other output is in netCDF format and can be graphically displayed.\\
+   \vspace{2mm}
+   Additionally, power spectra can be output using the spectra-package (use \texttt{mrun}-option \texttt{â-p spectraâ}).
+   
+\end{frame}
+
+% Folie 3
+\begin{frame}
+   \tikzstyle{yellow} = [rectangle, fill=yellow!20, font=\scriptsize, minimum height=1.2cm]
+   \tikzstyle{purple} = [rectangle, fill=magenta!10, font=\scriptsize, minimum height=0.9cm]
+   \tikzstyle{white} = [rectangle, font=\tiny, minimum height=0.9cm]
+      
+   \frametitle{Processing Standard Output Data with Graphics Software (Public Domain-Software)}
+   
+   \footnotesize
+   The standard output files are in netCDF format which can be easily displayed with \texttt{ncview}, \texttt{ncl}, or \texttt{ferret}.
+   
+   \begin{tikzpicture}[auto, node distance=0]
+   
+      % Zeile 1
+      \node [yellow, text width=0.2\textwidth] (1) {standard output};
+      \node [yellow, text width=0.25\textwidth, right=0.0cm of 1] (2) {names of local files created by PALM};   
+      \node [yellow, text width=0.25\textwidth, right=0.0cm of 2] (3) {suffix of permanent files as defined in \texttt{.mrun.config}};   
+      \node [yellow, text width=0.25\textwidth, right=0.0cm of 3] (4) {call of graphics software};   
+      
+      % Zeile 2      
+      \node [purple, text width=0.2\textwidth, below=0.0cm of 1] (12) {mean vertical profiles};
+      \node [white, text width=0.25\textwidth, below=0.0cm of 2] (22) {\texttt{DATA\_1D\_PR\_NETCDF}};
+      \node [white, text width=0.25\textwidth, below=0.0cm of 3] (32) {\texttt{\_pr.nc}};
+      \node [white, text width=0.25\textwidth, below=0.0cm of 4] (42) {\texttt{ncview <filename>}\\
+      \texttt{palmplot pr <options>}\\
+      \texttt{ferret -gui}};
+      
+      % Zeile 3      
+      \node [purple, text width=0.2\textwidth, below=0.0cm of 12] (13) {time series};
+      \node [white, text width=0.25\textwidth, below=0.0cm of 22] (23) {\texttt{DATA\_1D\_TS\_NETCDF}};
+      \node [white, text width=0.25\textwidth, below=0.0cm of 32] (33) {\texttt{\_ts.nc}};
+      \node [white, text width=0.25\textwidth, below=0.0cm of 42] (43) {\texttt{ncview <filename>}\\
+      \texttt{palmplot ts <options>}\\
+      \texttt{ferret -gui}};
+      
+      % Zeile 4           
+      \node [purple, text width=0.2\textwidth, minimum height=1.5cm, below=0.0cm of 13] (14) {2d-cross-sections};
+      \node [white, text width=0.25\textwidth, minimum height=1.5cm, below=0.0cm of 23] (24) {\texttt{DATA\_2D\_XY\_NETCDF}\\ \texttt{DATA\_2D\_XZ\_NETCDF}\\ \texttt{DATA\_2D\_YZ\_NETCDF}};
+      \node [white, text width=0.25\textwidth, minimum height=1.5cm, below=0.0cm of 33] (34) {\texttt{\_xy.nc}\\ \texttt{\_xz.nc}\\ \texttt{\_yz.nc}};
+      \node [white, text width=0.25\textwidth, minimum height=1.5cm, below=0.0cm of 43] (44) {\texttt{ncview <filename>}\\
+      \texttt{palmplot xy <options>}\\
+      \texttt{palmplot xz <options>}\\
+      \texttt{palmplot yz <options>}\\
+      \texttt{ferret -gui}};
+                  
+      % Zeile 5      
+      \node [purple, text width=0.2\textwidth, below=0.0cm of 14] (15) {3d-data}; 
+      \node [white, text width=0.25\textwidth, below=0.0cm of 24] (25) {\texttt{DATA\_3D\_NETCDF}};
+      \node [white, text width=0.25\textwidth, below=0.0cm of 34] (35) {\texttt{\_3d.nc}};  
+      \node [white, text width=0.25\textwidth, below=0.0cm of 44] (45) {\texttt{ncview <filename>}\\
+      \texttt{palmplot xy <options>}\\
+      \texttt{ferret -gui}};
+   
+
+   \end{tikzpicture}
+\end{frame}
+
+% Folie 4
+\begin{frame}
+   \frametitle{User Actions Necessary to Get Output}
+   Example for the case of mean vertical profiles:
+   \footnotesize
+   \begin{enumerate}
+   
+      \item<2-> Carefully think about, which variables you want to analyze
+      \begin{itemize}
+         \scriptsize
+	      \item[]<2-> e.g. temperature, wind, etc., resolved- or subgrid-scale?, output interval?, should they be time averaged?
+      \end{itemize}
+      
+      \item<3-> Find and set the appropriate output parameters in the parameter file
+      \begin{itemize}
+         \scriptsize
+	      \item[]<3-> \texttt{data\_output\_pr = 'pt', 'u', 'w ''pt'' ',  dt\_dopr = 900.0,}
+	      \item[]<3-> \texttt{averaging\_interval\_pr = 600.0, dt\_averaging\_input\_pr = 10.0}
+      \end{itemize}    
+      
+      \item<4-> Check, if the necessary file connection statements exist in the .mrun.config file
+      \begin{itemize}
+         \scriptsize
+	      \item[]<4-> \texttt{DATA\_1D\_PR\_NETCDF   out:loc:tr  pr\#      \~{}/palm/current\_version/JOBS/\$fname/OUTPUT  \_pr  nc}
+      \end{itemize}  
+      
+      \item<5-> Don't forget to activate the file connection statements by setting the correct activation string(s) in \texttt{mrun}-option \texttt{-r}
+      \begin{itemize}
+         \scriptsize
+	      \item[]<5-> \texttt{mrun ... -r ''... pr\# ...'' ...}
+      \end{itemize}   
+      
+      \item<6-> After job completion, change to the OUTPUT-directory and call the appropriate graphics software
+      \begin{itemize}
+         \scriptsize
+	      \item[]<6-> \texttt{ncview <filename>} or \texttt{palmplot pr <options>}
+      \end{itemize}  
+   \end{enumerate}   
+
+\end{frame}
+
+\end{document}
Index: /palm/trunk/TUTORIAL/SOURCE/mrun_steering_parameters.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/mrun_steering_parameters.tex	(revision 945)
+++ /palm/trunk/TUTORIAL/SOURCE/mrun_steering_parameters.tex	(revision 945)
@@ -0,0 +1,244 @@
+% $Id$
+\input{header_tmp.tex}
+%\input{../header_lectures.tex}
+
+\usepackage[utf8]{inputenc}
+\usepackage{ngerman}
+\usepackage{pgf}
+\usetheme{Dresden}
+\usepackage{subfigure}
+\usepackage{units}
+\usepackage{multimedia}
+\usepackage{hyperref}
+\newcommand{\event}[1]{\newcommand{\eventname}{#1}}
+\usepackage{xmpmulti}
+\usepackage{tikz}
+\usetikzlibrary{shapes,arrows,positioning}
+\usetikzlibrary{decorations.markings}             %neues paket
+\usetikzlibrary{decorations.pathreplacing}        %neues paket
+\def\Tiny{\fontsize{4pt}{4pt}\selectfont}
+\usepackage{amsmath}
+\usepackage{amssymb}
+\usepackage{multicol}
+\usepackage{pdfcomment}
+\usepackage{graphicx}
+\usepackage{listings}
+\lstset{showspaces=false,language=fortran,basicstyle=
+        \ttfamily,showstringspaces=false,captionpos=b}
+
+\institute{Institut fÃŒr Meteorologie und Klimatologie, Leibniz UniversitÃ€t Hannover}
+\date{last update: \today}
+\event{PALM Seminar}
+\setbeamertemplate{navigation symbols}{}
+
+\setbeamertemplate{footline}
+  {
+    \begin{beamercolorbox}[rightskip=-0.1cm]&
+     {\includegraphics[height=0.65cm]{imuk_logo.pdf}\hfill \includegraphics[height=0.65cm]{luh_logo.pdf}}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[ht=2.5ex,dp=1.125ex,
+      leftskip=.3cm,rightskip=0.3cm plus1fil]{title in head/foot}
+      {\leavevmode{\usebeamerfont{author in head/foot}\insertshortauthor} \hfill \eventname \hfill \insertframenumber \; / \inserttotalframenumber}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[colsep=1.5pt]{lower separation line foot}
+    \end{beamercolorbox}
+  }
+%\logo{\includegraphics[width=0.3\textwidth]{luhimuk_logo.pdf}}
+
+\title[General Steering Parameters]{General Steering Parameters}
+\author{Siegfried Raasch}
+
+\begin{document}
+
+% Folie 1
+\begin{frame}
+\titlepage
+\end{frame}
+
+\section{General Steering Parameters}
+\subsection{General Steering Parameters}
+
+% Folie 2
+\begin{frame}                         
+   \frametitle{General Hints for Carrying out LES}
+   
+   
+   \begin{itemize}
+      \scriptsize
+      
+      \item<2-> Domain size
+      \begin{itemize}
+         \scriptsize
+         \item[-]<3-> Must be large enough to capture all relevant scales of turbulence
+      \end{itemize}
+      
+      \item<4-> Grid spacing
+      \begin{itemize}
+         \scriptsize
+         \item[-]<4-> Must be so fine that most of the turbulent transport is resolved (explicit transport $>>$ subgrid-scale transport)\\ $\rightarrow$ check profiles of resolved-scale and subgrid-scale fluxes
+         \item[-]<5-> Results should not depend on grid spacing $\rightarrow$ carry out sensitivity study
+      \end{itemize}
+      
+      \item<6-> Simulation time
+      \begin{itemize}
+         \scriptsize
+         \item[-]<6-> Must be long enough that turbulence can develop $\rightarrow$ check the timeseries of velocity components or resolved-scale TKE
+         \item[-]<7-> In case of horizontally homogeneous boundary conditions, onset of turbulence has to be triggered by imposing random disturbances to the flow $\rightarrow$ otherwise, there will be no turbulence!
+         \item[-]<8-> Must be long enough to guarantee, that the mean flow has reached a (quasi-) stationary state $\rightarrow$ otherwise, turbulence statistics may be wrong
+      \end{itemize}
+      
+      \item<9-> Data analysis
+      \begin{itemize}
+         \scriptsize
+         \item[-]<9-> Data analysis should start only after onset of turbulence and after the mean flow has reached a (quasi-) stationary state
+         \item[-]<10-> Getting correct mean flow profiles generally requires temporal averaging of the data (e.g. over the eddy-turnover timescale in the \\ convective boundary layer)
+      \end{itemize}
+      
+   \end{itemize}
+\end{frame}
+
+% Folie 3
+\begin{frame}
+   \frametitle{PALM - General Steering Parameters - Overview (I)}
+   
+   Steering parameters can be classified into different groups:
+   \begin{itemize}
+      \footnotesize
+      
+      \item<2-> Grid parameters (computational grid / processor grid)
+      \begin{itemize}
+         \footnotesize
+         \item[-]<2-> grid spacing, number of gridpoints, etc.
+      \end{itemize}
+      
+      \item<3-> Numerical parameters
+      \begin{itemize}
+         \footnotesize
+         \item[-]<3-> timestep scheme, advection scheme, etc.
+      \end{itemize}
+      
+      \item<4-> Boundary condition parameters
+      \begin{itemize}
+         \footnotesize
+         \item[-]<4-> horizontal (cyclic/non-cyclic), vertical (Prandtl-layer, free-slip condition, etc.)
+      \end{itemize}
+      
+      \item<5-> Initialization parameters
+      \begin{itemize}
+         \footnotesize
+         \item[-]<5-> kind of initial profiles, restart run, main rain (following pre-run)
+      \end{itemize}   
+      
+      \item<6-> Output parameters
+      \begin{itemize}
+         \footnotesize
+         \item[-]<6-> 1d, 2d, 3d output, output intervals, etc.
+      \end{itemize}         
+      
+      \item<7-> Physical parameters
+      \begin{itemize}
+         \footnotesize
+         \item[-]<7-> latitude, angular velocity, etc.
+      \end{itemize} 
+                
+   \end{itemize}
+   
+\end{frame}
+
+% Folie 4
+\begin{frame}
+   \frametitle{PALM - General Steering Parameters - Overview (II)}
+   \footnotesize A complete alphabetical list of all parameters can be found under: \url{http://palm.muk.uni-hannover.de/wiki/doc/app/parlist}
+
+   \begin{itemize}
+      \footnotesize
+      
+      \item<2-> General initialization methods
+      \begin{itemize}
+         \footnotesize
+         \item[-]<2-> controlled by parameter \texttt{initializing\_actions =}
+      \end{itemize}
+      
+      \item<3-> Initial run:
+      \begin{itemize}
+         \footnotesize
+         \item[-]<3-> \texttt{initializing\_actions = âset\_constant\_profilesâ}\\
+         constant, piecewise linear, profiles are used
+         \item[-]<4-> \texttt{initializing\_actions = âset\_1d-model-profilesâ}\\
+wind/TKE-profiles are created by a 1d-model, embedded in PALM, using stationary temperature/humidity-profiles
+         \item[-]<5-> \texttt{initializing\_actions = âcyclic\_fillâ}\\
+         3d-data from a pre-run (possibly with smaller domain size than the initial run) are used
+         \item[-]<6-> \texttt{initializing\_actions = âby\_userâ}\\
+         user has to provide all initial settings
+      \end{itemize}
+      
+      \item<7-> Restart run:
+      \begin{itemize}
+         \footnotesize
+         \item[-]<7-> \texttt{initializing\_actions = âread\_restart\_dataâ}\\
+         data from the previous run in the job-chain are used
+      \end{itemize}
+                
+   \end{itemize}
+
+\end{frame}
+
+% Folie 5
+\begin{frame}
+   \frametitle{PALM - Initialization Example}
+
+   \begin{itemize}
+      \footnotesize
+      \item<1-> The following parameters have to be set for an initial atmosphere at rest with neutral temperature stratification and a capping inversion:
+
+      \quad \texttt{initializing\_actions = âset\_constant\_profilesâ,}\\
+      \quad \texttt{ug\_surface = 0.0, vg\_surface = 0.0,}\\
+      \quad \texttt{pt\_surface = 300.0,}\\
+      \quad \texttt{pt\_initial\_gradient = 0.0, 1.0,}\\
+      \quad \texttt{pt\_initial\_gradient\_level = 0.0, 800.0,}\\
+   \end{itemize}
+
+   \begin{center}
+      \onslide<2->
+      \begin{tikzpicture}[scale=0.7]
+
+         % define coordinates
+         \coordinate (O) at (0,0) ;
+         \coordinate (X) at (5,0) ;
+         \coordinate (Z) at (0,5) ;
+    
+         % axis
+         \draw[->, thick] (O) -- (X) ;
+         \draw[->, thick] (O) -- (Z) ;
+   
+         % axis tics
+         \draw[-] (1,-0.2) -- (1,0) ;
+         \draw[-] (-0.2,0) -- (0,0) ;
+         \draw[-] (-0.2,3) -- (0,3) ;
+       
+         % x-axis labels
+         \node[below] at (5,-0.2) {$\theta$};
+         \node[below] at (1,-0.2) {$\unit{300}{K}$};
+   
+         % z-axis labels
+         \node[left] at (-0.2,5) {$z$};
+         \node[left] at (-0.2,3) {$\unit{800}{m}$};
+         \node[left] at (-0.2,0) {$\unit{0}{m}$};
+    
+         % theta lines
+         \draw[red, ultra thick] (1,0) -- (1,3) ;
+         \draw[red, ultra thick] (1,3) -- (3,4.4) ;
+
+         % theta profiles
+         \uncover<3->{
+         \draw [decorate,decoration={brace,amplitude=10pt,mirror}] (1,0) -- (1,3) node[black,midway,xshift=0pt] {} ;
+         \node at (3.6,1.5) {$\dfrac{\partial \theta}{\partial z} = \unit{0.0}{K} / \unit{100}{m}$} ;}
+         \uncover<4->{
+         \node at (4.7,3.5) {$\dfrac{\partial \theta}{\partial z} = \unit{1.0}{K} / \unit{100}{m}$} ;}
+   
+      \end{tikzpicture}
+   \end{center}
+   
+\end{frame}
+
+\end{document}
Index: /palm/trunk/TUTORIAL/SOURCE/non_cyclic_boundary_conditions.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/non_cyclic_boundary_conditions.tex	(revision 944)
+++ /palm/trunk/TUTORIAL/SOURCE/non_cyclic_boundary_conditions.tex	(revision 945)
@@ -71,4 +71,7 @@
    \end{itemize}   
 \end{frame}
+
+\section{Motivation}
+\subsection{Motivation}
 
 %Folie 3
@@ -114,4 +117,7 @@
 \end{frame}
 
+\section{How to Create a Turbulent Inflow}
+\subsection{How to Create a Turbulent Inflow}
+
 % Folie 5
 \begin{frame}
@@ -136,7 +142,7 @@
 \begin{frame}
    \frametitle{How to Create a Turbulent Inflow (II)}
-   \small
+   \footnotesize
    Initial  turbulence is created by a precursor run with cyclic boundary conditions and much smaller domain size than used for the main run.
-   \tikzstyle{line} = [draw, yellow, thick, dashed, -latex']    
+   \tikzstyle{line} = [draw, blue, thick, dashed, -latex']    
    \begin{tikzpicture}      
       \uncover<1>{\node(picture) {\includegraphics[width=0.4\textwidth]{non_cyclic_figures/create_turbulent_inflow_2/create_turbulent_inflow_1.png}};}
@@ -148,5 +154,5 @@
          \begin{itemize}
          \item<4->{When the precursor run is finished, data of the last timestep are stored on disc.}
-         \item<5->{These data are then read by the main run and repeatedly mapped to the main run domain, unless it is completely filled.}
+         \item<5->{These data are then read by the main run and repeatedly mapped to the main run domain, until it is completely filled.}
          \end{itemize}}};
      \uncover<6>{\node(picture2) [below=1.8cm of picture.east] {\includegraphics[width=0.9\textwidth]{non_cyclic_figures/create_turbulent_inflow_2/create_turbulent_inflow_4.png}};}
@@ -200,4 +206,7 @@
 \end{frame}
 
+\section{Implementation in PALM}
+\subsection{Implementation in PALM}
+
 % Folie 8
 \begin{frame}
@@ -205,7 +214,8 @@
    \textbf{Status of availability:}
    \begin{itemize}
-      \item<2->{Non-cyclic boundary conditions along \textbf{one} of the horizontal directions (x \textbf{or} y).}
+      \item<2->{Non-cyclic boundary conditions along \textbf{one} of the horizontal directions (\textit{x} \textbf{or} \textit{y}).}
       \begin{itemize}
-         \item<3->{Dirichlet conditions at inflow (stationary vertical profiles, u(z), v(z), pt(z), q(z), w=0).}
+         \item<3->{Dirichlet conditions at inflow (stationary vertical profiles, \textit{u}(\textit{z}), \textit{v}(\textit{z}),
+                   \textit{pt}(\textit{z}), \textit{q}(\textit{z}), \textit{w}=0).}
          \item<4->{Radiation conditions at outflow. Tendencies at the boundary are replaced by e.g.}
       \end{itemize}      
@@ -234,4 +244,8 @@
 \end{frame}
 
+\section{Current Applications}
+\subsection{Current Applications}
+
+
 % Folie 10
 \begin{frame}
@@ -260,4 +274,7 @@
    \end{center}
 \end{frame}
+
+\section{How to set up}
+\subsection{How to set up}
 
 % Folie 12
@@ -351,4 +368,7 @@
 \end{frame}
 
+\section{Final remarks}
+\subsection{Final remarks}
+
 % Folie 16
 \begin{frame}
Index: /palm/trunk/TUTORIAL/SOURCE/parallelization.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/parallelization.tex	(revision 945)
+++ /palm/trunk/TUTORIAL/SOURCE/parallelization.tex	(revision 945)
@@ -0,0 +1,525 @@
+% $Id$
+\input{header_tmp.tex}
+%\input{../header_lectures.tex}
+
+\usepackage[utf8]{inputenc}
+\usepackage{ngerman}
+\usepackage{pgf}
+\usetheme{Dresden}
+\usepackage{subfigure}
+\usepackage{units}
+\usepackage{multimedia}
+\usepackage{hyperref}
+\newcommand{\event}[1]{\newcommand{\eventname}{#1}}
+\usepackage{xmpmulti}
+\usepackage{tikz}
+\usetikzlibrary{shapes,arrows,positioning}
+\usetikzlibrary{decorations.markings}             %neues paket
+\usetikzlibrary{decorations.pathreplacing}        %neues paket
+\def\Tiny{\fontsize{4pt}{4pt}\selectfont}
+\usepackage{amsmath}
+\usepackage{amssymb}
+\usepackage{multicol}
+\usepackage{pdfcomment}
+\usepackage{graphicx}
+\usepackage{listings}
+\lstset{showspaces=false,language=fortran,basicstyle=
+        \ttfamily,showstringspaces=false,captionpos=b}
+
+\institute{Institut fÃŒr Meteorologie und Klimatologie, Leibniz UniversitÃ€t Hannover}
+\date{last update: \today}
+\event{PALM Seminar}
+\setbeamertemplate{navigation symbols}{}
+
+\setbeamertemplate{footline}
+  {
+    \begin{beamercolorbox}[rightskip=-0.1cm]&
+     {\includegraphics[height=0.65cm]{imuk_logo.pdf}\hfill \includegraphics[height=0.65cm]{luh_logo.pdf}}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[ht=2.5ex,dp=1.125ex,
+      leftskip=.3cm,rightskip=0.3cm plus1fil]{title in head/foot}
+      {\leavevmode{\usebeamerfont{author in head/foot}\insertshortauthor} \hfill \eventname \hfill \insertframenumber \; / \inserttotalframenumber}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[colsep=1.5pt]{lower separation line foot}
+    \end{beamercolorbox}
+  }
+%\logo{\includegraphics[width=0.3\textwidth]{luhimuk_logo.pdf}}
+
+\title[Parallelization]{Parallelization}
+\author{Siegfried Raasch}
+
+\begin{document}
+
+% Folie 1
+\begin{frame}
+   \titlepage
+\end{frame}
+
+\section{Parallelization}
+\subsection{Parallelization}
+
+% Folie 2
+\begin{frame}
+   \frametitle{Basics of Parallelization}
+   \tikzstyle{yellow} = [rectangle,  fill=yellow!20, text width=0.6\textwidth, font=\scriptsize]
+   \scriptsize
+   \textbf{Parallelization:}
+   \begin{itemize}
+      \item<2-> All processor elements (PE, core) are carrying out the same program (SIMD).
+      \item<3-> Each PE of a parallel computer operates on a different set of data.
+   \end{itemize}
+
+   \ \\
+   \onslide<4->\textbf{Realization:}
+   \begin{columns}[T]
+      \begin{column}{0.45\textwidth}
+         \onslide<5->each PE solves the equations for a different subdomain of the total domain
+         \begin{center}
+            \includegraphics[width=0.5\textwidth]{parallelization_figures/subdomain.png}
+         \end{center}
+         \onslide<7->each PE only knows the variable values from its subdomain, communication / data exchange between PEs is necessary\\
+         \onslide<9->\textbf{message passing model (MPI)}
+      \end{column}
+      \begin{column}{0.45\textwidth}
+         \onslide<6->program loops are parallelized, i.e. each processor solves for a subset of the total index range
+         \begin{center}
+            \begin{tikzpicture}[auto, node distance=0]
+               \node [yellow] (1) {%
+               \texttt{!\$OMP DO}\\
+               \texttt{\quad \quad DO  i = 1, 100}\\
+               \quad \quad \quad $\vdots$\\
+               \texttt{\quad \quad ENDDO}};
+            \end{tikzpicture}
+         \end{center}
+         \onslide<8-> parallelization can easily be done by the compiler, if all PEs have access to all variables (shared memory)\\
+         \onslide<10-> \textbf{shared memory model (OpenMP)}
+      \end{column}
+   \end{columns}
+\end{frame}
+
+% Folie 3
+\begin{frame}
+   \frametitle{Basic Architectures of Massively Parallel Computers}
+   \tikzstyle{info} = [rectangle, text width=0.25\textwidth, font=\scriptsize]
+   
+   
+   \begin{center}
+      \begin{tikzpicture}
+
+         \node (center) at (0,1) {};
+         \onslide<2-> \node (Network) at (-3.5,1) [ellipse,fill=green!20] {Network};
+         \node (dis_mem) at (-3.5,-1) [text width=0.28\textwidth] {\footnotesize \textbf{distributed} memory\\(Cray-T3E)};
+         \onslide<3-> \node (add_mem) at (3.5,1) [rectangle, draw] {adressable memory};
+         \node (sha_mem) at (3.5,-1) [text width=0.35\textwidth] {\footnotesize \textbf{shared} memory\\(SGI-Altix, multicore PCs)};
+         \onslide<7-> \node (MPI) at (-3.5,-3) [ellipse,fill=yellow!90] {MPI};
+         \onslide<8-> \node (OpenMP) at (3.5,-3) [ellipse,fill=yellow!90] {OpenMP};         
+         \onslide<6-> \node (clustered_systems) at (0,-3) [draw, text width=0.15\textwidth] {clustered systems};
+         \node (cs_info) at (0,-4.2) [text width=0.4\textwidth] {\footnotesize (IBM-Regatta, Linux-Cluster,
+NEC-SX, SGI-ICE, Cray-XT4)};
+
+% Adressable memory node (big)
+
+         \onslide<3-> \node (p1) at (2,-0.05) [draw,circle, scale=0.9] {\scriptsize p};
+         \node (p2) at (2.6,-0.05) [draw,circle, scale=0.9] {\scriptsize p};
+         \node (p3) at (3.2,-0.05) [draw,circle, scale=0.9] {\scriptsize p};
+         \node (p4) at (3.8,-0.05) [draw,circle, scale=0.9] {\scriptsize p};
+         \node (p5) at (4.4,-0.05) [draw,circle, scale=0.9] {\scriptsize p};
+         \node (p6) at (5,-0.05) [draw,circle, scale=0.9] {\scriptsize p};
+         
+         \draw[-] (3.5,0.7) -- (3.5,0.4);
+         \draw[-] (2,0.4) -- (5,0.4);
+         \draw[-] (2,0.4) -- (p1);
+         \draw[-] (2.6,0.4) -- (p2);
+         \draw[-] (3.2,0.4) -- (p3);         
+         \draw[-] (3.8,0.4) -- (p4);
+         \draw[-] (4.4,0.4) -- (p5);         
+         \draw[-] (5,0.4) -- (p6);
+         
+% Adressable memory node (small)    
+         \onslide<4->
+         \draw[->, thick] (1.5,0.2) -- (0.4,0.2) ;    
+         \node at (0,0.2) [scale=0.2] {%
+         \begin{tikzpicture}
+            
+            \node (add_mem_small) at (3.5,0.9) [ultra thick, rectangle, draw, minimum width=3cm] {};
+            \node (p1_small) at (2,-0.05) [ultra thick, draw,circle, scale=0.9] {};
+            \node (p2_small) at (2.6,-0.05) [ultra thick, draw,circle, scale=0.9] {};
+            \node (p3_small) at (3.2,-0.05) [ultra thick, draw,circle, scale=0.9] {};
+            \node (p4_small) at (3.8,-0.05) [ultra thick, draw,circle, scale=0.9] {};
+            \node (p5_small) at (4.4,-0.05) [ultra thick, draw,circle, scale=0.9] {};
+            \node (p6_small) at (5,-0.05) [ultra thick, draw,circle, scale=0.9] {};
+         
+            \draw[-, ultra thick] (add_mem_small.south) -- (3.5,0.4);
+            \draw[-, ultra thick] (2,0.4) -- (5,0.4);
+            \draw[-, ultra thick] (2,0.4) -- (p1_small);
+            \draw[-, ultra thick] (2.6,0.4) -- (p2_small);
+            \draw[-, ultra thick] (3.2,0.4) -- (p3_small);         
+            \draw[-, ultra thick] (3.8,0.4) -- (p4_small);
+            \draw[-, ultra thick] (4.4,0.4) -- (p5_small);         
+            \draw[-, ultra thick] (5,0.4) -- (p6_small);
+            
+            
+         \end{tikzpicture}
+         } ;
+         
+         \onslide<5->
+         \node (add_info) at (0,-0.1) [scale=0.9] {\scriptsize node};
+
+% Black Arrows
+         \onslide<6-> \draw[->, thick] (-2.5,-1.5) -- (-0.8,-2.2) ;
+         \draw[->, thick] (2.5,-1.5) -- (0.8,-2.2) ;
+
+% MPI Arrows
+         \onslide<7-> \draw[->, ultra thick, color=yellow] (-3.5,-2.7) -- (-3.5,-1.5) ;
+         \draw[->, ultra thick, color=yellow] (-2.9,-3) -- (-1.0,-3.0) ;
+         \draw[->, ultra thick, color=yellow] (-3.0,-2.8) -- (1.5,-1.0) ;
+
+% OpenMP Arrows         
+         \onslide<8-> \draw[->, ultra thick, color=yellow] (3.5,-2.6) -- (3.5,-1.5) ;
+         \draw[->, ultra thick, color=yellow] (2.5,-2.8) -- (-2.5,0.7) ;
+         
+% Network decorations
+         \onslide<2-> \node (pr1) at (-4.6,0.7) [draw,circle,scale=0.5] {};
+         \node (mem1) at (-4.6,0.45) [draw,rectangle,scale=0.5] {};
+         \draw[-] (-4.5,0.9) -- (pr1);
+         \draw[-] (mem1) -- (pr1);
+         \draw[-] ([xshift=0.02cm]pr1.east) -- ([xshift=0.3cm, yshift=-0.2cm]pr1.east);
+         \draw[-] ([xshift=0.02cm]mem1.east) -- ([xshift=0.3cm, yshift=-0.2cm]mem1.east);  
+         \node at (-3.7,0.45) {\tiny processor};    
+         \node at (-3.3,0.25) {\tiny adressable memory};   
+         
+         \node (pr2) at (-4.6,1.3) [draw,circle,scale=0.5] {};
+         \node (mem2) at (-4.6,1.55) [draw,rectangle,scale=0.5] {};
+         \draw[-] (-4.5,1.1) -- (pr2);
+         \draw[-] (mem2) -- (pr2);
+         \node (pr3) at (-3.9,1.5) [draw,circle,scale=0.5] {};
+         \node (mem3) at (-3.9,1.75) [draw,rectangle,scale=0.5] {};
+         \draw[-] (-3.8,1.3) -- (pr3);
+         \draw[-] (mem3) -- (pr3);        
+         \node (pr4) at (-4.9,0.95) [draw,circle,scale=0.5] {};
+         \node (mem4) at (-4.9,0.7) [draw,rectangle,scale=0.5] {};
+         \draw[-] (-4.55,1.0) -- (pr4);
+         \draw[-] (mem4) -- (pr4);    
+         \node (pr5) at (-3.0,1.5) [draw,circle,scale=0.5] {};
+         \node (mem5) at (-3.0,1.75) [draw,rectangle,scale=0.5] {};
+         \draw[-] (-3.08,1.3) -- (pr5);
+         \draw[-] (mem5) -- (pr5);    
+         \node (pr6) at (-2.2,1.1) [draw,circle,scale=0.5] {};
+         \node (mem6) at (-2.2,1.35) [draw,rectangle,scale=0.5] {};
+         \draw[-] (-2.45,1.0) -- (pr6);
+         \draw[-] (mem6) -- (pr6);    
+                           
+      \end{tikzpicture}
+   \end{center}
+
+\end{frame}
+
+% Folie 4
+\begin{frame}
+   \frametitle{PALM Parallelization Model}
+   \scriptsize
+   \onslide<2-> \textbf{General demands for a parallelized program:}
+   \begin{itemize}
+      \item<3-> Load balancing
+      \item<4-> Small communication overhead
+      \item<5-> Scalability (up to large numbers of processors)
+   \end{itemize}
+   \vspace{2mm}
+   \onslide<6-> \textbf{The basic parallelization method used for PALM is a 2D-domain decomposition along $x$ and $y$:}\\
+   \begin{columns}[T]
+      \begin{column}{0.3\textwidth}
+         \onslide<7-> \includegraphics[width=1.0\textwidth]{parallelization_figures/subdomain.png}
+      \end{column}
+      \begin{column}{0.6\textwidth}
+         \ \\
+         \onslide<8-> contiguous data in memory (FORTRAN):\\
+         \ \\
+         \ \\
+         \textcolor{blue}{columns of i}\\
+         \textcolor{red}{no contiguous data at all}\\
+         \onslide<9-> \textcolor{blue}{columns of k}\\
+         \textcolor{red}{planes of k,j (all data contiguous)}
+      \end{column}
+   \end{columns}   
+   \vspace{2mm}
+   \begin{itemize}
+      \item<10-> Alternatively, a 1D-decomposition along $x$ or $y$ may be used in case of slow networks, but this generally doesn't scale for processor numbers $>$ 256.
+      \item<11-> Message passing is realized using MPI.
+      \item<12-> OpenMP parallelization as well as mixed usage of OpenMP and
+MPI is also possible. (OpenMP tests and optimization is under way)
+   \end{itemize}
+\end{frame}
+
+% Folie 5
+\begin{frame}
+   \frametitle{Implications of Decomposition}
+   \scriptsize
+   \begin{columns}[T]
+      \begin{column}{0.5\textwidth}
+         \begin{itemize}
+            \item<2-> Central finite differences cause \textcolor{red}{local data dependencies}\\
+            \ \\
+            solution:  introduction of \textcolor{red}{ghost points}
+            \vspace{5mm}
+            
+            \begin{flushright}
+               \onslide<3-> $\left. \dfrac{\partial \psi}{\partial x} \right|_i = \dfrac{\psi_{i+1} - \psi_{i-1}}{2 \Delta x}$
+            \end{flushright}
+            \vspace{10mm}
+            \item<4-> FFT and linear equation solver cause \textcolor{red}{non-local data dependencies}\\
+            \ \\
+            solution: transposition of 3D-arrays
+         \end{itemize}
+      \end{column}
+      \begin{column}{0.6\textwidth}
+      \begin{center}
+         \vspace{-5mm}
+         \onslide<3-> \includegraphics[width=0.7\textwidth]{parallelization_figures/ghost_points.png}
+         \vspace{4mm}
+         \onslide<5-> \includegraphics[width=0.8\textwidth]{parallelization_figures/fft.png} \end{center}
+         \vspace{-4mm}
+         \textbf{Example: transpositions for solving the poisson equation}
+      \end{column}
+   \end{columns}   
+\end{frame}  
+
+% Folie 6
+\begin{frame}
+   \frametitle{How to Use the Parallelized Version of PALM}   
+   \scriptsize
+   \begin{columns}[T]
+      \begin{column}{1.12\textwidth}
+         \begin{itemize} 
+            \item<1-> The parallel version of PALM is switched on by \texttt{mrun}-option ''\texttt{-K parallel}''. Additionally, the number of required processors and the number of tasks per node (number of PEs to be used on one node) have to be provided:\\
+	         \quad \texttt{mrun ... -K parallel -X64 -T8 ...}
+	         \item<2-> From an accounting point of view, it is always most efficient to use all PEs of a node (\texttt{-T8}) (in case of a ''non-shared'' usage of nodes).
+	         \item<3-> If a normal unix-kernel operating system (not a micro-kernel) is running on each CPU, then there migth be a speed-up of the code, if 1-2 PEs less than the total number of PEs on the node are used.
+	         \item<4-> On machines with a comparably slow network, a 1D-decomposition (along $x$) should be used, because then only two transpositions have to be carried out by the pressure solver. A 1D-decomposition is automatically used for NEC-machines (e.g.  \texttt{-h necriam}). The virtual processor grid to be used can be set manually by d3par-parameters \texttt{npex} and \texttt{npey}.
+            \item<6-> Using the Open-MP parallelization does not yield any advantage over using a pure domain decomposition with MPI (contrary to expectations, it mostly slows down the computational speed), but this may change on cluster systems for very large number of processors ($>$10000?).\\        
+         \end{itemize}
+         \begin{center}
+         \vspace{-7mm}
+         \onslide<5-> \includegraphics[width=0.13\textwidth]{parallelization_figures/folie_6.png}
+         \end{center}
+      \end{column}
+   \end{columns}  
+\end{frame}
+
+% Folie 7
+\begin{frame}
+   \frametitle{MPI Communication}   
+   \scriptsize
+   \begin{columns}[T]
+      \begin{column}{1.12\textwidth}
+         \begin{itemize}
+            \item<1-> MPI (message passing interface) is a portable interface for communication between PEs (FORTRAN or C library).
+            \vspace{2mm}
+            \item<2-> To make MPI available on HLRNâs SGI-ICE, the module \texttt{mpt} must be loaded by setting the \texttt{\%modules} option  in .mrun.config appropriately: 
+
+	         \quad \texttt{\%modules   ...:mpt:...}	
+            \vspace{2mm}
+	         \item<2-> The path to the MPI-library may have to be given in the compiler call, by setting an appropriate option in the configuration file .mrun.config:
+
+	         \quad \texttt{\%lopts  -axW:-cpp:-r8:-nbs:-Vaxlib:\textcolor{blue}{-L:<replace by mpi library path>:-lmpi}}
+            \vspace{2mm}
+	         \item<3-> All MPI calls must be within\\
+	         \quad \texttt{CALL MPI\_INIT( ierror )}\\
+	         \quad $\vdots$\\
+            \quad \texttt{CALL MPI\_FINALIZE( ierror )}\\
+         \end{itemize}
+         
+      \end{column}
+   \end{columns}  
+\end{frame}
+
+% Folie 8
+\begin{frame}
+   \frametitle{Communication Within PALM}   
+   \small
+   \begin{itemize}
+      \item<1-> MPI calls within PALM are available when using the \texttt{mrun}-option ''\texttt{-K parallel}''.
+      \item<2-> Communication is needed for
+      \begin{itemize}
+         \footnotesize
+         \item<2-> exchange of ghost points
+         \item<3-> transpositions (FFT-poisson-solver)
+         \item<4-> calculating global sums (e.g. for calculating horizontal averages)
+      \end{itemize}
+      \item<5-> Additional MPI calls are required to define the so-called virtual processor grid and to define special data types needed for more comfortable exchange of data.
+   \end{itemize}
+\end{frame}
+
+% Folie 9
+\begin{frame}
+   \frametitle{Virtual Processor Grid Used in PALM}   
+   \footnotesize
+   The processor grid and special data types are defined in file \texttt{init\_pegrid.f90}
+   \begin{itemize}
+      \item<2-> PALM uses a two-dimensional virtual processor grid (in case of a 1D-decomposition, it has only one element along $y$). It is defined by a so called communicator (here: \texttt{comm2d}):\\
+      \scriptsize
+      \quad \texttt{ndim = 2}\\
+	   \quad \texttt{pdims(1) = npex    ! \# of processors along x}\\
+	   \quad \texttt{pdims(2) = npey    ! \# of processors along y}\\
+	   \quad \texttt{cyclic(1) = .TRUE.}\\
+	   \quad \texttt{cyclic(2) = .TRUE.}\\
+
+	   \quad \texttt{CALL MPI\underline{\ }CART\underline{\ }CREATE( MPI\underline{\ }COMM\underline{\ }WORLD, ndim, pdims, cyclic,  \&}\\
+	   \quad \texttt{\hspace{10.5em} reorder, \textcolor{blue}{comm2d}, ierr )}  
+      \item<3-> The processor number (id) with respect to this processor grid, \texttt{myid}, is given by:\\
+      \scriptsize
+      \quad \texttt{CALL MPI\underline{\ }COMM\underline{\ }RANK( comm2d, \textcolor{blue}{myid}, ierr )}      
+      \item<4-> The ids of the neighbouring PEs are determined by:\\
+      \scriptsize
+      \quad \texttt{CALL MPI\underline{\ }CARD\underline{\ }SHIFT( comm2d, 0, 1, \textcolor{blue}{pleft},  \textcolor{blue}{pright}, ierr )}\\
+      \quad \texttt{CALL MPI\underline{\ }CARD\underline{\ }SHIFT( comm2d, 1, 1, \textcolor{blue}{psouth}, \textcolor{blue}{pnorth}, ierr )}
+   \end{itemize}
+\end{frame}
+
+% Folie 10
+\begin{frame}
+   \frametitle{Exchange of ghost points}   
+   \scriptsize
+         \begin{itemize}
+            \item<1-> Ghost points are stored in additional array elements added at the horizontal boundaries of the subdomains, e.g.\\
+            \tiny
+            \quad \texttt{u(:,:,nxl\textcolor{blue}{-ngl}), u(:,:,nxr\textcolor{blue}{+ngl})    ! left and right boundary}\\
+            \quad \texttt{u(:,nys\textcolor{blue}{-ngl},:), u(:,nyn\textcolor{blue}{+ngl},:)    ! south and north boundary}\\
+            \hspace{3mm}
+            \item<2-> \scriptsize The exchange of ghost points is done in file \texttt{exchange\underline{\ }horiz.f90}\\
+            \textbf{\underline{Simplified} example:} synchroneous exchange of ghost points along $x$ ($yz$-planes, send left, receive right plane):\\
+            \tiny
+            \quad \texttt{CALL MPI\underline{\ }SENDRECV( ar(nzb,nys-\textcolor{blue}{ngl},nxl),   ngp\underline{\ }yz, MPI\underline{\ }REAL, pleft,  0,}\\
+            \quad \texttt{\hspace{9.5em}ar(nzb,nys-\textcolor{blue}{ngl},nxr+1), ngp\underline{\ }yz, MPI\underline{\ }REAL, pright, 0,}\\
+            \quad \texttt{\hspace{9.5em}comm2d, status, ierr )}\\
+            \hspace{3mm}
+            \item<3-> \scriptsize In the real code special MPI data types (vectors) are defined for exchange of $yz$/$xz$-planes for performance reasons and because array elements to be exchanged are not consecutively stored in memory for $xz$-planes:\\
+            \tiny
+            \quad \texttt{ngp\underline{\ }yz(0) = (nzt - nzb + 2) * (nyn - nys + 1 + 2 * \textcolor{blue}{ngl} )}\\
+            \quad \texttt{CALL MPI\underline{\ }TYPE\underline{\ }VECTOR( \textcolor{blue}{ngl}, ngp\underline{\ }yz(0), ngp\underline{\ }yz(0), MPI\underline{\ }REAL, type\underline{\ }yz(0), ierr )}\\ 
+            \quad \texttt{CALL MPI\underline{\ }TYPE\underline{\ }COMMIT( type\underline{\ }xz(0), ierr )   ! see file init\underline{\ }pegrid.f90}\\
+            \ \\
+            \quad \texttt{CALL MPI\underline{\ }SENDRECV( ar(nzb,nys-ngl,nxl), type\underline{\ }yz(grid\underline{\ }level), MPI\underline{\ }REAL, pleft, 0, ...}\\
+         \end{itemize}       
+\end{frame}
+
+% Folie 11
+\begin{frame}
+   \frametitle{Transpositions}   
+   \footnotesize
+    \begin{columns}[T]
+      \begin{column}{1.05\textwidth}
+         \begin{itemize}
+            \item<1-> Transpositions can be found in file \texttt{transpose.f90} (several subroutines for 1D- or 2D-decompositions; they are called mainly from the FFT pressure solver, see \texttt{poisfft.f90}.\\
+            \ \\
+            \item<2-> The following example is for a transposition from $x$ to $y$, i.e. for the input array all data elements along $x$ reside on the same PE, while after the transposition, all elements along $y$ are on the same PE:\\
+            \ \\
+            \scriptsize
+            \texttt{!}\\
+            \texttt{!--   in SUBROUTINE transpose\underline{\ }xy:}\\
+      	   \texttt{CALL MPI\underline{\ }ALLTOALL( f\underline{\ }inv(nys\underline{\ }x,nzb\underline{\ }x,0), sendrecvcount\underline{\ }xy, MPI\underline{\ }REAL, \&}\\
+      	   \texttt{\hspace{9.5em}work(1), \hspace{6.5em}sendrecvcount\underline{\ }xy, MPI\underline{\ }REAL, \&}\\
+      	   \texttt{\hspace{9.5em}comm1dy, ierr )}\\
+      	   \ \\
+      	   \item<3-> The data resorting before and after the calls of MPI\_ALLTOALL is highly optimized to account for the different processor architectures.
+         \end{itemize}
+      \end{column}
+   \end{columns}  
+\end{frame}
+
+% Folie 12
+\begin{frame}
+   \frametitle{Parallel I/O} 
+   \scriptsize
+   \begin{columns}[T]
+      \begin{column}{1.1\textwidth}
+         \begin{itemize}
+            \item<1-> PALM writes and reads some of the input/output files in parallel, i.e. each processor writes/reads his own file. \textbf{Each file then has a different name!}\\
+            \ \\
+            \textbf{Example:} binary files for restart are written into a subdirectory of the PALM working directory:\\
+            \quad \texttt{BINOUT/\_0000}\\
+	         \quad \texttt{BINOUT/\_0001}\\
+	         \quad $\vdots$
+	         \item<2-> These files can be handled (copied) by \texttt{mrun} using the file attribute \texttt{pe} in the configuration file:\\
+	         \texttt{BINOUT  out:loc:pe restart \~{}/palm/current\underline{\ }version/JOBS/\$fname/RESTART  \underline{\ }d3d}\\
+	         \ \\
+	         \onslide<3->In this case, filenames are interpreted as directory names. 
+	         An \texttt{mrun} call using option\\
+	         ''\texttt{-d example\underline{\ }cbl -r restart}'' will copy the local \textbf{\underline{directory}} \texttt{BINOUT} to the \textbf{\underline{directory}} \texttt{.../RESTART/example\underline{\ }cbl\underline{\ }d3d}  .
+         \end{itemize}
+         \onslide<4-> \textbf{General comment:}
+         \begin{itemize}
+            \item Parallel I/O on a large number of files ($>$1000) currently may cause severe file system problems (e.g. on Lustre file systems). A workaround for this problem will\\ be available soon. 
+         \end{itemize}
+      \end{column}
+   \end{columns}  
+\end{frame}
+
+
+
+% Folie 13
+\begin{frame}
+   \frametitle{PALM Parallel I/O for 2D/3D Data} 
+   \footnotesize
+   \begin{itemize}
+      \item<1-> 2D- and 3D-data output is also written in parallel by the processors (2D: by default, 3D: generally).
+      \item<2-> Because the graphics software (\texttt{ncview}, \texttt{ncl}, \texttt{ferret}, etc.) expect the data to be in one file, these output files have to be merged to one single file after PALM has finished.\\
+      \ \\
+      This is done within the job by calling the utility program \texttt{combine\underline{\ }plot\underline{\ }fields.x} after PALM has successfully finished.
+      \item<3-> \texttt{combine\underline{\ }plot\underline{\ }fields.x} is automatically executed by \texttt{mrun}.
+      \item<4-> The executable \texttt{combine\underline{\ }plot\underline{\ }fields.x} is created during the installation process by the command\\
+      \ \\
+      \quad \texttt{mbuild -u -h <host identifier>}
+   \end{itemize}
+\end{frame}
+
+% Folie 14
+\begin{frame}
+   \frametitle{Performance Examples (I)} 
+   \begin{itemize}
+      \item Simulation using 1536 * 768 * 242 grid points  ($\sim$ 60 GByte)
+   \end{itemize}
+   \includegraphics[scale=0.28]{parallelization_figures/perf_left.png} 
+   \includegraphics[scale=0.28]{parallelization_figures/perf_right.png}
+   \includegraphics[scale=0.28]{parallelization_figures/legende.png}  \\
+   \scriptsize
+      \begin{columns}[T]
+         \begin{column}{0.18\textwidth}
+         \end{column}
+         \begin{column}{0.4\textwidth}
+            IBM-Regatta, HLRN, Hannover\\
+            (1D domain decomposition)
+         \end{column}
+         \begin{column}{0.4\textwidth}
+            Sun Fire X4600, Tokyo Institute of Technology\\
+(2D domain decomposition)
+         \end{column} 
+         \begin{column}{0.2\textwidth}
+         \end{column}           
+         
+      \end{columns}
+
+\end{frame}
+
+% Folie 15
+\begin{frame}
+   \frametitle{Performance Examples (II)} 
+   \begin{itemize}
+      \item Simulation with $2048^3$ grid points  ($\sim$ 2 TByte memory)
+   \end{itemize}
+      \begin{columns}[T]
+         \begin{column}{0.5\textwidth}
+            \includegraphics[scale=0.25]{parallelization_figures/perf_3.png} \\
+            \scriptsize
+            \quad SGI-ICE2, HLRN-II, Hannover\\
+            \quad (2D-domain decomposition)
+         \end{column}
+         \begin{column}{0.5\textwidth}
+            \vspace{35mm}
+            \onslide<2-> currently largest simulation feasible on that system:\\
+            \ \\
+            $4096^3$ grid points
+         \end{column} 
+      \end{columns}
+\end{frame}
+
+\end{document}
Index: /palm/trunk/TUTORIAL/SOURCE/particle_model.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/particle_model.tex	(revision 945)
+++ /palm/trunk/TUTORIAL/SOURCE/particle_model.tex	(revision 945)
@@ -0,0 +1,1425 @@
+% $Id$
+\input{header_tmp.tex}
+%\input{../header_lectures.tex}
+
+\usepackage[utf8]{inputenc}
+\usepackage{ngerman}
+\usepackage{pgf}
+\usetheme{Dresden}
+\usepackage{subfigure}
+\usepackage{units}
+\usepackage{multimedia}
+\usepackage{hyperref}
+\newcommand{\event}[1]{\newcommand{\eventname}{#1}}
+\usepackage{xmpmulti}
+\usepackage{tikz}
+\usetikzlibrary{shapes,arrows,positioning}
+\usetikzlibrary{calc}                             %neues paket
+\usetikzlibrary{decorations.markings}             %neues paket
+\usetikzlibrary{decorations.pathreplacing}        %neues paket
+\def\Tiny{\fontsize{4pt}{4pt}\selectfont}
+\usepackage{amsmath}
+\usepackage{amssymb}
+\usepackage{multicol}
+\usepackage{pdfcomment}
+\usepackage{graphicx}
+\usepackage{listings}
+\lstset{showspaces=false,language=fortran,basicstyle=
+        \ttfamily,showstringspaces=false,captionpos=b}
+
+\institute{Institut fÃŒr Meteorologie und Klimatologie, Leibniz UniversitÃ€t Hannover}
+\date{last update: \today}
+\event{PALM Seminar}
+\setbeamertemplate{navigation symbols}{}
+
+\setbeamertemplate{footline}
+  {
+    \begin{beamercolorbox}[rightskip=-0.1cm]&
+     {\includegraphics[height=0.65cm]{imuk_logo.pdf}\hfill \includegraphics[height=0.65cm]{luh_logo.pdf}}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[ht=2.5ex,dp=1.125ex,
+      leftskip=.3cm,rightskip=0.3cm plus1fil]{title in head/foot}
+      {\leavevmode{\usebeamerfont{author in head/foot}\insertshortauthor} \hfill \eventname \hfill \insertframenumber \; / \inserttotalframenumber}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[colsep=1.5pt]{lower separation line foot}
+    \end{beamercolorbox}
+  }
+%\logo{\includegraphics[width=0.3\textwidth]{luhimuk_logo.pdf}}
+
+\title[PALM's Lagrangian Particle Model]{PALM's Lagrangian Particle Model}
+\author{Siegfried Raasch}
+
+\begin{document}
+
+% Folie 1
+\begin{frame}
+\titlepage
+\end{frame}
+
+\section{The embedded Lagrangian particle model}
+\subsection{The embedded Lagrangian particle model}
+
+% Folie 2
+\begin{frame}
+   \frametitle{Overview}
+
+   \begin{itemize}     
+	   \item<1-> The Lagrangian particle model embedded in PALM can be used for
+different purposes:
+	   \begin{itemize}
+	   \footnotesize
+	      \item Cloud droplet simulation
+	      \item Dispersion modelling / Footprint analysis 
+	      \item Visualization
+      \end{itemize}   
+      \vspace{3mm}
+      \item<2-> Therefore the particles can have different properties, e.g.: 
+      \begin{itemize}
+         \footnotesize
+	      \item Particles can be transported (advected) \textbf{passively} with the \textbf{resolved-scale} flow
+	      \item Particle transport by the subgrid-scale (SGS) turbulence can be included by switching on a stochastic SGS model for the particle transport (parameter: \texttt{use\underline{ }sgs\underline{ }for\underline{ }particles})
+	      \item Particles can be given a mass and thus an \textbf{inertia} and a \textbf{radius} which affects their \textbf{flow resistance} (parameter: \texttt{density\underline{ }ratio}, \texttt{radius})
+	      \item Tails can be added to the particles (showing the particle trajectories) for visualization purpose using the special visualization package \textbf{dvrp}
+      \end{itemize}   
+   \end{itemize}   
+\end{frame}
+
+
+% Folie 3
+\begin{frame}
+   \frametitle{Basics (I)}
+
+   \begin{itemize}     
+	   \item<1-> The particle model is switched on by adding a \texttt{\&particles\underline{ }par} NAMELIST to the parameter file (PARIN). This NAMELIST has to be added \textbf{after} the \texttt{\&d3par}-NAMELIST.
+	   \item All parameters for steering the particle model are described in: Documentation $\rightarrow$ Model steering $\rightarrow$ Parameters $\rightarrow$ Particles (http://palm.muk.uni-hannover.de/)
+	   \item \textbf{The particle model requires to use a constant vertical grid spacing (due to the implemented scheme for the interpolation of information from the LES grid to particle positions, that is required for the calculation of particle velocities)!}
+   \end{itemize}
+\end{frame}
+
+% Folie 4
+\begin{frame}
+   \frametitle{Basic Particle Parameters (I)}
+   \small
+   Parameters that define the locations of particle source(s):
+   \begin{itemize}
+      \item Step I: Define the volume of the particle source
+   \end{itemize}
+
+   \begin{tikzpicture}
+      \definecolor{darkgreen1}{rgb}{0.2,0.7,0.2}
+      \definecolor{darkgreen2}{rgb}{0.4,0.7,0.4}
+      \definecolor{darkgreen3}{rgb}{0.1,0.6,0.2}
+     
+      % Draw the box
+      \onslide<2->
+      \draw[-] (0,0) -- (5,0);
+      \draw[-] (0,0) -- (0,4);
+      \draw[-] (5,4) -- (5,0);
+      \draw[-] (0,4) -- (5,4);
+      \draw[-] (2,1.5) -- (7,1.5);
+      \draw[-] (2,1.5) -- (2,5.5);
+      \draw[-] (7,5.5) -- (7,1.5);
+      \draw[-] (2,5.5) -- (7,5.5);
+      \draw[-] (0,0) -- (2,1.5);
+      \draw[-] (5,0) -- (7,1.5);
+      \draw[-] (5,4) -- (7,5.5);
+      \draw[-] (0,4) -- (2,5.5);
+      \node at (4,5) {\small Total model domain};
+     
+      % Draw coordinate system
+      \node at (8.5,2.5) [scale=1.0] {%
+      \begin{tikzpicture}
+         \draw[->] (0,0) -- (1,0);
+         \draw[->] (0,0) -- (0,1);
+         \draw[->] (0,0) -- (0.5,0.5);
+         \node at (-0.2,0.9) {z};
+         \node at (0.9,-0.2) {x};
+         \node at (0.65,0.3) {y};
+      \end{tikzpicture}
+      };
+      
+      % Draw green box
+      \onslide<3->
+      \draw[fill=darkgreen1,draw=darkgreen1,opacity=.95]
+         (0,1) -- 
+         (3,1) --
+         (3,2.5) --
+         (0,2.5) -- cycle ;
+      \draw[fill=darkgreen2,draw=darkgreen2,opacity=.95]
+         (3,1) -- 
+         (4,1.75) --
+         (4,3.25) --
+         (3,2.5) -- cycle ;
+      \draw[fill=darkgreen3,draw=darkgreen3,opacity=.95]
+         (0,2.5) -- 
+         (3,2.5) --
+         (4,3.25) --
+         (1,3.25) -- cycle ;
+      \node at (1.5,2) {\small \glqq Source Volume\grqq };         
+      
+      % Dashed green lines   
+      \draw[dashed, ultra thick, color=darkgreen3] (0,1) -- (0,0);
+      \draw[dashed, ultra thick, color=darkgreen3] (3,1) -- (3,0);
+      \draw[dashed, ultra thick, color=darkgreen3] (3,1) -- (5,1); 
+      \draw[dashed, ultra thick, color=darkgreen3] (4,1.75) -- (6,1.75);
+      \draw[dashed, ultra thick, color=darkgreen3] (5,1) -- (5,0); 
+      \draw[dashed, ultra thick, color=darkgreen3] (6,1.75) -- (6,0.75);
+      
+      % Add Labels
+      \node at (1,-0.25) {\scriptsize \texttt{ps1} (default 0.0)}; 
+      \node at (4.25,-0.25) {\scriptsize \texttt{psr} (default \texttt{nx*dx})}; 
+      \node at (7,0) {\scriptsize \texttt{pss} (default 0.0)}; 
+      \node at (8,0.75) {\scriptsize \texttt{psn} (default \texttt{ny*dy})}; 
+      \node [text width=4em] at (-0.7,0.5) {\scriptsize \texttt{psb} (default zu(\texttt{nz}/2))}; 
+      \node [text width=4em] at (-0.7,2) {\scriptsize \texttt{pst} (default zu(\texttt{nz}/2))};  
+      
+   \onslide<1->
+   \end{tikzpicture}
+\end{frame}
+
+% Folie 5
+\begin{frame}
+   \frametitle{Basic Particle Parameters (II)}
+   \small
+   Parameters that define the locations of particle source(s):
+   \begin{itemize}
+      \item Step IIa: Define the points of single particle release   
+   \end{itemize}
+   
+   \begin{tikzpicture}
+      \definecolor{darkgreen}{rgb}{0.0,0.35,0.0}
+      \definecolor{darkgreen3}{rgb}{0.2,0.6,0.2}
+      \definecolor{darkred}{rgb}{0.5,0.0,0.0}
+      
+      % Draw green box (except for one line that is drawn later)
+      \draw[-, ultra thick, color=darkgreen3] (0,0) -- (5,0);
+      \draw[-, ultra thick, color=darkgreen3] (0,0) -- (0,4);
+      \draw[-, ultra thick, color=darkgreen3] (0,4) -- (5,4);
+      \draw[-, ultra thick, color=darkgreen3] (2,1.5) -- (7,1.5);
+      \draw[-, ultra thick, color=darkgreen3] (2,1.5) -- (2,5.5);
+      \draw[-, ultra thick, color=darkgreen3] (7,5.5) -- (7,1.5);
+      \draw[-, ultra thick, color=darkgreen3] (2,5.5) -- (7,5.5);
+      \draw[-, ultra thick, color=darkgreen3] (0,0) -- (2,1.5);
+      \draw[-, ultra thick, color=darkgreen3] (5,0) -- (7,1.5);
+      \draw[-, ultra thick, color=darkgreen3] (5,4) -- (7,5.5);
+      \draw[-, ultra thick, color=darkgreen3] (0,4) -- (2,5.5);
+      \node at (4,5) {\small \glqq Source Volume\grqq};
+      
+      % Draw circles and dashed lines
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd1) at (0,0) {};
+      \node at (0,0) {1};
+      \onslide<2->
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd2) at (2,0) {};
+      \draw[dashed, ultra thick, color=blue] (rd1) -- (rd2);
+      \node at (2,0) {2};
+      \node at (1,-0.25) {\scriptsize \texttt{pdx}};
+      \onslide<3->
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd3) at (4,0) {};
+      \draw[dashed, ultra thick, color=blue] (rd2) -- (rd3);
+      \node at (4,0) {3};
+      \onslide<4>
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rdx1) at (6,0) {};
+      \draw[dashed, ultra thick, color=blue] (rd3) -- (rdx1);
+      \node[scale=1.6] at (6,0) {X};
+      \onslide<6->
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd4) at (1.5,1.125) {};
+      \draw[dashed, ultra thick, color=darkgreen] (rd1) -- (rd4);      
+      \node at (1.5,1.125) {4};  
+      \node at (1.1,0.43) {\scriptsize \texttt{pdy}};
+      \onslide<7->
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd5) at (3.5,1.125) {};
+      \draw[dashed, ultra thick, color=blue] (rd4) -- (rd5);
+      \node at (3.5,1.125) {5}; 
+      \onslide<7->      
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd6) at (5.5,1.125) {};
+      \draw[dashed, ultra thick, color=blue] (rd5) -- (rd6);
+      \node at (5.5,1.125) {6};
+      \onslide<8>
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rdx2) at (3,2.25) {};   
+      \draw[dashed, ultra thick, color=darkgreen] (rd4) -- (rdx2);
+      \node[scale=1.6] at (3,2.25) {X};
+      \onslide<10->      
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd7) at (0,2.2) {};
+      \draw[dashed, ultra thick, color=darkred] (rd1) -- (rd7);
+      \node at (0,2.2) {7};
+      \node at (0.3,1.3) {\scriptsize \texttt{pdz}};
+      \onslide<11->
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd8) at (2,2.2) {};
+      \draw[dashed, ultra thick, color=blue] (rd7) -- (rd8);
+      \node at (2,2.2) {8};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd9) at (4,2.2) {};
+      \draw[dashed, ultra thick, color=blue] (rd8) -- (rd9);
+      \node at (4,2.2) {9};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd10) at (1.5,3.325) {};
+      \draw[dashed, ultra thick, color=darkgreen] (rd7) -- (rd10);      
+      \node[scale=0.8] at (1.5,3.325) {10};  
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd11) at (3.5,3.325) {};
+      \draw[dashed, ultra thick, color=blue] (rd10) -- (rd11);
+      \node[scale=0.8] at (3.5,3.325) {11}; 
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd12) at (5.5,3.325) {};
+      \draw[dashed, ultra thick, color=blue] (rd11) -- (rd12);
+      \node[scale=0.8] at (5.5,3.325) {12};            
+      \onslide<12>      
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rdx3) at (0,4.4) {};
+      \draw[dashed, ultra thick, color=darkred] (rd7) -- (rdx3);
+      \node[scale=1.6] at (0,4.4) {X};
+      
+      % Draw rest of the green box
+      \onslide<1-13>
+      \draw[-, ultra thick, color=darkgreen3] (5,4) -- (5,0); 
+      
+      % Draw coordinate system
+      \node at (7.2,0.1) [scale=1.0] {%
+      \begin{tikzpicture}
+         \draw[->] (0,0) -- (1,0);
+         \draw[->] (0,0) -- (0,1);
+         \draw[->] (0,0) -- (0.5,0.5);
+         \node at (-0.2,0.9) {z};
+         \node at (0.9,-0.2) {x};
+         \node at (0.65,0.3) {y};
+      \end{tikzpicture}
+      };
+      
+      % Add text
+      \node at (9.0,3) [scale=0.8] {%
+      \begin{tikzpicture}
+         \node[text width=11em] {\scriptsize \texttt{maximum\underline{ }number\underline{ }of\underline{ }particles} number of particles (per PE) for that memory must be allocated at the beginning of a run; this number must be $\ge$ the initial number of particles \textbf{per subdomain(!)}.\\ \ \\ \textbf{Attention:} If netCDF output of particle data is switched on, \texttt{maximum\underline{ }number\underline{ }of\underline{ }particles} must be $\ge$ the maximum number of particles per subdomain observed throughout the complete run!\\ \ \\ Choosing a too large value may cause memory problems!\\};
+      \end{tikzpicture}
+      };      
+      
+   \end{tikzpicture}
+   
+\end{frame}
+
+% Folie 6
+\begin{frame}
+   \frametitle{Basic Particle Parameters (III)}
+   \small
+   Parameters that define the locations of particle source(s):
+   \begin{itemize}
+      \item Step IIb: Random start positions of particles 
+   \end{itemize}
+   
+   \begin{tikzpicture}
+      \definecolor{darkgreen3}{rgb}{0.2,0.6,0.2}
+
+      % Draw green box
+      \draw[-, ultra thick, color=darkgreen3] (0,0) -- (5,0);
+      \draw[-, ultra thick, color=darkgreen3] (0,0) -- (0,4);
+      \draw[-, ultra thick, color=darkgreen3] (5,4) -- (5,0); 
+      \draw[-, ultra thick, color=darkgreen3] (0,4) -- (5,4);
+      \draw[-, ultra thick, color=darkgreen3] (2,1.5) -- (7,1.5);
+      \draw[-, ultra thick, color=darkgreen3] (2,1.5) -- (2,5.5);
+      \draw[-, ultra thick, color=darkgreen3] (7,5.5) -- (7,1.5);
+      \draw[-, ultra thick, color=darkgreen3] (2,5.5) -- (7,5.5);
+      \draw[-, ultra thick, color=darkgreen3] (0,0) -- (2,1.5);
+      \draw[-, ultra thick, color=darkgreen3] (5,0) -- (7,1.5);
+      \draw[-, ultra thick, color=darkgreen3] (5,4) -- (7,5.5);
+      \draw[-, ultra thick, color=darkgreen3] (0,4) -- (2,5.5);
+
+      
+      % Draw circles and dashed lines
+      \onslide<1-3>
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd3) at (4,0) {};
+      \node at (4,0) {3};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd9) at (4,2.2) {};
+      \node at (4,2.2) {9};
+
+      \onslide<1>
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd1) at (0,0) {};
+      \node at (0,0) {1};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd2) at (2,0) {};
+      \node at (2,0) {2};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd4) at (1.5,1.125) {};
+      \node at (1.5,1.125) {4};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd5) at (3.5,1.125) {};
+      \node at (3.5,1.125) {5}; 
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd6) at (5.5,1.125) {};
+      \node at (5.5,1.125) {6};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd7) at (0,2.2) {};
+      \node at (0,2.2) {7};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd8) at (2,2.2) {};
+      \node at (2,2.2) {8};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd10) at (1.5,3.325) {};
+      \node[scale=0.8] at (1.5,3.325) {10};  
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd11) at (3.5,3.325) {};
+      \node[scale=0.8] at (3.5,3.325) {11}; 
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd12) at (5.5,3.325) {};
+      \node[scale=0.8] at (5.5,3.325) {12};
+                  
+      \onslide<3>
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd1n) at (1.0,0.3) {};
+      \node at (1.0,0.3) {1};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd2n) at (1.8,0.3) {};
+      \node at (1.8,0.3) {2};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd4n) at (1.7,1.0) {};
+      \node at (1.7,1.0) {4};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd5n) at (3.0,1.2) {};
+      \node at (3.0,1.2) {5}; 
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd6n) at (4.5,1.125) {};
+      \node at (4.5,1.125) {6}; 
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd7n) at (0.9,2.8) {};
+      \node at (0.9,2.8) {7};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd8n) at (3,1.8) {};
+      \node at (3,1.8) {8};
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd10n) at (2.1,3) {};
+      \node[scale=0.8] at (2.1,3) {10};     
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd11n) at (4,4.5) {};
+      \node[scale=0.8] at (4,4.5) {11}; 
+      \node[circle, draw, thick, fill=red!90, scale=1.1] (rd12n) at (4.5,3.2) {};
+      \node[scale=0.8] at (4.5,3.2) {12};      
+      
+      % Draw coordinate system
+      \onslide<1->
+      \node at (9,2) [scale=1.0] {%
+      \begin{tikzpicture}
+         \draw[->] (0,0) -- (1,0);
+         \draw[->] (0,0) -- (0,1);
+         \draw[->] (0,0) -- (0.5,0.5);
+         \node at (-0.2,0.9) {z};
+         \node at (0.9,-0.2) {x};
+         \node at (0.65,0.3) {y};
+      \end{tikzpicture}
+      };
+      
+      % Add text
+      \node at (9.2,4) {\scriptsize \texttt{random\underline{ }start\underline{ }position = .T.}};
+      
+   \end{tikzpicture}
+   
+\end{frame}
+
+% Folie 7
+\begin{frame}
+   \frametitle{Basic Particle Parameters (IV)}
+   \small
+   Parameters that define the period of particle release: \\
+   \vspace{10mm}
+   \begin{columns}[T]
+      \begin{column}{1.15\textwidth}
+         \begin{tikzpicture}
+            \definecolor{darkred}{rgb}{0.6,0.1,0.1}
+            \definecolor{grey}{rgb}{0.25,0.25,0.25}
+            \draw[->, ultra thick] (0,0) -- (10.5,0);
+            \draw[->, ultra thick] (0,0.5) -- (0,-0.5);
+            \node at (10.7,0) {t};
+            \node at (0,-0.8) {0};    
+            \node[text width=6em] at (0.2,-1.9) {\scriptsize Start of LES, determination of particle release points};
+      
+            \onslide<2->
+            \draw[->, ultra thick, color=red] (2.5,0.5) -- (2.5,-0.5);
+            \node at (2.8,-0.8) {\scriptsize \texttt{particle\underline{ }advection\underline{ }start}};       
+            \node[text width=6em] at (2.8,-2.1) {\scriptsize Calculation of particle trajectories begins (default value: 0.0)};
+      
+      
+      
+      
+            \onslide<3->
+            \draw[->, ultra thick, color=red] (5,0.5) -- (5,-0.5);
+            \node[text width=4em] at (4.8,-1.7) {\scriptsize Release of a new set of particles};  
+            \node at (3.75,0.3) {\scriptsize \texttt{dt\underline{ }prel}};
+            \draw[<->, thick, color=blue] (2.5,0.6) -- (4.95,0.6); 
+      
+      
+      
+            \onslide<4->
+            \draw[->, ultra thick, color=darkred] (6.5,0.5) -- (6.5,-0.5);   
+            \node[text width=5em] at (6.7,-1.7) {\scriptsize Deletion of the first set of particles};
+            \draw[<->, thick, color=darkred] (2.5,0.9) -- (6.5,0.9); 
+            \node at (4.5,1.2) {\scriptsize \texttt{particle\underline{ }maximum\underline{ }age}};
+     
+            \onslide<5->
+            \draw[->, ultra thick, color=darkred] (8.5,0.5) -- (8.5,-0.5);  
+            \node[text width=5em] at (8.6,-1.9) {\scriptsize No release of new particles after this time};
+            \node at (8.5,-0.8) {\scriptsize \texttt{end\underline{ }time\underline{ }prel}};
+            \draw[<->, thick, color=blue] (5.05,0.6) -- (8.5,0.6); 
+
+            \onslide<6->
+            \draw[->, ultra thick, color=grey] (10.2,0.5) -- (10.2,-0.5);     
+            \node[text width=5em] at (10.7,-1.9) {\scriptsize Deletion of the second set of particles};
+            \draw[<->, thick, color=darkred] (5.0,1.6) -- (10.2,1.6); 
+            
+            \onslide<1->
+         \end{tikzpicture}
+       \end{column}
+   \end{columns}
+
+  
+\end{frame}
+
+% Folie 8
+\begin{frame}[t]
+   \frametitle{Basic Particle Parameters (V)}
+   \small
+   Parameter that defines the mode of particle movement: \\
+   The concept of LES ...\\
+   \vspace{-5mm}
+   \begin{center}
+      \includegraphics[scale=0.1]{particle_model_figures/basic_particle_parameters_5.png}
+   \end{center}
+   \vspace{-5mm}
+   \onslide<2->
+   ... transferred to the embedded particle model leads to particle velocity\\
+   \vspace{1mm}
+   \begin{columns}[T]
+      \begin{column}{0.35\textwidth}
+         $\vec{V}_{i_{\text{particle}}} = \vec{V}_{i_{\text{resolved}}} + \vec{V}_{i_{\text{subgrid}}}$
+      \end{column}
+      \begin{column}{0.55\textwidth}
+         \scriptsize
+         \onslide<3->
+         Particle movement as a result of 
+         \begin{itemize}
+            \item advection, resolved turbulence $\vec{V}_{i_{\text{resolved}}}$
+            \vspace{-2mm}
+            \item and subgrid turbulence $\vec{V}_{i_{\text{subgrid}}}$
+         \end{itemize}
+      \end{column}
+   \end{columns}
+   
+   \begin{tikzpicture}[remember picture, overlay]
+      \node [shift={(6 cm,-6.3cm)}]  at (current page.north west)
+         {%
+         \begin{tikzpicture}[remember picture, overlay]
+            \uncover<4->{\draw[->, ultra thick] (-2.05,0) -- (-5,-0.8);
+            \node[text width=14em] at (-3.2,-1.5) {\scriptsize $=0$, if \texttt{use\underline{ }sgs\underline{ }for\underline{ }particles = .F.} (default value)\\};}
+            \uncover<5->{\draw[->, ultra thick] (-1.95,0) -- (0,-0.8);
+            \node[text width=20em] at (3.2,-1.5) {\scriptsize $\ne0$, if \texttt{use\underline{ }sgs\underline{ }for\underline{ }particles = .T.}\\ determination of the subgrid part of the particle velocity as a solution of a stochastic differential equation\\};
+            \node[text width=14em] at (2.5,-2.5) {\scriptsize requires initialization parameter \texttt{use\underline{ }upstream\underline{ }for\underline{ }tke = .T.}\\ };}
+         \end{tikzpicture}
+         };
+    \end{tikzpicture}
+
+\end{frame}
+
+% Folie 9
+\begin{frame}[t]
+   \frametitle{Basic Particle Parameters (VI)}
+   \small
+   \vspace{-2mm}
+   Parameter \texttt{dt\underline{ }sort\underline{ }particles} that improves the performance of a simulation with (many) particles:
+
+   \onslide<2->
+   \begin{tikzpicture}[remember picture, overlay]
+      \node [shift={(1 cm,2.5cm)}]  at (current page.south west)
+         {%
+         \begin{tikzpicture}[remember picture, overlay]
+            \node at (2.5,4.2) {$t=t_0$:};
+            \draw[-] (0,0) -- (5,0);
+            \draw[-] (0,1) -- (5,1);
+            \draw[-] (0,2) -- (5,2);
+            \draw[-] (0,3) -- (5,3);
+            \draw[-] (0,0) -- (0,4);
+            \draw[-] (1,0) -- (1,4);            
+            \draw[-] (2,0) -- (2,4);             
+            \draw[-] (3,0) -- (3,4); 
+            \draw[-] (4,0) -- (4,4);            
+            \draw[-] (5,4) -- (5,0);
+            \draw[-] (0,4) -- (5,4);
+            
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd1) at (0.25,0.5) {};
+            \node[scale=0.8] at (rd1) {1};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd2) at (0.75,0.5) {};
+            \node[scale=0.8] at (rd2) {2};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd3) at (1.25,0.5) {};
+            \node[scale=0.8] at (rd3) {3};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd4) at (1.75,0.5) {};
+            \node[scale=0.8] at (rd4) {4};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd5) at (2.25,0.5) {};
+            \node[scale=0.8] at (rd5) {5};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd6) at (2.75,0.5) {};
+            \node[scale=0.8] at (rd6) {6};   
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd7) at (3.25,0.5) {};
+            \node[scale=0.8] at (rd7) {7};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd8) at (3.75,0.5) {};
+            \node[scale=0.8] at (rd8) {8};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd9) at (4.25,0.5) {};
+            \node[scale=0.8] at (rd9) {9};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd10) at (4.75,0.5) {};
+            \node[scale=0.8] at (rd10) {10};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd11) at (0.25,2.5) {};
+            \node[scale=0.8] at (rd11) {11};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd12) at (0.75,2.5) {};
+            \node[scale=0.8] at (rd12) {12};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd13) at (1.25,2.5) {};
+            \node[scale=0.8] at (rd13) {13};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd14) at (1.75,2.5) {};
+            \node[scale=0.8] at (rd14) {14};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd15) at (2.25,2.5) {};
+            \node[scale=0.8] at (rd15) {15};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd16) at (2.75,2.5) {};
+            \node[scale=0.8] at (rd16) {16};   
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd17) at (3.25,2.5) {};
+            \node[scale=0.8] at (rd17) {17};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd18) at (3.75,2.5) {};
+            \node[scale=0.8] at (rd18) {18};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd19) at (4.25,2.5) {};
+            \node[scale=0.8] at (rd19) {19};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd20) at (4.75,2.5) {};
+            \node[scale=0.8] at (rd20) {20};  
+                   
+            \node[text width=14em] at (2.5,-0.9) {\scriptsize Particles are sorted in a way that their order follows the order in which the grid point values are stored (beneficial as the code contains many loops over all particles)\\};
+
+         \end{tikzpicture}
+         };
+      \uncover<3->{
+      \node [shift={(7 cm,2.5cm)}]  at (current page.south west)
+         {%
+         \begin{tikzpicture}[remember picture, overlay]
+
+            \node at (2.5,4.2) {$t>t_0$:};
+            \draw[-] (0,0) -- (5,0);
+            \draw[-] (0,1) -- (5,1);
+            \draw[-] (0,2) -- (5,2);
+            \draw[-] (0,3) -- (5,3);
+            \draw[-] (0,0) -- (0,4);
+            \draw[-] (1,0) -- (1,4);            
+            \draw[-] (2,0) -- (2,4);             
+            \draw[-] (3,0) -- (3,4); 
+            \draw[-] (4,0) -- (4,4);            
+            \draw[-] (5,4) -- (5,0);
+            \draw[-] (0,4) -- (5,4);
+            
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd1) at (1.75,1.3) {};
+            \node[scale=0.8] at (rd1) {1};
+         
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd2) at (1.2,2.3) {};
+            \node[scale=0.8] at (rd2) {2};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd3) at (2.3,2.3) {};
+            \node[scale=0.8] at (rd3) {3};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd4) at (3.25,1.21) {};
+            \node[scale=0.8] at (rd4) {4};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd5) at (3.2,2.7) {};
+            \node[scale=0.8] at (rd5) {5};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd6) at (3.25,1.7) {};
+            \node[scale=0.8] at (rd6) {6};   
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd7) at (1.25,1.6) {};
+            \node[scale=0.8] at (rd7) {7};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd8) at (3.7,0.5) {};
+            \node[scale=0.8] at (rd8) {8};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd9) at (3.77,1.8) {};
+            \node[scale=0.8] at (rd9) {9};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd10) at (2.6,1.3) {};
+            \node[scale=0.8] at (rd10) {10};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd11) at (2.7,0.7) {};
+            \node[scale=0.8] at (rd11) {11};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd12) at (0.21,1.3) {};
+            \node[scale=0.8] at (rd12) {12};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd13) at (0.3,2.5) {};
+            \node[scale=0.8] at (rd13) {13};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd14) at (1.75,2.5) {};
+            \node[scale=0.8] at (rd14) {14};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd15) at (2.3,1.7) {};
+            \node[scale=0.8] at (rd15) {15};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd16) at (2.4,2.8) {};
+            \node[scale=0.8] at (rd16) {16};   
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd17) at (4.23,0.7) {};
+            \node[scale=0.8] at (rd17) {17};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd18) at (3.77,2.6) {};
+            \node[scale=0.8] at (rd18) {18};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd19) at (4.23,3.3) {};
+            \node[scale=0.8] at (rd19) {19};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd20) at (3.75,1.23) {};
+            \node[scale=0.8] at (rd20) {20};  
+            
+            \node[text width=14em] at (2.5,-1.05) {\scriptsize By default, particles are not sorted after every time step, particles with subsequent numbers will need information from quite different LES grid points\\ \textcolor{red}{Bad cache utilization}\\};
+            \node at (-0.2,-1.9) {$\rightarrow$};
+         \end{tikzpicture}
+         };}
+   \end{tikzpicture} 
+\end{frame}
+
+% Folie 10
+\begin{frame}[t]
+   \frametitle{Basic Particle Parameters (VI)}
+   \small
+   \vspace{-2mm}
+   Parameter \texttt{dt\underline{ }sort\underline{ }particles} that improves the performance of a simulation with (many) particles:
+
+   \begin{tikzpicture}[remember picture, overlay]
+      \node [shift={(1 cm,2.5cm)}]  at (current page.south west)
+         {%
+         \begin{tikzpicture}[remember picture, overlay]
+            \node[text width=14em] at (2.5,3.8) {Higher performance with\\ resorting of particles:\\};
+            \uncover<2->{\node[text width=14em] at (2.5,1.6) {\scriptsize Temporal interval between the\\ sorting of particles determined\\ by the parameter\\ \ \\ \texttt{dt\underline{ }sort\underline{ }particles}\\ \ \\ (default value 0.0, i.e. particles are resorted at every time step)};}  
+            \uncover<3->{\node[text width=28em] at (5,-0.9) {Keep in mind that resorting of particles is time consuming itself, so that using the default value of \texttt{dt\underline{ }sort\underline{ }particles} probably wonât yield the best performance that is possible.\\};}
+         \end{tikzpicture}
+         };
+      \node [shift={(7 cm,2.5cm)}]  at (current page.south west)
+         {%
+         \begin{tikzpicture}[remember picture, overlay]
+
+            \node at (2.5,4.2) {$t>t_0$:};
+            \draw[-] (0,0) -- (5,0);
+            \draw[-] (0,1) -- (5,1);
+            \draw[-] (0,2) -- (5,2);
+            \draw[-] (0,3) -- (5,3);
+            \draw[-] (0,0) -- (0,4);
+            \draw[-] (1,0) -- (1,4);            
+            \draw[-] (2,0) -- (2,4);             
+            \draw[-] (3,0) -- (3,4); 
+            \draw[-] (4,0) -- (4,4);            
+            \draw[-] (5,4) -- (5,0);
+            \draw[-] (0,4) -- (5,4);
+            
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd1) at (1.75,1.3) {};
+            \node[scale=0.8] at (rd1) {1};
+         
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd2) at (1.2,2.3) {};
+            \node[scale=0.8] at (rd2) {2};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd3) at (2.3,2.3) {};
+            \node[scale=0.8] at (rd3) {3};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd4) at (3.25,1.21) {};
+            \node[scale=0.8] at (rd4) {4};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd5) at (3.2,2.7) {};
+            \node[scale=0.8] at (rd5) {5};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd6) at (3.25,1.7) {};
+            \node[scale=0.8] at (rd6) {6};   
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd7) at (1.25,1.6) {};
+            \node[scale=0.8] at (rd7) {7};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd8) at (3.7,0.5) {};
+            \node[scale=0.8] at (rd8) {8};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd9) at (3.77,1.8) {};
+            \node[scale=0.8] at (rd9) {9};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd10) at (2.6,1.3) {};
+            \node[scale=0.8] at (rd10) {10};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd11) at (2.7,0.7) {};
+            \node[scale=0.8] at (rd11) {11};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd12) at (0.21,1.3) {};
+            \node[scale=0.8] at (rd12) {12};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd13) at (0.3,2.5) {};
+            \node[scale=0.8] at (rd13) {13};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd14) at (1.75,2.5) {};
+            \node[scale=0.8] at (rd14) {14};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd15) at (2.3,1.7) {};
+            \node[scale=0.8] at (rd15) {15};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd16) at (2.4,2.8) {};
+            \node[scale=0.8] at (rd16) {16};   
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd17) at (4.23,0.7) {};
+            \node[scale=0.8] at (rd17) {17};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd18) at (3.77,2.6) {};
+            \node[scale=0.8] at (rd18) {18};      
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd19) at (4.23,3.3) {};
+            \node[scale=0.8] at (rd19) {19};
+            \node[circle, draw, thick, fill=red!90, scale=1.1] (rd20) at (3.75,1.23) {};
+            \node[scale=0.8] at (rd20) {20};  
+         \end{tikzpicture}
+         };
+   \end{tikzpicture} 
+\end{frame}
+
+% Folie 11
+\begin{frame}[t]
+   \frametitle{Basic Particle Parameters (VI)}
+   \small
+   Example for the beneficial effect of resorting on the consumption of CPU time \texttt{(dt\underline{ }sort\underline{ }particles = 0.0)}:\\
+   \scriptsize \ \\
+   Release of 3.200.000 particles into a convective boundary layer.\\
+   Extract from CPU time measurement file.\\
+   \ \\
+
+   \begin{tabular}{|p{2.5cm}|p{1.3cm}|p{1.3cm}|p{1.3cm}|p{1.3cm}|p{1.3cm}|}
+      \hline
+	   Part of PALM & Consumed CPU time in s \textbf{without resorting} & Percentage of totally consumed CPU time \textbf{(without)} & Consumed CPU time in s \textbf{with resorting}  & Percentage of totally consumed CPU time \textbf{(with)} & Saved CPU time \textbf{with resorting} in \%\\
+      \hline
+	   total & 50027.225 & 100.0 & 47805.635  & 100.0 & \textcolor{red}{4.4}\\
+      \hline
+	   advec\underline{ }particles & 22049.711 & 44.08 & 19926.364  & 41.68  & \textcolor{red}{9.6}\\
+      \hline
+	   advec\underline{ }particles\underline{ }advec & 13640.729 & 27.27 & 11424.540  & 23.90  & \textcolor{red}{16.2}\\
+      \hline
+   \end{tabular}
+
+
+\end{frame}
+
+% Folie 12
+\begin{frame}[t]
+   \frametitle{Basic Particle Parameters (VII)}
+   \small
+   \vspace{-2mm}
+   Parameters that define the boundary conditions for particles\\
+   \scriptsize \ \\
+   \uncover<10>{In PALM particles are \textbf{always} reflected at \textbf{vertical walls and roofs of buildings.}}\\
+   \ \\
+
+   \begin{tikzpicture}
+      \definecolor{darkgreen}{rgb}{0.2,0.7,0.2}
+      % Bottom
+      \uncover<2>{\draw[fill=darkgreen,draw=darkgreen,opacity=.85]
+         (0,0) -- 
+         (2,1.5) --
+         (7,1.5) --
+         (5,0) -- cycle ;}
+      % Top
+      \uncover<4>{\draw[fill=darkgreen,draw=darkgreen,opacity=.85]
+         (0,4) -- 
+         (2,5.5) --
+         (7,5.5) --
+         (5,4) -- cycle ;}
+      % Front
+      \uncover<6>{\draw[fill=darkgreen,draw=darkgreen,opacity=.85]
+         (0,0) -- 
+         (0,4) --
+         (5,4) --
+         (5,0) -- cycle ;}
+      % Back
+      \uncover<6>{\draw[fill=darkgreen,draw=darkgreen,opacity=.85]
+         (2,1.5) -- 
+         (7,1.5) --
+         (7,5.5) --
+         (2,5.5) -- cycle ;}
+      % Left
+      \uncover<8>{\draw[fill=darkgreen,draw=darkgreen,opacity=.85]
+         (0,0) -- 
+         (0,4) --
+         (2,5.5) --
+         (2,1.5) -- cycle ;}
+      % Right
+      \uncover<8>{\draw[fill=darkgreen,draw=darkgreen,opacity=.85]
+         (5,0) -- 
+         (5,4) --
+         (7,5.5) --
+         (7,1.5) -- cycle ;}
+         
+      % Draw Box  
+      \draw[-] (0,0) -- (5,0);
+      \draw[-] (0,0) -- (0,4);
+      \draw[-] (5,4) -- (5,0);
+      \draw[-] (0,4) -- (5,4);
+      
+      \draw[-] (2,1.5) -- (7,1.5);
+      \draw[-] (2,1.5) -- (2,5.5);
+      \draw[-] (7,5.5) -- (7,1.5);
+      \draw[-] (2,5.5) -- (7,5.5);
+      
+      \draw[-] (0,0) -- (2,1.5);
+      \draw[-] (5,0) -- (7,1.5);
+      \draw[-] (5,4) -- (7,5.5);
+      \draw[-] (0,4) -- (2,5.5);
+      
+      \node at (4,5) {\small Total model domain};
+      
+      % Labels
+      \uncover<2->{\node at (2.7,0.15) {\scriptsize \texttt{bc\underline{ }par\underline{ }b = 'reflect', 'absorb'}};}  
+      \uncover<4->{\node at (3.0,4.25) {\scriptsize \texttt{bc\underline{ }par\underline{ }t = 'absorb', 'reflect'}};}        
+      \uncover<6->{\node at (3.25,2.15) {\scriptsize \texttt{bc\underline{ }par\underline{ }ns = 'cyclic', 'reflect', 'absorb'}};}      
+      \uncover<8->{\node[text width=15.5em] at (7.7,3.7) {\scriptsize \texttt{bc\underline{ }par\underline{ }lr = 'cyclic', 'reflect',}\\ \texttt{\hspace{5em} 'absorb'}};}            
+
+                
+      % Draw coordinate system
+      \node at (9,2) [scale=1.0] {%
+      \begin{tikzpicture}
+         \draw[->] (0,0) -- (1,0);
+         \draw[->] (0,0) -- (0,1);
+         \draw[->] (0,0) -- (0.5,0.5);
+         \node at (-0.2,0.9) {z};
+         \node at (0.9,-0.2) {x};
+         \node at (0.65,0.3) {y};
+      \end{tikzpicture}
+      };
+      
+   \end{tikzpicture}
+   
+\end{frame}
+
+% Folie 13
+\begin{frame}
+   \frametitle{Basic Particle Parameters (VIII)}
+   \small
+   Parameters that steer the output of particle data
+   \begin{itemize}
+      \item There are two output files containing particle data:
+      \begin{itemize}
+         \item \texttt{DATA\underline{ }1D\underline{ }PTS\underline{ }NETCDF}:
+         \hspace{0.5em} contains particle time series, output\\ 
+         \hspace{11.0em}interval is controlled by parameter\\ 
+         \hspace{11.0em}\texttt{dt\underline{ }dopts}, one file for the total\\ 
+         \hspace{11.0em}domain, e.g. time series of the total\\
+         \hspace{11.0em}number of particles, mean particle\\
+         \hspace{11.0em}velocity, mean subgrid scale part of\\
+         \hspace{11.0em}the particle velocity, mean particle\\
+         \hspace{11.0em}location etc.
+         \vspace{1mm}
+         \item \texttt{DATA\underline{ }PRT\underline{ }NETCDF}:
+         \hspace{2.5em}contains \textbf{all} particle data (see slide\\
+         \hspace{11.0em}The Data Type Used for Particles),\\
+         \hspace{11.0em}output is controlled by\\
+         \hspace{11.0em}\texttt{dt\underline{ }write\underline{ }particle\underline{ }data},\\
+         \hspace{11.0em}one file per subdomain/PE
+      \end{itemize}
+   \end{itemize}
+\end{frame}
+
+% Folie 14
+\begin{frame}
+   \frametitle{An Example of a Particle NAMELIST}
+   \includegraphics[scale=0.3]{particle_model_figures/namelist.png}
+   \begin{itemize}
+      \item<2-> \small Several (up to 10) so called particle groups with different density ratio, radius, and starting positions can be defined by setting parameter number\underline{ }of\underline{ }particle\underline{ }groups to the required number of groups, and by assigning values for each particle groups to the respective parameters (e.g. density\underline{ }ratio = 0.001, 0.0, etc.)
+   \end{itemize}
+\end{frame}
+
+% Folie 15
+\begin{frame}[t]
+   \frametitle{Theory of the Lagrangian Particle Model (I)}
+   \textbf{Advection of Passive particles}\\
+   \small
+   \vspace{1mm}
+   The position of a particle is found by integrating $ \dfrac{dX_{\text{particle}}}{dt} = \vec{V}_{\text{particle}}$\\
+   \vspace{2mm}
+   \onslide<2->Transferring the LES concept ...
+   \includegraphics[scale=0.1]{particle_model_figures/basic_particle_parameters_5.png}\\
+   \vspace{-2mm}
+   \scriptsize \hspace{2em}total energy\hspace{2.25em}=\hspace{3em}resolved part\hspace{2.5em}+\hspace{3em}modelled part\\
+   \vspace{1mm}
+   \small ... to the embedded particle model leads to: $\vec{V}_{\text{particle}} = \vec{V}_{\text{res}} (+ \vec{V}_{\text{sub}})$\\
+   \vspace{2mm}
+   \onslide<3->$\vec{V}_{\text{res}}:$\\ 
+   \begin{tikzpicture}[remember picture, overlay]
+      \node [shift={(1.7 cm,0.6cm)}]  at (current page.south west)
+         {%   
+         \begin{tikzpicture}[scale=0.3,remember picture, overlay]
+            \draw[-] (0,0) -- (5,0);
+            \draw[-] (0,0) -- (0,4);
+            \draw[-] (5,4) -- (5,0);
+            \draw[-] (0,4) -- (5,4);
+            \draw[-] (2,1.5) -- (7,1.5);
+            \draw[-] (2,1.5) -- (2,5.5);
+            \draw[-] (7,5.5) -- (7,1.5);
+            \draw[-] (2,5.5) -- (7,5.5);
+            \draw[-] (0,0) -- (2,1.5);
+            \draw[-] (5,0) -- (7,1.5);
+            \draw[-] (5,4) -- (7,5.5);
+            \draw[-] (0,4) -- (2,5.5);
+      
+            \node[circle, fill=blue, scale=0.5] at (0,0) {};
+            \node[circle, fill=blue, scale=0.5] at (5,0) {};
+            \node[circle, fill=blue, scale=0.5] at (0,4) {};
+            \node[circle, fill=blue, scale=0.5] at (5,4) {};
+            \node[circle, fill=blue, scale=0.5] at (2,1.5) {};
+            \node[circle, fill=blue, scale=0.5] at (7,1.5) {};
+            \node[circle, fill=blue, scale=0.5] at (7,5.5) {};
+            \node[circle, fill=blue, scale=0.5] at (2,5.5) {};
+      
+            \node[circle, fill=red, scale=0.5] at (2.5,1.1) {};
+
+            \draw[->, ultra thick, color=red] (7.4,0.7) -- (2.9,1.1);
+            \node at (9.0,0.1) {\scriptsize \textcolor{red}{particle location}}; 
+      
+            \draw[->, ultra thick] (8,2.5) -- (12,2.5);
+         \end{tikzpicture}
+         };
+      \node [shift={(5.8 cm,0.6cm)}]  at (current page.south west)
+         {%   
+         \begin{tikzpicture}[scale=0.3,remember picture, overlay]
+            \definecolor{darkgreen}{rgb}{0.2,0.7,0.2}
+            \draw[-] (0,0) -- (5,0);
+            \draw[-] (0,4) -- (5,4);
+            \draw[-] (2,1.5) -- (7,1.5);
+            \draw[-] (2,5.5) -- (7,5.5);
+            \draw[-] (0,0) -- (2,1.5);
+            \draw[-] (5,0) -- (7,1.5);
+            \draw[-] (5,4) -- (7,5.5);
+            \draw[-] (0,4) -- (2,5.5);
+      
+            \node[circle, fill=blue, scale=0.5] at (0,0) {};
+            \node[circle, fill=blue, scale=0.5] at (5,0) {};
+            \node[circle, fill=blue, scale=0.5] at (0,4) {};
+            \node[circle, fill=blue, scale=0.5] at (5,4) {};
+            \node[circle, fill=blue, scale=0.5] at (2,1.5) {};
+            \node[circle, fill=blue, scale=0.5] at (7,1.5) {};
+            \node[circle, fill=blue, scale=0.5] at (7,5.5) {};
+            \node[circle, fill=blue, scale=0.5] at (2,5.5) {};
+            
+            \node[circle, draw, color=darkgreen, ultra thick, scale=0.5] at (2.5,0.6) {};        
+            \node[circle, draw, color=darkgreen, ultra thick, scale=0.5] at (2.5,4.6) {};          
+            \draw[->, ultra thick] (8,2.5) -- (12,2.5);
+         \end{tikzpicture}
+         };
+      \node [shift={(9 cm,0.6cm)}]  at (current page.south west)
+         {%   
+         \begin{tikzpicture}[scale=0.3,remember picture, overlay]
+            \definecolor{darkgreen}{rgb}{0.2,0.7,0.2}
+            
+            \node[circle, draw, color=darkgreen, ultra thick, scale=0.5] at (2.5,0.6) {};        
+            \node[circle, fill=red, scale=0.5] at (2.5,1.1) {};
+            \node[circle, draw, color=darkgreen, ultra thick, scale=0.5] at (2.5,4.6) {};          
+         \end{tikzpicture}
+         };
+      \end{tikzpicture}
+\end{frame}
+
+% Folie 16
+\begin{frame}[t]
+   \frametitle{Theory of the Lagrangian Particle Model (II)}
+   \scriptsize \textbf{A: Passive particles}\\
+   \ \\
+   \uncover<10->{\normalsize \textbf{\underline{Calculation of the subgrid part of the particle velocity $\vec{V}_{\text{sub}}$:}}}
+   \footnotesize
+   \begin{itemize}
+      \item<3-> Application of the method of Weil et al. (2004)
+      \item<2-> \uncover<4->{they derived an adaptation of Thomson's model (1987)}\\
+      \vspace{1mm}
+      \uncover<2->{$\dfrac{dV_{\text{particle}_i}}{dt} = a_i dt + (C_0 \overline{\varepsilon})^{\frac{1}{2}} d \xi_i$ \quad deterministic + random velocity forcing}\\
+      \vspace{1mm}
+      \uncover<5->{to the grid-volume level, i.e.:}
+      \item<6-> Ensemble-mean velocity replaced by the LES resolved velocity
+      \item<7-> Lagrangian stochastic model describes the subgrid scale random velocity fluctuation about the resolved velocity
+      \item<8-> The subgrid scale velocities are specified by a Gaussian probability density function based on the subgrid scale stress tensor and its inverse
+      \item<9-> The ensemble mean dissipation rate can be replaced by the local dissipation rate      
+   \end{itemize}
+\end{frame}
+
+% Folie 17
+\begin{frame}[t]
+   \frametitle{Theory of the Lagrangian Particle Model (III)}
+   \scriptsize \textbf{A: Passive particles}\\
+   \ \\
+   \normalsize \textbf{\underline{Weil's formula for the subgrid part of the particle velocity:}}
+   \footnotesize \\
+   \vspace{2mm}
+   Assumption: subgrid scale turbulence locally isotropic\\
+   \vspace{6mm}
+   $dV_{\text{sub}_i} = - \dfrac{3 f_s C_0}{4} \dfrac{V_{\text{sub}_i}}{e_s} dt + \dfrac{1}{3} \left( \dfrac{\partial e_s}{\partial x_i} + \dfrac{3}{2 e_s} \dfrac{d e_s}{dt} V_{\text{sub}_i}\right) dt + \sqrt{f_s C_0 \varepsilon}\, d\xi_i$\\
+   \vspace{2mm}
+   $f_s = \dfrac{\langle 2 e_s / 3 \rangle}{\langle 2 e_s / 3 \rangle + \langle \left( \sigma^2_{\text{res}U} + \sigma^2_{\text{res}V} + \sigma^2_{\text{res}W} \right) /3 \rangle}$\\
+   \vspace{6mm}
+   Local dissipation rate $\varepsilon$ , subgrid scale turbulent kinetic energy $e_s$ and variances of resolved velocity components $\sigma_{\text{res}_i}$ derived from LES data\\
+\end{frame}
+
+% Folie 18
+\begin{frame}[t]
+   \frametitle{Theory of the Lagrangian Particle Model (IV)}
+   \scriptsize \textbf{A: Passive particles}\\
+   \ \\
+   \normalsize \textbf{\underline{Particle time step in case of \texttt{use\underline{ }sgs\underline{ }for\underline{ }particles = .TRUE.}:}}
+   \footnotesize \\
+   \vspace{2mm}
+   limited by the Lagrangian time scale $T_L$ \qquad $dt=0.025 T_L$\\
+   \vspace{3mm}
+   subsequent particle time steps: velocities correlated, accelerations not correlated\\
+   \vspace{3mm}
+   Lagrangian autocorrelation function:\\
+   \begin{tikzpicture}[domain=0:4]
+      \draw[->] (0,0) -- (4.5,0);
+      \draw[->] (0,0) -- (0,2);
+      \node at (4.5,-0.3) {$\tau$};
+      \node at (-0.5,1.8) {$R_L(\tau)$}; 
+      \draw[thick, domain=0:4] plot (\x,{1.7*exp(-1.6*\x)+0.05});
+   \end{tikzpicture}\\
+   $R_L(\tau) = \dfrac{W(t) W(t + \tau)}{\sigma^2_w} = exp\left( - \dfrac{\tau}{T_L} \right) \hspace{10mm} T_L = 4 e_s / (3 f_s C_0 \varepsilon)$\\
+   \ \\
+   Particle time step can be smaller than LES time step!
+\end{frame}
+
+% Folie 19
+\begin{frame}[t]
+   \frametitle{Theory of the Lagrangian Particle Model (V)}
+   \scriptsize \textbf{B: Non-passive particles (e.g. cloud droplets) }\\
+   \ \\
+   \footnotesize
+   $\rightarrow$ advection of particles by the non-linear drag law following Clift et al., 1978\\
+   \vspace{4mm}
+   \onslide<2->$\dfrac{dV_i}{dt} = \dfrac{1}{\tau_p} (u_i - V_i -\delta_{i3}w_s) \rightarrow V_i(t) = V_i(0) e^{-\Delta t / \tau_p} + (u_i -w_s \delta_{i3}) \left( 1 - e^{-\Delta t / \tau_p} \right)$\\
+      \vspace{2mm}
+   with $\tau_p^{-1} = \dfrac{3 \pi}{8 \beta r} C_D \left| \vec{u} - \vec{V} \right|$, $C_D = \dfrac{24}{\text{Re}} \left( 1 + 0.15 \text{Re}^{0.687} \right)$, $w_s = \dfrac{\beta -1}{\beta} g \tau_p$,\\ \vspace{1mm} \hspace{2em} $\beta = \dfrac{\rho_p}{\rho_f}$\\
+   \vspace{5mm}
+   \onslide<1->
+   \begin{tabular}{llll}
+	   $C_D$ & = drag coefficient           & $w_s$    & = terminal velocity\\
+	   $g$   & = gravitational acceleration & $\beta$  & = density coefficient\\
+	   Re    & = Reynolds number            & $\rho_p$ & = density of the particle\\
+	   $u_i$ & = velocity of the fluid      & $\rho_f$ & = density of the fluid\\
+	   $V_i$ & = particle velocity          & $\tau_p$ & = response time with respect to inertia\\
+   \end{tabular}
+\end{frame}
+
+
+% Folie 20
+\begin{frame}
+   \frametitle{Flow Chart of Particle Code (I)}
+   \footnotesize
+   \begin{tikzpicture}[scale=0.8, transform shape]
+      % Define colours
+      \tikzstyle{gelb1} = [draw, fill=yellow!60, text width=7em, text centered, minimum height=1.6em]
+      \tikzstyle{orange} = [draw, fill=orange!60, text width=7em, text centered]
+      
+      % Define coordinates and draw nodes      
+      \node[gelb1, text width=5em] (PALM) at (0,0.1) {PALM};
+
+      \coordinate (A) at (0,-0.7);
+
+      \node[gelb1, right=0.6cm of A] (init3d) {init\underline{ }3d\underline{ }model};
+      
+      \coordinate[below=0.4cm of init3d] (B) ;
+      \coordinate[below=1.0cm of init3d] (C) ;        
+      \coordinate[below=1.6cm of init3d] (D) ;       
+      \coordinate[below=2.2cm of init3d] (E) ;       
+      \coordinate[below=2.8cm of init3d] (F) ;        
+      \coordinate[below=4.2cm of init3d] (G) ;      
+      \coordinate[below=4.8cm of init3d] (H) ;      
+      \coordinate[below=7cm of init3d] (I) ;   
+      \coordinate (J) at (0,-8.6);
+            
+      \node[gelb1, right=0.5cm of B, text width=17em] (init1d) {init\underline{ }1d\underline{ }model (\textit{calls various subroutines})};
+      \node[gelb1, right=0.5cm of C] (initslope) {init\underline{ }slope};
+      \node[gelb1, right=0.5cm of D] (disturb) {disturb\underline{ }heatflux};
+      \node[gelb1, right=0.5cm of E] (initrankine) {init\underline{ }rankine};
+      \node[gelb1, right=0.0cm of initrankine] {init\underline{ }pt\underline{ }anomaly};
+      \node[gelb1, right=0.5cm of F] (disturbfield) {disturb\underline{ }field};
+      \node[gelb1, right=0.0cm of disturbfield] (pres) {pres};
+      \node[gelb1, right=0.5cm of G] (read3d) {read\underline{ }3d\underline{ }binary};
+      \node[gelb1, right=0.0cm of read3d] (initdvrp) {init\underline{ }dvrp};
+      \node[gelb1, right=0.0cm of initdvrp] (initocean) {init\underline{ }ocean};
+      \node[gelb1, right=0.0cm of initocean] {init\underline{ }cloud\underline{ }physics};            
+      \node[orange, right=0.5cm of H] (initparticles) {init\underline{ }particles};     
+      \node[gelb1, right=0.5cm of I] (initadvec) {init\underline{ }advec};      
+      \node[gelb1, right=0.0cm of initadvec] (userinit) {user\underline{ }init}; 
+      \node[gelb1, right=0.6cm of J] (dataoutput2d) {data\underline{ }output\underline{ }2d};      
+      \node[gelb1, right=0.0cm of dataoutput2d] {data\underline{ }output\underline{ }3d};         
+
+      \coordinate[below=0.15cm of pres] (K);
+      \coordinate[right=0.2cm of K] (L);
+      \coordinate[right=2cm of L] (M);
+      \coordinate[right=2cm of M] (N);
+            
+      \node[gelb1, below=0.1cm of L, text width=4em] (poisfft) {poisfft}; 
+      \node[gelb1, below=0.1cm of M, text width=4em] (sor) {sor}; 
+      \node[gelb1, below=0.1cm of N, text width=4em] (poismg) {poismg}; 
+      
+      \coordinate[below=0.1cm of initparticles] (O);
+      \coordinate[below=0.6cm of O] (P);
+      \coordinate[below=0.6cm of P] (Q);
+      
+      \node[orange, right=1.5cm of O] (userinitparticles) {user\underline{ }init\underline{ }particles}; 
+      \node[orange, right=1.5cm of P] (sortparticles) {sort\underline{ }particles}; 
+      \node[orange, right=1.5cm of Q] (dataoutputdvrp) {data\underline{ }output\underline{ }dvrp}; 
+      
+      \coordinate[right=1.5cm of dataoutputdvrp] (R);
+
+      \node[orange, below=0.3cm of R] (userdvrp) {user\underline{ }dvrp\underline{ }coltab};
+   
+      % Draw lines  
+      \draw[dotted, thick] (PALM) -- (0,-0.5);
+      \draw[-, thick] (0,-0.5) -- (0,-8.7);
+      \draw[dotted, thick] (0,-8.7) -- (0,-9.0);      
+      \draw[-, thick] (init3d.west) -- (A) ;
+      \draw[-, thick] (init3d.south) -- (I) ;
+      \draw[dashed, thick] (B) -- (init1d.west);
+      \draw[dashed, thick] (C) -- (initslope.west);
+      \draw[dashed, thick] (D) -- (disturb.west);
+      \draw[dashed, thick] (E) -- (initrankine.west);
+      \draw[dashed, thick] (F) -- (disturbfield.west);
+      \draw[dashed, thick] (G) -- (read3d.west);      
+      \draw[-, thick] (H) -- (initparticles.west);      
+      \draw[-, thick] (I) -- (initadvec.west);         
+      \draw[dashed, thick] (J) -- (dataoutput2d);      
+      \draw[-, thick] (pres.south) -- (K);
+      \draw[-, thick] (K) -- (N);
+      \draw[-, thick] (L) -- (poisfft.north);
+      \draw[-, thick] (M) -- (sor.north);      
+      \draw[-, thick] (N) -- (poismg.north);        
+      \draw[-, thick] (initparticles.south) -- (P);
+      \draw[dashed, thick] (P) -- (Q);
+      \draw[-, thick] (O) -- (userinitparticles.west);
+      \draw[-, thick] (P) -- (sortparticles.west);
+      \draw[dashed, thick] (Q) -- (dataoutputdvrp.west);            
+      \draw[-, thick] (dataoutputdvrp.east) -- (R);
+      \draw[-, thick] (R) -- (userdvrp.north);
+      
+   \end{tikzpicture}
+   
+   
+\end{frame}
+
+% Folie 21
+\begin{frame}
+   \frametitle{Flow Chart of Particle Code (II)}
+   \footnotesize
+   \begin{tikzpicture}[scale=0.8, transform shape]
+      % Define colours
+      \tikzstyle{gelb1} = [draw, fill=yellow!60, text width=7em, text centered, minimum height=1.6em]
+      \tikzstyle{orange} = [draw, fill=orange!60, text width=7em, text centered]
+      
+      % Define coordinates and draw nodes
+      \coordinate (A) at (0,-0.7);
+
+      \node[gelb1, right=0.6cm of A] (timeintegration) {time\underline{ }integration};
+      
+      \coordinate[below=0.3 of timeintegration] (B);
+      \coordinate[below=0.9 of timeintegration] (C);
+      
+      \node[gelb1, right=0.6cm of B] (timestep) {timestep};
+      \node[gelb1, right=0.6cm of C] (runcontrol) {run\underline{ }control};
+      
+      \coordinate[below=0.2cm of runcontrol] (D);
+      
+      \node[gelb1, right=1.5cm of D] (flowstat) {flow\underline{ }statistics};
+      
+      \coordinate[below=1.8cm of timeintegration] (E);
+      
+      \node[gelb1, right=0.6cm of E] (surface) {surface\underline{ }coupler};
+      
+      \coordinate[below=2.4cm of timeintegration] (F);
+        
+      \node[gelb1, right=0.6cm of F, text width=13em] (useractions) {user\underline{ }actions (\textit{before\underline{ }timestep})};    
+ 
+       \coordinate[below=3.0cm of timeintegration] (G);
+       
+      \node[gelb1, right=0.6cm of G, text width=11em] (timestepscheme) {timestep\underline{ }scheme\underline{ }steering};       
+      
+      \coordinate[below=3.5cm of timeintegration] (H);
+      \coordinate[right=2cm of H] (I);
+      \coordinate[right=3.5cm of I] (J); 
+      
+      \node[draw, text width=22em,minimum height=4.5em,fill=black!15] (progframe) at (5.75,-5.3) {};
+      \node[draw, text width= 9.5em, right=0.5cm of progframe] {For details, see PALM Flow Chart (V).};
+      \node[gelb1, below=0.3cm of I, text width=9em] (prog) {prognostic\underline{ }equations};      
+      \node[gelb1, below=0.3cm of J, text width=10.5em] (progfast) {prognostic\underline{ }equations\underline{ }fast};  
+      \node[gelb1, below=0.1cm of progfast, text width=10.5em] (progvec) {prognostic\underline{ }equations\underline{ }vec};       
+      \node[draw, fill=red, text width=4em] at (8.2,-4) {\textcolor{white}{standard advection}};
+      
+      \coordinate[below=5.5cm of timeintegration] (K);
+      
+      \node[orange, right=0.6cm of K] (advecparticles) {advec\underline{ }particles};             
+      
+      \coordinate[below=0.2cm of advecparticles] (L);
+     
+      \node[orange, right=1.5cm of L, text width=13em] (userparticlesatt) {user\underline{ }particle\underline{ }attributes + more}; 
+      
+      \coordinate[below=6.6cm of timeintegration] (M);
+      
+      \node[orange, right=0.6cm of M, text width=10em] (interaction) {interaction\underline{ }droplets\underline{ }ptq};     
+
+      \coordinate[below=7.2cm of timeintegration] (N);
+      
+      \node[gelb1, right=0.6cm of N] (asselin) {asselin\underline{ }filter};     
+      
+      \coordinate[below=7.8cm of timeintegration] (O);
+      
+      \node[gelb1, right=0.6cm of O] (boundary) {boundary\underline{ }conds};       
+      \node[gelb1, right=0.0cm of boundary] {swap\underline{ }timelevel};  
+            
+      \coordinate[below=8.4cm of timeintegration] (P);      
+      
+      \node[gelb1, right=0.6cm of P] (inflow) {inflow\underline{ }turbulence}; 
+      \node[gelb1, right=0.0cm of inflow] {disturb\underline{ }field}; 
+                                                      
+      % Draw lines  
+      \draw[dotted, thick] (0,-0.3) -- (0,-0.7);
+      \draw[-, thick] (0,-0.7) -- (0,-7.7);
+      \draw[dotted, thick] (0,-7.7) -- (0,-9.0);      
+      \draw[-, thick] (A) -- (timeintegration);
+      \draw[-, thick] (B) -- (timestep);
+      \draw[-, thick] (C) -- (runcontrol);
+      \draw[-, thick] (runcontrol.south) -- (D);
+      \draw[-, thick] (D) -- (flowstat);
+      \draw[dashed, thick] (E) -- (surface);
+      \draw[-, thick] (F) -- (useractions);      
+      \draw[-, thick] (G) -- (timestepscheme); 
+      \draw[-, thick] (H) -- (I); 
+      \draw[-, thick] (I) -- (prog.north); 
+      \draw[-, thick, color=red] (I) -- (J);       
+      \draw[->, thick, color=red] (J) -- (progfast.north); 
+      \draw[dashed, thick] (K) -- (advecparticles);            
+      \draw[-, thick] (advecparticles.south) -- (L);            
+      \draw[-, thick] (L) -- (userparticlesatt.west);       
+      \draw[dashed, thick] (M) -- (interaction.west);  
+      \draw[dashed, thick] (N) -- (asselin.west);        
+      \draw[-, thick] (O) -- (boundary.west);  
+      \draw[dashed, thick] (P) -- (inflow.west);             
+      \draw[-, thick] (timeintegration.south) -- (O);  
+      \draw[dashed, thick] (O) -- (P);  
+      
+   \end{tikzpicture}   
+   
+\end{frame}
+
+
+% Folie 22
+\begin{frame}
+   \frametitle{Detailed Flow Chart of \texttt{advec\underline{ }particles} (I)}
+   \scriptsize
+   \begin{tikzpicture}[scale=0.87, transform shape] 
+      \node (0) at (0,0) {};
+      \uncover<2->{\node[draw, right=0.0cm of 0, text width=15em] {write particle data on file\\ \qquad binary (\texttt{PARTICLE\underline{ }DATA/})\\ \quad + NetCDF (\texttt{DATA\underline{ }PRT\underline{ }NETCDF/})};}
+      \uncover<3->{\node[draw, right=0.0cm of 0, yshift=-0.9cm] {calculate exponential terms for particles groups with inertia};}
+      \uncover<4->{\node[draw, right=0.0cm of 0, yshift=-1.5cm] {particle growth by condensation/evaporation and collision};}
+      \uncover<5->{\node[draw, right=0.0cm of 0, yshift=-2.1cm] {If SGS-velocities are used: calculate gradients of TKE};}
+      \uncover<6->{\node[draw, right=0.0cm of 0, yshift=-2.85cm, text width=29em] {timestep loop\\ (repeated, unless each particle has reached the LES timestep \texttt{dt\underline{ }3d})};}
+      \uncover<7->{\node[draw, right=0.5cm of 0, yshift=-3.9cm, text width=36em] {for each particle:\\ - interpolate velocities and SGS quantities (SGS-velocities, Lagrangian timescale, etc.\\ - calculate the particle advection};}
+      \uncover<8->{\node[draw, right=0.5cm of 0, yshift=-4.8cm] {calculate particle reflection from walls (subroutine \texttt{particle\underline{ }boundary\underline{ }conds})};}
+      \uncover<9->{\node[draw, right=0.5cm of 0, yshift=-5.4cm] {user defined actions (subroutine \texttt{user\underline{ }advec\underline{ }particles})};}     
+      \uncover<10->{\node[draw, right=0.5cm of 0, yshift=-6.0cm] {if necessary, release a new set of particles};}
+      \uncover<11->{\node[draw, right=0.5cm of 0, yshift=-6.6cm] {particle exchange between the subdomains};}    
+      \uncover<12->{\node[draw, right=0.5cm of 0, yshift=-7.2cm] {boundary conditions at bottom and top};}
+      \uncover<13->{\node[draw, right=0.5cm of 0, yshift=-7.8cm] {delete, pack, and sort particles};}    
+   \end{tikzpicture}
+\end{frame}
+
+% Folie 23
+\begin{frame}
+   \frametitle{Detailed Flow Chart of \texttt{advec\underline{ }particles} (II)}
+   \scriptsize
+   \begin{tikzpicture}[auto, node distance=0] 
+      \node (0) at (0,0) {};
+      \node[draw, right=0.0cm of 0] {In case of cloud droplets: calculate the liquid water content};
+      \uncover<2->{\node[draw, right=0.0cm of 0, yshift=-0.6cm] {user defined setting of particle attributes (subroutine user\underline{ }particle\underline{ }attributes)};}
+      \uncover<3->{\node[draw, right=0.0cm of 0, yshift=-1.2cm] {if necessary, add actual positions to the particle tails};}
+      \uncover<4->{\node[draw, right=0.0cm of 0, yshift=-1.8cm] {write particle statistics on file \texttt{PARTICLE\underline{ }INFOS} (ASCII format)};  }    
+   \end{tikzpicture}
+   \vspace{5mm}
+   \small
+   \begin{itemize}
+      \item<5-> For a better modular structure, subroutine advec\underline{ }particles will be split into several subroutines in one of the next PALM releases.
+   \end{itemize}
+\end{frame}
+
+% Folie 24
+\begin{frame}
+   \frametitle{The Data Type Used for Particles}
+   \small
+   \begin{itemize}
+      \item Particle data are stored in a FORTRAN derived data type:
+   \end{itemize}
+   \includegraphics[scale=0.3]{particle_model_figures/data_type.png}
+\end{frame}
+
+% Folie 25
+\begin{frame}
+   \frametitle{How to Read netCDF Particle Data from an External Program}
+   \footnotesize
+   \begin{itemize}
+      \item An example program for reading netCDF particle data (from file DATA\underline{ }PRT\underline{ }NETCDF/) can be found in the PALM repository under \texttt{...../trunk/UTIL/analyze\underline{ }particle\underline{ }netcdf\underline{ }data.f90}
+       \item<2-> \textbf{Attention:}\\ The particle feature \grqq density\underline{ }ratio\grqq\, is stored in variable particle\underline{ }groups which (so far) is \textbf{not} contained in the netCDF file.\\ Also, informations about particle tails (history of particle positions) are \textbf{not} on the netCDF file!\\
+       \vspace{1mm}
+       Both informations can only be found on file PARTICLE\underline{ }DATA/.\\
+       \vspace{1mm}
+       For the format of this file (one per PE, i.e. filenames \underline{ }0000, \underline{ }0001, etc.) see beginning of subroutine advec\underline{ }particles.
+   \end{itemize}
+   \onslide<3->\hspace{4mm}\includegraphics[scale=0.27]{particle_model_figures/particle_data.png}
+\end{frame}
+
+% Folie 26
+\begin{frame}
+   \frametitle{Application example: Footprint modelling above a homogeneously heated surface (I)}
+   \footnotesize
+   \textbf{What is a footprint?}
+   \begin{itemize}
+      \item field of view of a micrometeorological measurement
+   \end{itemize}
+   \onslide<2->
+   \textbf{What is the motivation for footprint modelling?}
+   \begin{itemize}
+      \item measured turbulent fluxes donât represent the fluxes originating directly from below the measuring device, but rather represent the fluxes originating from an area upwind of the measuring device
+   \end{itemize}
+   \onslide<3->
+   \textbf{How is it done?}
+   \begin{itemize}
+      \item particle trajectories are calculated in LES using embedded Lagrangian Particle Model
+      \item once a particle intersects with chosen measuring height, footprint relevant data is output
+      \item footprints are calculated in postprocessing
+   \end{itemize}
+   \onslide<4->
+   \textbf{What to keep in mind?}
+   \begin{itemize}
+      \item including subgridscale particle velocities necessary, when calculating footprints close to the surface, where subgridscale contribution\\to turbulent kinetic energy is relatively large 
+   \end{itemize}
+\end{frame}
+
+% Folie 27
+\begin{frame}
+   \frametitle{Application example: Footprint modelling above a homogeneously heated surface (II)}
+   \footnotesize
+   \begin{center}
+      \includegraphics[scale=0.4]{particle_model_figures/footprint2.png}
+   \end{center}
+   \vspace{-6mm}
+   \begin{flushright}
+      after Steinfeld, 2009
+   \end{flushright}
+\end{frame}
+
+% Folie 28
+\begin{frame}
+   \frametitle{Application example: Footprint modelling above a homogeneously heated surface (III)}
+   \footnotesize
+   \textbf{Setup} (according to Steinfeld et al., 2008)
+   \includegraphics[scale=0.285]{particle_model_figures/footprint3_1.png} \hspace{2mm}
+   \includegraphics[scale=0.5]{particle_model_figures/footprint3_2.png}
+   \begin{itemize}
+      \item particles are released every 2min over a period of 30min at z=70m in the total model domain ($\rightarrow$ 7 * 106 particles)
+      \item particles are measured at z=72.5m, 77.5m, 100.0m
+   \end{itemize}
+\end{frame}
+
+% Folie 29
+\begin{frame}
+   \frametitle{Application example: Footprint modelling above a homogeneously heated surface (IV)}
+   \footnotesize
+   Extract from the corresponding parameter file:
+   \includegraphics[scale=0.285]{particle_model_figures/footprint4.png}
+\end{frame}
+
+% Folie 30
+\begin{frame}
+   \frametitle{Application example: Footprint modelling above a homogeneously heated surface (V)}
+   \footnotesize
+   Additionally required user-defined code (continued):
+   \begin{enumerate}
+      \scriptsize
+      \setcounter{enumi}{0}
+      \item	Open files (one per PE and measuring height) for the additional output of footprint relevant particle data in \texttt{user\underline{ }init}
+   \end{enumerate}
+   \includegraphics[scale=0.27]{particle_model_figures/footprint5_1.png}
+   \begin{enumerate}
+      \scriptsize
+      \setcounter{enumi}{1}
+      \item Create directory into which the files containing the particle data shall be moved to and move the files (in .mrun.config)
+   \end{enumerate}
+   \includegraphics[scale=0.27]{particle_model_figures/footprint5_2.png}
+\end{frame}
+
+% Folie 31
+\begin{frame}
+   \frametitle{Application example: Footprint modelling above a homogeneously heated surface (VI)}
+   \footnotesize
+   Additionally required user-defined code (continued):
+   \begin{enumerate}
+      \scriptsize
+      \setcounter{enumi}{2}
+      \item Output of footprint relevant data in \texttt{user\underline{ }advec\underline{ }particles} (checking if particle has crossed measuring height)
+   \end{enumerate}
+   \includegraphics[scale=0.285]{particle_model_figures/footprint6.png}
+\end{frame}
+
+% Folie 32
+\begin{frame}
+   \frametitle{Application example: Footprint modelling above a homogeneously heated surface (VII)}
+   \includegraphics[scale=0.3]{particle_model_figures/example1.png}
+   \includegraphics[scale=0.35]{particle_model_figures/example2.png}\\
+   \begin{itemize}
+      \item sensor position at x = 0m
+   \end{itemize}
+\end{frame}
+
+% Folie 33
+\begin{frame}
+   \frametitle{Using Particles as Cloud Droplets}
+   \begin{itemize}
+      \item<1-> This feature is switched on by setting the initial parameter cloud\underline{ }droplets = \textit{.TRUE.}.
+      \item<2-> In this case, the change in particle radius by condensation/evaporation and collision is calculated for every timestep.
+      \item<3-> In case of condensation or evaporation, the potential temperature and the specific humidity has to be adjusted in the respective grid volumes. This is done within the subroutine interaction\underline{ }droplets\underline{ }ptq.
+   \end{itemize}
+\end{frame}
+
+% Folie 34
+\begin{frame}
+   \frametitle{General Warning}
+   \begin{itemize}
+      \item<2-> Errors in the user interface routines for particles may cause problems which are very difficult to debug. Please be extremely careful with modifying the user interface and try to find out exactly how the default particle code works, before you make your modifications.
+   \end{itemize}
+\end{frame}
+
+\end{document}
Index: /palm/trunk/TUTORIAL/SOURCE/program_control.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/program_control.tex	(revision 944)
+++ /palm/trunk/TUTORIAL/SOURCE/program_control.tex	(revision 945)
@@ -48,10 +48,10 @@
 % jeder frame in einer subsection bekommt einen punkt (horizontal ausgerichtet)
 \begin{document}
-
+% Folie 1
 \begin{frame}
 \titlepage
 \end{frame}
 
-% Folie 1
+% Folie 2
 \begin{frame}
    \frametitle{Steering of PALM and Interpreting the Output}
@@ -62,6 +62,5 @@
 \end{frame}
 
-% Folie 2
-
+% Folie 3
 \begin{frame}
    \frametitle{PALM Input/Output Overview (I)}
@@ -85,20 +84,29 @@
     \uncover<5->{\node[red] (restartdata2) [below=4.5cm of restartdata1] {restart data};}
 
-    \uncover<3->{\node[yellow1] (runcontrol) [below=1.0cm of palm]{run control output\\ (parameter settings + \\ timestep informations)};}
-    \uncover<3->{\node[yellow2] (headerfile) [left=0.5cm of runcontrol]{header file};}
+    \uncover<4->{
+    \node[orange1] (timeseries) [below left=4.4cm of palm] {time series};
+    \node[orange2] (2dsectionstime) [right=0.5cm of timeseries] {2D sections \\ time averaged};
+    \node[orange2] (3ddatatime) [right=0.39cm of 2dsectionstime] {3D data \\ time averaged};
+
+    \path<4->[line] (palm) -- (timeseries);
+    \path<4->[line] (palm) -- (2dsectionstime);
+    \path<4->[line] (palm) -- (3ddatatime);
+    
+    \node[orange1] (1dmean) [above=0.2cm of timeseries] {1D mean \\ profiles};
+    \node[orange1] (2dsections) [right=0.5cm of 1dmean] {2D sections};
+    \node[orange1] (3ddata) [right=0.5cm of 2dsections] {3D data};}
+
+    \path<4->[line] (palm) -- (1dmean);
+    \path<4->[line] (palm) -- (2dsections);
+    \path<4->[line] (palm) -- (3ddata);
+
+    \uncover<3->{\node[yellow2] (headerfile) [above=0.5cm of 2dsections]{header file};}
+    \uncover<3->{\node[yellow1] (runcontrol) [right=0.5cm of headerfile]{run control output\\ (parameter settings + \\ timestep informations)};}
     \uncover<3->{\node[yellow2] (cpumeasure) [left=0.5cm of headerfile]{cpu\\ measurements};}
 
-    \uncover<4->{\node[orange1] (1dmean) [below=0.5cm of cpumeasure] {1D mean \\ profiles};
-    \node[orange1] (2dsections) [right=0.5cm of 1dmean] {2D sections};
-    \node[orange1] (3ddata) [right=0.5cm of 2dsections] {3D data};
-
-    \node[orange1] (timeseries) [below=0.2cm of 1dmean] {time series};
-    \node[orange2] (2dsectionstime) [right=0.5cm of timeseries] {2D sections \\ time averaged};
-    \node[orange2] (3ddatatime) [right=0.39cm of 2dsectionstime] {3D data \\ time averaged};}
-
-    \node (program) [right=3.1cm of palm] {program};
-    \uncover<2->{\node (steeringdata) [right=0.6cm of restartdata1] {steering data};}
-    \uncover<3->{\node (run) [right=2.5cm of runcontrol] {run informations};}
-    \uncover<4->{\node (analysis) [right=3.6cm of 3ddata] {analysis data};}
+    \node (program) [right=2.8cm of palm] {program};
+    \uncover<2->{\node (steeringdata) [right=0.45cm of restartdata1] {steering data};}
+    \uncover<3->{\node (run) [right=2.7cm of runcontrol] {run informations};}
+    \uncover<4->{\node (analysis) [right=3.8cm of 3ddata] {analysis data};}
 
     \uncover<7->{
@@ -114,10 +122,4 @@
     \path<3->[line] (palm) -- (headerfile);
     \path<3->[line] (palm) -- (runcontrol);
-    \path<4->[line] (palm) -- (1dmean);
-    \path<4->[line] (palm) -- (2dsections);
-    \path<4->[line] (palm) -- (3ddata);
-    \path<4->[line] (palm) -- (timeseries);
-    \path<4->[line] (palm) -- (2dsectionstime);
-    \path<4->[line] (palm) -- (3ddatatime);
     \path<5->[line] (palm) -- (restartdata2);
     \path<6->[line] (restartdata1) -- (palm);
@@ -126,7 +128,7 @@
 \end{frame}
 
-% Folie 3
-\begin{frame}
-   \frametitle{PALM Input/Output Overview (I)}
+% Folie 4
+\begin{frame}
+   \frametitle{PALM Input/Output Overview (II)}
    \tikzstyle{start} = [ellipse, draw, fill=green!20, font=\small]   
    \tikzstyle{yellow1} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, font=\Tiny]
@@ -161,6 +163,6 @@
     \node[orange2] (3ddatatime) [right=0.39cm of 2dsectionstime] {3D data \\ time averaged};
 
-    \node (program) [right=3.1cm of palm] {program};
-    \node (steeringdata) [right=0.6cm of restartdata1] {steering data};
+    \node (program) [right=2.8cm of palm] {program};
+    \node (steeringdata) [right=0.8cm of restartdata1] {steering data};
     \node (run) [right=2.5cm of runcontrol] {run informations};
     \node (analysis) [right=3.6cm of 3ddata] {analysis data};
@@ -174,4 +176,5 @@
 
     %--------- neue Ordner
+    \uncover<2->{
     \node[yellow4] (currentversion) [above=0.6cm of parameterfile] {current\_version/};
     \node[yellow4] (jobs) [right=0.3cm of currentversion] {JOBS/};
@@ -180,80 +183,116 @@
     \node[yellow4] (monitoring) [below=0.1cm of input] {MONITORING/};
     \node[yellow4] (output) [below=0.1cm of monitoring] {OUTPUT/};
-    \node[yellow4] (restart) [below=0.1cm of output] {RESTART\_DATA/};
-
-    \node[yellow4] (input2) [below=0.1cm of parameterfile] {INPUT/};
-    \node[yellow4] (monitoring2) [above=0.6cm of headerfile] {MONITORING/};
-    \node[yellow4] (restart2) [below=0.1cm of restartdata1] {RESTART\_DATA/};
-    \node[yellow4] (tmpdata) [below=0.1cm of restart2] {/tmp\_data\_catalog/};
-    \node[yellow4] (output2) [below=0.5cm of restartdata2] {OUTPUT/};
-
-    \path[line] (currentversion) -- (jobs);
-    \path[line] (jobs) -- (runidentifier);
-    \path[line] (runidentifier.east) -- (input.west);
-    \path[line] (runidentifier.east) -- (monitoring.west);
-    \path[line] (runidentifier.east) -- (output.west);
-    \path[line] (runidentifier.east) -- (restart.west);
-
-    \draw[decorate,decoration={brace,raise=6pt,amplitude=9pt},thick]
+    \node[yellow4] (restart) [below=0.1cm of output] {RESTART\_DATA/};}
+
+    \uncover<3->{\node[yellow4] (input2) [below=0.1cm of parameterfile] {INPUT/};}
+    \uncover<4->{\node[yellow4] (monitoring2) [above=0.6cm of headerfile] {MONITORING/};}
+    \uncover<6->{\node[yellow4] (restart2) [below=0.1cm of restartdata1] {RESTART\_DATA/};}
+    \uncover<7->{\node[yellow4] (tmpdata) [below=0.1cm of restart2] {/tmp\_data\_catalog/};}
+    \uncover<5->{\node[yellow4] (output2) [below=0.5cm of restartdata2] {OUTPUT/};}
+
+    \path[line]<2-> (currentversion) -- (jobs);
+    \path[line]<2-> (jobs) -- (runidentifier);
+    \path[line]<2-> (runidentifier.east) -- (input.west);
+    \path[line]<2-> (runidentifier.east) -- (monitoring.west);
+    \path[line]<2-> (runidentifier.east) -- (output.west);
+    \path[line]<2-> (runidentifier.east) -- (restart.west);
+
+    \draw<4->[decorate,decoration={brace,raise=6pt,amplitude=9pt},thick]
        (-4.5,-0.95)--(-1,-0.95) ;
-    \draw[decorate,decoration={brace,mirror,raise=5pt,amplitude=6pt},thick]
-       (0.45,-3)--(0.45,-1.9) ;
-
-
-%     \path[line] (monitoring2.south) -- (cpumeasure.north);
-%     \path[line] (monitoring2.south) -- (headerfile.north);
-%     \path[line] (monitoring2.south) -- (runcontrol.north);
-   
-   \end{tikzpicture}
-\end{frame}
-
-%---------------------------------------------------
+    \draw<5->[decorate,decoration={brace,mirror,raise=5pt,amplitude=6pt},thick]
+       (0.45,-3)--(0.45,-1.9) ;   
+   \end{tikzpicture}
+\end{frame}
+
+% Folie 5
 \begin{frame}
    \frametitle{The Parameter File}
-   \tikzstyle{box} = [rectangle, draw, text width=\textwidth, font=\tiny]
+   \tikzstyle{box} = [rectangle, draw, text width=0.9\textwidth, font=\tiny]
+   \tikzstyle{line} = [draw, thick, -latex']
    \footnotesize
    \begin{itemize}
-      \item{Physical and numerical features of a PALM run (e.g. initial and boundary conditions, numerical methods)
+      \item<1->{Physical and numerical features of a PALM run (e.g. initial and boundary conditions, numerical methods)
             are controlled by a so called \textbf{parameter file} which uses FORTRAN-NAMELIST syntax.} 
-      \item{General structure of a FORTRAN-NAMELIST file}
+      \item<2->{General structure of a FORTRAN-NAMELIST file}
    \end{itemize}   
-   \begin{tikzpicture}[auto]      
+   \begin{tikzpicture}[auto]  
+   \uncover<3->{    
       \node[box](firstbox){ \begin{tabbing}        
-         \&abcd \quad \=no\_of\_eggs = 100, litres\_of\_milk = 50.0, \= \\
-                 \>kilos\_of\_butter = 20.0, \> /  \end{tabbing}};       
-   \end{tikzpicture}
-   \begin{itemize}
-      \item{This file can be read from a FORTRAN program in the following way:} 
-   \end{itemize}
-   \begin{tikzpicture}[auto, node distance=0]      
+         \quad \&abcd \quad \=no\_of\_eggs = 100, litres\_of\_milk = 50.0, \= \\
+                 \>kilos\_of\_butter = 20.0, \> /  \end{tabbing}};  
+   \node[font=\tiny] (leading_blank) at (-5,0.8) {\textbf{leading blank}}; 
+   \node[font=\tiny] (namelist) at (-2,0.8) {\textbf{NAMELIST group}}; 
+   \node[font=\tiny] (terminating) at (3,0.8) {\textbf{terminating character}};
+   \path[line] (-5,0.7) -- (-4.8,0);  
+   \path[line] (-2,0.7) -- (-4,0);
+   \path[line] (3,0.7) -- (0.2,-0.3);}
+   \end{tikzpicture}
+   \begin{itemize}
+      \item<4->{This file can be read from a FORTRAN program in the following way:} 
+   \end{itemize}
+   \begin{tikzpicture}[auto, node distance=0] 
+   \uncover<4->{     
       \node[box](secondbox){ \begin{tabbing} 
          INTEGER :: \=no\_of\_eggs = 30 \\
          REAL :: \> litres\_of\_milk = 0.0, kilos\_of\_butter, kilos\_of\_cream = 33.0 \\
+         \\
          NAMELIST /abcd/ \quad no\_of\_eggs, litres\_of\_milk, kilos\_of\_butter, kilos\_of\_cream \\
-         \par\bigskip
+         \\
          OPEN ( 1, FILE='Filename' ) \\
-         READ ( 1, abcd ) \end{tabbing}};       
+         \\
+         READ ( 1, abcd ) \end{tabbing}};}       
    \end{tikzpicture}
    \normalsize 
 \end{frame}
 
-
-%-----------------------------------------------------
+% Folie 6
+\begin{frame}
+   \frametitle{An Example of PALM - NAMELIST Input}
+   \tikzstyle{box} = [rectangle, draw, text width=\textwidth, font=\tiny]
+   \begin{tikzpicture}[auto, node distance=0]      
+      \node[box](box){ \begin{tabbing} 
+         \&inipar \=nx = 39, ny = 39, nz = 40, \\
+                  \>dx = 50.0, dy = 50.0, dz = 50.0, \\
+                  \\
+                  \>initializing\_actions = 'set\_constant\_profiles', \\  
+                  \>ug\_surface = 0.0, vg\_surface = 0.0, \\
+                  \\
+                  \>pt\_vertical\_gradient  \qquad = 0.0, 1.0, \\
+                  \>pt\_vertical\_gradient\_level = 0.0, 800.0, \\
+                  \\
+                  \>surface\_heatflux = 0.1, bc\_pt\_b ='neumann', / \\
+                  \\
+                  \\
+         \&d3par  \>end\_time = 3600.0, \\
+                  \\
+                  \>dt\_dopr = 900.0, averaging\_interval\_pr = 600.0, \\
+                  \>data\_output\_pr = 'pt', 'u', 'v', / \\ \end{tabbing}};       
+   \end{tikzpicture}
+   \footnotesize
+   \begin{itemize}
+      \item<2->{There are two NAMELIST groups ({\tt \&inipar} and {\tt \&d3par}).} 
+      \item<3->{Assignments to parameters in {\tt\&inipar} are ignored within restart runs \\
+            (exception: {\tt initializing\_actions} = {\tt'read\_restart\_data'} is obligatory for restart runs).}
+      \item<4->{Values of {\tt \&d3par} parameters can be changed for restart runs.}
+   \end{itemize}
+\end{frame}
+
+% Folie 7
 \begin{frame}
    \frametitle{The Run Control File}
    \scriptsize
    \begin{itemize}
-      \item{For initial runs, the parameter settings and many additional informations about the run (header informations) are printed at the beginning of this file.}
+      \item<1->{For initial runs, the parameter settings and many additional informations about the run (header informations) are printed at the beginning of this file.}
       \item<2->{The parameter settings are followed by values of specific model variables for certain timesteps (one line for each timestep, the output intervall can be
             controlled by run parameter {\tt dt\_run\_control}).}
    \end{itemize}
-   \onslide<3->{
-   \textbf{Contents of this timestep output should be carefully checked after each run, because it allows a first control, if the model had run correctly, or if any
-           errors have occurred!}}
+   \onslide<3->{\textbf{Contents of this timestep output should be carefully checked after each run, because it allows a first control, if the model had run correctly, or if any
+      errors have occurred!}}
+   \par\bigskip
    \includegraphics[width=1.6\textwidth]{program_control_figures/run_control_file.png}
    \normalsize
 \end{frame}
 
-%-----------------------------------------------------
+% Folie 8
 \begin{frame}
    \frametitle{The Header File}
@@ -271,5 +310,5 @@
 \end{frame}
 
-%-------------------------------
+% Folie 9
 \begin{frame}
    \frametitle{CPU Measurements File}
@@ -286,15 +325,16 @@
       \normalsize
    \column{0.58\textwidth}
-      \includegraphics[width=\textwidth]{program_control_figures/cpu_measurements_file.png}
+      \includegraphics[width=1.1\textwidth]{program_control_figures/cpu_measurements_file.png}
    \end{columns}
 \end{frame}
 
-%-----------------------------------------------------
+% Folie 10
 \begin{frame}
    \frametitle{Other Files}
+   \small
    \begin{itemize}
       \item<1->{Data output files (1D profiles and timeseries, 2D cross sections, 3D volume data) are by default in \textbf{netCDF} format which is suitable to be processed by
-            public domain graphics software like \textbf{ncview}, \textbf{ferret}, \textbf{ncl} (used by PALM group),\\
-            \textbf{IDL}, etc. \\
+            public domain graphics software like \textbf{ncview}, \textbf{ferret}, \textbf{ncl} (used by PALM group), \textbf{IDL}, etc. \\
+            \par\bigskip
             For a first look, {\tt ncview} is a convenient tool.}
       \item<2->{{\tt ncdump} can be used to display the netCDF file contents in ASCII format ({\tt ncdump -c} displays only header informations).}
@@ -303,18 +343,22 @@
 \end{frame}
 
-%----------------------------------------------------
+% Folie 11
 \begin{frame}
    \frametitle{Steering by Unix Environment Variables}
-   \footnotesize
+   \scriptsize
    Most features of PALM are controlled by the parameter file but a few are exclusively controlled by unix environment variables. The most important one is  {\tt write\_binary}. \\
+   \par\bigskip
    Setting \\
-   \begin{centering} {\tt write\_binary = true} \end{centering} \\
-   within the shell causes PALM to write binary data for restart runs at the end of a run.
-   
-   Setting of these environment variables is automatically done by  mrun. It generates a local file (named {\tt ENVPAR}) in FORTRAN-NAMELIST-format, which is then read by PALM. This file
-   includes the following variables: \\
- 
+   \par\medskip
+   {\centering \texttt{ write\_binary = true} \\
+   \par\medskip
+   within the shell causes PALM to write binary data for restart runs at the end of a run.}
+   \par\bigskip
+   \uncover<2->{Setting of these environment variables is automatically done by  {\tt mrun}. It generates a local file (named {\tt ENVPAR}) in FORTRAN-NAMELIST-format, which is then
+   read by PALM. This file includes the following variables:} \\
+   \par\bigskip
    \tiny
-   \begin{tabular}{|p{3cm}|p{5cm}|p{2cm}|} \hline
+   \uncover<3->{
+   \begin{tabular}{|p{3cm}|p{4cm}|p{3cm}|} \hline
       \textbf{Variable}                 & \textbf{Meaning} & \textbf{Value set by {\tt mrun}-option} \\
       \hline
@@ -323,11 +367,11 @@
       {\tt run\_identifier}             & identification string for the run    & {\tt -d}    \\
       {\tt tasks\_per\_node}            & number of MPI tasks to be started on each node     & {\tt -T}     \\
-      {\tt write\_binary}               & switch for writing binary data to be used for restart runs     & {\tt -r} (+setting in configuration file {\tt .mrun.config)}       \\
+      {\tt write\_binary}               & switch for writing binary data to be used for restart runs     & {\tt -r} (+setting in configuration file {\tt .mrun.config)}  \\
       \hline
-   \end{tabular}
+   \end{tabular}}
    \normalsize
 \end{frame}
 
-%-----------------------------------------
+% Folie 12
 \begin{frame}
    \frametitle{PALM / netCDF Documentation}
Index: /palm/trunk/TUTORIAL/SOURCE/program_structure.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/program_structure.tex	(revision 945)
+++ /palm/trunk/TUTORIAL/SOURCE/program_structure.tex	(revision 945)
@@ -0,0 +1,930 @@
+% $Id$
+\input{header_tmp.tex}
+%\input{../header_lectures.tex}
+
+\usepackage[utf8]{inputenc}
+\usepackage{ngerman}
+\usepackage{pgf}
+\usetheme{Dresden}
+\usepackage{subfigure}
+\usepackage{units}
+\usepackage{multimedia}
+\newcommand{\event}[1]{\newcommand{\eventname}{#1}}
+\usepackage{xmpmulti}
+\usepackage{tikz}
+\usepackage{pdfcomment}
+\usetikzlibrary{shapes,arrows,positioning}
+\def\Tiny{\fontsize{4pt}{4pt}\selectfont}
+\usepackage{listings}
+\lstset{language=[90]Fortran,
+  basicstyle=\ttfamily \tiny,
+  keywordstyle=\color{black},
+  commentstyle=\color{black},
+  morecomment=[l]{!\ }% Comment only with space after !
+}
+
+
+\institute{Institut fÃŒr Meteorologie und Klimatologie, Leibniz UniversitÃ€t Hannover}
+\date{last update: \today}
+\event{PALM Seminar}
+\setbeamertemplate{navigation symbols}{}
+
+\setbeamertemplate{footline}
+  {%
+    \begin{beamercolorbox}[rightskip=-0.1cm]&
+     {\includegraphics[height=0.65cm]{imuk_logo.pdf}\hfill \includegraphics[height=0.65cm]{luh_logo.pdf}}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[ht=2.5ex,dp=1.125ex,%
+      leftskip=.3cm,rightskip=0.3cm plus1fil]{title in head/foot}%
+      {\leavevmode{\usebeamerfont{author in head/foot}\insertshortauthor} \hfill \eventname \hfill \insertframenumber \; / \inserttotalframenumber}%
+    \end{beamercolorbox}%
+%    \begin{beamercolorbox}[colsep=1.5pt]{lower separation line foot}%
+%    \end{beamercolorbox}
+  }
+%\logo{\includegraphics[width=0.3\textwidth]{luhimuk_logo.png}}
+
+\title[PALM Program Structure]{PALM Program Structure}
+\author{Siegfried Raasch}
+
+
+% Notes:
+% jede subsection bekommt einen punkt im menu (vertikal ausgerichtet.
+% jeder frame in einer subsection bekommt einen punkt (horizontal ausgerichtet)
+\begin{document}
+
+\begin{frame}
+\titlepage
+\end{frame}
+
+\section{PALM Program Structure}
+\subsection{PALM Program Structure}
+
+%Folie 01
+\begin{frame}
+   \begin{center}
+      PALM - Program Structure
+   \end{center}
+\end{frame}
+
+%Folie 02
+\begin{frame}
+   \frametitle{Contents}
+   \begin{flushleft}
+      This part gives a brief overview about the structure of the PALM code:
+   \end{flushleft}
+   \begin{itemize}
+      \item<2->{Flow chart}
+      \item<3->{Most important variables and how they are declared}
+      \item<4->{Machine dependencies}
+   \end{itemize}
+\end{frame}
+
+%Folie 03
+\begin{frame}[fragile]
+   \frametitle{PALM Code: General Features}
+   \begin{itemize}
+      \item<2->{PALM is written in FORTRAN90. Current version number is 3.8.}
+      \item<3->{With some very minor exceptions, the code is using the FORTRAN standard, so it should compile without error on any FORTRAN90/95 compiler.}
+      \item<4->{Data handling between subroutines is mostly done using FORTRAN90-modules instead of using parameter lists.
+      \begin{minipage}{0.45\textwidth}
+         \centering
+         \begin{lstlisting}
+SUBROUTINE parin
+   USE control_parameters
+   USE grid_variables
+   .
+   .
+         \end{lstlisting}
+      \end{minipage}
+      \begin{minipage}{0.45\textwidth}
+         \centering
+         \begin{lstlisting}
+SUBROUTINE parin( a, b, c, ... )
+   INTEGER ::  a, b
+   REAL    ::  c, ...
+   .
+   .
+         \end{lstlisting}
+      \end{minipage}
+      \mbox{All modules can be found in file .../trunk/SOURCE/modules.f90}}
+   \end{itemize}
+\end{frame}
+
+%Folie 04
+\begin{frame}
+   \frametitle{PALM Code: General Features}
+   \begin{itemize}
+      \item<2->{Machine dependent code segments, e.g. calls for flushing of buffers (CALL FLUSH / CALL FLUSH\_), or calls of special software (e.g. netCDF or dvrp), which are available on some machines only, are activated using preprocessor directives.}
+      \item<3->{The serial and parallel PALM version is also activated by preprocessor directives.}
+      \item<4->{The code is splitted into several files, most of them containing just one subroutine, e.g. file ``parin.f90'' contains ``SUBROUTINE parin''.}
+      \item<5->{The code includes an interface which can be used by users to add their own code extensions. Advantage: These code extensions can be reused (normally) for future PALM releases without requiring any changes.}
+   \end{itemize}
+\end{frame}
+
+%Folie 05
+\begin{frame}
+   \frametitle{PALM Flow Chart (I)}
+
+   \tikzstyle{white} = [rectangle, text width=0.2\textwidth, font=\tiny]
+   \tikzstyle{white2} = [rectangle, text width=0]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, minimum size=15pt, font=\tiny]
+   \tikzstyle{line} = [draw, -]
+
+   \begin{tikzpicture}[auto, node distance=0]
+      \uncover<1->{\node [yellow] (PALM) {PALM};}
+      \uncover<1->{\node [white2, right=0.2cm of PALM] (PALMspace) {};}
+
+      \uncover<2->{\node [yellow, below=0.2cm of PALMspace] (localtre) {local\_tremain\_ini};}
+      \path<2-> [line] (PALM.south) |- (localtre.west);
+
+      \uncover<3->{\node [yellow, below=0.05cm of localtre] (initdvrp) {init\_dvrp\_logging};}
+      \path<3-> [line] (PALM.south) |- (initdvrp.west);
+
+      \uncover<4->{\node [yellow, below=0.05cm of initdvrp] (parin) {parin};}
+      \path<4-> [line] (PALM.south) |- (parin.west);
+      \uncover<4->{\node [white, right=0.2cm of parin] (parinspace) {};}
+
+         \uncover<5->{\node [yellow, below=0cm of parinspace] (readvar) {read\_var\_list};}
+         \path<5-> [line,dashed] (parin.south) |- (readvar.west);
+
+         \uncover<6->{\node [yellow, below=0.05cm of readvar] (packageparin) {package\_parin};}
+         \path<6-> [line,dashed] (parin.south) |- (packageparin.west);
+
+         \uncover<7->{\node [yellow, below=0.05cm of packageparin] (userparin) {user\_parin};}
+         \path<7-> [line] (parin.south) |- (userparin.west);
+
+      \uncover<8->{\node [yellow, below=1.4cm of parin] (initpeg) {init\_pegrid};}
+      \path<8-> [line] (PALM.south) |- (initpeg.west);
+      \uncover<8->{\node [white, right=0.2cm of initpeg] (initpegspace) {};}
+
+         \uncover<9->{\node [yellow, below=0cm of initpegspace] (poisfftinit) {poisfft\_init};}
+         \path<9-> [line] (initpeg.south) |- (poisfftinit.west);
+
+      \uncover<10->{\node [yellow, below=0.3cm of initpeg] (initgrid) {init\_grid};}
+      \path<10-> [line] (PALM.south) |- (initgrid.west);
+
+      \uncover<11->{\node [yellow, below=0.05cm of initgrid] (checkpara) {check\_parameters};}
+      \path<11-> [line] (PALM.south) |- (checkpara.west);
+
+      \uncover<12->{\node [yellow, below=0.05cm of checkpara] (header) {header};}
+      \path<12-> [line] (PALM.south) |- (header.west);
+      \uncover<12->{\node [white, right=0.2cm of header] (headerspace) {};}
+
+         \uncover<13->{\node [yellow, below=0cm of headerspace] (userheader) {user\_header};}
+         \path<13-> [line,dashed] (header.south) |- (userheader.west);
+
+      \uncover<1->{\node [white, below=5.8cm of PALM] (continu2) {};}
+      \path<1-> [line,dashed] (PALM.south) |- (continu2.north);
+
+      \uncover<1->{\node [white, below=5.2cm of PALM] (continu1) {};}
+      \path<1-> [line] (PALM.south) |- (continu1.north);
+   \end{tikzpicture}
+\end{frame}
+
+%Folie 06
+\begin{frame}
+   \frametitle{PALM Flow Chart (II)}
+
+   \tikzstyle{white} = [rectangle, text width=0.2\textwidth, font=\tiny]
+   \tikzstyle{whitelarge} = [rectangle, text width=0.43\textwidth, font=\tiny]
+   \tikzstyle{whitesmall} = [rectangle, text width=0.08\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{white2} = [rectangle, text width=0]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{yellowsmall} = [rectangle, draw, fill=yellow!20, text width=0.08\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{yellowlarge} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{yellowLarge} = [rectangle, draw, fill=yellow!20, text width=0.43\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{line} = [draw, -]
+
+   \begin{tikzpicture}[auto, node distance=0]
+      \uncover<1->{\node [white2] (contino1) {};}
+      \uncover<1->{\node [white2, below=0.26cm of contino1] (PALM) {};}
+
+      \uncover<2->{\node [yellow, right=0.2cm of PALM] (init3d) {init\_3d\_model};}
+      \path<2-> [line] (PALM.south) |- (init3d.west);
+      \uncover<2->{\node [white, right=0.05cm of init3d] (init3dspace) {};}
+      \uncover<2->{\node [whitelarge, right=0.05cm of init3d] (init3dspacelarge) {};}
+
+         \uncover<3->{\node [yellowLarge, below=-0.05cm of init3dspacelarge] (init1d) {init\_1d\_model (calls various subroutines)};}
+         \path<3-> [line,dashed] (init3d.south) |- (init1d.west);
+
+         \uncover<4->{\node [yellow, below=0.5cm of init3dspace] (initslope) {init\_slope};}
+         \path<4-> [line,dashed] (init3d.south) |- (initslope.west);
+
+         \uncover<5->{\node [yellow, below=0.05cm of initslope] (disturbh) {disturb\_heatflux};}
+         \path<5-> [line,dashed] (init3d.south) |- (disturbh.west);
+
+         \uncover<6->{\node [yellow, below=0.05cm of disturbh] (initrank) {init\_rankine};}
+         \path<6-> [line,dashed] (init3d.south) |- (initrank.west);
+
+            \uncover<7->{\node [yellow, right=0.05cm of initrank] (initpt) {init\_pt\_anomaly};}
+            \path<7-> [line] (initrank.east) -- (initpt.west);
+
+         \uncover<8->{\node [yellow, below=0.05cm of initrank] (disturbf) {disturb\_field};}
+         \path<8-> [line,dashed] (init3d.south) |- (disturbf.west);
+
+            \uncover<9->{\node [yellow, right=0.05cm of disturbf] (pres) {pres};}
+            \path<9-> [line] (disturbf.east) -- (pres.west);
+            \uncover<9->{\node [white, below=-0.05cm of pres] (presspace) {};}
+
+               \uncover<10->{\node [yellowsmall, right=0.05cm of presspace] (poisfft) {poisfft};}
+               \path<10-> [line] (pres.east) -| (poisfft.north);
+
+               \uncover<11->{\node [yellowsmall, right=0.05cm of poisfft] (sor) {sor};}
+               \path<11-> [line] (pres.east) -| (sor.north);
+
+               \uncover<12->{\node [yellowsmall, right=0.05cm of sor] (poismg) {poismg};}
+               \path<12-> [line] (pres.east) -| (poismg.north);
+
+         \uncover<13->{\node [yellow, below=0.4cm of disturbf] (read3d) {read\_3d\_binary};}
+         \path<13-> [line,dashed] (init3d.south) |- (read3d.west);
+
+            \uncover<14->{\node [yellow, right=0.05cm of read3d] (initdvrp) {init\_dvrp};}
+            \path<14-> [line] (read3d.east) -- (initdvrp.west);
+
+               \uncover<15->{\node [yellowlarge, right=0.05cm of initdvrp] (initcloud) {init\_cloud\_physics};}
+               \path<15-> [line] (initdvrp.east) -- (initcloud.west);
+
+         \uncover<16->{\node [yellow, below=0.05cm of read3d] (initpart) {init\_particles};}
+         \path<16-> [line] (init3d.south) |- (initpart.west);
+         \uncover<16->{\node [white, right=0.05cm of initpart] (initpartspace) {};}
+
+            \uncover<17->{\node [yellow, below=-0.05cm of initpartspace] (userinitpart) {user\_init\_particles};}
+            \path<17-> [line] (initpart.south) |- (userinitpart.west);
+
+            \uncover<18->{\node [yellow, below=0.05cm of userinitpart] (sortpart) {sort\_particles};}
+            \path<18-> [line] (initpart.south) |- (sortpart.west);
+
+            \uncover<19->{\node [yellow, below=0.05cm of sortpart] (dataoutput) {data\_output\_dvrp};}
+            \path<19-> [line,dashed] (initpart.south) |- (dataoutput.west);
+
+               \uncover<20->{\node [yellow, right=0.05cm of dataoutput] (userdvrp) {user\_dvrp\_coltab};}
+               \path<20-> [line,dashed] (dataoutput.east) -- (userdvrp.west);
+
+         \uncover<21->{\node [yellow, below=1.45cm of initpart] (initadvec) {init\_advec};}
+         \path<21-> [line] (init3d.south) |- (initadvec.west);
+
+            \uncover<22->{\node [yellow, right=0.05cm of initadvec] (userinit) {user\_init};}
+            \path<22-> [line] (initadvec.east) -- (userinit.west);
+
+      \uncover<23->{\node [yellow, below=5.8cm of init3d] (dataout2d) {data\_output\_2d};}
+      \path<23-> [line,dashed] (PALM.south) |- (dataout2d.west);
+
+         \uncover<24->{\node [yellow, right=0.05cm of dataout2d] (dataout3d) {data\_output\_3d};}
+         \path<24-> [line] (dataout2d.east) -- (dataout3d.west);
+
+      \uncover<1->{\node [white2, below=6.6cm of PALM] (continu2) {};}
+      \path<1-> [line,dashed] (contino1.south) |- (continu2.north);
+
+      \uncover<1->{\node [white2, below=6.0cm of PALM] (continu1) {};}
+      \path<1-> [line] (PALM.south) |- (continu1.north);
+   \end{tikzpicture}
+\end{frame}
+
+
+%Folie 07
+\begin{frame}
+   \frametitle{PALM Flow Chart (III)}
+
+   \tikzstyle{white} = [rectangle, text width=0.2\textwidth, font=\tiny]
+   \tikzstyle{whitelarge} = [rectangle, text width=0.3\textwidth, font=\tiny]
+   \tikzstyle{whitesmall} = [rectangle, text width=0.08\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{white2} = [rectangle, text width=0]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{yellowsmall} = [rectangle, draw, fill=yellow!20, text width=0.08\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{yellowlarge} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{yellowLarge} = [rectangle, draw, fill=yellow!20, text width=0.3\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{line} = [draw, -]
+   \tikzstyle{linered} = [draw, color=red, -]
+   \tikzstyle{Bigwhite} = [rectangle, text width=0.63\textwidth, minimum size=35pt, font=\tiny]
+   \tikzstyle{Bigbox} = [rectangle, draw, fill=gray!20, text width=0.65\textwidth, minimum size=33pt, font=\tiny]
+   \tikzstyle{redsmall} = [rectangle, draw, align=center, fill=red!100, text width=0.08\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{boxinfo} = [rectangle, align=center, text width=0.3\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{whitebox} = [rectangle, text width=0.2\textwidth, minimum size=12pt, font=\tiny]
+   
+   %"align=center" hinzufÃŒgen, um in den boxen zu zentrieren.
+   
+   \begin{tikzpicture}[auto, node distance=0]
+      \uncover<1->{\node [white2] (contino1) {};}
+      \uncover<1->{\node [white2, below=0.26cm of contino1] (PALM) {};}
+
+      \uncover<1->{\node [yellow, right=0.2cm of PALM] (timeintegr) {time\_integration};}
+      \uncover<1->{\node [whitebox, right=0.3cm of PALM] (timeintegrline) {};}
+      \path<1-> [line] (PALM.south) |- (timeintegr.west);
+      \uncover<1->{\node [white, right=0.05cm of timeintegr] (timeintegrspace) {};}
+      \uncover<1->{\node [whitelarge, right=0.05cm of timeintegr] (timeintegrspacelarge) {};}
+      \uncover<1->{\node [Bigwhite, right=0.05cm of timeintegr] (timeintegrspacebox) {};}
+
+         \uncover<1->{\node [yellow, below=-0.05cm of timeintegrspace] (timestep) {timestep};}
+         \path<1-> [line] (timeintegr.south) |- (timestep.west);
+
+         \uncover<1->{\node [yellow, below=0.05cm of timestep] (runcontrol) {run\_control};}
+         \path<1-> [line] (timeintegr.south) |- (runcontrol.west);
+
+            \uncover<1->{\node [yellow, right=0.05cm of runcontrol] (flowstatistics) {flow\_statistics};}
+            \path<1-> [line] (runcontrol.east) -- (flowstatistics.west);
+
+         \uncover<1->{\node [yellowLarge, below=0.95cm of timeintegrspacelarge] (useractions) {user\_actions (before\_timestep)};}
+         \path<1-> [line] (timeintegr.south) |- (useractions.west);
+
+         \uncover<1->{\node [yellowLarge, below=0.05cm of useractions] (timestepscheme) {timestep\_scheme\_steering};}
+         \path<1-> [line] (timeintegr.south) |- (timestepscheme.west);
+
+         \uncover<1->{\node [Bigbox, below=1.75cm of timeintegrspacebox] (bigbox) {};}
+%         \path<1-> [line] (timeintegr.south) |- (bigbox.west);
+         \uncover<1->{\node [white, below=2cm of timeintegrline] (boxlinespace) {};}
+         \path<1-> [line] (timeintegrline.south) |- (boxlinespace.north);
+
+            \uncover<1->{\node [yellowLarge, below=0.4cm of timestepscheme] (prognosticequno) {prognostic\_equations\_noopt};}
+            \uncover<1->{\node [yellowLarge, right=0.05cm of prognosticequno] (prognosticequca) {prognostic\_equations\_cache};}
+            \uncover<1->{\node [yellowLarge, below=0.05cm of prognosticequca] (prognosticequve) {prognostic\_equations\_vector};}
+            \uncover<1->{\node [boxinfo, below=-0.025cm of prognosticequno] (Boxinfo) {For details, see \\ PALM Flow Chart (V).};}
+            \path<1-> [linered] (boxlinespace.north) -| (prognosticequca.north);
+            \path<1-> [line] (boxlinespace.north) -| (prognosticequno.north);
+            \uncover<1->{\node [redsmall, above=0.3cm of prognosticequca] (redadv) {standard\\advection};}
+
+         \uncover<1->{\node [yellow, below=2.7cm of runcontrol] (advecpart) {advec\_particles};}
+         \path<1-> [line,dashed] (advecpart.west) -| (timeintegr.south);
+
+            \uncover<1->{\node [yellowLarge, right=0.05cm of advecpart] (userpartatt) {user\_particle\_attributes + more};}
+            \path<1-> [line] (advecpart.east) -- (userpartatt.west);
+
+         \uncover<1->{\node [yellowLarge, below=2.15cm of timestepscheme] (interactiondrop) {interaction\_droplets\_ptq};}
+         \path<1-> [line,dashed] (interactiondrop.west) -| (timeintegr.south);
+
+         \uncover<1->{\node [yellow, below=0.535cm of advecpart] (asselinfilter) {asselin\_filter};}
+         \path<1-> [line,dashed] (asselinfilter.west) -| (timeintegr.south);
+
+         \uncover<1->{\node [yellow, below=0.05cm of asselinfilter] (swaptimelevel) {swap\_timelevel};}
+         \path<1-> [line] (swaptimelevel.west) -| (timeintegr.south);
+
+            \uncover<1->{\node [yellow, right=0.05cm of swaptimelevel] (boundaryconds) {boundary\_conds};}
+            \path<1-> [line] (swaptimelevel.east) -- (boundaryconds.west);
+
+         \uncover<1->{\node [yellow, below=0.05cm of swaptimelevel] (disturbfield) {disturb\_field};}
+         \path<1-> [line,dashed] (disturbfield.west) -| (timeintegr.south);
+
+      \uncover<1->{\node [white2, below=6.6cm of PALM] (continu2) {};}
+      \path<1-> [line,dashed] (contino1.south) |- (continu2.north);
+
+      \uncover<1->{\node [white2, below=6.0cm of PALM] (continu1) {};}
+      \path<1-> [line] (PALM.south) |- (continu1.north);
+   \end{tikzpicture}
+\end{frame}
+
+
+%Folie 08
+\begin{frame}
+   \frametitle{PALM Flow Chart (IV)}
+
+   \tikzstyle{white} = [rectangle, text width=0.2\textwidth, font=\tiny]
+   \tikzstyle{whitelarge} = [rectangle, text width=0.3\textwidth, font=\tiny]
+   \tikzstyle{whitesmall} = [rectangle, text width=0.08\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{white2} = [rectangle, text width=0]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{yellowsmall} = [rectangle, draw, fill=yellow!20, text width=0.08\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{yellowlarge} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{yellowLarge} = [rectangle, draw, fill=yellow!20, text width=0.3\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{line} = [draw, -]
+   \tikzstyle{linered} = [draw, color=red, -]
+   \tikzstyle{Bigwhite} = [rectangle, text width=0.63\textwidth, minimum size=35pt, font=\tiny]
+   \tikzstyle{Bigbox} = [rectangle, draw, fill=gray!20, text width=0.65\textwidth, minimum size=33pt, font=\tiny]
+   \tikzstyle{redsmall} = [rectangle, draw, align=center, fill=red!100, text width=0.08\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{boxinfo} = [rectangle, align=center, text width=0.3\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{whitebox} = [rectangle, text width=0.2\textwidth, minimum size=12pt, font=\tiny]
+   
+   %"align=center" hinzufÃŒgen, um in den boxen zu zentrieren.
+   
+   \begin{tikzpicture}[auto, node distance=0]
+      \uncover<1->{\node [white2] (contino1) {};}
+      \uncover<1->{\node [white2, below=0.26cm of contino1] (PALM) {};}
+
+      \uncover<1->{\node [yellow, right=0.2cm of PALM] (timeintegr) {time\_integration};}
+      \path<1-> [line] (PALM.south) |- (timeintegr.west);
+      \uncover<1->{\node [white, right=0.05cm of timeintegr] (timeintegrspace) {};}
+      \uncover<1->{\node [whitelarge, right=0.05cm of timeintegr] (timeintegrspacelarge) {};}
+
+         \uncover<1->{\node [yellow, below=-0.05cm of timeintegrspace] (pres) {pres};}
+         \path<1-> [line] (timeintegr.south) |- (pres.west);
+         \uncover<1->{\node [white, below=-0.05cm of pres] (presspace) {};}
+
+            \uncover<1->{\node [yellowsmall, right=0.05cm of presspace] (poisfft) {poisfft};}
+            \path<1-> [line] (pres.east) -| (poisfft.north);
+
+            \uncover<1->{\node [yellowsmall, right=0.05cm of poisfft] (sor) {sor};}
+            \path<1-> [line] (pres.east) -| (sor.north);
+
+            \uncover<1->{\node [yellowsmall, right=0.05cm of sor] (poismg) {poismg};}
+            \path<1-> [line] (pres.east) -| (poismg.north);
+
+         \uncover<1->{\node [yellow, below=0.355cm of pres] (boundaryconds) {boundary\_conds};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (boundaryconds.west);
+
+         \uncover<1->{\node [yellow, below=0.05cm of boundaryconds] (computevpt) {compute\_vpt};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (computevpt.west);
+
+            \uncover<1->{\node [yellowLarge, right=0.05cm of computevpt] (calcliquidwatercontent) {calc\_liquid\_water\_content};}
+            \path<1-> [line] (computevpt.east) -- (calcliquidwatercontent.west);
+
+         \uncover<1->{\node [yellow, below=0.05cm of computevpt] (prandtlfluxes) {prandtl\_fluxes};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (prandtlfluxes.west);
+
+         \uncover<1->{\node [yellow, below=0.05cm of prandtlfluxes] (diffusivities) {diffusivities};}
+         \path<1-> [line] (timeintegr.south) |- (diffusivities.west);
+
+         \uncover<1->{\node [yellowLarge, below=2.855cm of timeintegrspacelarge] (useractionsafter) {user\_actions (after\_integration)};}
+         \path<1-> [line] (timeintegr.south) |- (useractionsafter.west);
+
+         \uncover<1->{\node [yellow, below=0.575cm of diffusivities] (checkforrestart) {check\_for\_restart};}
+         \path<1-> [line] (timeintegr.south) |- (checkforrestart.west);
+
+            \uncover<1->{\node [yellow, right=0.05cm of checkforrestart] (localtremain) {local\_tremain};}
+            \path<1-> [line] (checkforrestart.east) -- (localtremain.west);
+
+         \uncover<1->{\node [yellow, below=1.1cm of diffusivities] (flowstatistics) {flow\_statistics};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (flowstatistics.west);
+
+            \uncover<1->{\node [yellow, right=0.05cm of flowstatistics] (sumup3ddata) {sum\_up\_3d\_data};}
+            \path<1-> [line] (flowstatistics.east) -- (sumup3ddata.west);
+
+               \uncover<1->{\node [yellow, right=0.05cm of sumup3ddata] (calcspectra) {calc\_spectra};}
+               \path<1-> [line] (sumup3ddata.east) -- (calcspectra.west);
+
+         \uncover<1->{\node [yellow, below=0.05cm of flowstatistics] (runcontrol) {run\_control};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (runcontrol.west);
+
+            \uncover<1->{\node [yellow, right=0.05cm of runcontrol] (dataoutput) {data\_output\_***};}
+            \path<1-> [line] (runcontrol.east) -- (dataoutput.west);
+
+         \uncover<1->{\node [yellow, below=0.05cm of runcontrol] (disturbheatflux) {disturb\_heatflux};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (disturbheatflux.west);
+
+         \uncover<1->{\node [yellowLarge, below=2.125cm of useractionsafter] (useractionsaftert) {user\_actions (after\_timestep)};}
+         \path<1-> [line] (timeintegr.south) |- (useractionsaftert.west);
+
+      \uncover<1->{\node [white2, below=6.6cm of PALM] (continu2) {};}
+      \path<1-> [line,dashed] (contino1.south) |- (continu2.north);
+
+      \uncover<1->{\node [white2, below=6.0cm of PALM] (continu1) {};}
+      \path<1-> [line] (PALM.south) |- (continu1.north);
+   \end{tikzpicture}
+\end{frame}
+
+
+%Folie 09
+\begin{frame}
+   \frametitle{PALM Flow Chart (V)}
+
+   \tikzstyle{white} = [rectangle, text width=0.2\textwidth, font=\tiny]
+   \tikzstyle{whitelarge} = [rectangle, text width=0.3\textwidth, font=\tiny]
+   \tikzstyle{whitesmall} = [rectangle, text width=0.08\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{white2} = [rectangle, text width=0]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.18\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{yellowsmall} = [rectangle, draw, fill=yellow!20, text width=0.08\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{yellowlarge} = [rectangle, draw, fill=yellow!20, text width=0.255\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{yellowLarge} = [rectangle, draw, align=center, fill=yellow!20, text width=0.32\textwidth, minimum size=12pt, font=\scriptsize]
+   \tikzstyle{line} = [draw, -]
+   \tikzstyle{linered} = [draw, color=red, -]
+   \tikzstyle{Bigwhite} = [rectangle, text width=0.63\textwidth, minimum size=35pt, font=\tiny]
+   \tikzstyle{Bigbox} = [rectangle, draw, fill=gray!20, text width=1\textwidth, minimum size=183pt, font=\tiny]
+   \tikzstyle{redsmall} = [rectangle, draw, align=center, fill=red!100, text width=0.18\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{boxinfo} = [rectangle, align=center, text width=0.3\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{whitebox} = [rectangle, text width=0.2\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{bigbox} = [rectangle, draw, fill=white!100, text width=0.21\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{bigbox2} = [rectangle, draw, align=center, fill=white!100, text width=0.29\textwidth, minimum size=12pt, font=\tiny]
+   
+   \tikzstyle{framebox} = [rectangle, draw, text width=0.2\textwidth, minimum size=104pt, font=\tiny]
+   \tikzstyle{Endbox} = [rectangle, draw, fill=gray!20, text width=0.21\textwidth, minimum size=12pt, font=\tiny]
+
+   
+   %"align=center" hinzufÃŒgen, um in den boxen zu zentrieren.
+   
+   \begin{tikzpicture}[auto, node distance=0, >=stealth]
+
+      \uncover<1->{\node [Bigbox] (bigbox) {};}
+      \uncover<1->{\node [redsmall, above=-0.23cm of bigbox] (redadv) {standard advection};}
+
+      \uncover<1->{\node [yellow, below=0.1cm of redadv] (calcmeanptprofile) {calc\_mean\_pt\_profile};}
+
+      \uncover<1->{\node [yellowLarge, left=0.5cm of calcmeanptprofile] (prognosticequationsnoopt) {prognostic\_equations\_noopt};}
+      \uncover<1->{\node [yellowLarge, right=0.5cm of calcmeanptprofile] (prognosticequationscache) {prognostic\_equations\_cache};}
+      \uncover<1->{\node [yellowLarge, below=2.35cm of prognosticequationscache] (prognosticequationsvector) {prognostic\_equations\_vector};}
+
+      \uncover<1->{\node [yellow, below=-0.05cm of calcmeanptprofile] (calcradiation) {calc\_radiation};}
+      \uncover<1->{\node [yellow, below=-0.05cm of calcradiation] (impactoflatentheat) {impact\_of\_latent\_heat};}
+      \uncover<1->{\node [yellow, below=-0.05cm of impactoflatentheat] (calcprecipitation) {calc\_precipitation};}
+      \uncover<1->{\node [yellow, below=-0.05cm of calcprecipitation] (productioneinit) {production\_e\_init};}
+      
+      \uncover<1->{\node [whitesmall, left=-1.4cm of productioneinit] (productioneinitspace1) {};}
+      \uncover<1->{\node [whitesmall, below=0cm of productioneinitspace1] (productioneinitspace2) {};}
+
+      \uncover<1->{\node [bigbox, below=0.05cm of prognosticequationscache] (listingscache) {
+         \texttt{\linespread {0.7}\selectfont\noindent
+            DO i=nxl,nxr\\
+            \quad DO j=nys,nyn\\
+            \quad \quad CALL \textcolor{blue}{u-subr}\\
+            \quad \quad CALL \textcolor{blue}{v-subr}\\
+            \quad \quad CALL \textcolor{blue}{w-subr}\\
+            \quad \quad CALL \textcolor{blue}{pt-subr}\\
+            \quad \quad CALL \textcolor{blue}{q or s-subr}\\
+            \quad \quad CALL \textcolor{blue}{e-subr}\\
+            \quad ENDDO\\
+            ENDDO\\
+         }
+      };}
+      
+      \uncover<1->{\node [bigbox, below=0.05cm of prognosticequationsvector] (listingsvector) {
+         \texttt{\linespread {0.7}\selectfont\noindent
+            CALL \textcolor{blue}{u-subr}\\
+            CALL \textcolor{blue}{v-subr}\\
+            .\\
+            .\\
+            .\\
+            !within subroutines:\\
+            DO i=nxl,nxr\\
+            \quad DO j=nys,nyn\\
+            \quad \quad DO k=nzb+1,nzt\\
+            \quad \quad \quad \quad ...\\
+            \quad \quad ENDDO\\
+            \quad ENDDO\\
+            ENDDO\\
+         }
+      };}
+
+      \uncover<1->{\node [bigbox, below=0.05cm of prognosticequationsnoopt] (listingsnoopt1) {
+         \texttt{\linespread {0.7}\selectfont\noindent
+            DO i=nxl,nxr\\
+            \quad DO j=nys,nyn\\
+            \quad \quad CALL \textcolor{blue}{u-subr}\\
+            \quad ENDDO\\
+            ENDDO\\
+         }
+      };}
+
+      \uncover<1->{\node [bigbox, below=0.05cm of listingsnoopt1] (listingsnoopt2) {
+         \texttt{\linespread {0.7}\selectfont\noindent
+            DO i=nxl,nxr\\
+            \quad DO j=nys,nyn\\
+            \quad \quad CALL \textcolor{blue}{v-subr}\\
+            \quad ENDDO\\
+            ENDDO\\
+         }
+      };}
+
+      \uncover<1->{\node [bigbox, below=1.95cm of listingsnoopt2] (listingsnoopt3) {
+         \texttt{\linespread {0.7}\selectfont\noindent
+            DO i=nxl,nxr\\
+            \quad DO j=nys,nyn\\
+            \quad \quad CALL \textcolor{blue}{e-subr}\\
+            \quad ENDDO\\
+            ENDDO\\
+         }
+      };}
+
+      \path<1-> [line,dotted] (listingsnoopt2.south) |- (listingsnoopt3.north);
+
+      \uncover<1->{\node [whitesmall, right=-1.35cm of listingsnoopt2] (listingsnoopt251) {};}
+      \uncover<1->{\node [whitesmall, below=0.8cm of listingsnoopt251] (listingsnoopt252) {\texttt{\textcolor{blue}{w\\pt\\q or s}}};}
+
+      \uncover<1->{\node [bigbox2, below=-0.25cm of productioneinitspace2] (foreachvariable) {
+         \textcolor{blue}{
+            \textbf{\underline{For each variable:}}\\
+            u-, v-, w-component,\\
+            pt, q or s, sa, e (SGS-TKE)
+         }
+      };}
+
+      \uncover<1->{\node [whitesmall, right=-2.08cm of foreachvariable] (foreachvariablespace1) {};}
+      \uncover<1->{\node [whitesmall, below=-0.18cm of foreachvariablespace1] (foreachvariablespace2) {};}
+
+      \uncover<1->{\node [yellowlarge, below=0.05cm of foreachvariablespace2] (advecuvws) {advec\_\{uvws\}};}
+      \path<1-> [line] (advecuvws.west) -| (foreachvariable.west);
+
+      \uncover<1->{\node [yellowlarge, below=-0.05cm of advecuvws] (diffusionuvwse) {diffusion\_\{uvwse\}};}
+      \path<1-> [line] (diffusionuvwse.west) -| (foreachvariable.west);
+
+      \uncover<1->{\node [yellowlarge, below=-0.05cm of diffusionuvwse] (coriolis) {coriolis};}
+      \path<1-> [line,dashed] (coriolis.west) -| (foreachvariable.west);
+
+      \uncover<1->{\node [yellowlarge, below=-0.05cm of coriolis] (buoyancy) {buoyancy};}
+      \path<1-> [line,dashed] (buoyancy.west) -| (foreachvariable.west);
+
+      \uncover<1->{\node [yellowlarge, below=-0.05cm of buoyancy] (useractionstend) {\mbox{user\_actions (i,j,***-tendency)}};}
+      \path<1-> [line] (useractionstend.west) -| (foreachvariable.west);
+
+      \uncover<1->{\node [yellowlarge, below=-0.05cm of useractionstend] (productione) {production\_e};}
+      \path<1-> [line,dashed] (productione.west) -| (foreachvariable.west);
+
+      \uncover<1->{\node [framebox, below=-1.025cm of foreachvariable] (foreachvariableframe) {};}
+      \uncover<1->{\draw [<-,line width=5pt, color=blue] (1,0.2) -- (1.5,1);}
+      \uncover<1->{\draw [<-,line width=5pt, color=blue] (-1.54,0.2) -- (-2.04,1);}
+
+
+
+      \uncover<2->{\node [Endbox, below=6.05cm of redadv] (endbox) {
+         \texttt{\linespread {0.7}\selectfont\noindent
+            !within subroutines:\\
+            DO k=nzb+1,nzt\\
+            \quad \quad \textcolor{blue}{...}\\
+            ENDDO\\
+         }
+      };}
+
+      \uncover<2->{\draw [<-,thick] (endbox.east) -- (listingscache.west);}
+      \uncover<2->{\draw [<-,thick] (endbox.west) -- (listingsnoopt1.east);}
+      \uncover<2->{\draw [<-,thick] (endbox.west) -- (listingsnoopt2.east);}
+      \uncover<2->{\draw [<-,thick] (endbox.west) -- (listingsnoopt3.east);}
+
+   \end{tikzpicture}
+\end{frame}
+
+
+%Folie 10
+\begin{frame}
+   \frametitle{PALM Flow Chart (VI)}
+
+   \tikzstyle{white} = [rectangle, text width=0.2\textwidth, font=\tiny]
+   \tikzstyle{whitelarge} = [rectangle, text width=0.3\textwidth, font=\tiny]
+   \tikzstyle{whitesmall} = [rectangle, text width=0.08\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{white2} = [rectangle, text width=0]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{yellowsmall} = [rectangle, draw, fill=yellow!20, text width=0.08\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{yellowlarge} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{yellowLarge} = [rectangle, draw, fill=yellow!20, text width=0.3\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{line} = [draw, -]
+   \tikzstyle{linered} = [draw, color=red, -]
+   \tikzstyle{Bigwhite} = [rectangle, text width=0.63\textwidth, minimum size=35pt, font=\tiny]
+   \tikzstyle{Bigbox} = [rectangle, draw, fill=gray!20, text width=0.65\textwidth, minimum size=33pt, font=\tiny]
+   \tikzstyle{redsmall} = [rectangle, draw, align=center, fill=red!100, text width=0.08\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{boxinfo} = [rectangle, align=center, text width=0.3\textwidth, minimum size=12pt, font=\tiny]
+   \tikzstyle{whitebox} = [rectangle, text width=0.2\textwidth, minimum size=12pt, font=\tiny]
+   
+   %"align=center" hinzufÃŒgen, um in den boxen zu zentrieren.
+   
+   \begin{tikzpicture}[auto, node distance=0]
+      \uncover<1->{\node [white2] (contino1) {};}
+      \uncover<1->{\node [white2, below=0.26cm of contino1] (PALM) {};}
+
+      \uncover<1->{\node [yellow, right=0.2cm of PALM] (timeintegr) {time\_integration};}
+      \path<1-> [line] (PALM.south) |- (timeintegr.west);
+      \uncover<1->{\node [white, right=0.05cm of timeintegr] (timeintegrspace) {};}
+      \uncover<1->{\node [whitelarge, right=0.05cm of timeintegr] (timeintegrspacelarge) {};}
+      \uncover<1->{\node [white, below=0.8cm of timeintegr] (boxlinespace) {};}
+      \uncover<1->{\node [white, below=1.3cm of timeintegr] (boxlinespacedash) {};}
+      \path<1-> [line] (timeintegr.south) |- (boxlinespace.north);
+      \path<1-> [line,dashed] (timeintegr.south) |- (boxlinespacedash.north);
+
+
+      \uncover<1->{\node [yellow, below=2cm of timeintegr] (write3dbinary) {write\_3d\_binary};}
+      \path<1-> [line,dashed] (PALM.south) |- (write3dbinary.west);
+
+         \uncover<1->{\node [yellow, right=0.05cm of write3dbinary] (writevarlist) {write\_var\_list};}
+         \path<1-> [line] (write3dbinary.east) -- (writevarlist.west);
+
+      \uncover<1->{\node [yellow, below=0.05cm of write3dbinary] (writeparticles) {write\_particles};}
+      \path<1-> [line] (PALM.south) |- (writeparticles.west);
+
+      \uncover<1->{\node [yellow, below=0.05cm of writeparticles] (header) {header};}
+      \path<1-> [line] (PALM.south) |- (header.west);
+
+         \uncover<1->{\node [yellow, right=0.05cm of header] (userheader) {user\_header};}
+         \path<1-> [line] (header.east) -- (userheader.west);
+
+      \uncover<1->{\node [yellow, below=0.05cm of header] (userlastactions) {user\_last\_actions};}
+      \path<1-> [line] (PALM.south) |- (userlastactions.west);
+
+      \uncover<1->{\node [yellow, below=0.05cm of userlastactions] (cpustatistics) {cpu\_statistics};}
+      \path<1-> [line] (PALM.south) |- (cpustatistics.west);
+
+      \uncover<1->{\node [white2, below=5.6cm of PALM] (continu2) {};}
+      \path<1-> [line,dashed] (contino1.south) |- (continu2.north);
+
+      \uncover<1->{\node [white2, below=5.0cm of PALM] (continu1) {};}
+      \path<1-> [line] (PALM.south) |- (continu1.north);
+   \end{tikzpicture}
+\end{frame}
+
+%Folie 11
+\begin{frame}[fragile]
+   \frametitle{Important Variables and Their Declaration}
+   \begin{itemize}
+      \item<2->{3D-arrays of prognostic variables are named $\Psi_m$, $\Psi$, and $\Psi_p$ for time level $t-\Delta t$, $t$, and $t+\Delta T$, respectively, with $\Psi = u$, $v$, $w$, $pt$, $q$, $e$, $sa$}
+      \item<3->{They are by default declared as $\Psi$($z$,$y$,$x$) or $\Psi$($k$,$j$,$i$), e.g.\\
+      \begin{minipage}{0.2\textwidth}
+         with\\\\
+      \end{minipage}
+      \begin{minipage}{0.7\textwidth}
+         \centering
+         \begin{lstlisting}
+u(nzb:nzt+1,nysg:nyng,nxlg:nxrg)
+
+
+nysg = nys - ngl,  nyng = nyn + ngl
+nxlg = nxl - ngl,  nxrg = nxr + ngl
+nzb, nzt (bottom, top)
+nys, nyn (south, north)
+nxl, nxr (left, right)
+         \end{lstlisting}
+      \end{minipage}\\
+      as the index limits of the (sub-)domain. ngl is the number of ghost layers which depends on the advection scheme ( ngl = 3 for the default Wicker-Skamarock scheme)
+      }
+   \end{itemize}
+\end{frame}
+
+%Folie 12
+\begin{frame}[fragile]
+   \frametitle{Important Variables and Their Declaration}
+   \begin{itemize}
+      \item<1->{If only one processor is used, then\\
+      \begin{minipage}{0.2\textwidth}
+         \quad \\\\
+      \end{minipage}
+      \begin{minipage}{0.7\textwidth}
+         \centering
+         \begin{lstlisting}
+nxl = 0; nxr = nx
+nys = 0; nyn = ny
+         \end{lstlisting}
+      \end{minipage}\\
+      }
+      \item<2->{For speed optimization, most of the 3D-variables are declared as pointers, e.g.\\
+      \begin{minipage}{0.2\textwidth}
+         \quad \\\\
+      \end{minipage}
+      \begin{minipage}{0.7\textwidth}
+         \centering
+         \begin{lstlisting}
+REAL, DIMENSION(:,:,:), POINTER ::  u, u_m, u_p, ...
+         \end{lstlisting}
+      \end{minipage}\\
+      This does not affect the usage of these variables in the code in (almost) any way.
+      }
+   \end{itemize}
+\end{frame}
+
+%Folie 13
+\begin{frame}[fragile]
+   \frametitle{Some Other Frequently Used Variables}
+
+\begin{table}[htbp]
+  \centering
+%  \caption{Add caption}
+    \begin{tabular}{|l|l|p{0.22\linewidth}|l|}
+    \hline
+    variable & index bounds & meaning & comment\\
+    \hline
+    \hline
+    \texttt{\tiny zu }   & \texttt{\tiny nzb:nzt+1 }& \tiny heights of the scalar (u,v) grid levels & \texttt{\tiny zu(0)=-zu(1)}\\
+    \hline
+    \texttt{\tiny zw }   & \texttt{\tiny nzb:nzt+1 }& \tiny heights of the w grid level & \texttt{\tiny zw(0)=0 }\\
+    \hline
+    \texttt{\tiny dzu }  & \texttt{\tiny 1:nzt+1 }& \tiny vertical grid spacings between scalar grid levels & \texttt{\tiny dzu(k)=zu(k)-zu(k-1)}\\
+    \hline
+    \texttt{\tiny ddzu } & \texttt{\tiny 1:nzt+1 }& \tiny inverse of grid spacings & \texttt{\tiny ddzu(k)=1.0/dzu(k)}\\
+    \hline
+    \texttt{\tiny dx  }  &       & {\tiny grid spacing along x} &  \\
+    \hline
+    \texttt{\tiny ddx }  &       & {\tiny inverse of dx} & \texttt{\tiny ddx=1.0/dx }\\
+    \hline
+    \texttt{\tiny current\_timestep\_number} &       & {\tiny timestep counter} &  \\
+    \hline
+    \texttt{\tiny simulated\_time }&       & {\tiny simulated time in seconds} &  \\
+    \hline
+    \end{tabular}%
+%  \label{tab:addlabel}%
+\end{table}%
+\end{frame}
+
+
+%Folie 14
+\begin{frame}[fragile]
+   \frametitle{Preprocessor Directives (I)}
+   \begin{itemize}
+      \item<1->{Preprocessor directives are special lines in the code which allows to compile alternative parts of the code depending on so-called \textbf{define-string} switches.\\ Code example:\\
+      \begin{minipage}{0.2\textwidth}
+         \quad \\\\
+      \end{minipage}
+      \begin{minipage}{0.7\textwidth}
+         \centering
+         \begin{lstlisting}
+#if defined( __abc )
+CALL FLUSH( 9 )
+#else
+CALL FLUSH_( 9 )
+#endif
+         \end{lstlisting}
+      \end{minipage}\\
+      If now the compiler is called e.g.\\
+      \begin{minipage}{0.2\textwidth}
+         \quad \\\\
+      \end{minipage}
+      \begin{minipage}{0.7\textwidth}
+         \centering
+         \begin{lstlisting}
+ifort -cpp -D __abc ... (other options)
+         \end{lstlisting}
+      \end{minipage}\\
+      then the line containing ``\texttt{\tiny CALL FLUSH( 9 )}'' is compiled. \\If the compiler call is\\
+      \begin{minipage}{0.2\textwidth}
+         \quad \\\\
+      \end{minipage}
+      \begin{minipage}{0.7\textwidth}
+         \centering
+         \begin{lstlisting}
+ifort -cpp ... (other options)
+         \end{lstlisting}
+      \end{minipage}\\
+      the line containing ``\texttt{\tiny CALL FLUSH\_( 9 )}'' is compiled.
+      }
+   \end{itemize}
+\end{frame}
+
+
+%Folie 14
+\begin{frame}[fragile]
+   \frametitle{Preprocessor Directives (I)}
+   \begin{itemize}
+      \item<1->{The preprocessor directives require to include the compiler option ``\texttt{\scriptsize-cpp}'' in any way. Otherwise, the compilation will give error messages. \textbf{The option has to be given in the configuration file} \texttt{\scriptsize .mrun.config.} \textbf{Different compilers may require different options!}}\\
+
+      \item<2->{Define-string switches can be combined using logical AND / OR operators \&\& / $\lvert \lvert$.\\
+      \begin{minipage}{0.2\textwidth}
+         \quad \\\\
+      \end{minipage}
+      \begin{minipage}{0.7\textwidth}
+         \centering
+         \begin{lstlisting}
+#if defined ( __abc  &&  __def )
+         \end{lstlisting}
+      \end{minipage}
+      }
+   \end{itemize}
+\end{frame}
+
+
+%Folie 15
+\begin{frame}[fragile]
+   \frametitle{Preprocessor Directives (II)}
+   In the PALM code, define-string switches are used for following reasons:
+   \begin{itemize}
+      \item<2->{To switch between system dependent subroutines for:\\
+      \begin{itemize}
+         \item<2->{\texttt{\scriptsize \_\_ibm}} \quad IBM-Regatta systems\\
+         \item<2->{\texttt{\scriptsize \_\_lc}}\;\: \quad Linux clusters (using Intel compiler ifort)\\
+         \item<2->{\texttt{\scriptsize \_\_nec}} \quad NEC-SX systems\\
+      \end{itemize}
+      Switches are set automatically depending on mrun-option ``\texttt{\scriptsize-h}'', eg. ``\texttt{\scriptsize-h lcmine}'' sets ``\texttt{\scriptsize-D \_\_lc}''}
+      \item<3->{To switch between the serial and the parallel code:\\
+      \begin{itemize}
+         \item<3->{\texttt{\scriptsize \_\_parallel}}
+      \end{itemize}
+      This switch is set by mrun-option ``\texttt{\scriptsize-K parallel}''.}
+   \end{itemize}
+\end{frame}
+
+
+%Folie 15
+\begin{frame}[fragile]
+   \frametitle{Preprocessor Directives (II)}
+   In the PALM code, define-string switches are used for following reasons:
+   \begin{itemize}
+      \item<1->{To enable usage of special software packages which are not included in the compilation process by default\\
+      \begin{itemize}
+         \item<1->{\texttt{\scriptsize \_\_dvrp\_graphics}} \quad 3D visualization system\\
+         \item<1->{\texttt{\scriptsize \_\_spectra}} \quad \quad \quad \quad calculation and output of power spectra\\
+      \end{itemize}
+      Switches are activated with mrun-option ``\texttt{\scriptsize-p}'', \mbox{eg. ``\texttt{\scriptsize-p} ``\texttt{\scriptsize spectra dvrp\_graphics}''''}}
+   \end{itemize}
+    {\small \quad\\ \quad\\ \quad}\\ \quad  \\ \quad %nicht fragen, was das soll!! Mir ist leider nichts bsseres eingefallen um den Satz unter der Ãberschrift deckungsgleich auf beiden Folien zu haben.
+\end{frame}
+
+
+%Folie 14
+\begin{frame}[fragile]
+   \frametitle{Preprocessor Directives (III)}
+   \begin{itemize}
+      \item<1->{Preprocessor directives are also used for string replacement in the code.\\ Example:\\A compiler call with preprocessor option\\
+      \begin{minipage}{0.2\textwidth}
+         \quad \\\\
+      \end{minipage}
+      \begin{minipage}{0.7\textwidth}
+         \centering
+         \begin{lstlisting}
+ifort -cpp -Dabcd=efgh
+         \end{lstlisting}
+      \end{minipage}
+      will replace all strings ``\texttt{\scriptsize abcd}'' in the code with ``\texttt{\scriptsize efgh}'' \textbf{before} the code is compiled.\\
+      This is used in PALM to change the MPI\_REAL datatypes (which are 4 Byte long by default), to 8 Bytes. The respective cpp-directives are given in the configuration file \texttt{\scriptsize .mrun.config.}:\\
+      \begin{minipage}{0.2\textwidth}
+         \quad \\\\
+      \end{minipage}
+      \begin{minipage}{0.7\textwidth}
+         \centering
+         \begin{lstlisting}
+%cpp_options -DMPI_REAL=MPI_DOUBLE_PRECISION:
+             -DMPI_2REAL=MPI_2DOUBLE_PRECISION: ....
+         \end{lstlisting}
+      \end{minipage}
+      }
+   \end{itemize}
+\end{frame}
+
+\end{document}
Index: /palm/trunk/TUTORIAL/SOURCE/restarts_with_mrun.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/restarts_with_mrun.tex	(revision 945)
+++ /palm/trunk/TUTORIAL/SOURCE/restarts_with_mrun.tex	(revision 945)
@@ -0,0 +1,270 @@
+% $Id$
+\input{header_tmp.tex}
+%\input{../header_lectures.tex}
+
+\usepackage[utf8]{inputenc}
+\usepackage{ngerman}
+\usepackage{pgf}
+\usetheme{Dresden}
+\usepackage{subfigure}
+\usepackage{units}
+\usepackage{multimedia}
+\usepackage{hyperref}
+\newcommand{\event}[1]{\newcommand{\eventname}{#1}}
+\usepackage{xmpmulti}
+\usepackage{tikz}
+\usetikzlibrary{shapes,arrows,positioning}
+\usetikzlibrary{decorations.markings}
+\usetikzlibrary{decorations.pathreplacing}
+\def\Tiny{\fontsize{4pt}{4pt}\selectfont}
+\usepackage{amsmath}
+\usepackage{amssymb}
+\usepackage{multicol}
+\usepackage{pdfcomment}
+\usepackage{graphicx}
+\usepackage{listings}
+\lstset{showspaces=false,language=fortran,basicstyle=
+        \ttfamily,showstringspaces=false,captionpos=b}
+
+\institute{Institut fÃŒr Meteorologie und Klimatologie, Leibniz UniversitÃ€t Hannover}
+\date{last update: \today}
+\event{PALM Seminar}
+\setbeamertemplate{navigation symbols}{}
+
+\setbeamertemplate{footline}
+  {
+    \begin{beamercolorbox}[rightskip=-0.1cm]&
+     {\includegraphics[height=0.65cm]{imuk_logo.pdf}\hfill \includegraphics[height=0.65cm]{luh_logo.pdf}}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[ht=2.5ex,dp=1.125ex,
+      leftskip=.3cm,rightskip=0.3cm plus1fil]{title in head/foot}
+      {\leavevmode{\usebeamerfont{author in head/foot}\insertshortauthor} \hfill \eventname \hfill \insertframenumber \; / \inserttotalframenumber}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[colsep=1.5pt]{lower separation line foot}
+    \end{beamercolorbox}
+  }
+%\logo{\includegraphics[width=0.3\textwidth]{luhimuk_logo.pdf}}
+
+\title[Carrying out restart runs with mrun]{Carrying out restart runs with \texttt{mrun}}
+\author{Siegfried Raasch}
+
+\begin{document}
+
+% Folie 1
+\begin{frame}
+   \titlepage
+\end{frame}
+
+\section{Carrying out restart runs with mrun}
+\subsection{Carrying out restart runs with mrun}
+
+         
+
+% Folie 2
+\begin{frame}
+   \frametitle{Definition of ârestart runâ}
+  
+   \begin{itemize}
+      \item<1-> A \textbf{ârestart runâ} is a model run, which starts with an initial condition given by the simulated flow at the end of a previous (restart or initial) run.
+      \item<2-> In order to carry out a restart run, a file has to be written at the end of the previous run, which contains the values of all flow variables at the necessary time steps (Runge-Kutta: $t$, leap-frog: $t$, $t-\Delta t$). This file has to be read at the beginning of the restart run.
+      \item<3-> Initial and respective restart runs form a so called \textbf{job chain}.
+   \end{itemize}  
+
+\end{frame}
+
+
+% Folie 3
+\begin{frame}
+   \frametitle{Reasons for Restart Runs}
+  
+   \begin{itemize}
+      \item<1-> The maximum job time is generally limited by the queuing system:
+      \begin{itemize}
+         \item<1-> simulations must be split into several parts
+      \end{itemize}  
+      \item<2-> The user wants to carry out several runs on the basis of the same initial temporal development:
+      \begin{itemize}
+         \item<1-> the initial phase needs to be simulated only once,
+all runs start from the end point of this initial phase by reading the flow field data written at the end of the initial run
+      \end{itemize}
+   \end{itemize}  
+
+\end{frame}
+
+
+% Folie 4 (Zu voll)?
+\begin{frame}
+   \frametitle{Carrying Out Restart Runs With \texttt{mrun}}
+   \scriptsize
+
+   Concerning \texttt{mrun}, the first thing required to enable restart runs is to use the additional activating string \grqq \texttt{restart}\grqq\, in the \texttt{mrun}-call for the \underline{initial run}:\\
+   \quad \texttt{mrun -d test ... -r ''d3\# restart''}\\
+   This will have the following effects:
+   \vspace{2mm}
+   \begin{itemize}
+      \item<2-> At the end of the run, all necessary variables will bei written as binary data to the local file \texttt{BINOUT}. This is caused by an entry in the configuration file\\
+      \quad \texttt{\%write\underline{ }binary true restart}\\
+      which sets the environment variable \texttt{write\underline{ }binary}, which is in turn read by PALM from the local file \texttt{ENVPAR} created by \texttt{mrun}.
+      \item<3-> This binary file will be permanently stored in case that an appropriate file connection statement exists\\
+      \begin{columns}
+         \column{1.05\textwidth}
+         \texttt{BINOUT  out:loc:flpe restart \~{}/palm/current\underline{ }version/JOBS/\$fname/RESTART  \underline{ }d3d}
+      \end{columns}
+      \item<4-> If, during the run, PALM detects that the simulation cannot be finished due to limited job time, it tells \texttt{mrun} (by creating a local file named \texttt{CONTINUE\underline{ }RUN}) that a restart job has to be started. \texttt{mrun} will then automatically start such a job by submitting the command\\
+      \quad \texttt{mrun -d test ... -r ''d3f restart''}\\
+      on the \textbf{local host}. Options of this command are nearly the same as of the initial run, but every sharp symbol (\grqq\#\grqq) in the activating strings is replaced by an \grqq f\grqq.
+   \end{itemize}
+   \onslide<5->\textcolor{red}{\textbf{This effects the activation of file connections for the restart job!}}
+\end{frame}
+
+
+% Folie 5
+\begin{frame}
+   \frametitle{Input Files Necessary For Restart Jobs}
+   \scriptsize
+   \vspace{3mm}
+   File connection statements for input files from the default \texttt{.mrun.config} file:\\
+   \quad \texttt{PARIN \hspace{0.5em} in:job \hspace{3em} d3\# \hspace{0.5em} \$base\underline{ }data/\$fname/INPUT \hspace{1.5em} \underline{ }p3d}\\
+   \quad \texttt{PARIN \hspace{0.5em} in:job \hspace{3em} d3f \hspace{0.5em} \$base\underline{ }data/\$fname/INPUT \hspace{1.5em} \underline{ }p3df}\\
+   \quad \texttt{BININ \hspace{0.5em} in:loc:flpe \hspace{0.5em} d3f \hspace{0.5em} \$base\underline{ }data/\$fname/RESTART \hspace{0.5em} \underline{ }d3d}\\
+   \vspace{4mm}
+   \begin{itemize}
+      \item<2-> For the restart job, the model receives a different parameter file than for the initial job (e.g. \texttt{example\underline{ }cbl\underline{ }p3d\textcolor{blue}{f}} instead of \texttt{example\underline{ }cbl\underline{ }p3d}).\\
+   \vspace{2mm}
+   The parameter file for the restart job is nearly the same as for the initial run, but it must contain the parameter setting\\
+   \quad \texttt{initializing\underline{ }actions = 'read\underline{ }restart\underline{ }data'}\\
+   in the \texttt{\&inipar}-NAMELIST-group. All other \texttt{\&inipar}-parameter-settings are ignored!\\
+   \vspace{2mm}
+   \texttt{\&d3par}-parameter values can freely be changed compared with the parameter file for the initial run.\\
+   \vspace{4mm}
+   \item<3-> Input binary data file (\texttt{BININ}) is necessary (and available) only for restart jobs
+   \end{itemize}
+\end{frame}
+
+
+% Folie 6
+\begin{frame}
+   \frametitle{Output File Handling in Restart Jobs }
+   \scriptsize
+   \vspace{2mm}  
+   Example for output file connection statements from the default \texttt{.mrun.config} file:\\
+   \vspace{2mm}
+   \quad \texttt{RUN\underline{ }CONTROL \hspace{0.5em} out:loc:tr \hspace{1em} d3\# \hspace{0.5em} \$base\underline{ }data/\$fname/MONITORING \hspace{0.5em} \underline{ }rc}\\
+   \quad \texttt{RUN\underline{ }CONTROL \hspace{0.5em} out:loc:tra \hspace{0.5em} d3f \hspace{0.5em} \$base\underline{ }data/\$fname/MONITORING \hspace{0.5em} \underline{ }rc}\\
+   \vspace{2mm}
+   In case of restart jobs, the contents of many local output files are appended to the respective permanent files from the initial or previous run by using the \texttt{tra} file attribute.\\
+   \vspace{6mm}
+   \onslide<2-> File connection statement example for appending netCDF files when PALM is running on a remote host:\\
+   \quad \texttt{DATA\underline{ }1D\underline{ }PR\underline{ }NETCDF\hspace{1em}in:loc\hspace{2.5em}prf\hspace{3em}\$base\underline{ }data/\$fname/OUTPUT\hspace{0.5em}\underline{ }pr\hspace{0.5em}nc}\\
+   \quad \texttt{DATA\underline{ }1D\underline{ }PR\underline{ }NETCDF\hspace{1em}out:loc\hspace{2em}pr\#:prf\hspace{1em}\$base\underline{ }data/\$fname/OUTPUT\hspace{0.5em}\underline{ }pr\hspace{0.5em}nc}\\
+   \quad \texttt{DATA\underline{ }1D\underline{ }PR\underline{ }NETCDF\hspace{1em}out:loc:tr\hspace{0.5em}pr\#:prf\hspace{1em}\$base\underline{ }data/\$fname/OUTPUT\hspace{0.5em}\underline{ }pr\hspace{0.5em}nc}\\
+   \vspace{2mm}
+   The netCDF file from the respective previous run has to be provided as an INPUT file.\\
+   \vspace{2mm}
+   Therefore, if running PALM on a remote host, a copy of this data file must be additionally stored on the remote host (second statement). On the local host, each run creates a new file (cycle) which contains the complete data from the current run and all previous runs.
+   
+\end{frame}
+
+
+% Folie 7 (Zu voll?)
+\begin{frame}
+   \frametitle{Handling of Large Binary Data Files}
+   \scriptsize
+   \begin{columns}
+      \column{1.1\textwidth}
+      \begin{itemize}
+         \item<1-> Typically, the binary restart files are very large, so that they cannot be stored in the user's home-directory because of limited file quotas. Also, hard disks where \texttt{/home} is stored are typically very slow, so that the copy process needs very long time.
+         \item<2-> Using the file attribute \texttt{fl} (abbreviation for german \grqq Fortsetzungslauf\grqq) in the output file connection statement causes \texttt{mrun} to copy the local file to a special directory, which can be defined in the configuration file by the environment variable \texttt{tmp\underline{ }data\underline{ }catalog}. The permanent file described in the connection statement is also created, but it is \textbf{empty}.
+         \item<3-> At the end of the job, the second last cycle of the respective file with attribute \texttt{fl} is automatically deleted by \texttt{mrun} from the \texttt{tmp\underline{ }data\underline{ }catalog} in order to spare disc space. This can be prevented by setting the \texttt{mrun}-option \grqq\texttt{-k}\grqq (keep data from previous run).
+      \end{itemize}
+   \end{columns}
+   \ \\
+      \onslide<4-> \textbf{Example:}\\
+      \tiny \quad \texttt{\%base\underline{ }data\hspace{4.5em}\~{}/palm/current\underline{ }version/JOBS}\\
+      \tiny \quad \texttt{\%tmp\underline{ }data\underline{ }catalog\hspace{1.0em}/gfs2/work/niksiraa/palm\underline{ }restart\underline{ }data}\\
+      \vspace{1mm}
+      \tiny \quad \texttt{BINOUT\hspace{1.0em}out:loc:flpe\hspace{1.0em}restart\hspace{1.0em}\$base\underline{ }data/\$fname/RESTART\hspace{1.0em}\underline{ }d3d}\\
+      \ \\
+      \onslide<5-> \scriptsize \textbf{Files (directories) created when using \texttt{-d example\underline{ }cbl}:}  \\
+      \tiny \quad \texttt{/gfs2/work/niksiraa/palm\underline{ }restart\underline{ }data/example\underline{ }cbl\underline{ }d3d}\\
+      \tiny \quad \texttt{\~{}/palm/current\underline{ }version/JOBS/example/RESTART/example\underline{ }cbl\underline{ }d3d \# empty file (directory)}\\
+   \vspace{1mm}
+   \onslide<6-> \scriptsize \textcolor{red}{Concerning input files, \texttt{mrun} always determines the current cycle number to be \underline{used from the contents of the directory defined by the file connection statement!}}
+
+\end{frame}
+
+
+% Folie 8
+\begin{frame}
+   \frametitle{Checking the Restart Job Execution}
+   \scriptsize
+   \begin{itemize}
+      \item essentially by looking at the messages in the job protocol file:
+   \end{itemize} 
+   
+   \centering
+   \includegraphics[width=0.93\textwidth]{restarts_with_mrun_figures/checking.png}
+   \begin{tikzpicture}[remember picture, overlay]
+      \node[rectangle, draw,text width=0.29\textwidth, fill=white] at (-18mm,62mm) {\noindent \scriptsize In this example, restart time has been set 
+      
+      manually by the user.};
+   \end{tikzpicture}
+
+\end{frame}
+
+
+% Folie 9
+\begin{frame}
+   \frametitle{Setting the Restart Time Manually}
+   \scriptsize
+   \begin{columns}
+      \column{1.07\textwidth}
+      \begin{itemize}
+         \item<1-> By default, PALM checks after every timestep, if enough time remains from the job cpu limit to carry out the next timestep:\\
+         \quad \grqq\texttt{total job time}\grqq\, - \grqq\texttt{time already consumed}\grqq\, $\leftarrow$ \texttt{termination\underline{ }time\underline{ }needed}\\
+(as given by \texttt{mrun}-option \texttt{-t} ...) \hspace{5mm}  (as given by parameter in \texttt{\&d3par}-NAMELIST)
+         \item<2-> \texttt{termination\underline{ }time\underline{ }needed} has to include the cpu time needed before running PALM (e.g. for compilation, copying of input data, etc.; default value: 300 s)!\\
+         \ \\
+         \onslide<3-> \textbf{Warning:}\\
+         \quad \quad \grqq\texttt{total job time}\grqq\, $\leftarrow$ \texttt{termination\underline{ }time\underline{ }needed},\\
+         \quad forces a restart after the first timestep!
+         \item<4-> \texttt{\&d3par}-parameters \texttt{restart\underline{ }time} and \texttt{dt\underline{ }restart} can be used to set restart time(s) manually.
+         \item<5-> In case of manually setting the restart time, the default checking (see above) is still active and a restart will be automatically forced if the job reaches its cpu limit, even if the manually set restart time has not been reached!
+      \end{itemize} 
+   \end{columns}
+\end{frame}
+
+
+% Folie 10
+\begin{frame}
+   \frametitle{Starting Restart Jobs Manually}
+   \scriptsize
+      \begin{itemize}
+         \item<1-> After a job has finished (\texttt{end\underline{ }time} has been reached), the user can submit a restart job manually (provided that restart data have been saved) by entering:\\
+         \vspace{2mm}
+         \quad \texttt{mrun ... -r ''d3f ...'' ...}\\
+         or\\
+	      \quad \texttt{mrun ... -r ''d3f restart ...'' ...}\\
+	      \ \\
+         \item<2-> Remember to increase the value of \texttt{end\underline{ }time} in the parameter file before submitting the job.
+         \item<3-> If a manually started restart job shall continue a run of a former job chain which is somewhere in the middle of this chain, all binary files with respective higher cycle numbers have to be deleted or removed from their respective directories.
+   \end{itemize} 
+\end{frame}
+
+
+% Folie 11
+\begin{frame}
+   \frametitle{Exercise}
+   
+   \begin{itemize}
+      \item<2-> Set the job time ($-t$ ...) of a run (e.g. the example-run) in a way that at least one restart job is necessary to reach the end time of the simulation.
+      \item<3-> Alternatively, create a job chain containing at least one restart run by setting the \texttt{d3par}-parameters \texttt{restart\underline{ }time} and \texttt{dt\underline{ }restart} manually.
+      \item<4-> Compare, if the results from the job chain are the same as if the simulated is carried out in one single job. (They should be!)
+      \item<5-> Carry out this job and watch what happens.
+      \item<6-> Delete the results of the restart job(s) and carry out the restart from the initial run manually.
+   \end{itemize} 
+   
+\end{frame}
+
+
+\end{document}
Index: /palm/trunk/TUTORIAL/SOURCE/runs_with_mrun.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/runs_with_mrun.tex	(revision 945)
+++ /palm/trunk/TUTORIAL/SOURCE/runs_with_mrun.tex	(revision 945)
@@ -0,0 +1,692 @@
+% $Id$
+\input{header_tmp.tex}
+%\input{../header_lectures.tex}
+
+\usepackage[utf8]{inputenc}
+\usepackage{ngerman}
+\usepackage{pgf}
+\usetheme{Dresden}
+\usepackage{subfigure}
+\usepackage{units}
+\usepackage{multimedia}
+\usepackage{hyperref}
+\newcommand{\event}[1]{\newcommand{\eventname}{#1}}
+\usepackage{xmpmulti}
+\usepackage{tikz}
+\usetikzlibrary{shapes,arrows,positioning}
+\def\Tiny{\fontsize{4pt}{4pt}\selectfont}
+\usepackage{amsmath}
+\usepackage{amssymb}
+\usepackage{multicol}
+\usepackage{pdfcomment}
+\usepackage{graphicx}
+\usepackage{listings}
+\lstset{showspaces=false,language=fortran,basicstyle=
+        \ttfamily,showstringspaces=false,captionpos=b}
+
+\institute{Institut fÃŒr Meteorologie und Klimatologie, Leibniz UniversitÃ€t Hannover}
+\date{last update: \today}
+\event{PALM Seminar}
+\setbeamertemplate{navigation symbols}{}
+
+\setbeamertemplate{footline}
+  {
+    \begin{beamercolorbox}[rightskip=-0.1cm]&
+     {\includegraphics[height=0.65cm]{imuk_logo.pdf}\hfill \includegraphics[height=0.65cm]{luh_logo.pdf}}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[ht=2.5ex,dp=1.125ex,
+      leftskip=.3cm,rightskip=0.3cm plus1fil]{title in head/foot}
+      {\leavevmode{\usebeamerfont{author in head/foot}\insertshortauthor} \hfill \eventname \hfill \insertframenumber \; / \inserttotalframenumber}
+    \end{beamercolorbox}
+    \begin{beamercolorbox}[colsep=1.5pt]{lower separation line foot}
+    \end{beamercolorbox}
+  }
+%\logo{\includegraphics[width=0.3\textwidth]{luhimuk_logo.pdf}}
+
+\title[Carrying out runs using mrun]{Carrying out runs using \texttt{mrun}}
+\author{Siegfried Raasch}
+
+\begin{document}
+
+% Folie 1
+\begin{frame}
+\titlepage
+\end{frame}
+
+\section{Carrying out runs using mrun}
+\subsection{Carrying out runs using mrun}
+
+% Folie 2
+\begin{frame}
+   \frametitle{What is \texttt{mrun}?}
+   \begin{itemize}
+      \item<1-> \texttt{mrun} (\textbf{m}odel \textbf{run}) is a shell script (using 
+      \texttt{ksh}-syntax) which can be used to compile and run programs, including 
+      the handling of input/output files.
+      \item<2-> The \texttt{mrun}-command has a number of options to control the 
+      program execution\\
+         \quad \footnotesize \texttt{mrun -d example\_cbl -h lcsgih -K parallel -X8 -T2 ...}\\
+         \normalsize All options including a short description can be displayed by entering\\
+         \quad \footnotesize \texttt{mrun ?}
+      \item<3-> \normalsize The shellscript execution is also controlled by a configuration file with default name \texttt{.mrun.config} 
+   \end{itemize}
+\end{frame}
+
+% Folie 3
+\begin{frame}
+   \tikzstyle{green} = [rectangle, draw, fill=green!20, text width=0.1\textwidth, font=\scriptsize]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.22\textwidth, 
+   font=\scriptsize]
+   \tikzstyle{info} = [rectangle, text width=0.15\textwidth, font=\scriptsize]
+   \tikzstyle{white} = [rectangle, text width=0.7\textwidth, font=\scriptsize]
+   \tikzstyle{dummy} = [rectangle, text width=0.3\textwidth, font=\scriptsize]
+   \tikzstyle{line} = [draw, -]
+   \tikzstyle{alert} = [rectangle, draw, text width=0.77\textwidth, font=\scriptsize]
+ 
+   \scriptsize
+   \frametitle{Carrying Out Runs Using \texttt{mrun}}
+   Carrying out a program run typically needs two steps:\\
+   1. compilation\\
+   \quad \texttt{f90  ...  file1.f90 file2.f90 ...}\\
+   \onslide<2-> 2. execution\\
+   \quad \texttt{a.out}\\
+   \vspace{1mm}
+   \onslide<3->Besides, a program needs input data and creates output data:\\
+   
+   \onslide<4->\begin{tikzpicture}[auto, node distance=0]
+      \node [green] (first) {\textbf{a.out/} };
+      \node [dummy, right=0.1cm of first] (second) {};
+      
+      \node [yellow, above=0.5cm of second] (third) {\textbf{parameter for steering}};
+      \node [yellow, below=0.5cm of third] (fourth) {\textbf{control output}};
+      \node [yellow, below=0.3cm of fourth] (fifth) {\textbf{output for analysis}};
+      
+      \node [info, above=-0.1cm of third] (sixth) {input file};
+      \node [info, above=-0.1cm of fourth] (seventh) {output file 1};
+      \node [info, above=-0.1cm of fifth] (eight) {output file 2};
+
+      \draw [->] (third.west) -- (first.north);
+      \draw [->] (first.east) -- (fourth.west);
+      \draw [->] (first.south) -- (fifth.west);
+      
+      \uncover<5->{\node [white, right=0.25cm of third] (ninth) {
+         \texttt{OPEN (11, FILE='PARIN', FORM='FORMATTED')}};}
+      \uncover<5->{\node [white, right=0.25cm of fourth] (tenth) {
+         \texttt{OPEN (15, FILE='RUN\_CONTROL', FORM='FORMATTED')}};}
+      \uncover<5->{\node [white, right=0.25cm of fifth] (eleventh) {
+         \texttt{OPEN (40, FILE=âDATA\_1D\_PR\_NETCDF', FORM='FORMATTED')}};}
+   \end{tikzpicture}
+   
+   \vspace{1mm}
+   \scriptsize
+   \onslide<6->\textcolor{red}{Problems: The user has to copy or rename output files, if 
+   he/she wants to run the program more than once and if he concurrently wants to keep 
+   the files from the former run(s).
+   If he/she is using different input parameter files for steering, these files also have 
+   to be copied into the working directory before the program is executed.}\\
+   \ \\
+   \begin{tikzpicture}[auto, node distance=0] 
+      \uncover<7->{\node [alert] (alert) {\textcolor{red}{It is therefore very desirable 
+      to automate these tasks!}};}
+   \end{tikzpicture}
+\end{frame}
+
+% Folie 4
+\begin{frame}
+   \tikzstyle{green} = [rectangle, draw, fill=green!20, text width=0.45\textwidth, font=\scriptsize]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.18\textwidth, font=\scriptsize]
+   \tikzstyle{yellowsmall} = [rectangle, draw, fill=yellow!20, text width=0.10\textwidth, font=\scriptsize]
+   \tikzstyle{dummy} = [rectangle, text width=0.01\textwidth, font=\tiny]
+   
+   \frametitle{\texttt{mrun}: Principal Mode of Operation (I)}
+   \texttt{mrun} runs a program (in our case the PALM model) by carrying out the 
+   following principle tasks in a sequential order:\\
+   \scriptsize
+   \begin{enumerate}
+      \item<2-> Create a temporary working directory and change into this directory:\\
+      \quad \texttt{mkdir <tempdir>/<username>.<randomnumber>}\\
+      \quad \texttt{cd <tempdir>/<username>.<randomnumber>}\\
+      \ \\
+      The path of \texttt{<tempdir>} is given in the configuration file 
+      \texttt{.mrun.config} by the environment variable \texttt{tmp\_user\_catalog}, e.g.:\\
+	   \quad \texttt{\%tmp\_user\_catalog  /tmp \hspace{30mm} <hi>  parallel}\\
+	   \ \\
+	   \onslide<3-> On SGI-ICE: \\
+	   \quad \texttt{\%tmp\_user\_catalog  /gfs2/work/<username> 
+	   \hspace{5mm} <hi>  lcsgih parallel}
+	   \begin{center}
+	      \begin{tikzpicture}[auto, node distance=0] 
+            \uncover<4->{\node [green] (green) {/tmp/$<$username$>$.$<$randomnumber$>$};}
+         \end{tikzpicture}
+	   \end{center}
+	   \item<5-> Copy the input files from a directory of the user into this working directory:\\
+	   \scriptsize
+	   \onslide<6->\hspace{-15mm} \texttt{cp <user\_input\_file1> 
+	   /tmp/<username>.<randomnumber>/<temporary\_input\_file1>}\\
+      \hspace{-15mm} \texttt{cp <user\_input\_file2> 
+      /tmp/<username>.<randomnumber>/<temporary\_input\_file2>}
+      \begin{center}
+	      \begin{tikzpicture}[auto, node distance=0] 
+	      
+            \uncover<8->{\node [green] (green) {/tmp/$<$username$>$.$<$randomnumber$>$};}
+       
+            \uncover<7->{\node [yellowsmall, above=0.1cm of green] (yellow2) {JOBS/};}
+            \uncover<7->{\node [yellow, left=0.2cm of yellow2] (yellow1) {current\_version/};}
+            \uncover<7->{\node [yellow, right=0.2cm of yellow2] (yellow3) {example\_cbl/};}
+            \uncover<7->{\node [yellowsmall, right=0.2cm of yellow3] (yellow4) {INPUT/};}
+            
+            \draw<7-> [-] (yellow1.east) -- (yellow2.west);
+            \draw<7-> [-] (yellow2.east) -- (yellow3.west);
+            \draw<7-> [-] (yellow3.east) -- (yellow4.west);
+            
+            \node [dummy, right=0.1cm of yellow4] (dummy1) {};
+            \node [dummy, right=2.055cm of green] (dummy2) {};
+            
+            \draw<9-> [-] (yellow4.east) -- (dummy1.center);
+            \draw<9-> [-] (dummy1.center) -- (dummy2.center);
+            \draw<9-> [->] (dummy2.center) -- (green.east);
+            
+         \end{tikzpicture}
+	   \end{center}
+      
+	\end{enumerate}
+
+\end{frame}
+
+% Folie 5
+\begin{frame}
+   \tikzstyle{green} = [rectangle, draw, fill=green!20, text width=0.45\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.18\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{dummy} = [rectangle, text width=0.01\textwidth, font=\scriptsize, minimum height=0.6cm]
+   
+   \frametitle{\texttt{mrun}: Principal Mode of Operation (II)}
+
+	\begin{enumerate}
+      \setcounter{enumi}{2}
+	   \item<1-> Copy the pre-compiled routines to the temporary working directory:\\
+      
+      \begin{center}
+	      \begin{tikzpicture}[auto, node distance=0] 
+	         \uncover<2->{\node [yellow] (yellow) {current\_version/};}
+	         \uncover<1->{\node [dummy, right=0.0cm of yellow] (dummy1) {};}
+	         \uncover<2->{\node [green, right=0.2cm of yellow] (green1) {MAKE\_DEPOSITORY\_\textit{parallel}/};}
+	         \uncover<1->{\node [dummy, right=0.2cm of green1] (dummy2) {};}
+            \uncover<3->{\node [green, below=0.5cm of dummy1] (green2) {/tmp/$<$username$>$.$<$randomnumber$>$};}
+             \uncover<1->{\node [dummy, below=0.5cm of dummy2] (dummy3) {};}
+             \uncover<4->{\node [dummy, right=0.0cm of dummy3] (text) {Makefile\\
+	         *.f90\\
+	         *.o\\
+	         ...\\ \ \\};}
+             
+             \draw<2-> [-] (yellow.east) -- (green1.west);
+             \draw<4-> [-] (green1.east) -- (dummy2.center);
+             \draw<4-> [-] (dummy2.center) -- (dummy3.center);
+             \draw<4-> [->] (dummy3.center) -- (green2.east);
+	      \end{tikzpicture}
+	   \end{center}
+	   
+	   \item<5-> Compile the main program and use pre-compiled object files:\\
+     \quad \texttt{f90 palm.f90 *.o ...   ( make Makefile)}
+      \item<6-> Execute the program:\\
+     \quad \texttt{a.out}
+   \end{enumerate}
+\end{frame}
+
+% Folie 6
+\begin{frame}
+   \tikzstyle{green} = [rectangle, draw, fill=green!20, text width=0.45\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.18\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{dummy} = [rectangle, text width=0.01\textwidth, font=\scriptsize, minimum height=0.6cm]
+   
+   \frametitle{\texttt{mrun}: Principal Mode of Operation (III)}
+
+	\begin{enumerate}
+      \setcounter{enumi}{5}
+	   \item<1-> Copy the output files from the working directory to a (permanent) directory of the user:\\
+       \scriptsize \hspace{-16mm} \texttt{cp /tmp/<username>.<randomnumber>/<temporary\_output\_file1> <user\_output\_file1>}\\
+      \hspace{-16mm} \texttt{cp /tmp/<username>.<randomnumber>/<temporary\_output\_file2> <user\_output\_file2>}\\
+      
+      \begin{center}
+	      \begin{tikzpicture}[auto, node distance=0] 
+            \uncover<2->{\node [yellow] (yellow1) {MONITORING/};}
+
+            \uncover<2->{\node [dummy, right=0.2cm of yellow1] (dummy2) {};}
+            \uncover<2->{\node [dummy, above=0.2cm of dummy2] (dummy1) {};}
+            \uncover<2->{\node [dummy, below=0.2cm of dummy2] (dummy3) {};}
+            
+            \uncover<2->{\node [yellow, left=0.2cm of dummy3] (yellow2) {OUTPUT/};}
+            \uncover<2->{\node [yellow, left=0.2cm of yellow2] (yellow3) {example\_cbl/};}
+            \uncover<2->{\node [yellow, left=0.2cm of yellow3] (yellow4) {JOBS/};}
+            \uncover<2->{\node [yellow, left=0.2cm of yellow4] (yellow5) {current\_version/};}
+                      	                     
+	         \uncover<2-3>{\node [green, left=5.0cm of dummy1] (green) {/tmp/$<$username$>$.$<$randomnumber$>$};}
+	         
+            \draw<2-3> [-] (green.east) -- (dummy1.center);
+            \draw<2-3> [-] (dummy2.center) -- (dummy1.center);
+            \draw<2-3> [-] (dummy3.center) -- (dummy1.center);
+            
+            \draw<2-3> [->] (dummy2.center) -- (yellow1.east);
+            \draw<2-3> [->] (dummy3.center) -- (yellow2.east);
+            
+            \draw<2-> [-] (yellow2.west) -- (yellow3.east);
+            \draw<2-> [-] (yellow3.west) -- (yellow4.east);
+            \draw<2-> [-] (yellow4.west) -- (yellow5.east);
+	        
+	      \end{tikzpicture}
+	   \end{center}
+	   
+	   \item<3-> Delete the temporary working directory\\
+      \quad \texttt{rm -rf /tmp/<username>.<randomnumber>}\\
+      \onslide<5->\textcolor{red}{Question: How does \texttt{mrun} know which files have to be copied and where from or where to they have to be copied?}
+
+   \end{enumerate}
+\end{frame}
+
+% Folie 7
+\begin{frame}
+   \tikzstyle{small} = [rectangle, text width=0.08\textwidth, font=\scriptsize]
+   \tikzstyle{large} = [rectangle, text width=0.45\textwidth, font=\scriptsize]
+   \tikzstyle{box} = [rectangle, draw, text width=0.2\textwidth, font=\scriptsize]
+   \tikzstyle{boxbig} = [rectangle, draw, text width=0.4\textwidth, font=\scriptsize]
+   \tikzstyle{dummy} = [rectangle, text width=0.0\textwidth, font=\scriptsize, minimum height=0.5cm]
+   
+   \frametitle{Steering File Copy by the Configuration File (I)}
+   \scriptsize
+   \textbf{Copying of files is controlled by so called \textit{file connection statements}. They connect local files in the temporary working directory with permanent files residing in the directory of the user.}\\
+   \vspace{1mm}
+   Principle example of a file connection statement (for the PALM parameter file):
+   \vspace{-3mm}
+   \begin{center}
+	   \begin{tikzpicture}[auto, node distance=0] 
+         \uncover<1->{\node [small] (part1) {\texttt{PARIN}};}
+         \uncover<1->{\node [dummy, left=-0.2cm of part1] (dummy1) {};}
+         \uncover<1->{\node [dummy, below=1.25cm of dummy1] (dummy3) {};}
+         \uncover<1->{\node [small, right=0.0cm of part1] (part2) {\quad \texttt{in}};}
+         \uncover<1->{\node [dummy, right=0.0cm of part2] (dummy2) {};}
+         \uncover<1->{\node [small, right=0.2cm of part2] (part3) {\texttt{d3\#}};}
+	      \uncover<1->{\node [large, right=0.0cm of part3] (part4) {\texttt{\~{}/palm/current\_version/JOB/INPUT}};}
+	      \uncover<1->{\node [small, right=0.0cm of part4] (part5) {\texttt{\_p3d}};}
+	      \uncover<1->{\node [small, right=0.2cm of part5] (part6) {\texttt{( \textcolor{red}{nc} )}};}
+	            
+         \uncover<2->{\node [boxbig, below=1.25cm of dummy2] (box1) {local filename in the working directory (must correspond to the filename in the \texttt{OPEN} statement of the program)};}
+	      \draw<2-> [->] (dummy3.north) -- (dummy1.south);
+	      
+	      \uncover<3->{\node [box, below=0.7cm of part2] (box2) {file attributes};}
+	      \draw<3-> [->] (box2.north) -- (part2.south);
+	      
+	      \uncover<4->{\node [box, below=0.2cm of part3] (box3) {activating string};}
+	      \draw<4-> [->] (box3.north) -- (part3.south);
+	      	      
+	      \uncover<5->{\node [box, below=0.2cm of part4] (box4) {directory in which the permanent user file resides};}
+	      \draw<5-> [->] (box4.north) -- (part4.south);
+	      
+         \uncover<6->{\node [box, below=0.2cm of part5] (box5) {suffix of the permanent filename};}
+	      \draw<6-> [->] (box5.north) -- (part5.south);
+	      
+         \uncover<7->{\node [box, below=1.0cm of part6] (box6) {additional suffix for netCDF files};}
+	      \draw<7-> [->] (box6.north) -- (part6.south);    
+	   \end{tikzpicture}
+	\end{center}
+   
+   \onslide<8->The full name of the permanent file results from the directory name, the suffix and the value of \texttt{mrun}-Option \texttt{-d}, which defines the so-called \textbf{base name} of all files handled by \texttt{mrun}:\\
+   \quad \texttt{mrun -d \textcolor{blue}{example\_cbl} ...}\\
+   gives the filename\\
+   \quad \texttt{\~{}/palm/current\_version/JOB/INPUT/\textcolor{blue}{example\_cbl}\_p3d}\\
+   \quad \texttt{( ... /\textcolor{blue}{example\_cbl}\_p3d\textcolor{red}{.nc} )}
+   
+\end{frame}
+
+% Folie 8
+\begin{frame}
+   \frametitle{Steering File Copy by the Configuration File (II)}
+   \scriptsize
+   \onslide<1-> The \textbf{base name} can additionally be a part of the directory name 
+   by using \texttt{\$fname} in the directory column of the file connection statement:\\
+   \quad \texttt{PARIN in d3\# \~{}/palm/current\_version/JOBS/\$fname/INPUT \_p3d}\\
+   \ \\
+   \onslide<2-> Using the call\\
+   \quad \texttt{mrun -d abcde ...}\\
+   the input file will be expected under\\
+   \quad \texttt{\~{}/palm/current\_version/JOBS/abcde/INPUT/abcde\_p3d }\\
+   \ \\
+   \onslide<3-> In this way, all files handled by the \texttt{mrun}-call are stored in 
+   the same subdirectory (abcde/) and will have the same string (\texttt{abcde}) as 
+   part of their names, so they can be easily identified as ''belonging'' to the model 
+   run initiated by that \texttt{mrun} call.\\
+   \ \\
+   \onslide<4-> Instead of always writing the full path name (i.e. 
+   \texttt{\~{}/palm/current\_version/JOBS}), an environment variable can be declared for 
+   this at the beginning of the configuration file and be used in the file 
+   connection statements:\\
+   \quad \texttt{\%base\_data  \~{}/palm/current\_version/JOBS}\\
+   \quad \texttt{PARIN in d3\#  \$base\_data/\$fname/INPUT \_p3d}\\
+   \ \\
+   \onslide<5-> This easily allows to change the directories for all input/output files 
+   by just changing the value of \texttt{base\_data}.
+   
+\end{frame}
+
+% Folie 9
+\begin{frame}
+   \frametitle{Steering File Copy by the Configuration File (III)}
+   \scriptsize
+   \onslide<1-> File connection statements which shall be carried out, 
+   have to be activated by giving their activation string in the 
+   \texttt{mrun}-option \texttt{-r}:\\
+   \quad \texttt{PARIN in d3\# \~{}/palm/current\_version/JOBS/\$fname/INPUT \_p3d}\\
+   \ \\
+   \onslide<2-> The permanent file 
+   \texttt{\~{}/palm/current\_version/JOBS/example\_cbl/INPUT/example\_cbl\_p3d} 
+   will only be copied to the local file PARIN by using the call:\\
+   \quad \texttt{mrun -d example\_cbl -r ''d3\#'' ...}\\
+   \ \\
+   \onslide<3-> \textbf{Example for an output file:}\\
+   The file connection statement\\
+   \quad \texttt{DATA\_1D\_PR\_NETCDF out:loc pr\# 
+   \~{}/palm/current\_version/JOBS/\$fname/OUTPUT \_pr nc}\\
+   \onslide<4-> will copy (after program execution) the local file 
+   \texttt{DATA\_1D\_PR\_NETCDF} to the permanent file 
+   \texttt{\~{}/palm/current\_version/JOBS/example\_cbl/OUTPUT/example\_cbl\_pr.nc} if
+   \texttt{mrun} is called with the options\\
+   \quad \texttt{mrun -d example\_cbl -r ''d3\# pr\#'' ...}
+   
+\end{frame}
+
+% Folie 10
+\begin{frame}
+   \frametitle{Steering File Copy by the Configuration File (IV)}
+   \scriptsize
+   \onslide<1-> \texttt{mrun} never replaces/overwrites existing files!\\
+   \ \\
+   Instead, new, so-called file cycles are created.\\
+   If an output file, e.g.\\
+   \quad \texttt{\~{}/palm/current\_version/JOBS/example\_cbl/MONITORING/example\_cbl\_rc}\\
+   \ \\
+   has been created from a first call of \texttt{mrun} and if the same \texttt{mrun} 
+   call is submitted again, the second call will not replace the file 
+   \texttt{example\_cbl\_rc}, but will create a new file with name:\\
+   \quad \texttt{\~{}/palm/current\_version/JOBS/example\_cbl/MONITORING/example\_cbl\_rc.1}\\
+   \ \\
+   \onslide<2->In case of netCDF-files, the file cycle number is inserted before 
+   the netCDF-suffix .nc, e.g.\\
+   \quad \texttt{example\_cbl\_pr.1.nc}\\
+   \ \\
+   \onslide<3->The implemented file cycle mechanism does not allow to use 
+   any other dots "'."'  in the path or filename:\\
+   \quad \texttt{\~{}/palm/version\_3.6/JOBS/example.sbl/MONITORING/example.sbl\_rc}
+\end{frame}
+
+% Folie 11
+\begin{frame}[fragile]
+   \frametitle{\normalsize File Connection Statements From the Default \texttt{.mrun.config} file}
+   \begin{columns}
+      \column{1.1\textwidth}
+      \tiny
+      \begin{lstlisting}
+#----------------------------------------------------------------------------
+# List of input-files
+#----------------------------------------------------------------------------
+PARIN                    in:job        d3#      $base_data/$fname/INPUT    _p3d
+PARIN                    in:job        d3f      $base_data/$fname/INPUT    _p3df
+TOPOGRAPHY_DATA          in:locopt     d3#:d3f  $base_data/$fname/INPUT    _topo
+BININ                    in:loc:flpe   d3f:rec  $base_data/$fname/RESTART  _d3d
+PARTICLE_RESTART_DATA_IN in:loc:flpe   prtf     $base_data/$fname/RESTART  _rprt
+DATA_1D_PR_NETCDF        in:locopt     prf      $base_data/$fname/OUTPUT   _pr     nc
+DATA_1D_SP_NETCDF        in:locopt     spf      $base_data/$fname/OUTPUT   _sp     nc
+DATA_1D_TS_NETCDF        in:locopt     tsf      $base_data/$fname/OUTPUT   _ts     nc
+DATA_1D_PTS_NETCDF       in:locopt     ptsf     $base_data/$fname/OUTPUT   _pts    nc
+DATA_2D_XY_NETCDF        in:locopt     xyf      $base_data/$fname/OUTPUT   _xy     nc
+DATA_2D_XY_AV_NETCDF     in:locopt     xyf      $base_data/$fname/OUTPUT   _xy_av  nc
+DATA_2D_XZ_NETCDF        in:locopt     xzf      $base_data/$fname/OUTPUT   _xz     nc
+DATA_2D_YZ_NETCDF        in:locopt     yzf      $base_data/$fname/OUTPUT   _yz     nc
+DATA_3D_NETCDF           in:locopt     3df      $base_data/$fname/OUTPUT   _3d     nc
+DATA_PRT_NETCDF          in:locopt:pe  prtf     $base_data/$fname/OUTPUT   _prt
+#
+#----------------------------------------------------------------------------
+# List of output-files
+#----------------------------------------------------------------------------
+BINOUT                    out:loc:flpe restart   $base_data/$fname/RESTART  _d3d
+PARTICLE_RESTART_DATA_OUT out:loc:flpe prt#:prtf $base_data/$fname/RESTART  _rprt
+#
+RUN_CONTROL       out:loc:tr   d3#     $base_data/$fname/MONITORING  _rc
+RUN_CONTROL       out:loc:tra  d3f     $base_data/$fname/MONITORING  _rc
+HEADER            out:loc:tr   d3#     $base_data/$fname/MONITORING  _header
+HEADER            out:loc:tra  d3f     $base_data/$fname/MONITORING  _header
+CPU_MEASURES      out:loc:tr   d3#     $base_data/$fname/MONITORING  _cpu
+CPU_MEASURES      out:loc:tra  d3f     $base_data/$fname/MONITORING  _cpu
+#
+DATA_1D_PR_NETCDF    out:loc:tr   pr#:prf   $base_data/$fname/OUTPUT  _pr     nc
+DATA_1D_SP_NETCDF    out:loc:tr   sp#:spf   $base_data/$fname/OUTPUT  _sp     nc
+DATA_1D_TS_NETCDF    out:loc:tr   ts#:tsf   $base_data/$fname/OUTPUT  _ts     nc
+DATA_1D_PTS_NETCDF   out:loc:tr   pts#:ptsf $base_data/$fname/OUTPUT  _pts    nc
+DATA_2D_XY_NETCDF    out:loc:tr   xy#:xyf   $base_data/$fname/OUTPUT  _xy     nc
+DATA_2D_XY_AV_NETCDF out:loc:tr   xy#:xyf   $base_data/$fname/OUTPUT  _xy_av  nc
+DATA_2D_XZ_NETCDF    out:loc:tr   xz#:xzf   $base_data/$fname/OUTPUT  _xz     nc
+DATA_2D_XZ_AV_NETCDF out:loc:tr   xz#:xzf   $base_data/$fname/OUTPUT  _xz_av  nc
+DATA_2D_YZ_NETCDF    out:loc:tr   yz#:yzf   $base_data/$fname/OUTPUT  _yz     nc
+DATA_2D_YZ_AV_NETCDF out:loc:tr   yz#:yzf   $base_data/$fname/OUTPUT  _yz_av  nc
+DATA_3D_NETCDF       out:loc:tr   3d#:3df   $base_data/$fname/OUTPUT  _3d     nc
+DATA_3D_AV_NETCDF    out:loc:tr   3d#:3df   $base_data/$fname/OUTPUT  _3d_av  nc
+DATA_PRT_NETCDF      out:loc:pe   prt#:prtf $base_data/$fname/OUTPUT  _prt    nc
+DATA_PRT_NETCDF      out:loc:trpe prt#:prtf $base_data/$fname/OUTPUT  _prt    nc
+DATA_DVR             out:loc:trpe dvr       $base_data/$fname/OUTPUT  _dvr
+#
+DVRP_LOG          out:loc:tr   dv#       $base_data/$fname/MONITORING  _dvrp_log
+DVRP_LOG          out:loc:tra  dvf       $base_data/$fname/MONITORING  _dvrp_log
+PARTICLE_INFO     out:loc:tr   pt#       $base_data/$fname/MONITORING  _prt_info
+PARTICLE_INFO     out:loc:tra  ptf       $base_data/$fname/MONITORING  _prt_info
+PARTICLE_DATA     out:loc:flpe prt#:prtf $base_data/$fname/OUTPUT      _prt_dat
+
+      \end{lstlisting}
+   \end{columns}
+\end{frame}
+
+% Folie 12
+\begin{frame}
+   \frametitle{Additional Features of \texttt{mrun}}
+   \begin{itemize}
+      \footnotesize
+      \item<1-> Generating batch jobs on local \textbf{and} remote host.
+      \item<2-> Setting of unix environment variables for job and model control (e.g. for determining compiler options, etc.).
+      \item<3-> Values have to be set in the \texttt{mrun} configuration file \texttt{.mrun.config}:
+   \end{itemize}
+   \onslide<4->\hspace{-1cm}\includegraphics[scale=0.3]{mrun_figures/add_feat1.png}
+   \begin{itemize}
+      \footnotesize
+      \item<5-> User-defined unix commands are carried out before or after execution of the model (input/output commands) or in case of errors during the compile- or run-step (error commands).
+      These commands can also be defined in the \texttt{mrun} configuration file:
+      \onslide<6-> \includegraphics[scale=0.3]{mrun_figures/add_feat2.png}
+      \item<7-> Automatic generation of restart jobs.
+   \end{itemize}
+\end{frame}
+
+% Folie 13
+\begin{frame}
+   \frametitle{PALM \textit{Interactive} Example Run Using \texttt{mrun}: Tracing the Run by the User}
+   \tikzstyle{green} = [rectangle, draw, fill=green!20, text width=0.45\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.42\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{yellow_big} = [rectangle, draw, fill=yellow!20, text width=0.45\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{notes} = [rectangle, text width=0.46\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{dummy} = [rectangle, text width=0.01\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \vspace{-1.0cm}
+   \begin{center}
+	   \begin{tikzpicture}[auto, node distance=0] 
+         \uncover<1->{\node [yellow] (box1) {start run on local machine:\\
+                                            \texttt{mrun -d example\_cbl -h lcmuk ...}};}
+         \uncover<1->{\node [dummy, right=0.2cm of box1] (dummy1) {};}
+         \uncover<2->{\node [notes, above=0.2cm of dummy1] (notes1) {temporary working directory is created,\\all required files are copied there};}
+         \uncover<3->{\node [green, right=0.2cm of dummy1] (box2) {follow runs messages on terminal};}
+         \uncover<4->{\node [green, below=0.2cm of box2] (box3) {
+         as soon as message
+         
+         \texttt{*** execution starts in directory\\ \quad ''<tempdir>''}
+
+         you can change to this directory (in a new terminal) and watch the progess of timesteps
+
+         \texttt{cd <tempdir>}\\
+         \texttt{tail -f RUN\_CONTROL}
+
+         However, this might be difficult in case of short run times, because the run may have finished before you have entered the commands!
+         };}
+         \uncover<1->{\node [dummy, left=0.2cm of box3] (dummy2) {};}
+         \uncover<5->{\node [notes, below=1.7cm of dummy2] (notes2) {results are copied from temporary \\ working directory to the userâs permanent directory};}
+         \uncover<6->{\node [yellow_big, left=0.2cm of dummy2] (box4) {
+         check, if the output files have sucessfully been transferred to the permanent directory:\\
+         \texttt{cd \~{}/palm/current\_version/JOBS/\\ \quad example\_cbl/MONITORING}\\
+         \texttt{ls -al}\\
+         \texttt{cd \~{}/palm/current\_version/JOBS/\\ \quad example\_cbl/OUTPUT}\\
+         \texttt{ls -al}
+};}
+         \draw<2-> [->] (box1.east) -- (box2.west);    
+         \draw<4-> [->] (box2.south) -- (box3.north);   
+         \draw<5-> [->] (box3.west) -- (box4.east);   
+	   \end{tikzpicture}
+	\end{center}
+\end{frame}
+
+% Folie 14
+\begin{frame}
+   \frametitle{PALM \textit{Batch} Example Run (on HLRN, remote) Using \texttt{mrun}: Tracing the Run by the User}
+\tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.3\textwidth, font=\Tiny]
+\tikzstyle{green} = [rectangle, draw, fill=green!20, text width=0.4\textwidth, font=\Tiny]
+\tikzstyle{dummy} = [text width=0.2\textwidth, font=\Tiny]
+\tikzstyle{alert} = [rectangle, draw, text width=0.5\textwidth, font=\scriptsize]
+\tikzstyle{line} = [draw, -latex']
+\begin{itemize}
+   \item Reminder: Running batch jobs requires a directory \texttt{~/job\_queue} for the job protocol files on the local \underline{and} remote host.
+\end{itemize}
+\begin{tikzpicture}[auto, node distance=0]
+    \node [yellow] (first) {
+       \textbf{start job on local machine:}\\
+       \texttt{mrun -d example\_cbl -h lcsgih ...}
+    };
+\uncover<2->{
+    \node [dummy, right=0.5cm of first] (dummy) {
+       transfer of job by \texttt{scp} \\
+       \ \\
+       \ \\
+       submit of job by executing the \texttt{msub} command via \texttt{ssh}
+    };
+}
+\uncover<3->{
+    \node [green, right=3.5cm of first] (second) {
+       \textbf{follow job execution on remote host, by} \\
+       \texttt{showq} (better: \texttt{showq | grep hzkurs})
+    };
+}
+\uncover<4->{
+    \node [green, below=0.2cm of second] (third) {
+       \textbf{if job is running, you may follow its progress by watching the job protocol:} \\ 
+       \texttt{cd ~/job\_queue \\ tail lcmuk\_example\_cbl}
+    };
+}
+\uncover<5->{
+    \node [green, below=0.2cm of third] (fourth) {
+       \textbf{when job is running, change to directory \texttt{<tmp\_usr\_catalog>} and try to find there the latest directory \texttt{<HLRN-username>.<randomnumber>} \\ change to this directory and execute}\\
+       \texttt{tail -f RUN\_CONTROL}
+    };
+}
+\uncover<6->{
+    \node [green, below=0.2cm of fourth] (fifth) {
+       \textbf{when the job is finished, watch, if the job protocol is transferred to the local host without errors:}\\
+       \texttt{cd ~/job\_queue \\ cat last\_job\_transfer\_protocol}
+    };
+}
+\uncover<7->{
+    \node [dummy, left=0.5cm of fifth] (dummy) {
+       transfer results by \texttt{scp} \\
+       \ \\
+       \ \\
+    };
+}
+\uncover<8->{
+    \node [yellow, left=3.5cm of fifth] (sixth) {
+       \textbf{check, if the job protocol and all output files have successfully been transferred to the local machine:}\\
+       \texttt{cd ~/job\_queue \\ ls -al \\ cd ~/palm/current\_version/JOBS/example \\ ls -al *}
+    };
+}
+\uncover<9->{
+     \node [alert, below=0.5cm of first.south east] (alert) {
+        \textcolor{red}{Attention: Commands for submitting jobs and the behaviour of job protocol files are depending on the qeueuing system! Manual adjustments may be required in the mrun and subjob script!}
+     };
+}
+    \path<2-> [line] (first) -- (second);
+    \path<4-> [line] (second) -- (third);
+    \path<5-> [line] (third) -- (fourth);
+    \path<6-> [line] (fourth) -- (fifth);
+    \path<7-> [line] (fifth) -- (sixth);
+\end{tikzpicture}
+\end{frame}
+
+
+
+% Folie 15
+\begin{frame}
+   \tikzstyle{green} = [rectangle, draw, fill=green!20, text width=0.45\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{green_small} = [rectangle, draw, fill=green!20, text width=0.12\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{yellow_small} = [rectangle, draw, fill=yellow!20, text width=0.1\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.18\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{dummy} = [rectangle, text width=0.01\textwidth, font=\scriptsize, minimum height=0.6cm]
+   \tikzstyle{notes} = [rectangle, text width=0.15\textwidth, font=\scriptsize, minimum height=0.6cm]
+   
+   \frametitle{PALM Runs Using \texttt{mrun}: Further Details}
+   \begin{itemize}
+      \footnotesize
+      \item<2-> For every (initial) run, \texttt{mrun} creates a source directory which contains copies of
+      \begin{itemize}
+         \footnotesize
+         \item<4-> those source code files to be translated (always the main program, \texttt{palm.f90}, plus user interface files)
+         \item<4-> the Makefile
+         \item<5-> the configuration file
+         \item<6-> the mrun script
+      \end{itemize}
+   \end{itemize}
+   
+   \vspace{-0.8cm}
+   \begin{center}
+	   \begin{tikzpicture}[auto, node distance=0] 
+	   
+         \uncover<3->{\node [yellow_small] (box1) {\$HOME/};}
+         \uncover<3->{\node [yellow_small, right=0.2cm of box1] (box2) {palm/};}
+         \uncover<3->{\node [yellow, right=0.2cm of box2] (box3) {current\_version/};}
+         \uncover<3->{\node [green_small, right=0.4cm of box3] (box4) {trunk/};}
+         
+         \uncover<1->{\node [dummy, right=1.0cm of box4] (dummy1) {};}
+         
+         \uncover<3->{\node [green_small, above=-0.2cm of dummy1] (box5) {SCRIPTS};}
+         \uncover<3->{\node [green_small, below=-0.2cm of dummy1] (box6) {SOURCE};}
+         
+         \uncover<6->{\node [notes, right=0.1cm of box5] (notes1) {\texttt{mrun}};}
+         \uncover<4->{\node [notes, right=0.1cm of box6] (notes2) {\texttt{Makefile \\ palm.f90}};}
+         \uncover<5->{\node [notes, below=0.1cm of box3] (notes3) {\texttt{.mrun.config}};}
+          
+         \uncover<3->{\node [green, below=0.2cm of box6] (box7) {SOURCES\_FOR\_RUN\_$<$run\_identifier$>$};}
+         
+         \uncover<1->{\node [dummy, left=1.5cm of box7] (dummy2) {};}
+         \uncover<1->{\node [dummy, right=2.0cm of box5] (dummy3) {};}
+         \uncover<1->{\node [dummy, right=1.8cm of box6] (dummy4) {};}
+         \uncover<1->{\node [dummy, below=0.2cm of dummy4] (dummy5) {};}
+         \draw<3-> [-] (box1.east) -- (box2.west);  
+         \draw<3-> [-] (box2.east) -- (box3.west);  
+         \draw<3-> [-] (box3.east) -- (box4.west);  
+         \draw<3-> [-] (box4.east) -- (box5.west);  
+         \draw<3-> [-] (box4.east) -- (box6.west);     
+         \draw<3-> [-] (box3.east) -- (box7.west);    
+         \draw<6-> [-] ([xshift=-0.8cm]notes1.east) -- (dummy3.center);    
+         \draw<4-> [-] ([xshift=-0.4cm]notes2.east) -- (dummy4.center); 
+         \draw<4-> [-] (dummy4.center) -- ([yshift=0.1cm]dummy5.center); 
+         \draw<4-> [->] ([yshift=0.1cm]dummy5.center) -- ([yshift=0.1cm]box7.east); 
+         \draw<6-> [-] (dummy3.center) -- ([xshift=0.2cm, yshift=-0.1cm]dummy5.center); 
+         \draw<6-> [->] ([xshift=0.2cm, yshift=-0.1cm]dummy5.center) -- ([yshift=-0.1cm]box7.east);
+         \draw<5-> [-] ([yshift=0.3cm]dummy2.center) -- (dummy2.center);    
+         \draw<5-> [->] (dummy2.center) -- (box7.west);    
+	   \end{tikzpicture}
+	\end{center}
+   
+   \begin{itemize}
+      \footnotesize
+      \item<7-> These files are used in the run/job. They are also used by restart jobs, which guarantees, that all jobs in a job chain are using the same information. Please never modify these directories, unless you exactly know, what you are doing.
+   \end{itemize}
+\end{frame}
+
+\end{document}
Index: /palm/trunk/TUTORIAL/SOURCE/sgs_models.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/sgs_models.tex	(revision 944)
+++ /palm/trunk/TUTORIAL/SOURCE/sgs_models.tex	(revision 945)
@@ -19,5 +19,5 @@
 \usepackage{amssymb}
 \usepackage{multicol}
-\usepackage{float}
+\usepackage{pdfcomment}
 
 \institute{Institut fÃŒr Meteorologie und Klimatologie, Leibniz UniversitÃ€t Hannover}
@@ -43,7 +43,4 @@
 \author{Siegfried Raasch}
 
-% Notes:
-% jede subsection bekommt einen punkt im menu (vertikal ausgerichtet.
-% jeder frame in einer subsection bekommt einen punkt (horizontal ausgerichtet)
 \begin{document}
 
@@ -167,189 +164,3 @@
 
 
-\section{Deardoff Modification}
-\subsection{Deardoff Modification}
-
-% Folie 7
-\begin{frame}
-   \frametitle{Deardorff (1980) Modification (Used in PALM) (I)}
-   \footnotesize
-   \onslide<1->{
-      $ \nu_T = Cql = C_M \Lambda \sqrt{\bar{e}} $ \quad \textbf{with} \quad $ \bar{e} = \frac{\overline{u_i' u_i'}}{2} $ \quad \textbf{SGS-turbulent kinetic energy}}
-   \normalsize
-   \begin{itemize}
-      \item<2->{The SGS-TKE allows a much better estimation of the velocity scale for the SGS fluctuations and also contains information about the past history of the local fluid.}
-   \end{itemize} 
-   \onslide<3->{
-      $ C_M = const. = 0.1 $
-      \par\bigskip
-      \scriptsize
-      $ \Lambda = \begin{cases} min\left( 0.7 \cdot z, \Delta \right), & \textbf{unstable or neutral stratification} \\
-                          min\left( 0.7 \cdot z, \Delta, 0.76 \sqrt{\bar{e}} \left[ \frac{g}{\Theta_0} \frac{\partial \bar{\Theta}}{\partial z} \right]^{-1/2} \right), & \textbf{stable                             stratification} 
-                  \end{cases} $      
-      \normalsize
-      \par\bigskip
-      $ \Delta = \left( \Delta x \Delta y \Delta z \right)^{1/3} $ }
-\end{frame}
-
-% Folie 8
-\begin{frame}
-   \frametitle{Deardorff (1980) Modification (Used in PALM) (II)}
-   \begin{itemize}
-      \item{SGS-TKE from prognostic equation}
-   \end{itemize}
-   $ \frac{\partial \bar{e}}{\partial t} = -\bar{u_k} \frac{\partial \bar{e}}{\partial x_k} - \tau_{ki} \frac{\partial \bar{u_i}}{\partial x_k} + \frac{g}{\Theta_0} \overline{u_3'             \Theta'} - \frac{\partial}{\partial x_k} \left\{ \overline{u_k' \left( e' + \frac{\pi'}{\rho_0} \right)} \right\} - \epsilon $                                         
-   \par\bigskip                                        
-   $ \frac{\partial}{\partial x_k} \left[ \overline{u_k' \left( e' + \frac{\pi'}{\rho_0} \right)} \right] = - \frac{\partial}{\partial x_k} \nu_e \frac{\partial \bar{e}}{\partial x_k} $
-   \par\bigskip
-   $ \nu_e = 2 \nu_T $
-   \par\bigskip
-   $ \epsilon = C_{\epsilon} \frac{\bar{e}^{3/2}}{\Lambda} \qquad \qquad C_{\epsilon} = 0.19 + 0.74\frac{\Lambda}{\Delta} $
-\end{frame}
-
-% Folie 9
-\begin{frame}
-   \frametitle{Deardorff (1980) Modification (Used in PALM) (III)}
-   \begin{itemize}
-      \item{There are still problems with this parameterization:}
-      \begin{itemize}
-         \item[-]<2->{The model overestimates the velocity shear near the wall.}
-         \item[-]<3->{$\textrm{C}_\mathrm{M}$ is still a constant but actually varies for different types of flows.}
-         \item[-]<4->{Backscatter of energy from the SGS-turbulence to the resolved-scale flow can not be considered.}
-      \end{itemize}
-      \item<5->{Several other SGS models have been developed:}
-      \begin{itemize}
-         \item[-]<5->{Two part eddy viscosity model (Sullivan, et al.)}
-         \item[-]<6->{Scale similarity model (Bardina et al.)}
-         \item[-]<7->{Backscatter model (Mason)}
-      \end{itemize}
-      \item<8->{However, for fine grid resolutions ($\textrm{E}_\mathrm{SGS} << \ \textrm{E}$) LES results become almost independent
-               from the different models (Beare et al., 2006, BLM).}
-   \end{itemize} 
-\end{frame}
-
-
-\section{Summary / Important Points for Beginners}
-\subsection{Summary / Important Points for Beginners}
-
-% Folie 10
-\begin{frame}
-   \frametitle{Summary / Important Points for Beginners (I)}
-   \begin{columns}[c]
-   \column[T]{0.4\textwidth} 
-      \includegraphics<2-7>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_2.png}   
-      \includegraphics<8>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_8.png}
-      \includegraphics<9>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_9.png}
-      \includegraphics<10>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_10.png}
-      \onslide<8-10>{\begin{flushright} \begin{tiny} after Schatzmann and Leitl (2001) \end{tiny} \end{flushright}}              
-   \column[T]{0.2\textwidth}
-      \vspace{0.9cm}
-      \includegraphics<8-10>[width=0.7\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_arrow.png}
-      \par
-      \onslide<8->{\begin{small} fluctuations (\textbf{u},c) \end{small}}
-      \par\bigskip
-      \thicklines
-      \onslide<9->{\mbox{\line(6,0){5} \, \line(1,0){5} \, \line(1,0){5} \quad \begin{small} {critical concentration level} \end{small}}}
-      \vspace{1cm}
-      
-      \includegraphics<8-10>[width=0.7\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_arrow.png}
-      \par
-      \onslide<8->{\begin{small} smooth result \end{small}}   
-   \column[T]{0.4\textwidth}     
-      \includegraphics<1-2>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_1.png}
-      \includegraphics<3>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_3.png}
-      \includegraphics<4>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_4.png}
-      \includegraphics<5-10>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_5.png}
-      \vspace{1.3cm}
-      \includegraphics<6>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_6.png}
-      \uncover<7->{\includegraphics[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_7.png}}       
-   \end{columns}
-\end{frame}
-
-% Folie 11
-\begin{frame}
-   \frametitle{Summary / Important Points for Beginners (II)}
-    For an LES it always has to be guaranteed that the main energy containing eddies of the respective 
-    turbulent flow can really be simulated by the numerical model:      
-    \begin{itemize}
-       \item<2->{The grid spacing has to be fine enough.}
-       \item<3->{$\textrm{E}_\mathrm{SGS} < (<<) \ \textrm{E} $}
-       \item<4->{The inflow/outflow boundaries must not effect the flow turbulence \\
-                (therefore cyclic boundary conditions are used in most cases).}
-       \item<5->{In case of homogeneous initial and boundary conditions, the onset of turbulence 
-                  has to be triggered by imposing random fluctuations.}
-       \item<6->{Simulations have to be run for a long time to reach a stationary state and stable statistics.}
-    \end{itemize}      
-\end{frame}
-
-
-\section{Example Output}
-\subsection{Example Output}
-
-% Folie 12
-\begin{frame}
-   \frametitle{Example Output (I)}
-   \begin{itemize}
-      \item{LES of a convective boundary layer}
-   \end{itemize}
-   \includegraphics<1>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_1.png}
-   \includegraphics<2>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_2.png}
-   \includegraphics<3>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_3.png}
-   \includegraphics<4>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_4.png}
-   \includegraphics<5>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_5.png}
-   \includegraphics<6>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_6.png}
-   \includegraphics<7>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_7.png}
-\end{frame}
-
-% Folie 13
-\begin{frame}
-   \frametitle{Example Output (II)}
-   \begin{itemize}
-      \item{LES of a convective boundary layer}
-   \end{itemize}
-   \begin{center}
-      \includegraphics[width=0.8\textwidth]{sgs_models_figures/Example_output_2.png}
-      power spectrum of vertical velocity
-   \end{center}
-\end{frame}
-
-% Folie 14
-\begin{frame}
-   \frametitle{Some Symbols}
-   \begin{columns}[c]
-      \column{0.6\textwidth}
-      \begin{tabbing}
-      $u_i \quad (i = 1,2,3)$ \quad \= velocity components \\
-      $u,v,w$ \\ 
-
-      \\
-      
-      $x_i \quad (i = 1,2,3)$ \> spatial coordinates \\
-      $x,y,z$ \\
-
-      \\
-
-      $\Theta$ \> potential temperature \\ \\
-
-      $\Psi$ \> passive scalar \\ \\
-
-      $T$ \> actual Temperatur \\ \\
-      \end{tabbing}
-   \column{0.4\textwidth}
-      \begin{tabbing}
-      $\Phi = gz$  \quad \= geopotential \\ \\
-
-      $p$ \> pressure \\ \\
-
-      $\rho$ \> density \\ \\
-
-      $f_i$ \> Coriolis Parameter \\ \\
-
-      $\epsilon_{ijk}$ \> alternating symbol \\ \\
-
-      $\nu, \nu_\Psi$ \> molecular diffusivity \\ \\
-
-      $Q, Q_\Psi$ \> sources or sinks \\ \\
-      \end{tabbing}
-   \end{columns}
-\end{frame}
 \end{document}
