<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">% -*- mode: latex ; coding: utf-8 -*-
%
% Copyright(C) Youhei SASAKI, Shin-ichi Takehiro, SPMODEL Development Group.
%              All rights reserved.
% $Lastupdate: 2019-03-23 17:12:28$
% License: MIT/X11
%
% å¤ã„(obsolete)ã‚¹ã‚¿ã‚¤ãƒ«ã®è­¦å‘Šã‚’è¡¨ç¤º
\RequirePackage[l2tabu,orthodox]{nag}
\documentclass[xetex,slidetop,compress,c,12pt,cjk]{beamer}
% minted ã®ãŸã‚ã« xelatex ã§ typeset ã™ã‚‹ãŸã‚ã®ã‚ã‚Œã“ã‚Œ
\usepackage{zxjatype} % æ—¥æœ¬èªžãƒ•ã‚©ãƒ³ãƒˆã®æŒ‡å®š
\setjamainfont[BoldFont=IPAexGothic]{IPAexMincho}
\setjasansfont{IPAexGothic}
\setmonofont{Ubuntu Mono}
\setjamonofont[BoldFont=RictyDiminishedDiscord-Bold.ttf,ItalicFont=RictyDiminishedDiscord-Oblique.ttf]{RictyDiminishedDiscord-Regular.ttf}
\setbeamertemplate{navigation symbols}{}
\usepackage{amsmath,amssymb}
\usepackage[normalem]{ulem}
\usefonttheme[onlymath]{serif}
\usepackage{D6math}
% pygmentize: ã‚½ãƒ¼ã‚¹ã‚³ãƒ¼ãƒ‰ã® syntax highlight
\usepackage{minted}
% \usemintedstyle{}
\definecolor{mintedbg}{rgb}{0.95,0.95,0.95}
\newminted{fortran}{%
  bgcolor=mintedbg,mathescape,autogobble,fontsize=\footnotesize}
\newminted{sh}{%
  bgcolor=mintedbg,mathescape,autogobble,fontsize=\footnotesize}
\newmintinline{fortran}{fontsize=\footnotesize}
\newmintinline{sh}{fontsize=\footnotesize}
%% theme
\newenvironment{exampleenv}{\begin{altenv}{\usebeamertemplate{example text begin}\usebeamercolor[fg]{example text}\usebeamerfont{example text}}{\usebeamertemplate{example text end}}{\color{.}}{}}{\end{altenv}}
\newcommand&lt;&gt;{\example}[1]{\begin{exampleenv}#2\relax#1\end{exampleenv}}
\usetheme{Madrid}
% hyperref: set link color
\definecolor{links}{HTML}{FF7F7F}
\hypersetup{colorlinks,linkcolor=,urlcolor=links}
% titlepage ã®ãƒ•ã‚©ãƒ³ãƒˆã®å¤§ãã•
\setbeamerfont{title}{size=\Large}
\setbeamerfont{author}{size=\normalsize}
% frametitle ã® centering
\setbeamertemplate{frametitle}[default][center]
% \setbeamercolor{frametitle}{fg=black}
% itemize ã® indent èª¿æ•´
\setlength{\leftmargini}{1em}
\setlength{\leftmarginii}{.5em}
\setlength{\leftmarginiii}{.5em}
% itemize/enumerate ã®æ–‡ç«&nbsp;ã®ã‚µã‚¤ã‚º
\setbeamerfont{itemize/enumerate body}{size=\normalsize}
\setbeamerfont{itemize/enumerate subbody}{size=\small}
\setbeamerfont{itemize/enumerate subsubbody}{size=\footnotesize}
\setbeamertemplate{itemize item}{\scriptsize\raise1.25pt\hbox{\donotcoloroutermaths$\blacktriangleright$}}
\setbeamertemplate{itemize subitem}{\tiny\raise1.5pt\hbox{\donotcoloroutermaths$\bullet$}}
\setbeamertemplate{itemize subsubitem}{\tiny\raise1.5pt\hbox{\donotcoloroutermaths$-$}}
\setbeamertemplate{enumerate item}{\insertenumlabel.}
\setbeamertemplate{enumerate subitem}{\insertenumlabel.\insertsubenumlabel}
\setbeamertemplate{enumerate subsubitem}{\insertenumlabel.\insertsubenumlabel.\insertsubsubenumlabel}
\setbeamertemplate{enumerate mini template}{\insertenumlabel}
% ä½™ç™½èª¿æ•´
\setbeamersize{text margin left=.025\paperwidth}
\setbeamersize{text margin right=.025\paperwidth}
% â†’, â†
\newcommand{\RArrow}{\textbf{$\Rightarrow$}}
\newcommand{\LArrow}{\textbf{$\rightarrow$}}

\title[dcmodel/davisãƒãƒ¥ãƒ¼ãƒˆãƒªã‚¢ãƒ«]{éšŽå±¤çš„åœ°çƒæµä½“ã‚¹ãƒšã‚¯ãƒˆãƒ«ãƒ¢ãƒ‡ãƒ«é›†SPMODEL}
% \subtitle{$\sim$dcmodel/davis ãƒãƒ¥ãƒ¼ãƒˆãƒªã‚¢ãƒ«$\sim$}
\author[ä½ã€…æœ¨ \&amp; ç«¹åºƒ with åœ°çƒæµä½“é›»è„³å€¶æ¥½éƒ¨]{%
  ä½ã€…æœ¨æ´‹å¹³(äº¬å¤§ãƒ»æ•°å­¦), ç«¹åºƒçœŸä¸€(äº¬å¤§ãƒ»æ•°ç†ç&nbsp;”)
  \newline%
  with%
  \newline åœ°çƒæµä½“é›»è„³å€¶æ¥½éƒ¨%
  \newline SPMODEL ãƒ—ãƒ­ã‚¸ã‚§ã‚¯ãƒˆ%
  \newline dcmodel ãƒ—ãƒ­ã‚¸ã‚§ã‚¯ãƒˆ%
  \newline davis ãƒ—ãƒ­ã‚¸ã‚§ã‚¯ãƒˆ
}
\date[2019/03/29]{\small{2019å¹´3æœˆ29æ—¥}}

\begin{document}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{frame}[c]
  \titlepage
\end{frame}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{ã¯ã˜ã‚ã«}
\begin{frame}[c]
  \frametitle{æœ¬æ—¥ã®ãŠé¡Œ}

  \centering
  {\Large{\alert{æ•°å¼ã‚’æ›¸ãã‚ˆã†ã«ãƒ—ãƒ­ã‚°ãƒ©ãƒŸãƒ³ã‚°!!}}}
  \\ \vspace{.8em}
  ã—ã‹ã‚‚
  \\ \vspace{.8em}
  {\Large{\structure{ã‚¹ãƒšã‚¯ãƒˆãƒ«æ³•ã§!!}}}
  \\ \vspace{.8em}
  ã•ã‚‰ã«
  \\ \vspace{.8em}
  {\Large{\example{ç°¡å˜ã«è¨ˆç®—ãƒ‡ãƒ¼ã‚¿ã®å‡ºåŠ›\&amp;æç”»ã‚’!!}}}

\end{frame}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{ã¾ãšã¯ä½¿ã£ã¦ã¿ã‚ˆã†!}
\begin{frame}[c]
  \frametitle{ä¾‹é¡Œ: ä¸€æ¬¡å…ƒç§»æµæ–¹ç¨‹å¼}
  \vspace{-2em}
  {\Large{%
      \begin{align*}
        \DP{\zeta}{t} = -c \DP{\zeta}{x}
      \end{align*}
    }}
  \begin{itemize}
  \item ä¸€æ¬¡å…ƒå‘¨æœŸå¢ƒç•Œæ¡ä»¶: $\zeta(x+L, t) = \zeta(x, t)$
  \item åˆæœŸæ¡ä»¶: $\zeta(x,t) = \zeta_{0}(x)$
  \item ã¡ãªã¿ã«è§£æžè§£ã¯ $\zeta(x,t) = \zeta_{0}(x - ct)$
  \item ã‚µãƒ³ãƒ—ãƒ«ãƒ—ãƒ­ã‚°ãƒ©ãƒ&nbsp;ãã®1: \example{\texttt{advect.f90}}
  \end{itemize}
\end{frame}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{frame}[fragile,c]
  \frametitle{ã¾ãšã¯ä½¿ã£ã¦ã¿ã‚ˆã†!}
  \begin{itemize}
  \item ã‚³ãƒ³ãƒ‘ã‚¤ãƒ«
    \begin{shcode}
% spmfrt -o advect.out advect.f90
    \end{shcode}
    \begin{flushright}
      {\footnotesize{\RArrow \example{\texttt{advect.out}} ãŒç”Ÿæˆã•ã‚Œã‚‹}}
    \end{flushright}
  \item å®Ÿè¡Œ
    \begin{shcode}
% ./advect.out
    \end{shcode}
    \begin{flushright}
      {\footnotesize{\RArrow \example{\texttt{advect.nc}} ãŒå‡ºåŠ›ã•ã‚Œã‚‹}}
    \end{flushright}
  \item çµæžœè¡¨ç¤º
    \begin{shcode}
% gplist advect.nc
% gpview --anim t advect.nc@zeta
% gpview --range 0:1.5e3 --anim t --Gaw advect.nc@zeta
    \end{shcode}
  \end{itemize}
\end{frame}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{frame}[fragile,c]
  \frametitle{ç”¨ã„ã¦ã„ã‚‹ãƒ†ã‚¯ãƒ‹ãƒƒã‚¯ã¨ãƒ©ã‚¤ãƒ–ãƒ©ãƒª}
  \begin{itemize}
  \item Fortran($&gt;=$90)ã®é…åˆ—æ¼”ç®—è¨˜æ³•: \alert{é…åˆ—ã‚’è¿”ã™é–¢æ•°}
    \begin{columns}
      \begin{column}{.45\textwidth}
        \begin{fortrancode}
DO I=1,IM
   A(I) = B(I) + C(I)
ENDDO
        \end{fortrancode}
      \end{column}
      \begin{column}{.025\textwidth}
        \footnotesize{\RArrow}
      \end{column}
      \begin{column}{.4\textwidth}
        \hspace{-1em}
        \begin{minted}[%
          bgcolor=mintedbg,mathescape,autogobble,fontsize=\normalsize]{fortran}
A = B + C
        \end{minted}
      \end{column}
    \end{columns}
    \begin{columns}
      \begin{column}{.45\textwidth}
        \begin{fortrancode}
DO I=1,IM
   DATA(I) = EXP(-X(I)**2)
ENDDO
        \end{fortrancode}
      \end{column}
      \begin{column}{.025\textwidth}
        \footnotesize{\RArrow}
      \end{column}
      \begin{column}{.4\textwidth}
        \begin{minted}[bgcolor=mintedbg,mathescape,autogobble,fontsize=\normalsize]{fortran}
DATA = EXP(-X**2)
        \end{minted}
      \end{column}
    \end{columns}
  \item \structure{spmodel library}(spml): æ­£/é€†å¤‰æ›, ç©ºé–“å¾®åˆ†ãªã©ã‚’æä¾›
  \item çµæžœå‡ºåŠ›: \example{gtool5 library}
  \item çµæžœè¡¨ç¤º: Dennou Ruby è£½å“ç¾¤(GPhys, \example{gpview} $\cdots$)
  \end{itemize}
\end{frame}

\begin{frame}[c]
  \frametitle{ã‚¹ãƒšã‚¯ãƒˆãƒ«æ³•ã«ã‚ˆã‚‹æ•°å€¤è¨ˆç®—}
  \begin{enumerate}
  \item å¢ƒç•Œæ¡ä»¶ã‚’æº€ãŸã™é–¢æ•°ç³»ã§å±•é–‹
    {\small{%
        \begin{align*}
          \zeta(x_{j},t) = \sum_{k=-K}^{K} \tilde{\zeta}_{k}(t) e^{i \frac{2\pi k x_{j}}{L}},
          \quad %
          \tilde{\zeta}_{k}(t) = \frac{1}{J}\sum_{j=0}^{J-1} \zeta(x_{j},t)e^{- i \frac{2\pi k x_{j}}{L}}
        \end{align*}
      }}
  \item æ–¹ç¨‹å¼ã«ä»£å…¥ã™ã‚‹ã¨å¸¸å¾®åˆ†æ–¹ç¨‹å¼ã«ãªã‚‹
    {\small{%
        \begin{align*}
          \DD{\zeta_{k}}{t} = - c i \frac{2\pi k}{L} \tilde{\zeta}_{k}
        \end{align*}
      }}
  \item é©å½“ãªåˆæœŸå€¤ã‹ã‚‰é›¢æ•£åŒ–ã—ã¦æ™‚é–“ç©åˆ†
    {\small{%
        \begin{align*}
          \tilde{\zeta}_{k}(t+\Delta t) = \tilde{\zeta}_{k}(t) - c i \frac{2\pi k}{L} \tilde{\zeta}_{k}~\Delta t
        \end{align*}
      }}
  \item å®Ÿç©ºé–“ã®å¤‰æ•°ã«æˆ»ã™
    {\small{%
        \begin{align*}
          \zeta(x_{j},t) = \sum_{k=-K}^{K} \tilde{\zeta}_{k}(t) e^{i \frac{2\pi k x_{j}}{L}},
        \end{align*}
      }}
  \end{enumerate}
\end{frame}

\begin{frame}[fragile,c,shrink=5]
  \frametitle{æ•°å€¤è¨ˆç®—ã®æ‰‹é&nbsp;†}
  \begin{enumerate}
  \item ä½¿ç”¨ã™ã‚‹ãƒ¢ã‚¸ãƒ¥ãƒ¼ãƒ«ã®å®£è¨€
    \begin{fortrancode}
use ae_module
    \end{fortrancode}
  \item å¤‰æ•°å®£è¨€
    \begin{fortrancode}
real(kind(1.0D0)) :: g_Zeta(0:im-1)  ! æ&nbsp;¼å­ç‚¹ãƒ‡ãƒ¼ã‚¿
real(kind(1.0D0)) :: e_Zeta(-km:km)  ! ã‚¹ãƒšã‚¯ãƒˆãƒ«ãƒ‡ãƒ¼ã‚¿
    \end{fortrancode}
  \item ã‚¹ãƒšã‚¯ãƒˆãƒ«å¤‰æ›ã®åˆæœŸåŒ–
    \begin{fortrancode}
call ae_Initial(im,km,xmin,xmax)
    \end{fortrancode}
  \item åˆæœŸå€¤ã‚’ä¸Žãˆã‚‹
    \begin{fortrancode}
g_Zeta = U1*sech((g_X-X1)/sqrt(12/u1))**2   &amp;
     &amp; + U2*sech((g_X-X2)/sqrt(12/u2))**2
    \end{fortrancode}
  \item ã‚¹ãƒšã‚¯ãƒˆãƒ«ãƒ‡ãƒ¼ã‚¿ã«å¤‰æ›
    \begin{fortrancode}
e_Zeta = e_g(g_Zeta)
    \end{fortrancode}
  \item ã‚¹ãƒšã‚¯ãƒˆãƒ«ãƒ‡ãƒ¼ã‚¿ã‚’æ™‚é–“ç©åˆ†
    \begin{fortrancode}
e_Zeta = e_Zeta + dt*( - c *e_Dx_e(e_Zeta))
    \end{fortrancode}
  \item å®Ÿç©ºé–“ãƒ‡ãƒ¼ã‚¿ã«æˆ»ã—ã¦å‡ºåŠ›
    \begin{fortrancode}
g_Zeta = g_e(e_Zeta)
    \end{fortrancode}
  \end{enumerate}
\end{frame}

\begin{frame}[fragile]
  \frametitle{spml/ae\_module}
  {\centering{ã‚¹ãƒšã‚¯ãƒˆãƒ«è¨ˆç®—ã®ãŸã‚ã®ã‚µãƒ–ãƒ«ãƒ¼ãƒãƒ³ãƒ»é–¢æ•°ã‚’æä¾›}}
  \begin{itemize}
  \item åˆæœŸåŒ–
    \begin{fortrancode}
subroutine ae_Initial(im, km, xmin, xmax)
    \end{fortrancode}
  \item ã‚¹ãƒšã‚¯ãƒˆãƒ«æ­£å¤‰æ›/é€†å¤‰æ›
    \begin{fortrancode}
e_g(g_Data)   ! æ&nbsp;¼å­ç‚¹ $\to$ ã‚¹ãƒšã‚¯ãƒˆãƒ«ãƒ‡ãƒ¼ã‚¿
g_e(e_Data)   ! ã‚¹ãƒšã‚¯ãƒˆãƒ«ãƒ‡ãƒ¼ã‚¿ $\to$ æ&nbsp;¼å­ç‚¹ãƒ‡ãƒ¼ã‚¿
    \end{fortrancode}
  \item å¾®åˆ†è¨ˆç®—
    \begin{fortrancode}
e_Dx_e(e_Data) ! X å¾®åˆ†
    \end{fortrancode}
  \item ç©åˆ†ãƒ»å¹³å‡æ¼”ç®—
    \begin{fortrancode}
Int_g(g_Data)  ! å…¨é&nbsp;˜åŸŸç©åˆ†
Avr_g(g_Data)  ! å…¨é&nbsp;˜åŸŸå¹³å‡
    \end{fortrancode}
  \end{itemize}
\end{frame}

\begin{frame}[c,fragile]
  \frametitle{spml/ae\_module}
  \begin{itemize}
  \item ãã®ä¸­èº«ã¯?
    \begin{itemize}
    \item ISPACK(çŸ³å²¡, 2015)ã‚’ Fortran90 ã®é–¢æ•°ã§ãã‚‹ã‚“ã&nbsp;ã‚‚ã®
    \item FFTç”¨ã®å¤‰æ›ãƒ†ãƒ¼ãƒ–ãƒ«, é&nbsp;˜åŸŸã®å¤§ãã•â†’å¾®åˆ†è¨ˆç®—ã«ä½¿ç”¨
    \item åº§æ¨™å¤‰æ•°ã®è¨­å®š: \fortraninline|g_X, g_X_weight|
    \item å¾®åˆ†æ¼”ç®—â†’æ³¢æ•°ã®ã‹ã‘ç®—: \fortraninline|e_Dx_e(k) = - 2*pi*(k/L)*e_Data(-k)|
    \end{itemize}
  \item å¾¡åˆ©ç›Š: \alert{æ•°å¼ã®å¦‚ããƒ—ãƒ­ã‚°ãƒ©ãƒ&nbsp;ãŒæ›¸ã‘ã‚‹}
    \begin{columns}
      \begin{column}{.2\textwidth}
        \begin{align*}
          f = \DP{\zeta}{x} \quad \Rightarrow
        \end{align*}
      \end{column}
      \begin{column}[c]{.65\textwidth}
        \vspace{.8em}
        \begin{minted}[bgcolor=mintedbg,mathescape,autogobble,fontsize=\normalsize]{fortran}
  e_f = e_Dx_e(e_Zeta)
        \end{minted}
      \end{column}
    \end{columns}
    \begin{columns}
      \begin{column}{.2\textwidth}
        \begin{align*}
          f = \DP[2]{\zeta}{x} \quad \Rightarrow
        \end{align*}
      \end{column}
      \begin{column}[c]{.65\textwidth}
        \vspace{1em}
        \begin{minted}[bgcolor=mintedbg,mathescape,autogobble,fontsize=\normalsize]{fortran}
  e_f = e_Dx_e(e_Dx_e(e_Zeta))
        \end{minted}
      \end{column}
    \end{columns}
  \end{itemize}
\end{frame}

\begin{frame}[c,fragile]
  \frametitle{spml ãƒ—ãƒ­ã‚°ãƒ©ãƒŸãƒ³ã‚°æ›¸æ³•}
  \begin{itemize}
  \item å…ˆé&nbsp;­ã®æ–‡å­—ã§å¤‰æ•°ã®ç¨®é¡žã‚’åŒºåˆ¥:
  \item å®Ÿç©ºé–“æ&nbsp;¼å­ç‚¹ãƒ‡ãƒ¼ã‚¿: \fortraninline|g_| ã§å§‹ã‚ã‚‹
  \item ã‚¹ãƒšã‚¯ãƒˆãƒ«ãƒ‡ãƒ¼ã‚¿: \fortraninline|e_| ã§å§‹ã‚ã‚‹
  \item spmlã®é–¢æ•°åã®å‘½åè¦å‰‡:
    \begin{center}
      \alert{(å‡ºåŠ›ã®åž‹)\_(æ©Ÿèƒ½)\_(å…¥åŠ›ã®åž‹)}
    \end{center}
  \item ç¸®ç´„ã®å¦‚ããƒ—ãƒ­ã‚°ãƒ©ãƒ&nbsp;ã‚’æ›¸ã‘ã°åž‹ã‚’é–“é•ãˆã«ãã„
    \begin{minted}[bgcolor=mintedbg,mathescape,autogobble,fontsize=\normalsize]{fortran}
g_Data = g_e(e_Dx_e(e_g(g_Data1)))
    \end{minted}
  \end{itemize}
\end{frame}

\begin{frame}[fragile]
  \frametitle{ç·´ç¿’å•é¡Œ(1)}
  \begin{itemize}
  \item ç§»æµæ–¹ç¨‹å¼ã«æ‹¡æ•£é&nbsp;…ã‚’ä»˜ã‘åŠ&nbsp;ãˆã¦ã¿ã‚ˆã†
    {\Large{%
        \begin{align*}
          \DP{\zeta}{t} = -c \DP{\zeta}{x} + \textcolor{red}{\uwave{\textcolor{black}{\DP[2]{\zeta}{x}}}}
        \end{align*}
      }}
  \item Euler scheme ã&nbsp;ã¨ã“ã‚“ãªæ„Ÿã˜..?
    \begin{minted}[bgcolor=mintedbg,mathescape,autogobble,fontsize=\normalsize]{fortran}
e_Zeta = e_Zeta                              &amp;
       &amp; + dt * ( - c * e_Dx_e(e_Zeta)       &amp;
       &amp;          + e_Dx_e(e_Dx_e(e_Zeta)) )
     \end{minted}
  \end{itemize}
\end{frame}

\begin{frame}[fragile]
  \frametitle{éžç·šåž‹é&nbsp;…ã®å–ã‚Šæ‰±ã„(å¤‰æ›æ³•)}
  \begin{itemize}
  \item ç§»æµé&nbsp;…ãŒéžç·šåž‹ $\displaystyle{\zeta\DP{\zeta}{x}}$ ã§ã‚ã‚‹å&nbsp;´åˆã«ã¯
    \begin{center}
      \structure{ã‚¹ãƒšã‚¯ãƒˆãƒ«å¤‰æ•°ã‚’ä¸€åº¦å®Ÿç©ºé–“ã«æˆ»ã—ã¦ã‹ã‚‰ç©ã‚’å–ã‚‹}
    \end{center}
  \end{itemize}
  \begin{itemize}
  \item spml ã®é–¢æ•°ã‚’ç”¨ã„ã‚‹ã¨ä¸€è¡Œã§æ›¸ã‘ã‚‹
    \begin{fortrancode}
g_e(e_Zeta) * g_e(e_Dx_e(e_Zeta))
    \end{fortrancode}
  \end{itemize}
\end{frame}

\begin{frame}[fragile,c]
  \frametitle{ç·´ç¿’å•é¡Œ(2)}
  \begin{itemize}
  \item \texttt{advect\_lf.f90} ã‚’å…ƒã« KdVæ–¹ç¨‹å¼ã®ãƒ—ãƒ­ã‚°ãƒ©ãƒ&nbsp;ã‚’æ›¸ã„ã¦ã¿ã‚ˆã†
    \begin{align*}
      \DP{\zeta}{t} = - \zeta \DP{\zeta}{x} - \textcolor{red}{\uwave{\textcolor{black}{\DP[3]{\zeta}{x}}}}
    \end{align*}
  \item Leap frog scheme ã&nbsp;ã¨ã“ã‚“ãªæ„Ÿã˜..?
  \end{itemize}
  \begin{fortrancode}
e_Zeta = e_Zeta0                                                 &amp;
     &amp; + 2 * dt * ( - e_g(g_e(e_Zeta1) * g_e(e_Dx_e(e_Zeta1)))   &amp;
     &amp;              - e_Dx_e(e_Dx_e(e_Dx_e(e_Zeta1)))          ) &amp;
e_Zeta0 = e_Zeta1 ; e_Zeta1 = e_Zeta
  \end{fortrancode}
  \begin{itemize}
  \item åˆ‡æ–­æ³¢æ•°ã®å–ã‚Šæ–¹ã«æ³¨æ„
    \begin{itemize}
    \item å¤‰æ•°ã®ç©ã‹ã‚‰é«˜æ³¢æ•°æˆåˆ†ãŒç”Ÿæˆã•ã‚Œã‚‹ \\
      \RArrow J$\sim$2K+1ã®æ&nbsp;¼å­ç‚¹æ•°ã§ã¯ååˆ†ã«è¡¨ç¾ã§ããªã„
    \item 2æ¬¡ã®éžç·šåž‹é&nbsp;…ãªã‚‰æ&nbsp;¼å­ç‚¹æ•°ã¯ J $\ge$ 3K+1 ã«å¢—ã‚„ã—ã¦ãŠã
    \end{itemize}
  \end{itemize}
\end{frame}

\section{SPMODELãƒ—ãƒ­ã‚°ãƒ©ãƒŸãƒ³ã‚°}

\begin{frame}[fragile,c,shrink=10]
  \frametitle{SPMODELãƒ—ãƒ­ã‚°ãƒ©ãƒŸãƒ³ã‚°}
  \begin{enumerate}
  \item é&nbsp;˜åŸŸã¨å¢ƒç•Œæ¡ä»¶ã«é©åˆã—ãŸãƒ¢ã‚¸ãƒ¥ãƒ¼ãƒ«ã‚’é¸æŠž
  \item æ”¯é…æ–¹ç¨‹å¼ã‚’å½¢å¼çš„ã«ã‚¹ãƒšã‚¯ãƒˆãƒ«å¤‰æ›
    \begin{align*}
      \DP{\tilde{\zeta}_{m}}{t}
      = - \left[ \zeta \DP{\tilde{\zeta}}{x} \right] - \left[ \DP[3]{\tilde{\zeta}_{m}}{x} \right]
  \end{align*}
\item é©å½“ãªã‚¹ã‚­ãƒ¼ãƒ&nbsp;ã§æ™‚é–“ã«é–¢ã—ã¦å·®åˆ†åŒ–
  \begin{align*}
    \tilde{\zeta}^{\tau+1}_{m} = \tilde{\zeta}^{\tau}_{m} +\Delta t \times \left\{ - \left[ \zeta \DP{\tilde{\zeta}}{x} \right] - \left[ \DP[3]{\tilde{\zeta}_{m}}{x} \right] \right\}
  \end{align*}
\item 2,3 ã«å¾“ã£ã¦ãƒ—ãƒ­ã‚°ãƒ©ãƒ&nbsp;ã‚’æ›¸ã
  \begin{fortrancode}
e_Zeta = e_Zeta                                             &amp;
     &amp; + dt * ( - e_g(g_e(e_Zeta) * g_e(e_Dx_e(e_Zeta)))    &amp;
     &amp;          - e_Dx_e(e_Dx_e(e_Dx_e(e_Zeta)))          )
  \end{fortrancode}
  \end{enumerate}
\end{frame}

\begin{frame}[fragile]
  \frametitle{ã‚‚ã£ã¨ãŠã™ã™ã‚ã®æ–¹æ³•}
  \begin{itemize}
  \item ã‚µãƒ³ãƒ—ãƒ«ãƒ»ãƒ‡ãƒ¢ãƒ—ãƒ­ã‚°ãƒ©ãƒ&nbsp;ã‚’å…ƒã«æ”¹é€&nbsp;
    \begin{itemize}
    \item è¨ˆç®—ã—ãŸã„é&nbsp;˜åŸŸå½¢çŠ¶ã«å³ã—ãŸãƒ¢ã‚¸ãƒ¥ãƒ¼ãƒ«ã®ã‚µãƒ³ãƒ—ãƒ«
    \item (ãŸã„ã¦ã„)æ‹¡æ•£æ–¹ç¨‹å¼ç”¨ã®ãƒ—ãƒ­ã‚°ãƒ©ãƒ&nbsp;ãŒç”¨æ„ã•ã‚Œã¦ã„ã‚‹
    \item å¿…è¦ã«å¿œã˜ã¦å¤‰æ•°ã‚’è¿½åŠ&nbsp;, æ¼”ç®—ã‚’å¤‰æ›´
    \item æ™‚é–“ç©åˆ†éƒ¨åˆ†ã‚’æ”¹é€&nbsp;
    \end{itemize}
  \item ã‚µãƒ³ãƒ—ãƒ«ã®ç½®ãå&nbsp;´æ‰€:
    \begin{itemize}
    \item Web: \url{http://www.gfd-dennou.org/library/spmodel/}
    \end{itemize}
  \end{itemize}
\end{frame}

\begin{frame}[fragile]
  \frametitle{ä¸€èˆ¬çš„æ³¨æ„}
  \begin{itemize}
  \item ãƒ©ã‚¤ãƒ–ãƒ©ãƒªãƒ»ã‚µãƒ³ãƒ—ãƒ«ãƒ—ãƒ­ã‚°ãƒ©ãƒ&nbsp;ã¯ç„¡ä¿è¨¼
    \begin{itemize}
    \item å¿…ãšè‡ªåˆ†ã§ãƒ†ã‚¹ãƒˆã—ã¦ã¿ã‚‹ã“ã¨
    \item ã§ãã‚Œã°è§£æžè§£ã¨æ¯”è¼ƒã—ã¦ã¿ã‚‹
    \end{itemize}
  \item ãƒžãƒ‹ãƒ¥ã‚¢ãƒ«ã‚’è¦‹ã‚ˆã†
    \begin{itemize}
    \item æ°—åˆ†ã§ãƒ—ãƒ­ã‚°ãƒ©ãƒ&nbsp;ã‚’æ›¸ãã®ã¯å±é™º
    \item ãƒžãƒ‹ãƒ¥ã‚¢ãƒ«ã§ç¢ºèªã—ã¤ã¤æ›¸ãã“ã¨\\
      \structure{spml ã®ãƒžãƒ‹ãƒ¥ã‚¢ãƒ«ã‚’è¦‹ã¦ã¿ã‚ˆã†!}\\
      \structure{ãƒ¢ã‚¸ãƒ¥ãƒ¼ãƒ«ã¨è¨ˆç®—é&nbsp;˜åŸŸãƒ»å¢ƒç•Œæ¡ä»¶ã«æ³¨ç›®!}
      \begin{itemize}
      \item local: \url{http://localhost/spmodel/reference/}
      \item Web: \url{http://www.gfd-dennou.org/library/spmodel/}
      \end{itemize}
    \end{itemize}
  \item ã§ãã‚Œã°ã‚½ãƒ¼ã‚¹ã‚‚è¦‹ã¦ã¿ã‚ˆã†
  \end{itemize}
\end{frame}

\section{ãŠæ‰‹è»½å‡ºåŠ›\&amp;ãƒ‡ãƒ¼ã‚¿è§£æž}

\begin{frame}[fragile,c]
  \frametitle{å‡ºåŠ›æ“ä½œ: gtool5 library}
  \begin{itemize}
  \item ãƒ¢ã‚¸ãƒ¥ãƒ¼ãƒ«ã®å®£è¨€
    \begin{fortrancode}
use gtool_history
    \end{fortrancode}
  \item å‡ºåŠ›ãƒ•ã‚¡ã‚¤ãƒ«ã®ä½œæˆã€æ¬¡å…ƒã®å®šç¾©
    \begin{fortrancode}
call HistoryCreate(...
    \end{fortrancode}
  \item å¤‰æ•°ã®å®šç¾©
    \begin{fortrancode}
call HistoryAddVariable(...
    \end{fortrancode}
  \item å‡ºåŠ›
    \begin{fortrancode}
call HistoryPut(...
    \end{fortrancode}
  \item çµ‚äº†
    \begin{fortrancode}
call HistoryClose
    \end{fortrancode}
  \end{itemize}
\end{frame}

\begin{frame}[fragile]
  \frametitle{ç·´ç¿’å•é¡Œ(3): å‡ºåŠ›å¤‰æ•°ã®è¿½åŠ&nbsp;}
  \begin{itemize}
  \item \texttt{advect.f90} ã‚’ä½¿ã£ã¦ $\displaystyle{\DP{\zeta}{x}}$ ã‚’ $x,t$ ã®2æ¬¡å…ƒãƒ‡ãƒ¼ã‚¿ã¨ã—ã¦å‡ºåŠ›ã—ã¦ã¿ã‚‹
  \item å¤‰æ•°å®šç¾©ã®è¿½åŠ&nbsp;
    \begin{fortrancode}
call HistoryAddVariable(                     &amp;
       varname='dzetadx', dims=(/'x','t'/),  &amp;
       longname='derivative of displacement',&amp;
       units='1', xtype='double')
     \end{fortrancode}
  \item å‡ºåŠ›ãƒ«ãƒ¼ãƒãƒ³ã®è¿½åŠ&nbsp;
     \begin{fortrancode}
call HistoryPut('dzetadx',g_e(e_Dx_e(e_Zeta)))
     \end{fortrancode}
   \end{itemize}
\end{frame}

\begin{frame}[fragile]
  \frametitle{ç·´ç¿’å•é¡Œ(4): å‡ºåŠ›å¤‰æ•°ã®è¿½åŠ&nbsp;}
  \begin{itemize}
  \item $\displaystyle{\int_{0}^{L} \zeta^{2}\Dd x}$ ã‚’ $t$ ã®1æ¬¡å…ƒãƒ‡ãƒ¼ã‚¿ã¨ã—ã¦å‡ºåŠ›ã—ã¦ã¿ã‚‹
    \begin{itemize}
    \item å¤‰æ•°å®šç¾©ã®è¿½åŠ&nbsp;(æ¬¡å…ƒã«æ³¨æ„)
      \begin{fortrancode}
call HistoryAddVariable(                      &amp;
       varname='z2int', dims=(/'t'/),         &amp;
       longname='Integral of square of zeta', &amp;
       units='1', xtype='double')
     \end{fortrancode}
   \item å‡ºåŠ›ãƒ«ãƒ¼ãƒãƒ³ã®è¿½åŠ&nbsp;
     \begin{fortrancode}
call HistoryPut('z2int',Int_g(g_e(e_Zeta)*g_e(e_Zeta)))
     \end{fortrancode}
   \item \example{gpprint} ã‚³ãƒžãƒ³ãƒ‰ã§æ•°å­—ã‚’å‡ºåŠ›ã—ã¦ã¿ã‚‹
    \begin{shcode}
% gpprint advect.nc@z2int
    \end{shcode}
  \end{itemize}
\end{itemize}
\end{frame}

\begin{frame}[fragile,c]
  \frametitle{ä¾‹é¡Œ: 2æ¬¡å…ƒæ‹¡æ•£æ–¹ç¨‹å¼}
  \begin{itemize}
  \item 2æ¬¡å…ƒå‘¨æœŸå¢ƒç•Œæ¡ä»¶ã®ä¸‹ã§è§£ã„ã¦ã¿ã‚‹
    \begin{align*}
      \DP{\zeta}{t} = \nu \left( \DP[2]{\zeta}{x} + \DP[2]{\zeta}{y} \right)
    \end{align*}
  \item ã‚µãƒ³ãƒ—ãƒ«ãƒ—ãƒ­ã‚°ãƒ©ãƒ&nbsp;: \texttt{diffuse\_2d.f90}
  \end{itemize}
  \begin{center}
  \structure{ã‚³ãƒ³ãƒ‘ã‚¤ãƒ«ã—ã¦å®Ÿè¡Œã—ã¦ã¿ã‚ˆã†} \\
  \structure{ã‚½ãƒ¼ã‚¹ãƒ•ã‚¡ã‚¤ãƒ«ã‚’çœºã‚ã¦ã¿ã‚ˆã†}
  \end{center}
\end{frame}

\begin{frame}[fragile]
  \frametitle{gpview ã®ä¾¿åˆ©ãªã‚ªãƒ—ã‚·ãƒ§ãƒ³}
  \begin{itemize}
  \item ç¯„å›²æŒ‡å®š
    \begin{shcode}
% gpview --range 0:1 --anim t diffuse_2d.nc@zeta
    \end{shcode}
  \item ãƒ‡ãƒ¼ã‚¿åˆ‡å‡ºã—
    \begin{shcode}
% gpview --anim t diffuse_2d.nc@zeta,x=0.5
% gpview diffuse_2d.nc@zeta,x=0.5,y=0.5
    \end{shcode}
  \item å¹³å‡æ“ä½œ
    \begin{shcode}
% gpview --mean x --anim t diffuse_2d.nc@zeta
    \end{shcode}
  \item ãã®ä»–ã®ã‚ªãƒ—ã‚·ãƒ§ãƒ³
    \begin{shcode}
% gpview --help
% man gpview
    \end{shcode}
  \end{itemize}
\end{frame}

\begin{frame}[fragile]
  \frametitle{ãã®ä»–ã®ä¾‹é¡Œ}
  \begin{itemize}
  \item 2æ¬¡å…ƒãƒ™ãƒ¼ã‚¿é¢:ãƒ¢ãƒ‰ãƒ³
  \item 2æ¬¡å…ƒãƒãƒ£ãƒãƒ«é&nbsp;˜åŸŸ:ç†±å¯¾æµå•é¡Œ
  \item 2æ¬¡å…ƒçƒé¢é&nbsp;˜åŸŸ:ãƒ­ã‚¹ãƒ“ãƒ¼æ³¢\\
    $\cdots$
  \item Web ã‚’è¦‹ã¦ã¿ã‚ˆã†
    \begin{itemize}
    \item Web:\\
      \url{http://www.nagare.or.jp/mm/2006/spmodel/}\\
      \url{http://www.gfd-dennou.org/library/spmodel/}
    \end{itemize}
  \end{itemize}
\end{frame}

\begin{frame}[fragile]
  \frametitle{ç·´ç¿’å•é¡Œ(5)}
  \begin{itemize}
  \item ç§»æµæ–¹ç¨‹å¼ã«å¤‰ãˆã¦ã¿ã‚ˆã†
    \begin{align*}
      \DP{\zeta}{t} = - c_{x} \DP{\zeta}{x} - c_{y} \DP{\zeta}{y}
    \end{align*}
  \item Euler scheme ã&nbsp;ã¨ã“ã‚“ãªæ„Ÿã˜?
    \begin{fortrancode}
ee_Zeta = ee_Zeta                           &amp;
      &amp; + dt *( - cx * ee_Dx_ee(ee_Zeta)    &amp;
      &amp;         - cy * ee_Dy_ee(ee_Zeta)   )
    \end{fortrancode}
  \item Leap frog scheme ã®æ–¹ãŒå®‰å®šæ€§ãŒã‚ˆã‚ã—ã„
    \begin{fortrancode}
ee_Zeta = ee_Zeta0                           &amp;
      &amp; + dt * ( - cx * ee_Dx_ee(ee_Zeta1)   &amp;
      &amp;          - cy * ee_Dy_ee(ee_Zeta1) )
ee_Zeta0 = ee_Zeta1; ee_Zeta1=ee_Zeta2
    \end{fortrancode}
  \end{itemize}
\end{frame}

\begin{frame}[fragile]
  \frametitle{ç·´ç¿’å•é¡Œ(6)}
  \begin{itemize}
  \item ç·šåž‹$\beta$é¢é&nbsp;†åœ§æ–¹ç¨‹å¼ã«å¤‰ãˆã¦ã¿ã‚ˆã†
    \begin{align*}
      \DP{\zeta}{t} = - \beta \DP{\psi}{x}, \quad \Dlapla[2]\psi = \zeta
    \end{align*}
  \item Euler scheme ã&nbsp;ã¨ã“ã‚“ãªæ„Ÿã˜?
    \begin{fortrancode}
ee_Zeta = ee_Zeta + dt * ( - beta*ee_Dx_ee(ee_Psi) )
ee_Psi  = ee_LaplaInv_ee(ee_Zeta)
    \end{fortrancode}
  \item (ä½™åŠ›ãŒã‚ã‚Œã°)éžç·šåž‹ãƒ™ãƒ¼ã‚¿é¢é&nbsp;†åœ§æ–¹ç¨‹å¼ã«æŒ‘æˆ¦
    \begin{align*}
      \DP{\zeta}{t} = - J(\psi, \zeta) - \beta \DP{\psi}{x}, \quad%
      \Dlapla[2]\psi = \zeta
    \end{align*}
  \end{itemize}
\end{frame}

\end{document}
</pre></body></html>