source: palm/trunk/TUTORIAL/SOURCE/numerics_bc.tex @ 1809

Last change on this file since 1809 was 1649, checked in by knoop, 9 years ago

Latex lecture update for PALM seminar in Hong Kong

  • Property svn:keywords set to Id
File size: 26.4 KB
Line 
1% $Id: numerics_bc.tex 1649 2015-09-15 16:34:42Z raasch $
2\input{header_tmp.tex}
3%\input{header_lectures.tex}
4
5\usepackage[utf8]{inputenc}
6\usepackage{ngerman}
7\usepackage{pgf}
8\usetheme{Dresden}
9\usepackage{subfigure}
10\usepackage{units}
11\usepackage{multimedia}
12\usepackage{hyperref}
13\newcommand{\event}[1]{\newcommand{\eventname}{#1}}
14\usepackage{xmpmulti}
15\usepackage{tikz}
16\usetikzlibrary{shapes,arrows,positioning}
17\def\Tiny{\fontsize{4pt}{4pt}\selectfont}
18\usepackage{amsmath}
19\usepackage{amssymb}
20\usepackage{multicol}
21\usepackage{pdfcomment}
22
23\institute{Institute of Meteorology and Climatology, Leibniz UniversitÀt Hannover}
24\selectlanguage{english}
25\date{last update: \today}
26\event{PALM Seminar}
27\setbeamertemplate{navigation symbols}{}
28
29\setbeamertemplate{footline}
30  {
31    \begin{beamercolorbox}[rightskip=-0.1cm]&
32     {\includegraphics[height=0.65cm]{imuk_logo.pdf}\hfill \includegraphics[height=0.65cm]{luh_logo.pdf}}
33    \end{beamercolorbox}
34    \begin{beamercolorbox}[ht=2.5ex,dp=1.125ex,
35      leftskip=.3cm,rightskip=0.3cm plus1fil]{title in head/foot}
36      {\leavevmode{\usebeamerfont{author in head/foot}\insertshortauthor} \hfill \eventname \hfill \insertframenumber \; / \inserttotalframenumber}
37    \end{beamercolorbox}
38    \begin{beamercolorbox}[colsep=1.5pt]{lower separation line foot}
39    \end{beamercolorbox}
40  }
41%\logo{\includegraphics[width=0.3\textwidth]{luhimuk_logo.pdf}}
42
43\title[Numerics and Boundary Conditions]{Numerics and Boundary Conditions\\
44(used in PALM)
45}
46\author{PALM group}
47
48\begin{document}
49
50% Folie 1
51\begin{frame}
52\titlepage
53\end{frame}
54
55% Folie 2
56\begin{frame}
57   \frametitle{Overview}
58   \scriptsize PALM is (almost) using simple, standard and fast numerical schemes:
59   \begin{itemize}
60      \scriptsize
61      \item<2-> \textbf{Spatial and temporal discretization by finite differences}\\
62      \item<3-> \textbf{Explicit timestep methods:}\\
63         - Euler\\
64         - \underline{Runge-Kutta}, second or \underline{third order}
65      \item<4-> \textbf{Advection method}\\
66         - Upstream\\
67         - Piacsek-Williams (second order central finite differences)\\
68         - Bott-Chlond-scheme (monotone, positiv definit, for scalars only)\\
69         - \underline{5th-order scheme of Wicker and Skamarock}, (as used in WRF model)
70      \item<5-> \textbf{Poisson-equation for pressure}\\
71         - \underline{Direct FFT-method}\\
72         - Multigrid-method
73      \item<6-> \textbf{Lagrangian particle model included}
74      \item<7-> \textbf{Boundary conditions:}\\
75         - \underline{Cyclic} and non-cyclic horizontal boundary conditions\\
76         - Surface layer with Monin-Obukhov similarity\\
77         - Topography\\
78         - Turbulent inflow (for non-cyclic horizontal boundary conditions)
79         
80   \end{itemize}
81\end{frame}
82
83
84\section{Numerics}
85\subsection{Numerics}
86
87% Folie 3
88\begin{frame}
89   \frametitle{Numerical Grid}
90   \footnotesize
91   \vspace{2mm}
92   \includegraphics[width=\textwidth]{numerics_bc_figures/numerical_grid.png}
93   \begin{itemize}
94      \item<1->Equations are spatially discretized on an Arakawa-C grid.
95      \item<2->All scalar variables s (e.g. , $p^*$, $e$, $K_{\mathrm{m}}$,
96               $K_{\mathrm{h}}$) are defined at the cell centers.
97      \item<3->Velocity components ($u$, $v$, $w$) are shifted by half of the grid spacing.
98      \item<4->Spacings are equidistant, stretching along $z$ is possible.
99   \end{itemize}
100
101   \tikzstyle{plain} = [rectangle, draw, fill=white!20, text width=0.33\textwidth, font=\small]
102   \begin{tikzpicture}[remember picture, overlay]
103      \node at (current page.north west){%
104      \begin{tikzpicture}[overlay]
105         \node[plain, draw,anchor=west] at (88mm,-55mm) {
106         \noindent \scriptsize general definition (cylic):\\
107         $\Psi$(0:nz+1,-1:ny+1,-1:nx+1)\\
108         $\Psi$(:,-1,:) $=\Psi$(:,ny,:)\\
109         $\Psi$(:,ny+1,:) $=\Psi$(:,0,:)
110
111         };
112      \end{tikzpicture}
113      };
114   \end{tikzpicture}
115\end{frame}
116
117% Folie 4
118\begin{frame}
119   \frametitle{Timestep Methods (I)}
120   \footnotesize
121   \begin{itemize}
122      \item<1->\textbf{Euler}\\
123      \vspace{3mm}
124      $\dfrac{\partial \psi(t)}{\partial t} = F (\psi(t)) \rightarrow 
125      \dfrac{\psi(t + \Delta t) - \psi(t)}{\Delta t}
126      \approx F (\psi(t))$ \hspace{8mm} 
127      \onslide<2-> $u\dfrac{\Delta t}{\Delta x}=C<1$\\
128      \begin{flushright}
129         for stability
130      \end{flushright}
131
132      \onslide<1->$\psi (t+\Delta t) = \psi(t) 
133      + \Delta t \cdot F(\psi(t)) \hspace{28mm} \mathcal{O}(\Delta t)$\\
134      (used for SGS-TKE in special cases)
135         
136      \vspace{3mm}
137      \item<3-> \textbf{Runge-Kutta, third-order}\\
138      \vspace{2mm}
139      $k_1=F(\psi(t))$\\
140      \vspace{1mm}
141      $k_2=F \left( \psi(t) + \frac{1}{3} \Delta t \cdot k_1 \right)$\\
142      \vspace{1mm}
143      $k_3=F \left( \psi(t) - \frac{3}{16} \Delta t \cdot k_1 
144      + \frac{15}{16} \Delta t \cdot k_2 \right)$\\
145      \vspace{1mm}
146      $\psi(t + \Delta t) = \psi(t) + \frac{1}{30}\Delta t (5 k_1 + 9 k_2 + 16 k_3)$ 
147      \hspace{12mm} $\mathcal{O}(\Delta t^2)$ \hspace{3mm} $C \le 0.9$\\
148   \end{itemize}
149\end{frame}
150
151% Folie 5
152\begin{frame}
153   \frametitle{Timestep Methods (II)}
154   \footnotesize
155   \onslide<1->In the PALM code, the different timestep schemes are treated by one
156   equation using switches:
157   $\psi (t + \Delta t ) = (1 - c_1) \cdot \psi (t - \Delta t ) + c_1 \cdot \psi (t) 
158   + \Delta t \cdot \left[ c_2 \cdot F (\psi (t) ) + c_3 \cdot F (\psi (t - 
159   \Delta t ) ) \right]$
160   \vspace{1mm}
161
162   \onslide<2->
163   \begin{centering}
164      \begin{table}
165         \begin{tabular}{cccc}
166            \bf{Scheme} & \bf{c$_1$} & \bf{c$_2$} & \bf{c$_3$}\\
167            Euler & 1 & 1 & 0\\
168            RK (1st step) & 1 & 1/3 & 0\\
169            RK (2nd step) & 1 & 15/16 & -25/48\\
170            RK (3rd step) & 1 & 8/15 & 1/15\\
171         \end{tabular}
172      \end{table}
173   \end{centering}
174
175   \onslide<3->
176   \begin{align*}
177      \psi (t - \Delta t) &= \psi (t) \hspace{15mm} \textbf{after each RK substep}\\
178      \psi (t) &= \psi (t + \Delta t)
179   \end{align*}
180\end{frame}
181
182% Folie 6
183\begin{frame}
184   \frametitle{Advection Methods (I)}
185   \small
186   \begin{itemize}
187      \item<1-> Piacsek Williams C3 (1970, J. Comput. Phy., 6, 392).
188      \item<2-> Scheme of 2nd order accuracy.
189      \item<3-> Conserves integrals of linear and quadratic quantities.
190      \item<4-> Requires incompressibility $\rightarrow$ flux form of advection term.
191                \onslide<4-> \includegraphics[width=0.8\textwidth]{numerics_bc_figures/advection_methods.png}
192   \end{itemize}
193   $$\left.\frac{\partial (u \psi)}{\partial x}\right\vert_i = \frac{1}{2 \Delta x}
194   \left( u_{i+\frac{1}{2}} \psi_{i+1} - u_{i-\frac{1}{2}} \psi_{i-1} \right)$$
195   \begin{itemize}
196      \item<5-> In case of momentum advection (e.g. $\psi=u$), $u_{i-1}$ and
197                $u_{i+1}$ have to be obtained by linear interpolation.
198      \item<5-> May cause $2 \Delta x$ wiggles in case of sharp gradients.
199   \end{itemize}
200\end{frame}
201
202% Folie 7
203\begin{frame}
204   \frametitle{Advection Methods (II)}
205   \begin{itemize}
206   
207      \item<1-> \small Bott-Chlond\\ \scriptsize
208         \onslide<1-> - Chlond (1994)\\
209         \onslide<2-> - Monotone, positive definit. Can only be used for scalars\\
210         \onslide<3-> - Conserves sharp gradients\\
211         \onslide<4-> - Numerically expensive\\
212         \onslide<5-> - Not optimized for use on cache-based machines.
213      \par\bigskip
214      \item<6-> \small Default: Wicker and Skamarock scheme (5th order)\\ \scriptsize
215         \onslide<6-> - Much better accuracy than Piacsek Williams\\
216         \onslide<7-> - Much simpler algorithm than Bott-Chlond\\
217         \onslide<8-> - Requires additional ghost layers\\
218         \onslide<9-> - Adds additional numerical dissipation
219         
220   \end{itemize}
221\end{frame}
222
223% Folie 8
224\begin{frame}
225   \frametitle{Advection Methods – Wicker/Skamarock (I)}
226   \footnotesize
227   \begin{itemize}
228      \item Wicker and Skamarock (2002, Mon. Wea. Rev. 130, 2088 – 2097).
229      \item Based on flux form of advection term
230      \item Difference of fluxes at the edge of the grid cell is used to
231      discretise advection term
232   \end{itemize}
233
234   \begin{columns}[T]
235      \begin{column}{0.55\textwidth}
236         \hspace{8mm}\includegraphics[width=0.8\textwidth]{numerics_bc_figures/numerical_grid_small.png}
237      \end{column}
238      \begin{column}{0.45\textwidth}
239         $\frac{ \partial \psi}{\partial t} = - \nabla (u_i \psi) \approx 
240         - \frac{F_{i+\frac{1}{2}} - F_{i-\frac{1}{2}}}{\Delta x}$
241      \end{column}
242   \end{columns}
243
244   \tikzstyle{plain} = [rectangle, text width=0.1\textwidth, font=\small]
245   \begin{tikzpicture}[remember picture, overlay]
246      \node at (current page.north west){%
247
248      \begin{tikzpicture}[overlay]
249         \node[plain, anchor=west] at (2mm,-68mm) {
250         \tikz 
251         {
252         \draw[blue, -latex', line width=5pt] (1,0) -- (2,0);
253         }
254
255         $F_{i-\frac{1}{2}}$
256         };
257      \end{tikzpicture}
258
259      \begin{tikzpicture}[overlay]
260         \node[plain, anchor=west] at (62mm,-68mm) {
261         \tikz 
262         {
263         \draw[blue, -latex', line width=5pt] (,0) -- (2,0);
264         }
265         $F_{i+\frac{1}{2}}$
266         };
267      \end{tikzpicture}
268
269      };
270   \end{tikzpicture}
271\end{frame}
272
273% Folie 9
274\begin{frame}
275   \frametitle{Advection Methods – Wicker/Skamarock (II)}
276   
277
278
279   \textbf{Finite difference approximation of 6$^{\text{th}}$ order}
280   \begin{tikzpicture}[scale=2]
281      \tikzstyle{ann} = [draw=none,fill=none,right]
282      \matrix[nodes={draw, thick, fill=blue!20}, row sep=0.3cm,column sep=0.5cm]{
283      \node[rectangle, rounded corners]{
284      $F^{\text{6th}}_{i-\frac{1}{2}} = \frac{1}{60} u_{i-\frac{1}{2}} \left( 37 
285      (\Psi_i + \Psi_{i-1}) - 8 (\Psi_{i+1} + \Psi_{i-2}) + (\Psi_{i+2}
286      + \Psi_{i-3}) \right)$ 
287       };\\
288       };
289   \end{tikzpicture}
290   
291   \vspace{5mm}
292   
293   \textbf{Artificially added numerical dissipation term}
294   \begin{tikzpicture}[scale=2]
295      \tikzstyle{ann} = [draw=none,fill=none,right]
296      \matrix[nodes={draw, thick, fill=blue!40}, row sep=0.3cm,column sep=0.5cm]{
297      \node[rectangle, rounded corners]{
298      $-\frac{1}{60} \left| u_{i-\frac{1}{2}} \right| \left( 10 (\Psi_i - 
299      \Psi_{i-1}) - 5 (\Psi_{i+1} - \Psi_{i-2}) + (\Psi_{i+2} - \Psi_{i-3}) \right)$ 
300       };\\
301       };
302   \end{tikzpicture}
303\end{frame}
304
305% Folie 10
306\begin{frame}
307   \frametitle{Advection Methods – Wicker/Skamarock (III)}
308   
309   \begin{tikzpicture}[scale=2]
310      \tikzstyle{ann} = [draw=none,fill=none,right]
311      \matrix[nodes={draw, thick, fill=blue!20}, row sep=0.3cm,column sep=0.5cm]{
312      \node[rectangle, rounded corners]{
313      $F^{\text{6th}}_{i-\frac{1}{2}} = \frac{1}{60} u_{i-\frac{1}{2}}
314      \left( 37 (\Psi_i + \Psi_{i-1}) - 8 (\Psi_{i+1} + \Psi_{i-2}) + (\Psi_{i+2} + 
315      \Psi_{i-3}) \right)$ 
316       };\\
317       };
318   \end{tikzpicture}
319   
320   \begin{columns}[T]
321      \begin{column}{0.7\textwidth}
322         \includegraphics[width=1\textwidth]{numerics_bc_figures/numerical_oscillations.png}
323      \end{column}
324      \begin{column}{0.3\textwidth}
325         Centered Finite Differences produces numerical oscillations (''wiggles'')
326         near sharp gradients.
327      \end{column}
328   \end{columns}
329\end{frame}
330
331% Folie 11
332\begin{frame}
333   \frametitle{Advection Methods – Wicker/Skamarock (IV)}
334   \footnotesize   
335
336   \begin{tikzpicture}[scale=2]
337      \tikzstyle{ann} = [draw=none,fill=none,right]
338      \matrix[nodes={draw, thick, fill=blue!40}, row sep=0.3cm,column sep=0.5cm]{
339      \node[rectangle, rounded corners]{
340      $F^{\text{5th}}_{i-\frac{1}{2}} = F^{\text{6th}}_{i-\frac{1}{2}}
341         - \frac{1}{60} \left| u_{i-\frac{1}{2}} \right| \left( 10 (\Psi_i - \Psi_{i-1}) - 
342            5 (\Psi_{i+1} - \Psi_{i-2}) + (\Psi_{i+2} - \Psi_{i-3}) \right)$ 
343       };\\
344       };
345   \end{tikzpicture}
346   
347   \begin{columns}[T]
348      \begin{column}{0.7\textwidth}
349         \includegraphics[width=1\textwidth]{numerics_bc_figures/numerical_oscillations_2.png}
350      \end{column}
351      \begin{column}{0.3\textwidth}
352         \vspace{3mm}
353         \underline{Advantage}\\
354         Numerical Dissipation damps small scale oscillations.\\
355         \vspace{3mm}
356         \underline{Disadvantage}\\
357         In a turbulent flow numerical dissipation removes energy from small scales.
358
359      \end{column}
360   \end{columns}
361\end{frame}
362
363% Folie 12
364\begin{frame}
365   \frametitle{Advection Methods – Wicker/Skamarock (V)}
366   
367    \begin{columns}[T]
368      \begin{column}{0.6\textwidth}
369         \includegraphics[width=1\textwidth]{numerics_bc_figures/numerical_properties.png}
370      \end{column}
371      \begin{column}{0.4\textwidth}
372         \includegraphics[width=1\textwidth]{numerics_bc_figures/pw_ws.png}
373      \end{column}
374   \end{columns}
375   
376   \begin{itemize}
377      \item Better resolution of larger scales $(> 8\,\Delta x)$ and hence less
378      numerical energy transfer from larger to smaller scales compared to lower
379      order schemes.
380      \item Less spectral energy at smaller scales.
381   \end{itemize}
382   
383\end{frame}
384
385% Folie 13
386\begin{frame}
387   \frametitle{Pressure Solver (I)}
388   \footnotesize
389   \begin{itemize}
390      \item<1-> Governing equations of PALM require incompressibility
391      \item<2-> Incompressibility is reached by a predictor-corrector method\\
392            \scriptsize
393            1. Momentum equations are solved without the pressure term giving a
394            provisional velocity field which is not free of divergence.\\
395            \vspace{2mm}
396            $\overline{u}^{t+\Delta t}_{i_{\mathrm{prov}}} = \overline{u}^t_i +
397            \Delta t \left( - \frac{\partial}{\partial x_k} \overline{u}^t_k
398            \overline{u}^t_i - (\varepsilon_{ijk} f_j \overline{u}^t_k
399            - \varepsilon_{i3k} f_3 u_{\mathrm{g}_k}) 
400            + g \frac{\overline{\theta^*}^t}{\theta_0} \delta_{i3}
401            - \frac{\partial}{\partial x_k} \overline{u'_k u'_i}^t \right)$\\
402            \vspace{2mm}
403            \onslide<3-> 2. Assign all remaining divergences to the (perturbation)
404            pressure $p^*$ so that the new corrected velocity field is the sum of the
405            provisional, divergent field and the perturbation pressure term.\\
406            \vspace{2mm}
407            $\overline{u}^{t+\Delta t}_{i} = 
408            \overline{u}^{t+\Delta t}_{i_{\mathrm{prov}}} + 
409            \Delta t \left(-\frac{1}{\rho_0} \frac{\partial \overline{p^*}^t}{\partial x_i} \right)$\\
410            \vspace{2mm}
411            \onslide<4-> 3. The divergence operator is applied to this equation.
412            Demanding a corrected velocity field free of divergence, this leads to a
413            Poisson equation for the perturbation pressure.\\
414            \vspace{2mm}
415            $\frac{\partial^2 \overline{p^*}^t}{\partial x_i^2} = \frac{\rho_0}
416            {\Delta t} \frac{\partial \overline{u}_{i_{\mathrm{prov}}}^{t + \Delta t}}
417            {\partial x_i}$\\
418            \vspace{2mm}
419            \onslide<5-> 4. After solving the Poisson equation, the final velocity field
420            is \\
421            calculated as given in step 2.\\
422
423   \end{itemize}
424\end{frame}
425
426% Folie 14
427\begin{frame}
428   \frametitle{Pressure Solver (II)}
429   \small
430   
431   \begin{itemize}
432      \item FFT-solver\\
433      \onslide<1-> 1. Discretization of the Poisson-equation by central differences\\
434      \onslide<2-> 2. 2D discrete FFT in both horizontal directions\\
435      \onslide<3-> 3. Solving the resulting tridiagonal set of linear equations\\
436      \onslide<4-> 4. Inverse 2D discrete FFT in both horizontal directions leading
437      to the perturbation pressure
438
439      \begin{itemize}
440         \item<5-> Very fast and accurate, $\mathcal{O}(n \log n)$, $n$:
441         number of gridpoints
442         \item<6-> CPU requirement $<$ 50\% of total CPU time
443         \item<7-> Due to non-locality of the FFT, transpositions are required
444         on parallel computers
445         \item<8-> Requires periodic boundary conditions and uniform grids
446         along $x$ and $y$
447      \end{itemize}
448   \end{itemize}
449\end{frame}
450
451% Folie 15
452\begin{frame}
453   \frametitle{Pressure Solver (III)}
454   \scriptsize   
455   \begin{columns}
456      \begin{column}{1.03\textwidth}
457         \begin{itemize}
458            \item<1-> Multigrid-method\\
459            \begin{itemize}\scriptsize 
460               \item Iterative solver\\
461               \scriptsize
462               basic idea: Poisson equation is transformed to a fixed point problem:\\
463               $\vec{p}^{k+1} = T \cdot \vec{p}^k + \vec{c}^k$\\
464               \vspace{1mm}
465               \onslide<2-> starting from a first guess, the solution will be
466               improved by repeated execution of the fixed point problem:\\
467               $\begin{array}{rcl}
468               \vec{p}^{1} &=&T \cdot \vec{p}^0 + \vec{c}^0\\
469               \vec{p}^{2} &=&T \cdot \vec{p}^1 + \vec{c}^1
470               \vspace{-2mm}\\
471               
472               &\vdots&
473               \vspace{-1.5mm}\\
474               
475               \vec{p}^{k} &=&T \cdot \vec{p}^{k-1} + \vec{c}^{k-1}\\
476               \vec{p}^{k+1} &=&T \cdot \vec{p}^k + \vec{c}^k\\
477               \end{array}$\\
478               \vspace{1mm}
479               \onslide<3-> Depending on the structure of the matrix $T$ and vector
480               $c$ different iterative solvers can be defined, e.g.: Jacobi-scheme
481               (here on 2D-uniform grid):\\
482               $p^{k+1}_{i,j} = \frac{1}{4} \cdot \left( p^k_{i-1,j} + p^k_{i+1,j}
483               + p^k_{i,j-1} + p^k_{i,j+1} - \Delta x^2 f(i,j,k) \right)$\\
484               \scriptsize \vspace{2mm}
485               \item<4-> With each iteration step $k$ the improved solution converges towards
486               the exact solution.
487               \item<5-> Iterative schemes are 'local schemes' $\rightarrow$ information
488               is needed \\ only from neighboring grid-points.
489               \item<6-> Very low convergence: $\mathcal{O}(n^2)$.
490           \end{itemize}
491         \end{itemize}
492      \end{column}
493   \end{columns}
494\end{frame}
495   
496% Folie 16
497\begin{frame}
498   \frametitle{Pressure Solver (IV)} 
499   \begin{itemize}
500      \item<1-> Multigrid-method\\
501      \begin{itemize}
502         \item Due to their locality, iterative solvers show a frequency-dependent
503            reduction of the residual: low frequencies are reduced slower than high
504            frequencies.
505         \item<2-> The main idea of the multigrid method is to reduce errors of different
506         frequencies on grids with different grid spacing:
507         \begin{itemize}
508            \item errors of high frequency are reduced on fine grids
509            \item errors of low frequency are reduced on coarse grids.
510         \end{itemize}
511      \end{itemize}
512   \end{itemize}
513   \onslide<2->
514   \begin{figure}[htp]
515      \centering
516      \includegraphics[scale=0.35]{numerics_bc_figures/errors.png}
517   \end{figure}
518\end{frame}
519
520% Folie 17
521\begin{frame}
522   \frametitle{Pressure Solver (V)} 
523   
524   \begin{columns}[T]
525      \begin{column}{0.65\textwidth}
526         \begin{itemize}
527            \item<1-> Multigrid-method\\
528            \begin{itemize}
529               \footnotesize
530               \item On each grid-level an approximate solution of the fixed point
531                  equation is obtained performing a few iterations.
532               \item<2-> The solution is transmitted to the next coarser grid-level
533                  where it is used as the first guess to solve the fixed point problem.
534               \item<3-> This procedure is performed up to the coarsest grid-level
535                  containing two grid-points in each direction.
536               \item<4-> From the coarsest grid-level the procedure is passed in
537                  backward order to get the final solution.
538               \item<5-> For large grids faster than FFT method.
539               \item<6-> V- and W-cycles are implemented.
540            \end{itemize}
541      \end{itemize}
542      \end{column}
543      \begin{column}{0.5\textwidth}
544         \onslide<2->
545         \includegraphics[width=1\textwidth]{numerics_bc_figures/multigrid.png}
546      \end{column}
547   \end{columns}
548\end{frame}
549
550
551
552\section{Boundary Conditions}
553\subsection{Boundary Conditions}
554
555% Folie 18
556\begin{frame}
557   \frametitle{Boundary Conditions (I)}
558   
559   \begin{itemize}
560      \item<1-> Lateral $(xy)$ boundary conditions:\\
561      \begin{itemize}
562         \item Cyclic by default, allowing undisturbed evolution / advection of turbulence.
563            \begin{columns}[T]
564               \begin{column}{0.2\textwidth}
565                  %leer
566               \end{column}
567               \begin{column}{0.5\textwidth}
568                  \includegraphics[width=1\textwidth]{numerics_bc_figures/lateral_bc.png}\\
569                  \vspace{2mm}
570               \end{column}
571               \begin{column}{0.4\textwidth}
572                  $\begin{array}{rcl}
573                     \Psi(-1) &=& \Psi(n)\\
574                     \Psi(n+1) &=& \Psi(0)\\
575                  \end{array}$
576               \end{column}
577            \end{columns}
578   
579         \item<2-> Dirichlet (inflow) and radiation (outflow) conditions are allowed along
580            either $x$- or $y$-direction.
581
582         \item<3-> In case of a Dirichlet condition, the inflow is laminar (by default) and
583            the domain has to be extended to allow for the development of a turbulent
584            state, if neccessary.
585         \item<4->  Non-cyclic lateral conditions require the use of the multigrid-method
586            for solving the Poisson-equation.
587           
588      \end{itemize}
589   \end{itemize}
590\end{frame}
591
592% Folie 19
593\begin{frame}
594   \frametitle{Boundary Conditions (II)}
595   
596   \begin{columns}[T]
597      \begin{column}{0.7\textwidth}
598         \scriptsize
599         \begin{itemize}
600            \item<1-> Surface boundary condition:
601            \begin{itemize}
602               \scriptsize
603               \item<1-> Monin-Obukhov-similarity is used by default, i.e. a Prandtl-layer is
604                  assumed between the surface and the first grid layer.\\
605                  $\frac{\partial \overline{u}}{\partial z} = \frac{u_{*}}{\kappa z}
606                  \Phi_{\mathrm{m}}$; \hspace{3mm} $u_{*} = \sqrt{- \overline{w' u'_0}}
607                  = \sqrt{\frac{\tau_0}{\overline{\rho}}}$\\
608                  $\frac{\partial \overline{\theta}}{\partial z} = \frac{\vartheta_{*}}
609                  {\kappa z} \Phi_{\mathrm{h}}$; \hspace{3mm} $\vartheta_{*} = 
610                  \frac{\overline{w' \theta'_0}}{u_{*}}$\\
611               \vspace{2mm}
612               \item<2-> Integration between $z=z_0$ (roughness height) and $z=z_{\mathrm{p}}$
613                  (top of Prandtl-layer, $k=1$) gives the only unknowns $u_{*}$ and
614                  $\theta_{*}$ which then define the surface momentum and heat flux,
615                  used as the real boundary conditions.\\
616               \vspace{2mm}
617               \item<3-> $\Phi_{\mathrm{m}}$, $\Phi_{\mathrm{h}}$: Dyer-Businger functions\\
618               \onslide<4->$\Phi_{\mathrm{m}} = \left\{ \begin{array}{cc}
619                     1+5\,\mathrm{Rif} & \text{stable}\\
620                     1 & \text{neutral}\\
621                     (1-16\,\mathrm{Rif})^{-1/4} & \text{unstable}\\
622                  \end{array} \right. $
623
624            \end{itemize}
625         \end{itemize}
626      \end{column}
627      \begin{column}{0.3\textwidth}
628         \onslide<1->
629         \includegraphics[width=1\textwidth]{numerics_bc_figures/surface_bc.png}\\
630         \vspace{-2mm}
631         Prandtl-layer\\
632         \vspace{8mm}
633         \onslide<5->
634         $\mathrm{Rif} = \frac{\frac{g}{\tilde{\theta}}
635         \overline{w' \theta'_0}}{\overline{w' u'}
636         \frac{\partial \overline{u}}{\partial z}}$\\
637         \scriptsize Richardson flux number
638      \end{column}
639   \end{columns}
640\end{frame}
641
642% Folie 20
643\begin{frame}
644   \frametitle{Boundary Conditions (III)}
645
646   \begin{itemize}
647      \item<1-> Surface boundary condition:
648      \begin{itemize}
649         \footnotesize
650         \item<1-> Monin-Obukhov-similarity is only valid for a
651            horizontal surface with homogeneous conditions.
652         \item<2-> The surface temperature has to be prescribed.
653            Alternatively, the surface heat flux can be prescribed.
654         \item<3-> Instead of MO-similarity, no-slip conditions or
655            free-slip conditions can be used
656            \begin{equation*}
657               u(z=0) = 0, \quad v(z=0)=0 \hspace{15mm}
658               \frac{\partial u}{\partial z} = 0, \quad 
659               \frac{\partial v}{\partial z} = 0 \qquad
660            \end{equation*}
661            realized by
662            \begin{flalign*}
663               u(k=0)=-u(k=1) \hspace{18mm} u(k=0)=u(k=1)\\
664               v(k=0)=-v(k=1) \hspace{18mm} v(k=0)=v(k=1)
665            \end{flalign*}
666         \item<4-> Pressure boundary condition:
667            $\dfrac{\partial p}{\partial z} = 0$ 
668            in order to guarantee $w(z=0)=0$
669         \item<5-> SGS-TKE condition $\dfrac{\partial e}{\partial z}=0$
670      \end{itemize}
671   \end{itemize}
672\end{frame}
673
674% Folie 21
675\begin{frame}
676   \frametitle{Boundary Conditions (IV)}
677
678   \begin{itemize}
679      \item<1-> Boundary conditions at the top (default)
680      \begin{itemize}
681         \item<1-> Dirichlet conditions for velocities: $u=u_{\mathrm{g}},
682            \quad v=v_{\mathrm{g}}, \quad w=0$
683         \item<2-> Neumann conditions (temporal constant gradients) for scalars:
684            $$\frac{\partial \theta}{\partial z} = 
685            \left. \frac{\partial \theta}{\partial z} \right\vert_{t=0}$$
686         \item<3-> Pressure: Dirichlet $p=0$ 
687            ( Neumann $\dfrac{\partial p}{\partial z} = 0$ is better )
688         \item<4-> SGS-TKE: Neumann $\dfrac{\partial e}{\partial z} = 0$
689         \item<5-> A damping layer can be switched on in order to absorb
690            gravity waves.
691      \end{itemize}
692   \end{itemize}
693\end{frame}
694
695% Folie 22
696\begin{frame}
697   \frametitle{Initial Conditions}
698
699   All 3D-arrays are initialized with vertical profiles (horizontally homogeneous).\\
700   \quad \\
701   Two different profiles can be chosen:
702   \begin{itemize}
703      \item<2-> \textbf{constant (piecewise linear) profiles}
704         \begin{itemize}
705            \footnotesize
706            \item \textbf{e.g.} $u=0, v=0, \dfrac{\partial \theta}{\partial z}=0$ 
707               \textbf{up to} $z=\unit[1000]{m}$,
708               $\dfrac{\partial \theta}{\partial z}=+1.0$ \textbf{up to top}
709         \end{itemize}
710      \item<3-> \textbf{velocity profiles calculated by a 1D-model (which is a part of PALM)}
711         \begin{itemize}
712            \footnotesize
713            \item  \textbf{constant (piecewise linear) temperature profile is used
714               for the 1D-model}
715         \end{itemize}
716   \end{itemize}
717   \onslide<4->
718   \underline{Under horizontally homogeneous initial conditions, random}\\ 
719   \underline{fluctuations have to be added in order to generate turbulence!}
720\end{frame}
721
722\end{document}
Note: See TracBrowser for help on using the repository browser.