Index: /palm/trunk/TUTORIAL/SOURCE/exercise_neutral.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/exercise_neutral.tex	(revision 1225)
+++ /palm/trunk/TUTORIAL/SOURCE/exercise_neutral.tex	(revision 1226)
@@ -113,5 +113,5 @@
         \begin{itemize}
            \tiny
-           \item<4-> You probably will find it difficult to get the mean flow to a stationary state (for the 1D-model as well as for the 3D-model. Can you identify the mechanism responsible for this? Try parameters \texttt{\textcolor{blue}{damp\_level\_1d}} (for the 1D-model) and \texttt{\textcolor{blue}{rayleigh\_damping\_factor}} (for the 3D-model; this is a \texttt{d3par}-parameter!) to overcome this problem.
+           \item<4-> You probably will find it difficult to get the mean flow to a stationary state (for the 1D-model as well as for the 3D-model. Can you identify the mechanism responsible for this? Try parameters \texttt{\textcolor{blue}{damp\_level\_1d}} (for the 1D-model) and \texttt{\textcolor{blue}{rayleigh\_damping\_factor}} (for the 3D-model; this is a \texttt{inipar}-parameter!) to overcome this problem.
            \vspace{0.5em}
            \item<5-> You can switch on a Galilei-transformation in order to save CPU-time (see parameter \texttt{\textcolor{blue}{galilei\_transformation}}).
@@ -129,5 +129,5 @@
            \scriptsize
            \item<2-> Output of spectra requires to switch on the spectra-package using \textbf{mrun}-option \texttt{-p}:\\
-                     \texttt{mrun ... -p spectra}
+                     \texttt{mrun ... -p spectra -r 'sp\#'}
            \vspace{0.5em}
            \item<3-> Spectra output is controlled by parameters \texttt{\textcolor{blue}{data\_output\_sp}}, \texttt{\textcolor{blue}{dt\_dosp}}, etc. These package-parameters have to be given     in a separate NAMELIST-block which has to follow the \texttt{d3par}-block:\\
Index: /palm/trunk/TUTORIAL/SOURCE/installation.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/installation.tex	(revision 1225)
+++ /palm/trunk/TUTORIAL/SOURCE/installation.tex	(revision 1226)
@@ -853,5 +853,5 @@
            }
            \uncover<5->{
-              \draw[->, thick] (input) |- (instal);
+              \draw[<-, thick] (input) |- (instal);
            }
         \end{tikzpicture}
Index: /palm/trunk/TUTORIAL/SOURCE/non_cyclic_boundary_conditions.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/non_cyclic_boundary_conditions.tex	(revision 1225)
+++ /palm/trunk/TUTORIAL/SOURCE/non_cyclic_boundary_conditions.tex	(revision 1226)
@@ -66,5 +66,7 @@
       \item<4->{Non-cyclic boundary conditions give problems:}
       \begin{itemize}
+         \par\smallskip
          \item<5->{If Dirichlet conditions (fixed vertical profiles) are used at the inflow, the inflow is laminar and some (significant) domain space is needed in order to develop                         turbulence.}
+         \par\smallskip
          \item<6->{At the outflow, a boundary condition is required which allows the eddies to freely leave the domain.}
       \end{itemize}
@@ -81,5 +83,6 @@
    The main motivation for non-cyclic boundary conditions are studies of isolated phenomena.
    \begin{tabbing}
-   \uncover<2->{\textbf{Example:} \= Turbulence generated by a single obstacle. \\}                    
+   \uncover<2->{\textbf{Example:} \= Turbulence generated by a single obstacle. \\}    
+                    \\
                     \uncover<6->{ \> Cyclic boundary conditions along x would allow the generated turbulence\\
                      \>  to enter the domain again, and so finally to modify the turbulence \\
@@ -87,12 +90,12 @@
                      \\ 
                      \uncover<9>{ \> This wouldn't be a simulation of a single building, but of an\\
-                     \> infinite row of buildings! \\  }
+                     \> infinite row of buildings!   }
    \end{tabbing}
    \begin{center}
-   \includegraphics<3>[width=0.7\textwidth]{non_cyclic_figures/motivation_non_cyclic_1.png}
-   \includegraphics<4>[width=0.7\textwidth]{non_cyclic_figures/motivation_non_cyclic_2.png}
-   \includegraphics<5-6>[width=0.7\textwidth]{non_cyclic_figures/motivation_non_cyclic_3.png}
-   \includegraphics<7>[width=0.7\textwidth]{non_cyclic_figures/motivation_non_cyclic_4.png}
-   \uncover<8->{\begin{center} \includegraphics[width=0.7\textwidth]{non_cyclic_figures/motivation_non_cyclic_5.png} \end{center}}
+   \includegraphics<3|handout:0>[width=0.7\textwidth]{non_cyclic_figures/motivation_non_cyclic_1.png}
+   \includegraphics<4|handout:0>[width=0.7\textwidth]{non_cyclic_figures/motivation_non_cyclic_2.png}
+   \includegraphics<5-6|handout:0>[width=0.7\textwidth]{non_cyclic_figures/motivation_non_cyclic_3.png}
+   \includegraphics<7|handout:0>[width=0.7\textwidth]{non_cyclic_figures/motivation_non_cyclic_4.png}
+   \uncover<8-|handout:1>{\begin{center} \includegraphics[width=0.7\textwidth]{non_cyclic_figures/motivation_non_cyclic_5.png} \end{center}}
    \end{center}
    \normalsize
@@ -105,13 +108,13 @@
    \onslide<2->{Using Dirichlet-conditions (e.g u(z) = const.), there is no turbulence at the inflow. $\rightarrow $the flow is laminar $\rightarrow$ LES approach fails!}
    \par\bigskip
-   \includegraphics<3>[width=0.8\textwidth]{non_cyclic_figures/implications_non_cyclic_1.png}
-   \includegraphics<4>[width=0.8\textwidth]{non_cyclic_figures/implications_non_cyclic_2.png}
-   \uncover<5->{\includegraphics[width=0.8\textwidth]{non_cyclic_figures/implications_non_cyclic_3.png}}
+   \includegraphics<3|handout:0>[width=0.8\textwidth]{non_cyclic_figures/implications_non_cyclic_1.png}
+   \includegraphics<4|handout:0>[width=0.8\textwidth]{non_cyclic_figures/implications_non_cyclic_2.png}
+   \uncover<5-|handout:1>{\includegraphics[width=0.8\textwidth]{non_cyclic_figures/implications_non_cyclic_3.png}}
    \par\bigskip
    \onslide<6->{Flow internal turbulence may develop, but this may require a very long model domain.}
    \par\bigskip
-   \includegraphics<7>[width=\textwidth]{non_cyclic_figures/implications_non_cyclic_4.png}
-   \includegraphics<8>[width=\textwidth]{non_cyclic_figures/implications_non_cyclic_5.png}
-   \uncover<9->{\includegraphics[width=\textwidth]{non_cyclic_figures/implications_non_cyclic_6.png}}
+   \includegraphics<7|handout:0>[width=\textwidth]{non_cyclic_figures/implications_non_cyclic_4.png}
+   \includegraphics<8|handout:0>[width=\textwidth]{non_cyclic_figures/implications_non_cyclic_5.png}
+   \uncover<9-|handout:1>{\includegraphics[width=\textwidth]{non_cyclic_figures/implications_non_cyclic_6.png}}
    \onslide<10->{There is a need to supply turbulence information at the inflow.}
 \end{frame}
@@ -128,10 +131,10 @@
       \item<3->{by recycling-method  (Lund et al., 1998)}
    \end{itemize}
-   \includegraphics<4>[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_1_neu.png}
-   \includegraphics<5>[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_2_neu.png}
-   \includegraphics<6>[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_3_neu.png}
-   \includegraphics<7>[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_4_neu.png}
-   \includegraphics<8>[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_5_neu.png}
-   \uncover<9->{\includegraphics[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_6.png}}
+   \includegraphics<4|handout:0>[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_1_neu.png}
+   \includegraphics<5|handout:0>[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_2_neu.png}
+   \includegraphics<6|handout:0>[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_3_neu.png}
+   \includegraphics<7|handout:0>[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_4_neu.png}
+   \includegraphics<8|handout:0>[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_5_neu.png}
+   \uncover<9-|handout:1>{\includegraphics[width=\textwidth]{non_cyclic_figures/create_turbulent_inflow_1/create_turbulent_inflow_6.png}}
    \par\bigskip
    \uncover<10>{How do we get the initial turbulence in the recycle area? \\
@@ -236,5 +239,5 @@
    \begin{itemize}
       \item<2->{The \textbf{multigrid-method} has to be used for solving the Poisson-equation.}
-      \item<3->{A \textbf{damping zone} has sometimes to be activated in the vicinity of the outflow in order to avoid reflection of outgoing gravity waves.}
+      \item<3->{A \textbf{damping zone} has sometimes to be activated in the vicinity of the in- and outflow in order to avoid reflection of gravity waves.}
       \item<4->{\textbf{Volume flow conservation} should be activated, because otherwise flow acceleration or deceleration may occur along the non-cyclic direction.}
       \item<5->{If turbulence recycling is not used, it may be neccessary to \textbf{continuously impose perturbations} on the horizontal velocity field in the vicinity of the
@@ -308,4 +311,5 @@
       \item<2->{Restart data has to be output and output of instantaneous, horizontally averaged profiles has to be switched on and performed at the end of the run. 
                 This enables writing of profiles to the restart file, which can then be used by the main run.}
+      \item<3->{Instead of using averaged profiles from the prerun, inflow profiles for the main run can also be prescribed using parameters u\_profile and v\_profile.}
    \end{itemize}
    \tikzstyle{box} = [rectangle, draw, text width=\textwidth, font=\small]
@@ -376,6 +380,6 @@
    \begin{itemize}
       \item<1->{Non-cyclic boundary conditions and turbulence recycling method require extreme care with setting of the respective parameters.}
-      \item<2->{So far, these methods have been applied only to a few special cases (cold air outbreaks). Other setups may require modifications.}
-      \item<3->{Biggest problems are caused by gravity waves in capping inversions. Simulations with pure neutral stratification are expected to cause less problems.}
+      \item<2->{So far, these methods have been applied only to a few special cases (cold air outbreaks, urban canopy layer for neutral stratification). Other setups may require modifications.}
+      \item<3->{Biggest problems are caused by gravity waves in capping inversions. Simulations with pure neutral stratification cause less problems.}
    \end{itemize}
 \end{frame}
Index: /palm/trunk/TUTORIAL/SOURCE/numerics_bc.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/numerics_bc.tex	(revision 1225)
+++ /palm/trunk/TUTORIAL/SOURCE/numerics_bc.tex	(revision 1226)
@@ -61,10 +61,8 @@
       \item<3-> \textbf{Explicit timestep methods:}\\
          - Euler\\
-         - Leapfrog\\
          - \underline{Runge-Kutta}, second or \underline{third order}
       \item<4-> \textbf{Advection method}\\
          - Upstream\\
          - Piacsek-Williams (second order central finite differences)\\
-         - Upstream-spline\\
          - Bott-Chlond-scheme (monotone, positiv definit, for scalars only)\\
          - \underline{5th-order scheme of Wicker and Skamarock}, (as used in WRF model)
@@ -122,5 +120,5 @@
    \begin{itemize}
       \item<1->\textbf{Euler}\\
-      \vspace{1mm}
+      \vspace{3mm}
       $\dfrac{\partial \psi(t)}{\partial t} = F (\psi(t)) \rightarrow 
       \dfrac{\psi(t + \Delta t) - \psi(t)}{\Delta t} 
@@ -136,11 +134,6 @@
          
       \vspace{3mm}
-      \item<3-> \textbf{Leapfrog}\\
-      $\psi(t + \Delta t) = \psi(t - \Delta t)+2 \Delta t \cdot F(\psi(t))$ \hspace{16mm} $
-      \mathcal{O}(\Delta t^2)$ \hspace{3mm} $C \le 0.1$\\
-      Time-splitting requires a weak time filter (Asselin filter)
-         
-      \vspace{3mm}
-      \item<4-> \textbf{Runge-Kutta, third-order}\\
+      \item<3-> \textbf{Runge-Kutta, third-order}\\
+      \vspace{2mm}
       $k_1=F(\psi(t))$\\
       \vspace{1mm}
@@ -172,5 +165,4 @@
             \bf{Scheme} & \bf{c$_1$} & \bf{c$_2$} & \bf{c$_3$}\\
             Euler & 1 & 1 & 0\\
-            Leapfrog & 0 & 2 & 0\\
             RK (1st step) & 1 & 1/3 & 0\\
             RK (2nd step) & 1 & 15/16 & -25/48\\
@@ -211,19 +203,17 @@
    \frametitle{Advection Methods (II)}
    \begin{itemize}
-      \item<1-> \small Upstream-spline\\ \scriptsize
-         \onslide<1-> - Requires Euler timestep\\
-         \onslide<2-> - Nonlocal scheme: produces heavy load on communication network\\
-         \onslide<3-> - Numerically unstable under stable stratification
-      \item<4-> \small Bott-Chlond\\ \scriptsize
-         \onslide<4-> - Chlond (1994)\\
-         \onslide<5-> - Monotone, positive definit. Can only be used for scalars\\
-         \onslide<6-> - Conserves sharp gradients\\
-         \onslide<7-> - Numerically expensive\\
-         \onslide<8-> - Not optimized for use on cache-based machines.
-      \item<9-> \small Default: Wicker and Skamarock scheme (5th order)\\ \scriptsize
-         \onslide<9-> - Much better accuracy than Piacsek Williams\\
-         \onslide<10-> - Much simpler algorithm than Bott-Chlond\\
-         \onslide<11-> - Requires additional ghost layers\\
-         \onslide<12-> - Adds additional numerical dissipation
+   
+      \item<1-> \small Bott-Chlond\\ \scriptsize
+         \onslide<1-> - Chlond (1994)\\
+         \onslide<2-> - Monotone, positive definit. Can only be used for scalars\\
+         \onslide<3-> - Conserves sharp gradients\\
+         \onslide<4-> - Numerically expensive\\
+         \onslide<5-> - Not optimized for use on cache-based machines.
+      \par\bigskip
+      \item<6-> \small Default: Wicker and Skamarock scheme (5th order)\\ \scriptsize
+         \onslide<6-> - Much better accuracy than Piacsek Williams\\
+         \onslide<7-> - Much simpler algorithm than Bott-Chlond\\
+         \onslide<8-> - Requires additional ghost layers\\
+         \onslide<9-> - Adds additional numerical dissipation
          
    \end{itemize}
@@ -286,5 +276,5 @@
 
 
-   \textbf{Finite difference approxiamtion of 6$^{\text{th}}$ order}
+   \textbf{Finite difference approximation of 6$^{\text{th}}$ order}
    \begin{tikzpicture}[scale=2]
       \tikzstyle{ann} = [draw=none,fill=none,right]
@@ -305,5 +295,5 @@
       \matrix[nodes={draw, thick, fill=blue!40}, row sep=0.3cm,column sep=0.5cm]{
       \node[rectangle, rounded corners]{
-      $\frac{-1}{60} \left| u_{i-\frac{1}{2}} \right| \left( 10 (\Psi_i - 
+      $-\frac{1}{60} \left| u_{i-\frac{1}{2}} \right| \left( 10 (\Psi_i - 
       \Psi_{i-1}) - 5 (\Psi_{i+1} - \Psi_{i-2}) + (\Psi_{i+2} - \Psi_{i-3}) \right)$ 
        };\\
@@ -341,29 +331,16 @@
 \begin{frame}
    \frametitle{Advection Methods â Wicker/Skamarock (IV)}
-   \footnotesize
-   
-   \begin{columns}[T]
-      \begin{column}{0.1\textwidth}
-            \begin{tikzpicture}[scale=2]
-      \tikzstyle{ann} = [draw=none,fill=none,right]
-      \matrix[nodes={draw, thick, fill=blue!40}, row sep=0.3cm,column sep=0.5cm]{
-      \node[draw=none,fill=none]{
-      $F^{\text{5th}}_{i-\frac{1}{2}} = F^{\text{6th}}_{i-\frac{1}{2}}$
-      };\\
-       };
-   \end{tikzpicture}
-      \end{column}
-      \begin{column}{0.8\textwidth}
-            \begin{tikzpicture}[scale=2]
+   \footnotesize   
+
+   \begin{tikzpicture}[scale=2]
       \tikzstyle{ann} = [draw=none,fill=none,right]
       \matrix[nodes={draw, thick, fill=blue!40}, row sep=0.3cm,column sep=0.5cm]{
       \node[rectangle, rounded corners]{
-      $- \frac{1}{60} \left| u_{i-\frac{1}{2}} \right| \left( 10 (\Psi_i - \Psi_{i-1}) - 
-      5 (\Psi_{i+1} - \Psi_{i-2}) + (\Psi_{i+2} - \Psi_{i-3}) \right)$ 
+      $F^{\text{5th}}_{i-\frac{1}{2}} = F^{\text{6th}}_{i-\frac{1}{2}}
+         - \frac{1}{60} \left| u_{i-\frac{1}{2}} \right| \left( 10 (\Psi_i - \Psi_{i-1}) - 
+            5 (\Psi_{i+1} - \Psi_{i-2}) + (\Psi_{i+2} - \Psi_{i-3}) \right)$ 
        };\\
        };
    \end{tikzpicture}
-      \end{column}
-   \end{columns}
    
    \begin{columns}[T]
@@ -415,4 +392,5 @@
             1. Momentum equations are solved without the pressure term giving a
             provisional velocity field which is not free of divergence.\\
+            \vspace{2mm}
             $\overline{u}^{t+\Delta t}_{i_{\mathrm{prov}}} = \overline{u}^t_i +
             \Delta t \left( - \frac{\partial}{\partial x_k} \overline{u}^t_k
@@ -421,19 +399,21 @@
             + g \frac{\overline{\theta^*}^t}{\theta_0} \delta_{i3} 
             - \frac{\partial}{\partial x_k} \overline{u'_k u'_i}^t \right)$\\
-            \vspace{3mm}
+            \vspace{2mm}
             \onslide<3-> 2. Assign all remaining divergences to the (perturbation)
             pressure $p^*$ so that the new corrected velocity field is the sum of the
             provisional, divergent field and the perturbation pressure term.\\
+            \vspace{2mm}
             $\overline{u}^{t+\Delta t}_{i} = 
-            \overline{u}^{t+\Delta t}_{i_{\mathrm{prov}}} - 
-            \frac{\Delta t}{\rho_0} \frac{\partial \overline{p^*}^t}{\partial x_i}$\\
-            \vspace{3mm}
+            \overline{u}^{t+\Delta t}_{i_{\mathrm{prov}}} + 
+            \Delta t \left(-\frac{1}{\rho_0} \frac{\partial \overline{p^*}^t}{\partial x_i} \right)$\\
+            \vspace{2mm}
             \onslide<4-> 3. The divergence operator is applied to this equation.
             Demanding a corrected velocity field free of divergence, this leads to a
             Poisson equation for the perturbation pressure.\\
+            \vspace{2mm}
             $\frac{\partial^2 \overline{p^*}^t}{\partial x_i^2} = \frac{\rho_0}
             {\Delta t} \frac{\partial \overline{u}_{i_{\mathrm{prov}}}^{t + \Delta t}}
             {\partial x_i}$\\
-            \vspace{3mm}
+            \vspace{2mm}
             \onslide<5-> 4. After solving the Poisson equation, the final velocity field
             is \\
@@ -462,5 +442,5 @@
          \item<7-> Due to non-locality of the FFT, transpositions are required 
          on parallel computers
-         \item<8-> Usage requires periodic boundary conditions and uniform grids 
+         \item<8-> Requires periodic boundary conditions and uniform grids 
          along $x$ and $y$
       \end{itemize}
Index: /palm/trunk/TUTORIAL/SOURCE/parallelization.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/parallelization.tex	(revision 1225)
+++ /palm/trunk/TUTORIAL/SOURCE/parallelization.tex	(revision 1226)
@@ -15,6 +15,6 @@
 \usepackage{tikz}
 \usetikzlibrary{shapes,arrows,positioning}
-\usetikzlibrary{decorations.markings}             %neues paket
-\usetikzlibrary{decorations.pathreplacing}        %neues paket
+%\usetikzlibrary{decorations.markings}             %neues paket
+%\usetikzlibrary{decorations.pathreplacing}        %neues paket
 \def\Tiny{\fontsize{4pt}{4pt}\selectfont}
 \usepackage{amsmath}
@@ -76,5 +76,5 @@
          \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}
+            \includegraphics[width=0.3\textwidth]{parallelization_figures/subdomain_folie2.png}
          \end{center}
          \onslide<7->each PE only knows the variable values from its subdomain, communication / data exchange between PEs is necessary\\
@@ -109,5 +109,5 @@
          \node (center) at (0,1) {};
          \onslide<2-> \node (Network) at (-3.5,1) [draw, ellipse,fill=green!20] {Network};
-         \node (dis_mem) at (-3.5,-1) [text width=0.28\textwidth] {\footnotesize \textbf{distributed} memory\\(Cray-T3E)};
+         \node (dis_mem) at (-3.5,-1) [text width=0.28\textwidth] {\footnotesize \textbf{distributed} memory\\(Cray-XC30)};
          \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)};
@@ -116,5 +116,5 @@
          \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-XE6)};
+            NEC-SX, SGI-ICE, Cray-XC)};
 
 % Adressable memory node (big)
@@ -248,10 +248,10 @@
    \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<10-> Alternatively, a 1D-decomposition along $x$ or $y$ may be used.
       \vspace{2mm}
       \item<11-> Message passing is realized using MPI.
       \vspace{2mm}
       \item<12-> OpenMP parallelization as well as mixed usage of OpenMP and
-MPI is also possible. (OpenMP tests and optimization is under way)
+                    MPI is also possible.
    \end{itemize}
 \end{frame}
@@ -285,5 +285,5 @@
          \onslide<5-> \includegraphics[width=0.8\textwidth]{parallelization_figures/fft.png} \end{center}
          \vspace{-4mm}
-         \textbf{Example: transpositions for solving the Poisson\\ \hspace{4em}equation}
+         \textbf{Example: transpositions for solving the Poisson\\ \hspace{4.1em}equation}
       \end{column}
    \end{columns}   
@@ -302,9 +302,9 @@
 	         \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?).\\        
+            \item<5-> 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}
+         \onslide<4-> \includegraphics[width=0.13\textwidth]{parallelization_figures/folie_6.png}
          \end{center}
       \end{column}
@@ -325,9 +325,9 @@
 	         \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}}
+	         \item<3-> 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  -r8:-nbs:\textcolor{blue}{-L:<replace by mpi library path>:-lmpi}}
             \vspace{2mm}
-	         \item<3-> All MPI calls must be within\\
+	         \item<4-> All MPI calls must be within\\
 	         \quad \texttt{CALL MPI\_INIT( ierror )}\\
 	         \quad $\vdots$\\
@@ -417,5 +417,5 @@
             \quad \texttt{CALL MPI\underline{\ }TYPE\underline{\ }COMMIT( type\underline{\ }yz(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, ...}\\
+            \quad \texttt{CALL MPI\underline{\ }SENDRECV( ar(nzb,nys-ngl,nxl), 1, type\underline{\ }yz(grid\underline{\ }level), pleft, 0, ...}\\
          \end{itemize}       
 \end{frame}
@@ -468,5 +468,5 @@
          \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).\\ \textbf{Workaround:} reduce the maximum number of parallel I/O streams\\ \hspace{5.75em}(see \texttt{mrun}-options)
+            \item Parallel I/O on a large number of files ($>$1000) currently may cause severe file system problems (e.g. on Lustre file systems).\\ \textbf{Workaround:} reduce the maximum number of parallel I/O streams\\ \hspace{5.75em}(see \texttt{mrun}-option \texttt{-w})
          \end{itemize}
       \end{column}
@@ -476,5 +476,5 @@
 
 
-% Folie 13
+%Folie 13
 \begin{frame}
    \frametitle{PALM Parallel I/O for 2D/3D Data} 
@@ -492,5 +492,5 @@
 \end{frame}
 
-% Folie 14
+%Folie 14
 \begin{frame}
    \frametitle{Performance Examples (I)} 
@@ -520,5 +520,5 @@
 \end{frame}
 
-% Folie 15
+%Folie 15
 \begin{frame}
    \frametitle{Performance Examples (II)} 
@@ -542,3 +542,25 @@
 \end{frame}
 
+%Folie 16
+\begin{frame}
+   \frametitle{Performance Examples (III)} 
+   \begin{itemize}
+      \item Simulation with $2160^3$ grid points  ($\sim$ 2 TByte memory)
+   \end{itemize}
+      \begin{columns}[T]
+         \begin{column}{0.5\textwidth}
+            \includegraphics[scale=0.3]{parallelization_figures/perf_4.png} \\
+            \scriptsize
+            \quad Cray-XC30, HLRN-III, Hannover\\
+            \quad (2D-domain decomposition)
+         \end{column}
+         \begin{column}{0.5\textwidth}
+            \vspace{35mm}
+            \onslide<2-> currently largest simulation feasible on that system:\\
+            \ \\
+            $5600^3$ grid points
+         \end{column} 
+      \end{columns}
+\end{frame}
+
 \end{document}
Index: /palm/trunk/TUTORIAL/SOURCE/program_structure.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/program_structure.tex	(revision 1225)
+++ /palm/trunk/TUTORIAL/SOURCE/program_structure.tex	(revision 1226)
@@ -84,5 +84,5 @@
    \frametitle{PALM Code: General Features}
    \begin{itemize}
-      \item<2->{PALM is written in FORTRAN90. Current version number is 3.8.}
+      \item<2->{PALM is written in FORTRAN90. Current version number is 3.9.}
       \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.
@@ -107,5 +107,5 @@
          \end{lstlisting}
       \end{minipage}
-      \mbox{All modules can be found in file .../trunk/SOURCE/modules.f90}}
+      \mbox{Most modules can be found in file .../trunk/SOURCE/modules.f90}}
    \end{itemize}
 \end{frame}
@@ -129,4 +129,5 @@
    \tikzstyle{white2} = [rectangle, text width=0]
    \tikzstyle{yellow} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, minimum size=15pt, font=\tiny]
+   \tikzstyle{green} = [rectangle, draw, fill=green!20, text width=0.2\textwidth, minimum size=15pt, font=\tiny]
    \tikzstyle{line} = [draw, -]
 
@@ -134,43 +135,37 @@
       \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<2->{\node [yellow, below=0.2cm of PALMspace] (initcoup) {init\_coupling};}
+      \path<2-> [line] (PALM.south) |- (initcoup.west);
+
+      \uncover<3->{\node [yellow, below=0.05cm of initcoup] (localtre) {local\_tremain\_ini};}
+      \path<3-> [line] (PALM.south) |- (localtre.west);
+
+      \uncover<4->{\node [yellow, below=0.05cm of localtre] (initdvrp) {init\_dvrp\_logging};}
+      \path<4-> [line] (PALM.south) |- (initdvrp.west);
+
+      \uncover<5->{\node [yellow, below=0.05cm of initdvrp] (parin) {parin};}
+      \path<5-> [line] (PALM.south) |- (parin.west);
+      \uncover<5->{\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<5->{\node [yellow, below=0.05cm of readvar] (packageparin) {package\_parin};}
+         \path<5-> [line,dashed] (parin.south) |- (packageparin.west);
+
+          \uncover<5->{\node [green, below=0.05cm of packageparin] (userparin) {user\_parin};}
+          \path<5-> [line] (parin.south) |- (userparin.west);
+
+      \uncover<6->{\node [yellow, below=1.4cm of parin] (initpeg) {init\_pegrid};}
+      \path<6-> [line] (PALM.south) |- (initpeg.west);
+      \uncover<6->{\node [white, right=0.2cm of initpeg] (initpegspace) {};}
+
+      \uncover<7->{\node [yellow, below=0.05cm of initpeg] (initgrid) {init\_grid};}
+      \path<7-> [line] (PALM.south) |- (initgrid.west);
+      \uncover<7->{\node [white, right=0.2cm of initgrid] (initgridspace) {};}
+      
+         \uncover<7->{\node [green, below=0cm of initgridspace] (userinitgrid) {user\_init\_grid};}
+         \path<7-> [line,dashed] (initgrid.south) |- (userinitgrid.west);
 
       \uncover<1->{\node [white, below=5.8cm of PALM] (continu2) {};}
@@ -194,4 +189,6 @@
    \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{green} = [rectangle, draw, fill=green!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{green1} = [rectangle, draw, fill=green!20, text width=0.23\textwidth, minimum size=13pt, font=\tiny]
    \tikzstyle{line} = [draw, -]
 
@@ -200,76 +197,62 @@
       \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<1->{\node [yellow, right=0.2cm of PALM] (checkpara) {check\_parameters};}
+      \path<1-> [line] (PALM.south) |- (checkpara.west);
+      \uncover<1->{\node [white, right=0.2cm of checkpara] (checkparaspace) {};}
+      \uncover<1->{\node [white, right=0.365cm of checkpara] (checkparaspacelarge) {};}
+  
+          \uncover<2->{\node [green1, below=0cm of checkparaspacelarge] (usercheckdatapr) {user\_check\_data\_output\_pr};}
+          \path<2-> [line] (checkpara.south) |- (usercheckdatapr.west);
+
+          \uncover<2->{\node [green, below=0.52cm of checkparaspace] (usercheckdata) {user\_check\_data\_output};}
+          \path<2-> [line] (checkpara.south) |- (usercheckdata.west);
+
+          \uncover<2->{\node [yellow, below=0.05cm of usercheckdata] (initmasks) {init\_masks};}
+          \path<2-> [line,dashed] (checkpara.south) |- (initmasks.west);
+
+             \uncover<2->{\node [green, right=0.2cm of initmasks] (usercheckdata2) {user\_check\_data\_output};}
+             \path<2-> [line] (initmasks.east) |- (usercheckdata2.west);
+
+          \uncover<2->{\node [yellow, below=0.05cm of initmasks] (usercheckpara) {user\_check\_parameters};}
+          \path<2-> [line] (checkpara.south) |- (usercheckpara.west);
+
+      \uncover<3->{\node [yellow, below=1.9cm of checkpara] (init3d) {init\_3d\_model};}
+      \path<3-> [line] (PALM.south) |- (init3d.west);
+      \uncover<3->{\node [white, right=0.05cm of init3d] (init3dspace) {};}
+      \uncover<3->{\node [whitelarge, right=0.05cm of init3d] (init3dspacelarge) {};}
+
+         \uncover<4->{\node [yellowLarge, below=-0.05cm of init3dspacelarge] (init1d) {init\_1d\_model (calls various subroutines)};}
+         \path<4-> [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<4->{\node [green, below=0.05cm of initslope] (userinit3d) {user\_init\_3d\_model};}
+         \path<4-> [line,dashed] (init3d.south) |- (userinit3d.west);
+
+         \uncover<4->{\node [yellow, below=0.05cm of userinit3d] (disturbh) {disturb\_heatflux};}
+         \path<4-> [line,dashed] (init3d.south) |- (disturbh.west);
+
+         \uncover<4->{\node [yellow, below=0.05cm of disturbh] (initrank) {init\_rankine};}
+         \path<4-> [line,dashed] (init3d.south) |- (initrank.west);
+
+            \uncover<4->{\node [yellow, right=0.05cm of initrank] (pres) {pres};}
+            \path<4-> [line] (initrank.east) -- (pres.west);
+            \uncover<4->{\node [white, below=-0.05cm of pres] (presspace) {};}
+
+               \uncover<4->{\node [yellowsmall, right=0.05cm of presspace] (poisfft) {poisfft};}
+               \path<4-> [line] (pres.east) -| (poisfft.north);
+
+               \uncover<4->{\node [yellowsmall, right=0.05cm of poisfft] (sor) {sor};}
+               \path<4-> [line] (pres.east) -| (sor.north);
+
+               \uncover<4->{\node [yellowsmall, right=0.05cm of sor] (poismg) {poismg};}
+               \path<4-> [line] (pres.east) -| (poismg.north);
+
+         \uncover<4->{\node [yellow, below=0.05cm of initrank] (initpt) {init\_pt\_anomaly};}
+         \path<4-> [line,dashed] (init3d.south) |- (initpt.west);
+
+         \uncover<4->{\node [yellow, below=0.05cm of initpt] (randomfuncini) {random\_function\_ini};}
+         \path<4-> [line] (init3d.south) |- (randomfuncini.west);
 
       \uncover<1->{\node [white2, below=6.6cm of PALM] (continu2) {};}
@@ -278,11 +261,201 @@
       \uncover<1->{\node [white2, below=6.0cm of PALM] (continu1) {};}
       \path<1-> [line] (PALM.south) |- (continu1.north);
+
+      \uncover<4->{\node [white2, below=6.6cm of checkpara] (continu3) {};}
+      \path<4-> [line,dashed] (init3d.south) |- (continu3.north);
+
+      \uncover<4->{\node [white2, below=6.0cm of checkpara] (continu4) {};}
+      \path<4-> [line] (init3d.south) |- (continu4.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.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{green} = [rectangle, draw, fill=green!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{green1} = [rectangle, draw, fill=green!20, text width=0.23\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<1->{\node [yellow, right=0.2cm of PALM] (init3d) {init\_3d\_model};}
+       \path<1-> [line] (PALM.south) |- (init3d.west);
+       \uncover<1->{\node [white, right=0.05cm of init3d] (init3dspace) {};}
+       \uncover<1->{\node [whitelarge, right=0.05cm of init3d] (init3dspacelarge) {};}
+
+         \uncover<2->{\node [yellow, below=0.05cm of init3dspace] (read3d) {read\_3d\_binary};}
+         \path<2-> [line,dashed] (init3d.south) |- (read3d.west);
+
+            \uncover<2->{\node [green, right=0.05cm of read3d] (userreadrestart) {user\_read\_restart\_data};}
+            \path<2-> [line] (read3d.east) -- (userreadrestart.west);
+
+         \uncover<2->{\node [yellow, below=0.5cm of init3dspace] (initslope) {init\_slope};}
+         \path<2-> [line,dashed] (init3d.south) |- (initslope.west);
+
+         \uncover<2->{\node [yellow, below=0.05cm of initslope] (initadvec) {init\_advec};}
+         \path<2-> [line] (init3d.south) |- (initadvec.west);
+
+         \uncover<2->{\node [yellow, below=0.05cm of initadvec] (distfield) {disturb\_field};}
+         \path<2-> [line,dashed] (init3d.south) |- (distfield.west);
+
+         \uncover<2->{\node [yellow, below=0.05cm of distfield] (pres) {pres};}
+         \path<2-> [line,dashed] (init3d.south) |- (pres.west);
+         \uncover<2->{\node [white, below=-0.05cm of pres] (presspace) {};}
+
+            \uncover<2->{\node [yellowsmall, right=0.05cm of presspace] (poisfft) {poisfft};}
+            \path<2-> [line] (pres.east) -| (poisfft.north);
+
+            \uncover<2->{\node [yellowsmall, right=0.05cm of poisfft] (sor) {sor};}
+            \path<2-> [line] (pres.east) -| (sor.north);
+
+            \uncover<2->{\node [yellowsmall, right=0.05cm of sor] (poismg) {poismg};}
+            \path<2-> [line] (pres.east) -| (poismg.north);
+
+         \uncover<2->{\node [green, below=0.05cm of pres] (userinitplant) {user\_init\_plant\_canopy};}
+         \path<2-> [line,dashed] (init3d.south) |- (userinitplant.west);
+
+         \uncover<2->{\node [yellow, below=0.05cm of userinitplant] (initdvrp) {init\_dvrp};}
+         \path<2-> [line,dashed] (init3d.south) |- (initdvrp.west);
+
+         \uncover<2->{\node [yellow, below=0.05cm of initdvrp] (initocean) {init\_ocean};}
+         \path<2-> [line,dashed] (init3d.south) |- (initocean.west);
+
+            \uncover<2->{\node [yellow, right=0.05cm of initocean] (eqnstsea) {eqn\_state\_seawater};}
+            \path<2-> [line] (initocean.east) -| (eqnstsea.west);
+
+         \uncover<2->{\node [yellow, below=0.05cm of initocean] (initcloudphys) {init\_cloud\_physics};}
+         \path<2-> [line,dashed] (init3d.south) |- (initcloudphys.west);
+
+        \uncover<2->{\node [yellow, below=0.05cm of initcloudphys] (lpminit) {lpm\_init};}
+        \path<2-> [line,dashed] (init3d.south) |- (lpminit.west);
+        \uncover<2->{\node [white, right=0.2cm of lpminit] (lpminspace) {};}
+
+            \uncover<2->{\node [yellow, below=0.05cm of lpminspace] (lpmreadrestart) {lpm\_read\_restart\_file};}
+            \path<2-> [line,dashed] (lpminit.south) |- (lpmreadrestart.west);
+
+            \uncover<2->{\node [green, below=0.05cm of lpmreadrestart] (userlpmin) {user\_lpm\_init};}
+            \path<2-> [line] (lpminit.south) |- (userlpmin.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);
+
+      \uncover<2->{\node [white2, below=6.6cm of init3d] (continu3) {};}
+      \path<2-> [line,dashed] (init3d.south) |- (continu3.north);
+
+      \uncover<2->{\node [white2, below=6.0cm of init3d] (continu4) {};}
+      \path<2-> [line] (init3d.south) |- (continu4.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.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{green} = [rectangle, draw, fill=green!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{green1} = [rectangle, draw, fill=green!20, text width=0.23\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 [yellow, below=0.05cm of init3dspace] (lpminit) {lpm\_init};}
+       \path<3-> [line,dashed] (init3d.south) |- (lpminit.west);
+       \uncover<3->{\node [white, right=0.2cm of lpminit] (lpminspace) {};}
+
+            \uncover<4->{\node [yellow, below=0.05cm of lpminspace] (lpmsortar) {lpm\_sort\_arrays};}
+            \path<4-> [line,dashed] (lpminit.south) |- (lpmsortar.west);
+
+            \uncover<5->{\node [yellow, below=0.05cm of lpmsortar] (dataoutpdvrp) {data\_output\_dvrp};}
+            \path<5-> [line,dashed] (lpminit.south) |- (dataoutpdvrp.west);
+            \uncover<5->{\node [white, right=0.2cm of dataoutpdvrp] (dataoutpdvrpspace) {};}
+
+               \uncover<6->{\node [green, below=0.05cm of dataoutpdvrpspace] (usercoltap) {user\_dvrp\_coltab};}
+               \path<6-> [line,dashed] (dataoutpdvrp.south) |- (usercoltap.west);
+
+               \uncover<7->{\node [green, below=0.05cm of usercoltap] (userdataoutdvrp) {user\_data\_output\_dvrp};}
+               \path<7-> [line] (dataoutpdvrp.south) |- (userdataoutdvrp.west);
+
+       \uncover<8->{\node [green, below=1cm of lpminit] (userinit) {user\_init};}
+       \path<8-> [line] (init3d.south) |- (userinit.west);
+
+       \uncover<9->{\node [yellow, below=2.3cm of init3d] (header) {header};}
+       \path<9-> [line] (PALM.south) |- (header.west);
+
+          \uncover<10->{\node [green, right=0.05cm of header] (userheader) {user\_header};}
+          \path<10-> [line] (header.east) |- (userheader.west);
+
+       \uncover<11->{\node [yellow, below=0.05cm of header] (dataoutput2d) {data\_output\_2d};}
+       \path<11-> [line,dashed] (PALM.south) |- (dataoutput2d.west);
+
+          \uncover<12->{\node [green, right=0.05cm of dataoutput2d] (userdataoutput2d) {user\_data\_output\_2d};}
+          \path<12-> [line] (dataoutput2d.east) |- (userdataoutput2d.west);
+
+       \uncover<13->{\node [yellow, below=0.05cm of dataoutput2d] (dataoutput3d) {data\_output\_3d};}
+       \path<13-> [line,dashed] (PALM.south) |- (dataoutput3d.west);
+
+          \uncover<14->{\node [green, right=0.05cm of dataoutput3d] (userdataoutput3d) {user\_data\_output\_3d};}
+          \path<14-> [line] (dataoutput3d.east) |- (userdataoutput3d.west);
+
+       \uncover<15->{\node [yellow, below=0.05cm of dataoutput3d] (timeintegr) {time\_integration};}
+       \path<15-> [line] (PALM.south) |- (timeintegr.west);
+       \uncover<15->{\node [white, right=0.2cm of timeintegr] (timeintspace) {};}
+
+          \uncover<16->{\node [yellow, below=0.05cm of timeintspace] (runcontr) {run\_control};}
+          \path<16-> [line] (timeintegr.south) |- (runcontr.west);
+          \uncover<16->{\node [white, right=0.2cm of runcontr] (runcontrspace) {};}
+
+             \uncover<17->{\node [yellow, below=0.05cm of runcontrspace] (flowstat1) {flow\_statistics};}
+             \path<17-> [line,dashed] (runcontr.south) |- (flowstat1.west);
+
+                \uncover<18->{\node [green, right=0.05cm of flowstat1] (userstat1) {user\_statistics};}
+                \path<18-> [line] (flowstat1.east) |- (userstat1.west);
+
+          \uncover<19->{\node [yellow, below=0.5cm of runcontr] (surfcoup) {surface\_coupler};}
+          \path<19-> [line,dashed] (timeintegr.south) |- (surfcoup.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]
@@ -294,4 +467,7 @@
    \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{green} = [rectangle, draw, fill=green!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{green1} = [rectangle, draw, fill=green!20, text width=0.23\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{greenLarge} = [rectangle, draw, fill=green!20, text width=0.3\textwidth, minimum size=12pt, font=\tiny]
    \tikzstyle{line} = [draw, -]
    \tikzstyle{linered} = [draw, color=red, -]
@@ -318,11 +494,8 @@
          \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)};}
+            \uncover<1->{\node [yellow, right=0.05cm of timestep] (globminmax) {global\_min\_max};}
+            \path<1-> [line] (timestep.east) |- (globminmax.west);
+
+         \uncover<1->{\node [greenLarge, below=0.5cm of timeintegrspacelarge] (useractions) {user\_actions (before\_timestep)};}
          \path<1-> [line] (timeintegr.south) |- (useractions.west);
 
@@ -330,37 +503,37 @@
          \path<1-> [line] (timeintegr.south) |- (timestepscheme.west);
 
-         \uncover<1->{\node [Bigbox, below=1.75cm of timeintegrspacebox] (bigbox) {};}
+         \uncover<1->{\node [Bigbox, below=1.3cm 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).};}
+         \uncover<1->{\node [white, below=1.6cm of timeintegrline] (boxlinespace) {};}
+         \path<1-> [line] (timeintegr.south) |- (boxlinespace.north);
+
+            \uncover<1->{\node [yellowLarge, below=0.4cm of timestepscheme] (prognosticequve) {prognostic\_equations\_vector};}
+            \uncover<1->{\node [yellowLarge, right=0.05cm of prognosticequve] (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 prognosticequve] (Boxinfo) {For details, see \\ PALM Flow Chart (VIII).};}
             \path<1-> [linered] (boxlinespace.north) -| (prognosticequca.north);
-            \path<1-> [line] (boxlinespace.north) -| (prognosticequno.north);
+            \path<1-> [line] (boxlinespace.north) -| (prognosticequve.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 [yellow, below=3.1cm of timeintegrspace] (lpm) {lpm};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (lpm.west) ;
+
+            \uncover<1->{\node [yellowLarge, right=0.05cm of lpm] (lpmmore) {user\_lpm\_advec + more};}
+            \path<1-> [line] (lpm.east) -- (lpmmore.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};}
+         \uncover<1->{\node [yellow, below=0.65cm of lpm] (boundconds) {boundary\_conds};}
+         \path<1-> [line,dashed] (boundconds.west) -| (timeintegr.south);
+
+         \uncover<1->{\node [yellow, below=0.05cm of boundconds] (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 [yellow, below=0.05cm of swaptimelevel] (inflowturb) {inflow\_turbulence};}
+         \path<1-> [line,dashed] (inflowturb.west) -| (timeintegr.south);
+
+         \uncover<1->{\node [yellow, below=0.05cm of inflowturb] (distfield) {disturb\_field};}
+         \path<1-> [line,dashed] (distfield.west) -| (timeintegr.south);
 
       \uncover<1->{\node [white2, below=6.6cm of PALM] (continu2) {};}
@@ -372,8 +545,7 @@
 \end{frame}
 
-
-%Folie 08
-\begin{frame}
-   \frametitle{PALM Flow Chart (IV)}
+%Folie 10
+\begin{frame}
+   \frametitle{PALM Flow Chart (VI)}
 
    \tikzstyle{white} = [rectangle, text width=0.2\textwidth, font=\tiny]
@@ -385,4 +557,6 @@
    \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{green} = [rectangle, draw, fill=green!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{greenLarge} = [rectangle, draw, fill=green!20, text width=0.3\textwidth, minimum size=13pt, font=\tiny]
    \tikzstyle{line} = [draw, -]
    \tikzstyle{linered} = [draw, color=red, -]
@@ -417,12 +591,9 @@
             \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};}
+         \uncover<1->{\node [yellowLarge, below=0.8cm of timeintegrspacelarge] (calcliquidwatercontent) {calc\_liquid\_water\_content};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (calcliquidwatercontent.west);
+
+         \uncover<1->{\node [yellow, below=0.9cm of pres] (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};}
@@ -430,11 +601,11 @@
 
          \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,dashed] (timeintegr.south) |- (diffusivities.west);
+
+         \uncover<1->{\node [greenLarge, below=2.88cm 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);
+         \path<1-> [line,dashed] (timeintegr.south) |- (checkforrestart.west);
 
             \uncover<1->{\node [yellow, right=0.05cm of checkforrestart] (localtremain) {local\_tremain};}
@@ -444,21 +615,18 @@
          \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 [green, right=0.05cm of flowstatistics] (userstat) {user\_statistics};}
+            \path<1-> [line] (flowstatistics.east) -- (userstat.west);
+
+         \uncover<1->{\node [yellow, below=0.05cm of flowstatistics] (sumup3d) {sum\_up\_3d\_data};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (sumup3d.west);
+
+            \uncover<1->{\node [greenLarge, right=0.05cm of sumup3d] (user3ddataav) {user\_3d\_data\_averaging};}
+            \path<1-> [line] (sumup3d.east) -- (user3ddataav.west);
+
+         \uncover<1->{\node [yellow, below=0.05cm of sumup3d] (calcspec) {calc\_spectra};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (calcspec.west);
+
+            \uncover<1->{\node [green, right=0.05cm of calcspec] (userspec) {user\_spectra};}
+            \path<1-> [line] (calcspec.east) -- (userspec.west);
 
       \uncover<1->{\node [white2, below=6.6cm of PALM] (continu2) {};}
@@ -470,8 +638,68 @@
 \end{frame}
 
-
-%Folie 09
-\begin{frame}
-   \frametitle{PALM Flow Chart (V)}
+%Folie 11
+\begin{frame}
+   \frametitle{PALM Flow Chart (VII)}
+
+   \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{green} = [rectangle, draw, fill=green!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
+   \tikzstyle{greenLarge} = [rectangle, draw, fill=green!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] (runcontr) {run\_control};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (runcontr.west);
+         \uncover<1->{\node [white, right=0.2cm of runcontr] (runcontrspace) {};}
+
+             \uncover<1->{\node [yellow, below=0.05cm of runcontrspace] (flowstat1) {flow\_statistics};}
+             \path<1-> [line,dashed] (runcontr.south) |- (flowstat1.west);
+
+                \uncover<1->{\node [green, right=0.05cm of flowstat1] (userstat1) {user\_statistics};}
+                \path<1-> [line] (flowstat1.east) |- (userstat1.west);
+
+         \uncover<1->{\node [yellow, below=1cm of timeintegrspace] (print1d) {print\_1d};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (print1d.west);
+
+         \uncover<1->{\node [yellow, below=0.05cm of print1d] (dataoutp) {data\_output\_***};}
+         \path<1-> [line,dashed] (timeintegr.south) |- (dataoutp.west);
+
+         \uncover<1->{\node [greenLarge, below=2.15cm of timeintegrspacelarge] (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 12
+\begin{frame}
+   \frametitle{PALM Flow Chart (VIII)}
 
    \tikzstyle{white} = [rectangle, text width=0.2\textwidth, font=\tiny]
@@ -506,7 +734,7 @@
       \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 [yellowLarge, left=0.5cm of calcmeanptprofile] (prognosticequationsnoopt) {prognostic\_equations\_noopt};}
+      \uncover<1->{\node [yellowLarge, left=0.5cm of calcmeanptprofile] (prognosticequationscache) {prognostic\_equations\_cache};}
+      \uncover<1->{\node [yellowLarge, right=0.5cm of calcmeanptprofile] (prognosticequationsvector) {prognostic\_equations\_vector};}
 
       \uncover<1->{\node [yellow, below=-0.05cm of calcmeanptprofile] (calcradiation) {calc\_radiation};}
@@ -540,50 +768,14 @@
             .\\
             .\\
-            !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\\
+%             !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}{
@@ -621,5 +813,5 @@
 
 
-      \uncover<2->{\node [Endbox, below=6.05cm of redadv] (endbox) {
+      \uncover<2->{\node [Endbox, below=1.5cm of listingscache] (endboxcache) {
          \texttt{\linespread {0.7}\selectfont\noindent
             !within subroutines:\\
@@ -630,16 +822,26 @@
       };}
 
-      \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);}
+      \uncover<2->{\node [Endbox, below=2.5cm of listingsvector] (endboxvec) {
+         \texttt{\linespread {0.7}\selectfont\noindent
+            !within subroutines:\\
+            DO i = nxl, nxr \\
+            \quad DO j = nys, nyn \\
+            \quad \quad DO k=nzb+1,nzt\\
+            \quad \quad \quad \textcolor{blue}{...}\\
+            \quad \quad ENDDO \\
+            \quad ENDDO \\
+            ENDDO\\
+         }
+      };}
+
+      \uncover<2->{\draw [<-,thick] (endboxcache.north) -- (listingscache.south);}
+      \uncover<2->{\draw [<-,thick] (endboxvec.north) -- (listingsvector.south);}
 
    \end{tikzpicture}
 \end{frame}
 
-
-%Folie 10
-\begin{frame}
-   \frametitle{PALM Flow Chart (VI)}
+%Folie 13
+\begin{frame}
+   \frametitle{PALM Flow Chart (IX)}
 
    \tikzstyle{white} = [rectangle, text width=0.2\textwidth, font=\tiny]
@@ -651,4 +853,5 @@
    \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{green} = [rectangle, draw, fill=green!20, text width=0.2\textwidth, minimum size=13pt, font=\tiny]
    \tikzstyle{line} = [draw, -]
    \tikzstyle{linered} = [draw, color=red, -]
@@ -681,5 +884,5 @@
          \path<1-> [line] (write3dbinary.east) -- (writevarlist.west);
 
-      \uncover<1->{\node [yellow, below=0.05cm of write3dbinary] (writeparticles) {write\_particles};}
+      \uncover<1->{\node [yellow, below=0.05cm of write3dbinary] (writeparticles) {lpm\_write\_restart\_file};}
       \path<1-> [line] (PALM.south) |- (writeparticles.west);
 
@@ -687,8 +890,8 @@
       \path<1-> [line] (PALM.south) |- (header.west);
 
-         \uncover<1->{\node [yellow, right=0.05cm of header] (userheader) {user\_header};}
+         \uncover<1->{\node [green, 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};}
+      \uncover<1->{\node [green, below=0.05cm of header] (userlastactions) {user\_last\_actions};}
       \path<1-> [line] (PALM.south) |- (userlastactions.west);
 
@@ -704,5 +907,5 @@
 \end{frame}
 
-%Folie 11
+%Folie 14
 \begin{frame}[fragile]
    \frametitle{Important Variables and Their Declaration}
@@ -731,5 +934,5 @@
 \end{frame}
 
-%Folie 12
+%Folie 15
 \begin{frame}[fragile]
    \frametitle{Important Variables and Their Declaration}
@@ -754,5 +957,5 @@
          \centering
          \begin{lstlisting}
-REAL, DIMENSION(:,:,:), POINTER ::  u, u_m, u_p, ...
+REAL, DIMENSION(:,:,:), POINTER ::  u, u_p, v, v_p, ...
          \end{lstlisting}
       \end{minipage}\\
@@ -762,5 +965,5 @@
 \end{frame}
 
-%Folie 13
+%Folie 16
 \begin{frame}[fragile]
    \frametitle{Some Other Frequently Used Variables}
@@ -796,5 +999,5 @@
 
 
-%Folie 14
+%Folie 17
 \begin{frame}[fragile]
    \frametitle{Preprocessor Directives (I)}
@@ -840,9 +1043,10 @@
 
 
-%Folie 14
+%Folie 18
 \begin{frame}[fragile]
-   \frametitle{Preprocessor Directives (I)}
+   \frametitle{Preprocessor Directives (II)}
    \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<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} in the \texttt{\scriptsize \%cpp\_options} line. \textbf{Different compilers may require different options!}}\\
 
       \item<2->{Define-string switches can be combined using logical AND / OR operators \&\& / $\lvert \lvert$.\\
@@ -861,7 +1065,7 @@
 
 
-%Folie 15
+%Folie 19
 \begin{frame}[fragile]
-   \frametitle{Preprocessor Directives (II)}
+   \frametitle{Preprocessor Directives (III)}
    In the PALM code, define-string switches are used for following reasons:
    \begin{itemize}
@@ -882,7 +1086,7 @@
 
 
-%Folie 15
+%Folie 20
 \begin{frame}[fragile]
-   \frametitle{Preprocessor Directives (II)}
+   \frametitle{Preprocessor Directives (IV)}
    In the PALM code, define-string switches are used for following reasons:
    \begin{itemize}
@@ -898,7 +1102,7 @@
 
 
-%Folie 14
+%Folie 21
 \begin{frame}[fragile]
-   \frametitle{Preprocessor Directives (III)}
+   \frametitle{Preprocessor Directives (V)}
    \begin{itemize}
       \item<1->{Preprocessor directives are also used for string replacement in the code.\\ Example:\\A compiler call with preprocessor option\\
@@ -920,5 +1124,5 @@
          \centering
          \begin{lstlisting}
-%cpp_options -DMPI_REAL=MPI_DOUBLE_PRECISION:
+%cpp_options -cpp:-DMPI_REAL=MPI_DOUBLE_PRECISION:
              -DMPI_2REAL=MPI_2DOUBLE_PRECISION: ....
          \end{lstlisting}
Index: /palm/trunk/TUTORIAL/SOURCE/runs_with_mrun.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/runs_with_mrun.tex	(revision 1225)
+++ /palm/trunk/TUTORIAL/SOURCE/runs_with_mrun.tex	(revision 1226)
@@ -65,11 +65,14 @@
       \texttt{ksh}-syntax) which can be used to compile and run programs, including 
       the handling of input/output files.
-      \vspace{4mm}
+      \vspace{3mm}
       \item<2-> The \texttt{mrun}-command has a number of options to control the 
       program execution\\
+         \vspace{2mm}
          \quad \footnotesize \texttt{mrun -d example\underline{ }cbl -h lcsgih -K parallel -X8 -T2 ...}\\
+         \vspace{2mm}
          \normalsize All options including a short description can be displayed by entering\\
+         \vspace{2mm}
          \quad \footnotesize \texttt{mrun ?}
-      \vspace{4mm}
+      \vspace{3mm}
       \item<3-> \normalsize The shellscript execution is also controlled by a configuration file with default name \texttt{.mrun.config} 
    \end{itemize}
@@ -184,6 +187,6 @@
             \draw<7-> [-] (yellow3.east) -- (yellow4.west);
             
-            \node [dummy, right=0.1cm of yellow4] (dummy1) {};
-            \node [dummy, right=2.055cm of green] (dummy2) {};
+            \node [dummy, right=0.06cm of yellow4] (dummy1) {};
+            \node [dummy, below=0.38cm of dummy1] (dummy2) {};
             
             \draw<9-> [-] (yellow4.east) -- (dummy1.center);
@@ -240,5 +243,5 @@
 \begin{frame}
    \tikzstyle{green} = [rectangle, draw, fill=green!20, 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{yellow} = [rectangle, draw, fill=yellow!20, text width=0.2\textwidth, font=\scriptsize, minimum height=0.6cm]
    \tikzstyle{dummy} = [rectangle, text width=0.01\textwidth, font=\scriptsize, minimum height=0.6cm]
    
@@ -248,10 +251,11 @@
       \setcounter{enumi}{5}
 	   \item<1-> Copy the output files from the working directory to a (permanent) directory of the user:\\
+       \vspace{1mm}
        \tiny \quad \texttt{cp /<tmpdir>/<username>.<randomnumber>/<temporary\underline{ }output\underline{ }file1> <user\underline{ }output\underline{ }file1>}\\
       \quad \texttt{cp /<tmpdir>/<username>.<randomnumber>/<temporary\underline{ }output\underline{ }file2> <user\underline{ }output\underline{ }file2>}\\
       \footnotesize 
       \begin{center}
-	      \begin{tikzpicture}[auto, node distance=0] 
-            \uncover<2->{\node [yellow] (yellow1) {MONITORING/};}
+         \begin{tikzpicture}[auto, node distance=0] 
+            \uncover<2->{\node [yellow] (yellow1) {MONITORING/ };}
 
             \uncover<2->{\node [dummy, right=0.2cm of yellow1] (dummy2) {};}
@@ -264,5 +268,5 @@
             \uncover<2->{\node [yellow, left=0.2cm of yellow4] (yellow5) {current\underline{ }version/};}
                       	                     
-	         \uncover<2-3>{\node [green, left=5.0cm of dummy1] (green) {/$<$tmpdir$>$/$<$username$>$.$<$randomnumber$>$};}
+	         \uncover<2-3>{\node [green, left=4.0cm of dummy1] (green) {/$<$tmpdir$>$/$<$username$>$.$<$randomnumber$>$};}
 	         
             \draw<2-3> [-] (green.east) -- (dummy1.center);
@@ -277,6 +281,6 @@
             \draw<2-> [-] (yellow4.west) -- (yellow5.east);
 	        
-	      \end{tikzpicture}
-	   \end{center}
+	\end{tikzpicture}
+     \end{center}
 	   
 	   \item<3-> Delete the temporary working directory\\
@@ -348,11 +352,15 @@
    \onslide<1-> The \textbf{base name} can additionally be a part of the directory name 
    by using \textcolor{blue}{\texttt{\$fname}} in the directory column of the file connection statement:\\
+   \vspace{1mm}
    \quad \texttt{PARIN in d3\# \~{}/palm/current\underline{ }version/JOBS/\textcolor{blue}{\$fname}/INPUT \underline{ }p3d}\\
-   \ \\
+   \vspace{1mm}
    \onslide<2-> Using the call\\
+   \vspace{1mm}
    \quad \texttt{mrun -d \textcolor{blue}{abcde} ...}\\
+   \vspace{1mm}
    the input file will be expected under\\
+   \vspace{1mm}
    \quad \texttt{\~{}/palm/current\underline{ }version/JOBS/\textcolor{blue}{abcde}/INPUT/\textcolor{blue}{abcde}\underline{ }p3d }\\
-   \ \\
+   \vspace{1mm}
    \onslide<3-> In this way, all files handled by the \texttt{mrun}-call are stored in 
    the same subdirectory (\textcolor{blue}{abcde/}) and will have the same string (\texttt{\textcolor{blue}{abcde}}) as 
@@ -364,4 +372,5 @@
    this at the beginning of the configuration file and be used in the file 
    connection statements:\\
+   \vspace{1mm}
    \quad \texttt{\%base\underline{ }data  \~{}/palm/current\underline{ }version/JOBS}\\
    \quad \texttt{PARIN in d3\#  \textcolor{blue}{\$base\underline{ }data}/\textcolor{blue}{\$fname}/INPUT \underline{ }p3d}\\
@@ -379,19 +388,27 @@
    have to be activated by giving their activation string in the 
    \texttt{mrun}-option \texttt{-r}:\\
+   \vspace{1mm}
    \quad \texttt{PARIN in d3\# \~{}/palm/current\underline{ }version/JOBS/\$fname/INPUT \underline{ }p3d}\\
    \ \\
    \onslide<2-> The permanent file 
+   \vspace{1mm}
    \texttt{\~{}/palm/current\underline{ }version/JOBS/example\underline{ }cbl/INPUT/example\underline{ }cbl\underline{ }p3d} 
+   \vspace{1mm}
    will only be copied to the local file PARIN by using the call:\\
+   \vspace{1mm}
    \quad \texttt{mrun -d example\underline{ }cbl -r \dq d3\#\dq\, ...}\\
    \ \\
    \onslide<3-> \textbf{Example for an output file:}\\
    The file connection statement\\
-   \quad \texttt{DATA\underline{ }1D\underline{ }PR\underline{ }NETCDF out:loc pr\# 
-   \~{}/palm/current\underline{ }version/JOBS/\$fname/OUTPUT \underline{ }pr nc}\\
+   \vspace{1mm}
+   \quad \texttt{DATA\underline{ }1D\underline{ }PR\_NETCDF out:loc pr\# \textbackslash} \\
+   ~~~~~~\texttt{\~{}/palm/current\underline{ }version/JOBS/\$fname/OUTPUT \underline{ }pr nc}s\\
+   \vspace{1mm}
    \onslide<4-> will copy (after program execution) the local file 
    \texttt{DATA\underline{ }1D\underline{ }PR\underline{ }NETCDF} to the permanent file 
+   \vspace{1mm}
    \texttt{\~{}/palm/current\underline{ }version/JOBS/example\underline{ }cbl/OUTPUT/example\underline{ }cbl\underline{ }pr.nc} if
    \texttt{mrun} is called with the options\\
+   \vspace{1mm}
    \quad \texttt{mrun -d example\underline{ }cbl -r \dq d3\# pr\#\dq\, ...}
    
@@ -458,75 +475,76 @@
 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_MASK_01_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m01     nc
-DATA_MASK_01_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m01_av  nc
-DATA_MASK_02_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m02     nc
-DATA_MASK_02_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m02_av  nc
-DATA_MASK_03_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m03     nc
-DATA_MASK_03_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m03_av  nc
-DATA_MASK_04_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m04     nc
-DATA_MASK_04_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m04_av  nc
-DATA_MASK_05_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m05     nc
-DATA_MASK_05_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m05_av  nc
-DATA_MASK_06_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m06     nc
-DATA_MASK_06_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m06_av  nc
-DATA_MASK_07_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m07     nc
-DATA_MASK_07_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m07_av  nc
-DATA_MASK_08_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m08     nc
-DATA_MASK_08_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m08_av  nc
-DATA_MASK_09_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m09     nc
-DATA_MASK_09_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m09_av  nc
-DATA_MASK_10_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m10     nc
-DATA_MASK_10_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m10_av  nc
-DATA_MASK_11_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m11     nc
-DATA_MASK_11_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m11_av  nc
-DATA_MASK_12_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m12     nc
-DATA_MASK_12_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m12_av  nc
-DATA_MASK_13_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m13     nc
-DATA_MASK_13_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m13_av  nc
-DATA_MASK_14_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m14     nc
-DATA_MASK_14_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m14_av  nc
-DATA_MASK_15_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m15     nc
-DATA_MASK_15_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m15_av  nc
-DATA_MASK_16_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m16     nc
-DATA_MASK_16_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m16_av  nc
-DATA_MASK_17_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m17     nc
-DATA_MASK_17_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m17_av  nc
-DATA_MASK_18_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m18     nc
-DATA_MASK_18_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m18_av  nc
-DATA_MASK_19_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m19     nc
-DATA_MASK_19_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m19_av  nc
-DATA_MASK_20_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m20     nc
-DATA_MASK_20_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m20_av  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}
+% 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_MASK_01_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m01     nc
+% DATA_MASK_01_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m01_av  nc
+% DATA_MASK_02_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m02     nc
+% DATA_MASK_02_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m02_av  nc
+% DATA_MASK_03_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m03     nc
+% DATA_MASK_03_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m03_av  nc
+% DATA_MASK_04_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m04     nc
+% DATA_MASK_04_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m04_av  nc
+% DATA_MASK_05_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m05     nc
+% DATA_MASK_05_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m05_av  nc
+% DATA_MASK_06_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m06     nc
+% DATA_MASK_06_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m06_av  nc
+% DATA_MASK_07_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m07     nc
+% DATA_MASK_07_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m07_av  nc
+% DATA_MASK_08_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m08     nc
+% DATA_MASK_08_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m08_av  nc
+% DATA_MASK_09_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m09     nc
+% DATA_MASK_09_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m09_av  nc
+% DATA_MASK_10_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m10     nc
+% DATA_MASK_10_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m10_av  nc
+% DATA_MASK_11_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m11     nc
+% DATA_MASK_11_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m11_av  nc
+% DATA_MASK_12_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m12     nc
+% DATA_MASK_12_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m12_av  nc
+% DATA_MASK_13_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m13     nc
+% DATA_MASK_13_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m13_av  nc
+% DATA_MASK_14_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m14     nc
+% DATA_MASK_14_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m14_av  nc
+% DATA_MASK_15_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m15     nc
+% DATA_MASK_15_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m15_av  nc
+% DATA_MASK_16_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m16     nc
+% DATA_MASK_16_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m16_av  nc
+% DATA_MASK_17_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m17     nc
+% DATA_MASK_17_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m17_av  nc
+% DATA_MASK_18_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m18     nc
+% DATA_MASK_18_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m18_av  nc
+% DATA_MASK_19_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m19     nc
+% DATA_MASK_19_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m19_av  nc
+% DATA_MASK_20_NETCDF    out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m20     nc
+% DATA_MASK_20_AV_NETCDF out:loc:tr ma#:maf   $base_data/$fname/OUTPUT  _m20_av  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{frame}
 
 % Folie 12
 \begin{frame}
-   \frametitle{Additional Features of \texttt{mrun}}
+   \frametitle{Additional Features of \texttt{mrun} (I)}
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!30, text width=1.15\textwidth, font=\Tiny]
    \begin{itemize}
       \footnotesize
@@ -535,12 +553,52 @@
       \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}
+   \onslide<4->{\hspace{-0.95cm}\begin{tikzpicture}[auto]
+         \node[yellow]{\texttt{\%sgi\_feature \hspace{0.53cm} ice2 \hspace{2.71cm} lcsgih parallel}\\
+                       \texttt{\%modules \hspace{0.87cm}  intel.compiler/11.1.072:mpt:phdf5/1.8.5-mpt-intel-11.1:pnetcdf/4.1.1-mpt-intel-11.1 \quad\quad lcsgih parallel}\\
+                       \texttt{\%login\_init\_cmd \hspace{0.25cm} .:/usr/share/modules/init/bash  \quad\quad lcsgih parallel}\\
+                       \texttt{\#\%remote\_username \hspace{0.07cm} <replace by your HLRN username> \quad\quad lcsgih parallel}\\
+                       \texttt{\%compiler\_name \hspace{0.35cm} ifort \hspace{2.61cm} lcsgih parallel}\\
+                       \texttt{\%compiler\_name\_ser~ ifort \hspace{2.61cm} lcsgih parallel}\\
+                       \texttt{\%cpp\_options \hspace{0.53cm} -DMPI\_REAL=MPI\_DOUBLE\_PRECISION:-DMPI\_2REAL=MPI\_2DOUBLE\_PRECISION:-D\_\_netcdf:-D\_\_netcdf4:-D\_\_mpi2 \quad lcsgih parallel}\\
+                       \texttt{\%netcdf\_inc \hspace{0.62cm} -I:/sw/dataformats/pnetcdf/netcdf-4.1.1-mpt-intel-11.1/include:-I:/sw/dataformats/phdf5/hdf5-1.8.5-mpt-intel-11.1/in}\\ %clude    lcsgih parallel}\\
+                       \texttt{\%netcdf\_lib \hspace{0.62cm} -L/sw/dataformats/pnetcdf/netcdf-4.1.1-mpt-intel-11.1/lib:-lnetcdf:-lnetcdff:-L/sw/dataformats/phdf5/hdf5-1.8.5-mpt-}\\ %intel-11.1/lib:-lhdf5:-lhdf5\_hl:-lz      lcsgih parallel}\\
+                       \texttt{\%mopts \hspace{1.06cm} -j:4 \hspace{2.71cm} lcsgih parallel}\\
+                       \texttt{\%fopts \hspace{1.06cm} -fpe0:-O3:-cpp:-r8:-fp-model:precise:-align:all:-ftz:-fno-alias:-no-scalar-rep:-no-prec-div:-no-prec-sqrt:-ip:-nbs:}\\ %-convert:little\_endian:-diag-disable:8290,8291  lcsgih parallel}\\
+                       \texttt{\%lopts \hspace{1.06cm} -fpe0:-O3:-cpp:-r8:-fp-model:precise:-align:all:-ftz:-fno-alias:-no-scalar-rep:-no-prec-div:-no-prec-sqrt:-ip:-nbs:-}\\ %Vaxlib:-lmpi:-limf:-lm           lcsgih parallel}\\
+                       \texttt{\%memory \hspace{0.97cm} 1500 \hspace{2.71cm} lcsgih parallel}\\
+                       \texttt{\#\%tmp\_data\_catalog~  /gfs2/work/<replace by your HLRN username>/palm\_restart\_data \quad\quad lcsgih parallel}\\
+                       \texttt{\#\%tmp\_user\_catalog~  /gfs2/tmp/<replace by your HLRN username> \hspace{2.03cm} lcsgih parallel}};
+   \end{tikzpicture}}
+%  \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}
+
+\begin{frame}
+   \frametitle{Additional Features of \texttt{mrun} (II)}
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!30, text width=0.75\textwidth, font=\Tiny]
+
    \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).
+      \item<1-> 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.
+      \begin{center}
+         \onslide<2->{\begin{tikzpicture}
+            \node[yellow]{~\texttt{IC:echo ``PALM will soon start to execute in \textbackslash\$PWD'' > /home/h/niksiraa/mrun\_messages}\\
+                          ~\texttt{EC:ls -al}\\
+                          \vspace{0.5mm}
+                          ~\texttt{OC:tar -cf DEBUG.tar DEBUG\_*}};
+         \end{tikzpicture}}
+      \end{center}
+
+%      \onslide<2-> \includegraphics[scale=0.3]{mrun_figures/add_feat2.png}
+      \item<3-> Automatic generation of restart jobs.
    \end{itemize}
+
 \end{frame}
 
@@ -595,4 +653,5 @@
    \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{yellow2} = [rectangle, draw, fill=yellow!20, text width=0.4\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]
@@ -624,5 +683,5 @@
     \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\underline{ }queue \\ tail lcmuk\underline{ }example\underline{ }cbl}
+       \texttt{cd \~{}/job\underline{ }queue \\ tail lcmuk\underline{ }example\underline{ }cbl}
     };
 }
@@ -636,9 +695,9 @@
     \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\underline{ }queue \\ cat last\underline{ }job\underline{ }transfer\underline{ }protocol}
+       \texttt{cd \~{}/job\underline{ }queue \\ cat last\underline{ }job\underline{ }transfer\underline{ }protocol}
     };
 }
 \uncover<7->{
-    \node [dummy, left=0.5cm of fifth] (dummy) {
+    \node [dummy, left=0.001mm of fifth] (dummy) {
        transfer results by \texttt{scp} \\
        \ \\
@@ -647,7 +706,7 @@
 }
 \uncover<8->{
-    \node [yellow, left=3.5cm of fifth] (sixth) {
+    \node [yellow2, left=2.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\underline{ }queue \\ ls -al \\ cd ~/palm/current\underline{ }version/JOBS/example \\ ls -al *}
+       \texttt{cd \~{}/job\_queue \\ ls -al \\ cd \~{}/palm/current\_version/JOBS/example \\ ls -al *}
     };
 }
Index: /palm/trunk/TUTORIAL/SOURCE/sgs_models.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/sgs_models.tex	(revision 1225)
+++ /palm/trunk/TUTORIAL/SOURCE/sgs_models.tex	(revision 1226)
@@ -94,5 +94,5 @@
 \begin{frame}
    \frametitle{SGS Models (III)}
-   \onslide<1-> All the above observation suggest the use of an eddy viscosity type SGS model:
+   \onslide<1-> All the above observations suggest the use of an eddy viscosity type SGS model:
    \begin{footnotesize}
       \begin{itemize}
@@ -104,14 +104,15 @@
       \end{itemize}
    \end{footnotesize}
+   \vspace{-0.3cm}
    \onslide<3->Now we need a model for the eddy viscosity:
    \begin{footnotesize}
       \begin{itemize}
          \item<4-> Dimensionality of $\nu_T$ is $l^2/t$
-         \item<5-> Obvious choice: $\nu_T = Cql$ \hspace{5mm} (q, l: characterictic velocity / length scale)
+         \item<5-> Obvious choice: $\nu_T = Cql$ \hspace{5mm} (q, l: characteristic velocity / length scale)
          \item<6-> Turbulence length scale is easy to define: largest size of the unresolved scales is $\Delta$ \hspace{10mm} $l = \Delta$
          \item<7-> Velocity scale not obvious (smallest resolved scales, their size is of the order of the variation of velocity over one grid element)
          \begin{flalign*}
             &q = l \frac{\partial \overline{u}}{\partial x} = l \overline{S}& \text{for 3D: } \overline{S} = \sqrt{2 \overline{S}_{ki}\,\overline{S}_{ki}} \hspace{15mm} \\
-            & & \text{characterictic filtered rate of strain}\hspace{15mm}
+            & & \text{characteristic filtered rate of strain}\hspace{15mm}
          \end{flalign*}
       \end{itemize}
@@ -163,35 +164,8 @@
 \end{frame}
 
-
-% Folie 7
-\begin{frame}
-   \frametitle{The Smagorinsky Model: Performance}
-   \begin{itemize}
-      \item<2-> Predicts many flows reasonably well
-      \item<3-> Problems:
-      \begin{itemize}
-         \item<3-> Optimum parameter value varies with flow type:
-         \begin{itemize}
-            \item Isotropic turbulence: $C_S \approx 0.2$\\
-            \item Shear (channel) flows: $C_S \approx 0.065$
-         \end{itemize}
-         \item<4-> Length scale uncertain with anisotropic filter:
-         \begin{equation*}
-            (\Delta_x \Delta_y \Delta_z)^{1/3} \hspace{5mm} (\Delta_x + \Delta_y + \Delta_z)/3
-         \end{equation*}
-         \item<5-> Needs modification to account for:
-         \begin{itemize}
-            \item stratification: $C_S = F(Ri,...)$, $Ri$: Richardson number\\
-            \item near-wall region: $C_S = F(z+)$, $z+$: distance from wall
-         \end{itemize}
-      \end{itemize}
-   \end{itemize}
-\end{frame}
-
-
 \section{Deardoff Modification}
 \subsection{Deardoff Modification}
 
-% Folie 8
+% Folie 7
 \begin{frame}
    \frametitle{Deardorff (1980) Modification (Used in PALM) (I)}
@@ -199,8 +173,10 @@
    \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.}
+   \small
+   \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} 
+   \small
    \onslide<3->{
       $ C_M = const. = 0.1 $
@@ -210,10 +186,10 @@
                           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
+      \small
       \par\bigskip
       $ \Delta = \left( \Delta x \Delta y \Delta z \right)^{1/3} $ }
 \end{frame}
 
-% Folie 9
+% Folie 8
 \begin{frame}
    \frametitle{Deardorff (1980) Modification (Used in PALM) (II)}
@@ -236,5 +212,5 @@
 \end{frame}
 
-% Folie 10
+% Folie 9
 \begin{frame}
    \frametitle{Deardorff (1980) Modification (Used in PALM) (III)}
@@ -261,39 +237,39 @@
 \subsection{Summary / Important Points for Beginners}
 
-% Folie 11
+% 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}
+      \includegraphics<2-7|handout:0>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_2.png}   
+      \includegraphics<8|handout:0>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_8.png}
+      \includegraphics<9|handout:0>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_9.png}
+      \includegraphics<10|handout:1>[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}
+      \includegraphics<8-10|handout:1>[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}}
+      \onslide<8-|handout:1>{\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}}}
+      \onslide<9-|handout:1>{\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}
+      \includegraphics<8-10|handout:1>[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_neu.png}
-      \includegraphics<3>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_3_neu.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}
+      \includegraphics<1-2|handout:0>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_1_neu.png}
+      \includegraphics<3|handout:0>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_3_neu.png}
+      \includegraphics<4|handout:0>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_4.png}
+      \includegraphics<5-10|handout:1>[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_neu.png}
-      \uncover<7->{\includegraphics[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_7_neu.png}}       
+      \includegraphics<6|handout:0>[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_6_neu.png}
+      \uncover<7-|handout:1>{\includegraphics[width=\textwidth]{sgs_models_figures/Important_Points/Important_Points_1_7_neu.png}}       
    \end{columns}
 \end{frame}
 
-% Folie 12
+% Folie 11
 \begin{frame}
    \frametitle{Summary / Important Points for Beginners (II)}
@@ -315,20 +291,20 @@
 \subsection{Example Output}
 
+% Folie 12
+\begin{frame}
+   \frametitle{Example Output (I)}
+   \begin{itemize}
+      \item{LES of a convective boundary layer}
+   \end{itemize}
+   \includegraphics<1|handout:0>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_1.png}
+   \includegraphics<2|handout:0>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_2.png}
+   \includegraphics<3|handout:0>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_3.png}
+   \includegraphics<4|handout:0>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_4.png}
+   \includegraphics<5|handout:0>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_5.png}
+   \includegraphics<6|handout:0>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_6.png}
+   \includegraphics<7|handout:1>[width=\textwidth]{sgs_models_figures/Example_Output_1/Example_Output_1_7.png}
+\end{frame}
+
 % Folie 13
-\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 14
 \begin{frame}
    \frametitle{Example Output (II)}
@@ -342,5 +318,5 @@
 \end{frame}
 
-% Folie 15
+% Folie 14
 \begin{frame}
    \frametitle{Some Symbols}
Index: /palm/trunk/TUTORIAL/SOURCE/topography.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/topography.tex	(revision 1225)
+++ /palm/trunk/TUTORIAL/SOURCE/topography.tex	(revision 1226)
@@ -216,9 +216,9 @@
 %      \includegraphics[width=0.6\textwidth]{topography_figures/technical_implementation_grid/technical_implementation_grid_small3.png}
    \column{0.6\textwidth}
-      \includegraphics<1>[width=\textwidth]{topography_figures/technical_implementation_grid/technical_implementation_grid_1.png}
-      \includegraphics<2>[width=\textwidth]{topography_figures/technical_implementation_grid/technical_implementation_grid_2.png}
-      \includegraphics<3>[width=\textwidth]{topography_figures/technical_implementation_grid/technical_implementation_grid_3.png}
-      \includegraphics<4>[width=\textwidth]{topography_figures/technical_implementation_grid/technical_implementation_grid_4.png}
-      \includegraphics<5>[width=\textwidth]{topography_figures/technical_implementation_grid/technical_implementation_grid_5.png}
+      \includegraphics<1|handout:0>[width=\textwidth]{topography_figures/technical_implementation_grid/technical_implementation_grid_1.png}
+      \includegraphics<2|handout:0>[width=\textwidth]{topography_figures/technical_implementation_grid/technical_implementation_grid_2.png}
+      \includegraphics<3|handout:0>[width=\textwidth]{topography_figures/technical_implementation_grid/technical_implementation_grid_3.png}
+      \includegraphics<4|handout:0>[width=\textwidth]{topography_figures/technical_implementation_grid/technical_implementation_grid_4.png}
+      \includegraphics<5|handout:1>[width=\textwidth]{topography_figures/technical_implementation_grid/technical_implementation_grid_5.png}
    \end{columns}
 \end{frame}
@@ -234,5 +234,5 @@
       \item{The layout of example\_topo must conform to the computational domain size and to the grid size dx and dy.}
       \item{The rastered height data of example\_topo are given in m above ground and do not need to match
-            the vertical grid, since they are interpolated.}
+            the vertical grid, since they will be interpolated, if required.}
       \par\bigskip
       \item{Software known to be able to perfom the rastering process of GIS data in vector and/or raster format to PALM raster format:}
@@ -259,9 +259,10 @@
          \end{itemize}
       \end{itemize}     
-      \item{\dq 2 $\Delta$x\dq instabilities}
+      \item{\dq 2 $\Delta$x\dq instabilities (only if Piacsek-Williams advection scheme is used)}
       \begin{itemize}
          \item{Upstream of obstacle walls}
          \item{Due to second-order finite difference advection scheme}
          \item{Model remains stable throughout the simulation}
+         \item{The default Wicker-Skamarock scheme does not show any instabilities}
       \end{itemize}
    \end{itemize}
@@ -332,8 +333,8 @@
       \item{{\tt '\textcolor{blue}{cell\_center}'} \hspace{1.9cm} default for \textcolor{blue}{rastered} topography: \textcolor{blue}{$\bigcirc$ $\leftrightarrow$}} 
    \end{itemize}
-   \includegraphics<1>[width=0.5\textwidth]{topography_figures/control_parameters_1.png}
-   \includegraphics<2>[width=0.5\textwidth]{topography_figures/control_parameters_2.png}
-   \includegraphics<3>[width=0.5\textwidth]{topography_figures/control_parameters_3.png}
-   \includegraphics<4>[width=0.5\textwidth]{topography_figures/control_parameters_4.png}
+   \includegraphics<1|handout:0>[width=0.5\textwidth]{topography_figures/control_parameters_1.png}
+   \includegraphics<2|handout:0>[width=0.5\textwidth]{topography_figures/control_parameters_2.png}
+   \includegraphics<3|handout:0>[width=0.5\textwidth]{topography_figures/control_parameters_3.png}
+   \includegraphics<4|handout:1>[width=0.5\textwidth]{topography_figures/control_parameters_4.png}
 \end{frame}
 
@@ -595,7 +596,7 @@
    We are unable to check all these combinations by ourselves and rely on your help!
    \par\bigskip
-   For example, the combination of topography and non-cyclic lateral boundary conditions has not yet been tested 
-   because both features have originally been introduced separately for different research projects.
-   \par\bigskip 
+%    For example, the combination of topography and non-cyclic lateral boundary conditions has not yet been tested 
+%    because both features have originally been introduced separately for different research projects.
+%    \par\bigskip 
    Therefore, we ask you for your responsibility and contribution:
    \begin{itemize}
Index: /palm/trunk/TUTORIAL/SOURCE/user_defined_code.tex
===================================================================
--- /palm/trunk/TUTORIAL/SOURCE/user_defined_code.tex	(revision 1225)
+++ /palm/trunk/TUTORIAL/SOURCE/user_defined_code.tex	(revision 1226)
@@ -15,6 +15,6 @@
 \usepackage{tikz}
 \usetikzlibrary{shapes,arrows,positioning}
-\usetikzlibrary{decorations.markings}             %neues paket
-\usetikzlibrary{decorations.pathreplacing}        %neues paket
+%\usetikzlibrary{decorations.markings}             %neues paket
+%\usetikzlibrary{decorations.pathreplacing}        %neues paket
 \def\Tiny{\fontsize{4pt}{4pt}\selectfont}
 \usepackage{amsmath}
@@ -70,5 +70,5 @@
    \textbf{Problem:}
    \begin{itemize}
-      \item<3-> If a new PALM version is released (current release is 3.8) and the user wants to use it, he would have to add his modifications to the new release again.
+      \item<3-> If a new PALM version is released (current release is 3.9) and the user wants to use it, he would have to add his modifications to the new release again.
    \end{itemize}   
    \vspace{3mm}
@@ -85,4 +85,5 @@
 \begin{frame}
    \frametitle{General Structure of the User-Interface}
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!30, text width=0.7\textwidth, font=\Tiny]
    \scriptsize
    \begin{itemize}
@@ -92,6 +93,40 @@
    \end{itemize}
    \onslide<3->
-   \centering
-   \includegraphics[scale=0.3]{user_defined_code_figures/user_last_actions.png}\\   
+   \begin{center}
+   \begin{tikzpicture}[auto]
+      \node[yellow]{~\texttt{SUBROUTINE user\_last\_actions} \\
+                    \par\medskip
+                    \texttt{!------------------------------------------------------------------------------!}\\
+                    \texttt{!}\\
+                    \texttt{! Description:}\\
+                    \texttt{! ------------}\\
+                    \texttt{! Execution of user-defined actions at the end of a job.}\\
+                    \texttt{!------------------------------------------------------------------------------!}\\
+                    \par\medskip
+                    ~~~~\texttt{USE control\_parameters}\\
+                    ~~~~\texttt{USE user}\\
+                    \par\medskip
+                    ~~~~\texttt{IMPLICIT NONE}\\
+                    \par\medskip
+                    \texttt{!}\\
+                    \texttt{!-- Here the user-defined actions at the end of a job follow.}\\
+                    \texttt{!-- Sample for user-defined output:}\\
+                    \vspace{0.5mm}
+                    ~~~~\texttt{IF ( write\_binary(1:4) == 'true' )  THEN}\\
+                    \vspace{0.5mm}
+                    \texttt{!~~~~~~~IF ( ALLOCATED( u2\_av ) )  THEN}\\
+                    \vspace{0.5mm}
+                    \texttt{!~~~~~~~~~~WRITE ( 14 )  'u2\_av~~~~~~~~~~~~~~~';  WRITE ( 14 )  u2\_av}\\
+                    \vspace{0.5mm}
+                    \texttt{!~~~~~~~ENDIF}\\
+                    \par\medskip
+                    ~~~~~~~\texttt{WRITE ( 14 )  '*** end user ***~~~~'}\\
+                    \par\medskip
+                    ~~~~\texttt{ENDIF}\\
+                    \par\medskip
+                    ~\texttt{END SUBROUTINE user\_last\_actions}};
+   \end{tikzpicture}
+   \end{center}
+%   \includegraphics[scale=0.3]{user_defined_code_figures/user_last_actions.png}\\   
 \end{frame}
 
@@ -99,4 +134,5 @@
 \begin{frame}
    \frametitle{Embedding of User-Interface Routines}
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!30, text width=0.7\textwidth, font=\Tiny]
    \scriptsize
    \begin{itemize}
@@ -106,6 +142,50 @@
    \end{itemize}
    \onslide<2->
-   \centering
-   \includegraphics[scale=0.33]{user_defined_code_figures/embedding.png}\\
+   \begin{center}
+      \begin{tikzpicture}[auto]
+         \node[yellow]{~\texttt{...}\\
+                       \vspace{0.5mm}
+                       \texttt{!}\\
+                       \texttt{!-- If required, final user-defined actions, and}\\
+                       \texttt{!-- last actions on the open files and close files. Unit 14 was opened}\\
+                       \texttt{!-- in write\_3d\_binary but it is closed here, to allow writing on this}\\
+                       \texttt{!-- unit in routine user\_last\_actions.}\\
+                       \vspace{0.5mm}
+                       ~~~~\texttt{CALL cpu\_log( log\_point(4), 'last actions', 'start' )}\\
+                       ~~~~\texttt{DO  i = 0, io\_blocks-1}\\
+                       ~~~~~~~\texttt{IF ( i == io\_group )  THEN}\\
+                       ~~~~~~~~~~\texttt{\textcolor{blue}{CALL user\_last\_actions}}\\
+                       \vspace{0.5mm}
+                       ~~~~~~~~~~\texttt{IF ( write\_binary(1:4) == 'true' )  CALL close\_file( 14 )}\\
+                       ~~~~~~~\texttt{ENDIF}\\
+                       \vspace{0.5mm}
+                       \texttt{\#if defined( \_\_parallel )}\\
+                       ~~~~~~~\texttt{CALL MPI\_BARRIER( comm2d, ierr )}\\
+                       \vspace{0.5mm}
+                       \texttt{\#endif}\\
+                       \vspace{0.5mm}
+                       ~~~~\texttt{ENDDO}\\
+                       \vspace{0.5mm}
+                       ~~~~\texttt{CALL close\_file( 0 )}\\
+                       \vspace{0.5mm}
+                       ~~~~\texttt{CALL close\_dvrp}\\
+                       ~~~~\texttt{CALL cpu\_log( log\_point(4), 'last actions', 'stop' )}\\
+                       \vspace{1mm}
+                       ~\texttt{...}\\
+                       \vspace{1mm}
+                       \texttt{!}\\
+                       \texttt{!-- Take final CPU-time for CPU-time analysis}\\
+                       ~~~~\texttt{CALL cpu\_log( log\_point(1), 'total', 'stop' )}\\
+                       ~~~~\texttt{CALL cpu\_statistics}\\
+                       \texttt{\#if defined( \_\_parallel )}\\
+                       ~~~~\texttt{CALL MPI\_FINALIZE( ierr )}\\
+                       \vspace{0.5mm}
+                       \texttt{\#endif}\\
+                       \par\medskip
+                       ~\texttt{END PROGRAM palm}};
+      \end{tikzpicture} 
+   \end{center}
+
+%   \includegraphics[scale=0.33]{user_defined_code_figures/embedding.png}\\
 \end{frame}
 
@@ -119,70 +199,79 @@
       % Define colours
       \tikzstyle{green} = [draw, fill=green!30, text width=7.1em, text centered, minimum height=1.6em]
+      \tikzstyle{green1} = [draw, fill=green!30, text width=12em, text centered, minimum height=1.6em]
+      \tikzstyle{green2} = [draw, fill=green!30, text width=10em, text centered, minimum height=1.6em]
       \tikzstyle{yellow} = [draw, fill=yellow!30, text width=7.1em, text centered, minimum height=1.6em]
       \tikzstyle{orange} = [draw, fill=orange!60, text width=7.1em, text centered]
       
       % Define coordinates and draw nodes      
-      \node[green, text width=5em] (PALM) at (0,0.1) {PALM};
+      \node[yellow, text width=5em] (PALM) at (0,0.1) {PALM};
 
       \coordinate (A) at (0,-0.7);
-
-      \node[green, right=0.6cm of A] (parin) {parin};
-      
-      \coordinate[below=0.3cm of parin] (B);
-      \coordinate[below=0.9cm of parin] (C);
-      \coordinate[below=1.5cm of parin] (D);
-      
-      \node[green, right=0.6cm of B] (read) {read\_var\_list};
-      \node[green, right=0.6cm of C] (package) {package\_parin};
-      \node[yellow, right=0.6cm of D] (userparin) {user\_parin};
-      
-      \coordinate[below=3cm of PALM] (E);      
-      \coordinate[below=3.6cm of PALM] (F);    
-      \coordinate[below=4.2cm of PALM] (G);      
-      \coordinate[below=4.8cm of PALM] (H); 
-      \coordinate[below=5.6cm of PALM] (I); 
-      \coordinate[below=7.4cm of PALM] (J);             
-                
-      \node[green, right=0.6cm of E] (initpegrid) {init\_pegrid};      
-      \node[green, right=0.6cm of F] (initgrid) {init\_grid}; 
-      \node[yellow, right=0.9cm of initgrid] (userinitgrid) {user\_init\_grid}; 
-      
-      \node[green, right=0.6cm of G] (checkparameters) {check\_parameters};       
-      \node[yellow, right=0.9cm of checkparameters, text width=9.5em] (usercheckdataoutput) {user\_check\_data\_output}; 
-      \node[green, right=0.6cm of H] (header) {header}; 
-      \node[green, right=0.6cm of I] (init3dmodel) {init\_3d\_model};       
-      \node[yellow, right=0.9cm of header] (userheader) {user\_header}; 
-            
-      \node[orange, right=0.6cm of J] (timeint) {time\_integration};       
-      
-      \coordinate[below=0.3cm of init3dmodel] (K);   
-      \coordinate[below=0.9cm of init3dmodel] (L);        
-      
-      \node[green, right=0.6cm of K] (initparticles) {init\_particles};       
-      \node[yellow, right=0.9cm of initparticles] (userinitparticles) {user\_init\_particles};   
-      \node[yellow, right=0.6cm of L] (userinit) {user\_init};       
-     
-      % Draw lines
-      \draw[-, thick] (PALM) -- (0,-7.8); 
-      \draw[dotted, thick] (0,-8.2) -- (0,-7.8);
-      \draw[-, thick] (A) -- (parin);
-      \draw[-, thick] (parin) -- (D);  
-      \draw[dashed, thick] (B) -- (read);
-      \draw[dashed, thick] (C) -- (package);
-      \draw[-, thick] (D) -- (userparin); 
-      \draw[-, thick] (E) -- (initpegrid);
-      \draw[-, thick] (F) -- (initgrid);
-      \draw[-, thick] (G) -- (checkparameters);
-      \draw[-, thick] (H) -- (header);
-      \draw[-, thick] (I) -- (init3dmodel);
-      \draw[-, thick] (J) -- (timeint);
-      \draw[dotted, thick] (init3dmodel) -- (K);
-      \draw[-, thick] (K) -- (L);
-      \draw[dashed, thick] (K) -- (initparticles);
-      \draw[-, thick] (L) -- (userinit);
-      \draw[-, thick] (initgrid) -- (userinitgrid);      
-      \draw[-, thick] (checkparameters) -- (usercheckdataoutput);      
-      \draw[-, thick] (header) -- (userheader);      
-      \draw[-, thick] (initparticles) -- (userinitparticles);      
+      \node[yellow, right=0.6cm of A] (parin) {parin};
+
+      \node[green, right=1mm of parin] (userparin) {user\_parin};
+      \draw[-] (parin) -- (userparin);
+
+      \coordinate[below=0.6cm of A] (B);
+      \node[yellow, right=0.6cm of B] (initgrid) {init\_grid};
+
+      \node[green, right=1mm of initgrid] (userinigrid) {user\_init\_grid};
+      \draw[-] (initgrid) -- (userinigrid);
+
+      \coordinate[below=0.6cm of B] (C);
+      \node[yellow, right=0.6cm of C] (checkparam) {check\_parameters};
+
+      \coordinate[below=0.3cm of checkparam] (D);
+      \node[green1, right=0.6cm of D] (usercheckdataout) {user\_check\_data\_output/\_pr};
+
+      \coordinate[below=0.55cm of D] (E);
+      \node[green1, right=0.6cm of E] (usercheckparam) {user\_check\_parameters};
+
+      \coordinate[below=1.7cm of C] (F);
+      \node[yellow, right=0.6cm of F] (init3dmodel) {init\_3d\_model};
+
+      \coordinate[below=0.3cm of init3dmodel] (G);
+      \node[green2, right=0.6cm of G] (userinit3d) {user\_init\_3d\_model};
+
+      \coordinate[below=0.55cm of G] (H);
+      \node[yellow, right=0.6cm of H] (read3dbin) {read\_3d\_binary};
+
+      \coordinate[below=0.3cm of read3dbin] (I);
+      \node[green1, right=0.6cm of I] (userreadrestart) {user\_read\_restart\_data};
+
+      \coordinate[below=1.15cm of H] (J);
+      \node[green1, right=0.6cm of J] (userinitplan) {user\_init\_plant\_canopy};
+
+      \coordinate[below=0.6cm of J] (K);
+      \node[yellow, right=0.6cm of K] (lpminit) {lpm\_init};
+
+      \node[green, right=1mm of lpminit] (userlpminit) {user\_lpm\_init};
+      \draw[-] (lpminit) -- (userlpminit);      
+
+      \coordinate[below=0.6cm of K] (L);
+      \node[green, right=0.6cm of L] (userinit) {user\_init};
+
+      \coordinate[below=4.05cm of F] (M);
+      \node[yellow, right=0.6cm of M] (header) {header};
+
+      \node[green, right=1mm of header] (userheader) {user\_header};
+      \draw[-] (header) -- (userheader);      
+%      
+       % Draw lines
+       \draw[-, thick] (PALM) -- (0,-7.8); 
+       \draw[dotted, thick] (0,-8.2) -- (0,-7.8);
+       \draw[-] (A) -- (parin);
+       \draw[-] (B) -- (initgrid);
+       \draw[-] (C) -- (checkparam); 
+       \draw[-] (checkparam.south) |- (usercheckdataout.west); 
+       \draw[-] (checkparam.south) |- (usercheckparam.west); 
+       \draw[-] (F) -- (init3dmodel);
+       \draw[-,dashed] (init3dmodel.south) |- (userinit3d.west);
+       \draw[-,dashed] (init3dmodel.south) |- (read3dbin.west);
+       \draw[-] (read3dbin.south) |- (userreadrestart.west);
+       \draw[-,dashed] (init3dmodel.south) |- (userinitplan);
+       \draw[-,dashed] (init3dmodel.south) |- (lpminit);
+       \draw[-] (init3dmodel.south) |- (userinit);
+       \draw[-] (M) -- (header);   
       
    \end{tikzpicture}
@@ -197,4 +286,5 @@
       % Define colours
       \tikzstyle{green} = [draw, fill=green!30, text width=7.1em, text centered, minimum height=1.6em]
+      \tikzstyle{green1} = [draw, fill=green!30, text width=10em, text centered, minimum height=1.6em]
       \tikzstyle{yellow} = [draw, fill=yellow!30, text width=7.1em, text centered, minimum height=1.6em]
       \tikzstyle{orange} = [draw, fill=orange!60, text width=7.1em, text centered]
@@ -214,5 +304,5 @@
       \coordinate[right=3.8cm of D] (E);
                  
-      \node[yellow, right=0.6cm of B, text width=14em] (useractions1) {\textcolor{blue}{user\_actions\_(\textit{'before\_timestep'})}};    
+      \node[green, right=0.6cm of B, text width=14em] (useractions1) {\textcolor{blue}{user\_actions\_(\textit{'before\_timestep'})}};    
          
       \node[orange1, below=0.2cm of D] (progeq) {prognostic\_equations};    
@@ -220,5 +310,5 @@
       \node[draw, fill=red, text width=4em] at (8.6,-0.8) {\textcolor{white}{standard advection}};
                 
-      \node[yellow, right=0.3cm of progframe, text width=14em] (useractions2) {\textcolor{blue}{user\_actions\_(\textit{'*\_tendency'})}}; 
+      \node[green, right=0.3cm of progframe, text width=14em] (useractions2) {\textcolor{blue}{user\_actions\_(\textit{'*\_tendency'})}}; 
       
       
@@ -229,10 +319,10 @@
 
                               
-      \node[green, right=0.6cm of F] (advecparticles) {advec\_particles}; 
-      \node[yellow, right=0.9cm of advecparticles, text width=10em] (userparticlesattributes) {user\_particles\_attributes}; 
-      \node[green, right=0.6cm of G] (exchangehoriz) {exchange\_horiz};  
-      \node[green, right=0.0cm of exchangehoriz] (asselin) {asselin\_filter};     
-      \node[green, right=0.6cm of H] (swaptimelevel) {swap\_timelevel}; 
-      \node[green, right=0.6cm of I] (pres) {pres};
+      \node[yellow, right=0.6cm of F] (lpm) {lpm}; 
+      \node[green, right=0.9cm of lpm, text width=10em] (userlpmadvec) {user\_lpm\_advec}; 
+      \node[yellow, right=0.6cm of G] (exchangehoriz) {exchange\_horiz};  
+%      \node[yellow, right=0.0cm of exchangehoriz] (asselin) {asselin\_filter};     
+      \node[yellow, right=0.6cm of H] (swaptimelevel) {swap\_timelevel}; 
+      \node[yellow, right=0.6cm of I] (pres) {pres};
       
       \coordinate[below=0.3cm of pres] (J);    
@@ -244,22 +334,25 @@
       \coordinate[below=8.8cm of timeint] (P);     
                   
-      \node[green, right=0.6cm of K] (prandtlfluxes) {prandtl\_fluxes};    
-      \node[yellow, right=0.6cm of L, text width=14em] (useractions3) {\textcolor{blue}{user\_actions\_(\textit{'after\_integration'})}};             
-      \node[green, right=0.6cm of M] (diffusivities) {diffusivities};              
-      \node[green, right=0.0cm of diffusivities] {check\_for\_restart};      
-      \node[green, right=0.6cm of N] (flowstat) {flow\_statistics};
-      \node[green, right=0.0cm of flowstat] (runcontrol) {run\_control};  
-      \node[yellow, below=0.2cm of flowstat] (userstat) {user\_statistics};  
-      \node[yellow, right=0.6cm of O, text width=14em] (useractions4) {\textcolor{blue}{user\_actions\_(\textit{'after\_timestep'})}}; 
-      \node[green, right=0.6cm of P] (timestep) {timestep};             
-
-      \node[green, right=0.2cm of runcontrol] (dataoutput) {data\_output\_***};
-      \node[yellow, right=0.2cm of dataoutput] (userdvrpcoltab) {user\_dvrp\_coltab};
+%      \node[yellow, right=0.6cm of K] (prandtlfluxes) {prandtl\_fluxes};    
+      \node[green, right=0.6cm of K, text width=14em] (useractions3) {\textcolor{blue}{user\_actions\_(\textit{'after\_integration'})}};             
+%      \node[yellow, right=0.6cm of L] (diffusivities) {diffusivities};              
+%      \node[yellow, right=0.6cm of L] (checkrestart) {check\_for\_restart};      
+      \node[yellow, right=0.6cm of L] (flowstat) {flow\_statistics};
+      \node[green, right=0.6cm of flowstat] (userstat2) {user\_statistics};  
+
+      \node[yellow, right=0.6cm of M] (sum3ddata) {sum\_up\_3d\_data};  
+      \node[green1, right=0.6cm of sum3ddata] (user3ddataav) {user\_3d\_data\_averaging}; 
+
+      \node[green, right=0.6cm of O, text width=14em] (useractions4) {\textcolor{blue}{user\_actions\_(\textit{'after\_timestep'})}}; 
+%      \node[yellow, right=0.6cm of P] (timestep) {timestep};             
+
+      \node[yellow, right=0.2cm of user3ddataav] (dataoutput) {data\_output\_***};
+      \node[green, right=0.2cm of dataoutput] (userdvrpcoltab) {user\_dvrp\_coltab};
       \coordinate[below=0.2cm of dataoutput] (Q);   
       \coordinate[right=0.4cm of Q] (R);   
       \coordinate[right=3.0cm of R] (S); 
           
-      \node[yellow, below=0.2cm of R, text width=9em] (output2d) {user\_data\_output\_2d};
-      \node[yellow, below=0.2cm of S, text width=9em] (output3d) {user\_data\_output\_3d};
+      \node[green, below=0.2cm of R, text width=9em] (output2d) {user\_data\_output\_2d};
+      \node[green, below=0.2cm of S, text width=9em] (output3d) {user\_data\_output\_3d};
       
 
@@ -276,17 +369,19 @@
       \draw[->, thick, color=red] (E) -- (progeqfast);        
       \draw[-, thick] (progframe) -- (useractions2); 
-      \draw[-, thick] (F) -- (advecparticles);    
-      \draw[-, thick] (userparticlesattributes) -- (advecparticles);   
+      \draw[-, thick] (F) -- (lpm);    
+      \draw[-, thick] (userlpmadvec) -- (lpm);   
       \draw[-, thick] (G) -- (exchangehoriz);
       \draw[-, thick] (H) -- (swaptimelevel);
       \draw[-, thick] (I) -- (pres);     
       \draw[dotted, thick] (pres) -- (J);
-      \draw[-, thick] (K) -- (prandtlfluxes);   
-      \draw[-, thick] (L) -- (useractions3);     
-      \draw[-, thick] (M) -- (diffusivities);  
-      \draw[-, thick] (N) -- (flowstat);  
-      \draw[-, thick] (userstat) -- (flowstat);  
+%      \draw[-, thick] (K) -- (prandtlfluxes);   
+      \draw[-, thick] (K) -- (useractions3);     
+      \draw[-, thick] (L) -- (flowstat);  
+      \draw[-, thick] (M) -- (sum3ddata);  
+      \draw[-, thick] (sum3ddata) -- (user3ddataav);
+
+      \draw[-, thick] (userstat2) -- (flowstat);  
       \draw[-, thick] (O) -- (useractions4); 
-      \draw[-, thick] (P) -- (timestep);   
+%      \draw[-, thick] (O) -- (timestep);   
       \draw[-, thick] (dataoutput) -- (Q); 
       \draw[-, thick] (S) -- (Q); 
@@ -320,13 +415,13 @@
       \coordinate[below=2.5cm of PALM] (D);  
      
-      \node[green, right=0.6cm of D] (write3dbinary) {write\_3d\_binary};
-      \node[green, right=0.9cm of write3dbinary] (writevarlist) {write\_var\_list};   
+      \node[yellow, right=0.6cm of D] (write3dbinary) {write\_3d\_binary};
+      \node[yellow, right=0.9cm of write3dbinary] (writevarlist) {write\_var\_list};   
         
       \coordinate[below=3.5cm of PALM] (E); 
       \coordinate[below=4.1cm of PALM] (F); 
       \coordinate[below=4.7cm of PALM] (G); 
-      \node[green, right=0.6cm of E] (header) {header};      
-      \node[yellow, right=0.6cm of F] (userlastactions) {user\_last\_actions};    
-      \node[green, right=0.6cm of G] (cpustat) {cpu\_statistics};                
+      \node[yellow, right=0.6cm of E] (header) {header};      
+      \node[green, right=0.6cm of F] (userlastactions) {user\_last\_actions};    
+      \node[yellow, right=0.6cm of G] (cpustat) {cpu\_statistics};                
       % Draw lines
       \draw[-, thick] (PALM) -- (G); 
@@ -351,5 +446,5 @@
 	   \textbf{Name} & \textbf{Arguments} & \textbf{Called from} & \textbf{Task}\\
 	   \hline
-	   \texttt{user\_3d\_data\_averaging} & \texttt{mode}, \texttt{variable} & \texttt{sum\_up\_3d\_data} & temporal averaging for user-defined quantities\\
+	   \texttt{user\_3d\_data\_averaging} & \texttt{mode}, \texttt{variable} & \texttt{average\_3d\_data} + \texttt{sum\_up\_3d\_data} & temporal averaging for user-defined quantities\\
 	   \hline
 	   \texttt{user\_actions} \texttt{user\_actions} & \texttt{location} \,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\, \texttt{i}, \texttt{j}, \texttt{location} & \texttt{time\_integration} +
@@ -358,7 +453,5 @@
 	   \texttt{user\_dummy (user\_additional \_routines.f90)} & - - - & - - - & for additional subroutines defined by the user\\
 	   \hline
-	   \texttt{user\_advec\_particles} & - - - & \texttt{advec\_particles} & modification of particles after advection\\
-	   \hline
-	   \texttt{user\_check\_data\_output} & \texttt{variable}, \texttt{unit} & \texttt{check\_parameters} & check the user-defined output quantities\\
+	   \texttt{user\_check\_data\_output} & \texttt{variable}, \texttt{unit} & \texttt{check\_parameters} + \texttt{init\_masks}& check the user-defined output quantities\\
 	   \hline
 	   \texttt{user\_check\_data\_output\_pr} & \texttt{variable}, \texttt{var\_count}, \texttt{unit} & \texttt{check\_parameters} & check the user-defined profile output quantities\\
@@ -366,5 +459,5 @@
 	   \texttt{user\_check\_parameters} & - - - & \texttt{check\_parameters} & check user-defined variables\\
 	   \hline	   
-	   \texttt{user\_data\_output\_2d} & \texttt{av}, \texttt{variable}, \texttt{found}, \texttt{grid}, \texttt{local\_pf} & \texttt{data\_output\_2d} & output/calculation of additional user-defined quantities\\	
+	   \texttt{user\_data\_output\_2d} & \texttt{av}, \texttt{variable}, \texttt{found}, \texttt{grid}, \texttt{local\_pf}, \texttt{two\_d} & \texttt{data\_output\_2d} & output/calculation of additional user-defined quantities\\	
 	   \hline	   
 	   \texttt{user\_data\_output\_3d} & \texttt{av}, \texttt{variable}, \texttt{found}, \texttt{local\_pf}, \texttt{nz\_do} & \texttt{data\_output\_3d} & output/calculation of additional user-defined quantities\\
@@ -377,5 +470,9 @@
 	   \hline
 	   \texttt{user\_dvrp\_coltab} & \texttt{mode}, \texttt{variable} & \texttt{data\_output\_dvrp} & defining color tables for particles\\   
-	   \hline	   
+	   \hline
+           \texttt{user\_header} & \texttt{io} & \texttt{header} & output user variables to header\\
+	   \hline
+	   \texttt{user\_init} & - - - & \texttt{init\_3d\_model} & e.g. reading from restart file\\
+	   \hline
    \end{tabular}
 
@@ -391,27 +488,25 @@
 	   \textbf{Name} & \textbf{Arguments} & \textbf{Called from} & \textbf{Task}\\
 	   \hline
-	   \texttt{user\_header} & \texttt{io} & \texttt{header} & output user variables to header\\
-	   \hline
-	   \texttt{user\_init} & - - - & \texttt{init\_3d\_model} & e.g. reading from restart file\\
-	   \hline
 	   \texttt{user\_init\_3d\_model} & - - - & \texttt{init\_3d\_model} & special initializations\\
 	   \hline
-	   \texttt{user\_init\_grid} & \texttt{gls}, \texttt{nzb\_local} & \texttt{init\_grid} & defining a special topography\\
+	   \texttt{user\_init\_grid} & \texttt{gls} & \texttt{init\_grid} & defining a special topography\\
 	   \hline	   
-	   \texttt{user\_init\_particles} & - - - & \texttt{init\_particles} & defining initial particle sources\\
-	   \hline	   	   
 	   \texttt{user\_init\_plant\_canopy} & - - - & \texttt{init\_3d\_model} & setting of leaf area density and canopy drag coefficient\\
 	   \hline
 	   \texttt{user\_last\_actions} & - - - & \texttt{palm} & e.g. output for restart runs\\
-	   \hline	   
+	   \hline
+	   \texttt{user\_lpm\_advec} & - - - & \texttt{lpm} & modification of particles after advection \\
+	   \hline
+	   \texttt{user\_lmp\_init} & - - - & \texttt{lpm\_init} & defining initial particle sources \\
+	   \hline
+	   \texttt{user\_lpm\_set\_attributes} & - - - & \texttt{lpm} & defining particles attributes \\
+	   \hline
 	   \texttt{MODULE user (user\_module.f90)} & - - - & - - - & contains user defined variables\\
 	   \hline		   
 	   \texttt{user\_parin} &  & \texttt{parin} & reading user variables\\	   
-	   \hline	   
-	   \texttt{user\_particle\_attributes} & - - - & \texttt{advec\_particles} & defining particles attributes\\	   
-	   \hline
+	   \hline  
 	   \texttt{user\_read\_restart\_data} & \texttt{i}, \texttt{nxlfa}, \texttt{nxl\_on\_file}, \texttt{nxrfa}, \texttt{nxr\_on\_file}, \texttt{nynfa}, \texttt{nyn\_on\_file}, \texttt{nysfa}, \texttt{nys\_on\_file}, \texttt{offset\_xa}, \texttt{offset\_ya}, \texttt{overlap\_count}, \texttt{tmp\_2d}, \texttt{tmp\_3d} & \texttt{read\_3d\_binary} & reading user-defined 2d/3d-arrays from the restart file\\	   
 	   \hline		   
-	   \texttt{user\_spectra} & \texttt{mode}, \texttt{m}, \texttt{pr} & \texttt{data\_output\_spectra} & output/calculation of additional user-defined quantities\\	   
+	   \texttt{user\_spectra} & \texttt{mode}, \texttt{m}, \texttt{pr} & \texttt{calc\_spectra} + \texttt{data\_output\_spectra} & output/calculation of additional user-defined quantities\\	   
 	   \hline	   
 	   \texttt{user\_statistics} & \texttt{mode}, \texttt{sr}, \texttt{tn} & \texttt{flow\_statistics} & calculating additional horizontal averages + time series quantities\\		
@@ -429,4 +524,5 @@
 \begin{frame}
    \frametitle{Data Access / Exchange}
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!30, text width=0.6\textwidth, font=\tiny]
    \footnotesize
    \begin{itemize}
@@ -436,5 +532,22 @@
          \item<3-> by including the respective PALM modules in the user-interface subroutines.\\
          \begin{center}
-            \includegraphics[scale=0.3]{user_defined_code_figures/data_access_exchange.png}
+%           \includegraphics[scale=0.3]{user_defined_code_figures/data_access_exchange.png}
+            \begin{tikzpicture}[auto]
+               \node[yellow]{\texttt{SUBROUTINE user\_actions( location )} \\
+                             \par\medskip
+                             ~~~~~\texttt{\textcolor{blue}{USE arrays\_3d}} \\
+                             ~~~~~\texttt{\textcolor{blue}{USE control\_parameters}} \\
+                             ~~~~~\texttt{\textcolor{blue}{USE cpulog}} \\
+                             ~~~~~\texttt{\textcolor{blue}{USE indices}} \\
+                             ~~~~~\texttt{\textcolor{blue}{USE interfaces}} \\
+                             ~~~~~\texttt{\textcolor{blue}{USE pegrid}} \\
+                             ~~~~~\texttt{\textcolor{red}{USE user}} \\
+                             \par\medskip
+                             ~~~~~\texttt{IMPLICIT NONE} \\
+                             \par\medskip
+                             ~~~~~\texttt{CHARACTER (LEN=$^\ast$) ::  location} \\
+                             \par\medskip
+                             ~~~~~\texttt{INTEGER ::  i, j, k}};
+            \end{tikzpicture}
          \end{center} 
       \end{itemize}
@@ -451,8 +564,9 @@
 \begin{frame}
    \frametitle{Usage of \texttt{user\underline{ }actions} (I)}
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!30, text width=0.7\textwidth, font=\tiny]
    \scriptsize
    \begin{itemize}
       \item<1-> \texttt{user\underline{ }actions} is designed to add additional terms to the prognostic equations or to carry out special actions at the beginning or the end of each timestep.
-      \vspace{2mm}
+      \vspace{1.8mm}
       \item<2-> Therefore, several calls of \texttt{user\underline{ }actions} can be found in the default PALM routines \texttt{time\underline{ }integration} and \texttt{prognostic\underline{ }equations}. The place from which it is called is communicated to the routine by a string-argument, e.g.\\
    \ \\
@@ -461,8 +575,27 @@
 	\onslide<3-> It means that this call is from a place within \texttt{prognostic\underline{ }equations}, where the tendencies for the u-component are calculated and integrated:
    \end{itemize}
-   \vspace{-2mm}
+   \vspace{-3mm}
    \begin{center}
-      \includegraphics[scale=0.33]{user_defined_code_figures/user_actions_1.png}
+   \begin{tikzpicture}[auto]
+      \node[yellow] {\texttt{DO  i = nxl, nxr} \\
+                     ~~~\texttt{DO  j = nys, nyn} \\
+                     \texttt{...} \\
+                     ~~~~~~\texttt{CALL diffusion\_u( i, j )}\\
+                     ~~~~~~\texttt{CALL coriolis( i, j, 1 )} \\
+                     \texttt{...}\\
+                     ~~~~~~\texttt{\textcolor{blue}{CALL user\_actions( i, j, 'u-tendency' )}}\\
+                     \texttt{!} \\
+                     \texttt{!-- Prognostic equation for u-velocity component} \\
+                     ~~~~~~\texttt{DO  k = nzb\_u\_inner(j,i)+1, nzt} \\
+                     ~~~~~~~~~\texttt{u\_p(k,j,i) = u(k,j,i) + dt\_3d * ( tsc(2) * tend(k,j,i) + \&} \\
+                     \hspace{4.08cm} \texttt{tsc(3) * tu\_m(k,j,i) )       \&} \\
+                     \hspace{2.93cm} \texttt{- tsc(5) * rdf(k) * ( u(k,j,i) - ug(k) )}\\
+                     ~~~~~~\texttt{ENDDO} \\
+                     \texttt{...}};
+   \end{tikzpicture}
    \end{center}
+%    \begin{center}
+%       \includegraphics[scale=0.33]{user_defined_code_figures/user_actions_1.png}
+%    \end{center}
 \end{frame}
 
@@ -470,4 +603,5 @@
 \begin{frame}
    \frametitle{Usage of \texttt{user\underline{ }actions} (II)}
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!30, text width=0.7\textwidth, font=\tiny]
    \scriptsize
    \begin{itemize}
@@ -475,5 +609,32 @@
    \end{itemize}
    \begin{center}
-      \includegraphics[scale=0.35]{user_defined_code_figures/user_actions_2.png}
+      \begin{tikzpicture}[auto]
+         \node[yellow]{~\texttt{SUBROUTINE user\_actions( location )}\\
+                       \texttt{...}\\
+                       \texttt{!}\\
+                       \texttt{!--    Here the user-defined actions follow}\\
+                       \texttt{!--    No calls for single grid points are allowed at locations before and}\\
+                       \texttt{!--    after the timestep, since these calls are not within an i,j-loop}\\
+                       ~~~~~~~\texttt{SELECT CASE ( location )}\\
+                       \texttt{...}\\
+                       ~~~~~~~~~~\texttt{CASE ( 'after\_timestep' )}\\
+                       \texttt{!}\\
+                       \texttt{!-- Enter actions to be done after every timestep here}\\
+                       \par\medskip
+                       ~~~~~~~~~~\texttt{CASE ( 'u-tendency' )}\\
+                       \texttt{!}\\
+                       \texttt{!-- Enter actions to be done in the u-tendency term here}\\
+                       ~~~~~~~~~~~~~\texttt{\textcolor{blue}{DO i = nxl, nxr}}\\
+                       ~~~~~~~~~~~~~~~~\texttt{\textcolor{blue}{DO j = nys, nyn}}\\
+                       ~~~~~~~~~~~~~~~~~~~\texttt{\textcolor{blue}{DO k = nxb+1, nzt}}\\
+                       ~~~~~~~~~~~~~~~~~~~~~~~~~\texttt{\textcolor{blue}{tend(k,j,i) = tend(k,j,i) - const * u(k,j,i) ...}}\\
+                       ~~~~~~~~~~~~~~~~~~~\texttt{\textcolor{blue}{ENDDO}}\\
+                       ~~~~~~~~~~~~~~~~\texttt{\textcolor{blue}{ENDDO}}\\
+                       ~~~~~~~~~~~~~\texttt{\textcolor{blue}{ENDDO}}\\
+                       \par\bigskip
+                       ~~~~~~~~~~\texttt{CASE ( 'v-tendency' )}\\
+                       \texttt{...}};
+      \end{tikzpicture}
+%      \includegraphics[scale=0.35]{user_defined_code_figures/user_actions_2.png}
    \end{center}
 \end{frame}
@@ -482,4 +643,5 @@
 \begin{frame}[t]
    \frametitle{Usage of \texttt{user\underline{ }actions} (III)}
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!30, text width=0.5\textwidth, font=\Tiny]
    \scriptsize
    \begin{columns}[T]
@@ -507,10 +669,34 @@
    \uncover<4->{%
    \begin{tikzpicture}[remember picture, overlay]
-      \node [shift={(8.3 cm,3.0cm)}]  at (current page.south west)
-         {%
-         \begin{tikzpicture}[remember picture, overlay]
-            \node[text width=14em] at (0,0) {\includegraphics[scale=0.3]{user_defined_code_figures/user_actions_3.png}};
-         \end{tikzpicture}
-         };
+      \node [yellow,shift={(9.2 cm,3.0cm)}]  at (current page.south west){~\texttt{SUBROUTINE user\_actions\_ij( i, j, location )}\\
+                                                                          \par\medskip
+                                                                          ~~~\texttt{USE control\_parameters}\\
+                                                                          ~~~\texttt{USE pegrid}\\
+                                                                          ~~~\texttt{USE user}\\
+                                                                          \par\medskip
+                                                                          ~~~\texttt{IMPLICIT NONE}\
+                                                                          \par\medskip
+                                                                          ~~~\texttt{CHARACTER (LEN=*) ::  location}\\
+                                                                          \par\medskip
+                                                                          ~~~\texttt{INTEGER ::  i, idum, j}\\
+                                                                          \par\medskip
+                                                                          \texttt{!}\\
+                                                                          \texttt{!--    Here the user-defined actions follow}\\
+                                                                          \vspace{0.5mm}
+                                                                          ~~~\texttt{SELECT CASE ( location )}\\
+                                                                          \par\medskip
+                                                                          ~~~~~~\texttt{CASE ( 'u-tendency' )}\\
+                                                                          \texttt{!}\\
+                                                                          \texttt{!--Enter actions to be done in the u-tendency term here}\\
+                                                                          ~~~~~~~~~\texttt{\textcolor{blue}{DO k = nzb+1, nzt-1}}\\
+                                                                          ~~~~~~~~~~~~~~~\texttt{\textcolor{blue}{tend(k,j,i) = tend(k,j,i) + ...}}\\
+                                                                          ~~~~~~~~~\texttt{\textcolor{blue}{ENDDO}}\\
+                                                                          \par\medskip
+                                                                          ~~~~~~\texttt{CASE ( 'v-tendency' )}};
+%          {%
+%          \begin{tikzpicture}[remember picture, overlay]
+% %            \node[text width=14em] at (0,0) {\includegraphics[scale=0.3]{user_defined_code_figures/user_actions_3.png}};
+%          \end{tikzpicture}
+%          };
     \end{tikzpicture}}
    
@@ -520,4 +706,5 @@
 \begin{frame}
    \frametitle{Steering the User-Interface}
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!30, text width=0.7\textwidth, font=\Tiny]
    \scriptsize
    \begin{columns}[T]
@@ -530,15 +717,46 @@
          \item<1-> Add the variable name to module \texttt{user} in order to define it and to make it available in all user-interface subroutines. Set a default value for this variable.
          \begin{center}
-            \includegraphics[scale=0.3]{user_defined_code_figures/steering_1.png}
+%            \includegraphics[scale=0.3]{user_defined_code_figures/steering_1.png}
+            \begin{tikzpicture}
+               \node[yellow]{~\texttt{MODULE user}\\
+                             \vspace{0.4mm}
+                             \texttt{...}\\
+                             \vspace{0.4mm}
+                             ~\texttt{REAL \hspace{0.4cm}:: ~~\textcolor{blue}{foo = 0.0}}\\
+                             \vspace{0.4mm}
+                             \texttt{...}\\
+                             \vspace{0.4mm}
+                             ~\texttt{END MODULE user}};
+            \end{tikzpicture}
          \end{center}
          \vspace{1mm}
          \item<2-> Add the variable to the NAMELIST \texttt{/userpar/}. This NAMELIST already contains four predefined variables.
          \begin{center}
-            \includegraphics[scale=0.3]{user_defined_code_figures/steering_2.png}
+%            \includegraphics[scale=0.3]{user_defined_code_figures/steering_2.png}
+            \begin{tikzpicture}
+               \node[yellow]{~\texttt{SUBROUTINE user\_parin}\\
+                             \vspace{0.4mm}
+                             \texttt{...}\\
+                             \vspace{0.4mm}
+                             ~~~~~\texttt{NAMELIST ~~/userpar/ ~~ data\_output\_pr\_user, data\_output\_user,}\\
+                             \vspace{0.4mm}
+                             \hspace{3cm}\texttt{\textcolor{blue}{foo}, region}\\
+                             \vspace{0.4mm}
+                             \texttt{...}\\
+                             \vspace{0.4mm}
+                             ~\texttt{END SUBROUTINE user\_parin}};
+            \end{tikzpicture}
          \end{center}
          \vspace{1mm}
          \item<3-> Add the NAMELIST \texttt{\&userpar} to the parameter file (e.g. \texttt{example\underline{ }cbl\underline{ }p3d}) and assign a value to this variable.         
          \begin{center}
-            \includegraphics[scale=0.3]{user_defined_code_figures/steering_3.png}
+%            \includegraphics[scale=0.3]{user_defined_code_figures/steering_3.png}
+            \begin{tikzpicture}
+               \node[yellow]{~\texttt{\&inipar ~~~ nx = ... ~~/}\\
+                             \vspace{0.4mm}
+                             ~\texttt{\&d3par ~~~ end\_time = 3600.0, ... ~~/}\\
+                             \par\smallskip
+                             ~\texttt{\textcolor{blue}{\&userpar ~~foo = 12345.6 ~~/}}};
+            \end{tikzpicture}
          \end{center}
          \vspace{1mm}
@@ -575,4 +793,5 @@
 \begin{frame}
    \frametitle{User-Defined Data for Restart Runs (I)}
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!30, text width=0.7\textwidth, font=\tiny]
    \scriptsize
    \begin{itemize}
@@ -583,5 +802,15 @@
    \end{itemize}
    \begin{center}
-      \includegraphics[scale=0.3]{user_defined_code_figures/restart_1.png}
+%      \includegraphics[scale=0.3]{user_defined_code_figures/restart_1.png}
+      \begin{tikzpicture}[auto]
+         \node[yellow]{~\texttt{SUBROUTINE user\_last\_actions}\\
+                       \texttt{...}\\
+                       ~~~~~\texttt{\textcolor{blue}{WRITE ( 14 )  'foo \hspace{2cm}';  WRITE ( 14 )  foo}}\\
+                       ~~~~~\texttt{\textcolor{blue}{WRITE ( 14 )  'bar \hspace{2cm}';  WRITE ( 14 )  bar}}
+                       \par\smallskip
+                       ~~~~~\texttt{WRITE ( 14 ) '*** end user *** \hspace{0.66cm}'}
+                       \par\smallskip
+                       ~\texttt{END SUBROUTINE user\_last\_actions}};
+      \end{tikzpicture}
    \end{center}
 \end{frame}
@@ -590,10 +819,45 @@
 \begin{frame}
    \frametitle{User-Defined Data for Restart Runs (II)}
+   \tikzstyle{yellow} = [rectangle, draw, fill=yellow!30, text width=0.95\textwidth, font=\tiny]
    \scriptsize
    \begin{itemize}
       \item Additionally, these variables have to be read from the restart file (file-id \grqq \texttt{13}\grqq\,, local filename \texttt{BININ}) by adding code to the routine \texttt{user\underline{ }read\underline{ }restart\underline{ }data}:
    \end{itemize}
+   \vspace{-2.7mm}
    \begin{center}
-      \includegraphics[scale=0.3]{user_defined_code_figures/restart_2.png}
+%      \includegraphics[scale=0.3]{user_defined_code_figures/restart_2.png}
+      \begin{tikzpicture}
+         \node[yellow]{\texttt{~SUBROUTINE user\_read\_restart\_data( i, nxlfa, nxl\_on\_file, nxrfa, nxr\_on\_file, \&} \\
+                       \hspace{3.84cm}\texttt{nynfa, nyn\_on\_file, nysfa, nys\_on\_file,    \&} \\
+                       \hspace{3.84cm}\texttt{offset\_xa, offset\_ya, overlap\_count,       \&} \\
+                       \hspace{3.84cm}\texttt{tmp\_2d, tmp\_3d )}\\
+                       \texttt{...} \\
+                       ~~~~~\texttt{IF ( initializing\_actions == 'read\_restart\_data' )  THEN}\\
+                       ~~~~~~~~~\texttt{READ ( 13 )  field\_char} \\
+                       ~~~~~~~~~\texttt{DO  WHILE ( TRIM( field\_char )  '*** end user ***' )}\\
+                       \par\smallskip
+                       ~~~~~~~~~~~~~\texttt{nxlf = nxlfa(i,k)}
+                       \texttt{...} \\
+                       ~~~~~~~~~~~~~\texttt{SELECT CASE ( TRIM( field\_char ) )}\\
+                       \par\smallskip
+                       ~~~~~~~~~~~~~~~~~\texttt{CASE ( '\textcolor{blue}{foo}' )} \\
+                       ~~~~~~~~~~~~~~~~~~~~~\texttt{IF ( .NOT. ALLOCATED( \textcolor{blue}{foo} ) ) THEN}\\
+                       ~~~~~~~~~~~~~~~~~~~~~~~~~\texttt{ALLOCATE( \textcolor{blue}{foo}(nzb:nzt+1,nysg:nyng,nxlg:nxrg) )}\\
+                       ~~~~~~~~~~~~~~~~~~~~~\texttt{ENDIF}\\
+                       ~~~~~~~~~~~~~~~~~~~~~\texttt{IF ( k == 1 )  READ ( 13 )  tmp\_3d}\\
+                       ~~~~~~~~~~~~~~~~~~~~~\texttt{\textcolor{blue}{foo}(:,nysc-nbgp:nync+nbgp,nxlc-nbgp:nxrc+nbgp) = \&} \\
+                       \hspace{4.5cm}\texttt{tmp\_3d(:,nysf-nbgp:nynf+nbgp,nxlf-nbgp:nxrf+nbgp)}\\
+                       \texttt{...}\\
+                       ~~~~~~~~~~~~~\texttt{END SELECT}\\
+                       \par\smallskip
+                       ~~~~~~~~~\texttt{ENDDO}
+                       \par\smallskip
+                       ~~~~~~~~~\texttt{READ ( 13 )  field\_char}\\
+                       \par\smallskip
+                       ~~~~~~~~~\texttt{ENDDO}\\
+                       ~~~~~\texttt{ENDIF}\\
+                       \par\smallskip
+                       ~\texttt{END SUBROUTINE user\_read\_restart\_data}};
+      \end{tikzpicture}
    \end{center}
 \end{frame}
@@ -610,4 +874,5 @@
             \item<2-> Copy the default (empty) user-interface files that you need (e.g. user\underline{ }module.f90, user\underline{ }parin.f90, user\underline{ }actions.f90) to a directory of your choice, e.g.:\\
             \tiny
+            \par\smallskip
 	         \quad \texttt{cd \~{ }/palm/current\underline{ }version}\\
 	         \quad \texttt{mkdir -p USER\underline{ }CODE/example\underline{ }cbl}\\
