\subsection{examples/brusselator\+\_\+radau\+\_\+mkl/ode.h File Reference}
\label{ode_8h}\index{examples/brusselator\+\_\+radau\+\_\+mkl/ode.\+h@{examples/brusselator\+\_\+radau\+\_\+mkl/ode.\+h}}
\subsubsection*{Data Structures}
\begin{DoxyCompactItemize}
\item 
struct {\bf P\+A\+R\+A\+M\+E\+T\+E\+R}
\item 
struct {\bf B\+U\+T\+C\+H\+E\+R}
\end{DoxyCompactItemize}
\subsubsection*{Functions}
\begin{DoxyCompactItemize}
\item 
void {\bf rhs} (double t, double $\ast$u, {\bf P\+A\+R\+A\+M\+E\+T\+E\+R} param, double $\ast$f)
\item 
void {\bf newt} (double t, double $\ast$uprev, double $\ast$Kguess, double $\ast$g, {\bf P\+A\+R\+A\+M\+E\+T\+E\+R} param, {\bf B\+U\+T\+C\+H\+E\+R} rk)
\item 
void {\bf jac} (double t, double $\ast$uprev, double $\ast$Kguess, double $\ast$J, {\bf P\+A\+R\+A\+M\+E\+T\+E\+R} param, {\bf B\+U\+T\+C\+H\+E\+R} rk)
\item 
void {\bf step} (double t, double $\ast$u, {\bf P\+A\+R\+A\+M\+E\+T\+E\+R} param, double $\ast$unew, {\bf B\+U\+T\+C\+H\+E\+R} rk)
\end{DoxyCompactItemize}


\subsubsection{Function Documentation}
\index{ode.\+h@{ode.\+h}!jac@{jac}}
\index{jac@{jac}!ode.\+h@{ode.\+h}}
\paragraph[{jac(double t, double $\ast$uprev, double $\ast$\+Kguess, double $\ast$\+J, P\+A\+R\+A\+M\+E\+T\+E\+R param, B\+U\+T\+C\+H\+E\+R rk)}]{\setlength{\rightskip}{0pt plus 5cm}void jac (
\begin{DoxyParamCaption}
\item[{double}]{t, }
\item[{double $\ast$}]{uprev, }
\item[{double $\ast$}]{Kguess, }
\item[{double $\ast$}]{J, }
\item[{{\bf P\+A\+R\+A\+M\+E\+T\+E\+R}}]{param, }
\item[{{\bf B\+U\+T\+C\+H\+E\+R}}]{rk}
\end{DoxyParamCaption}
)}\label{ode_8h_a2f4e36896b92e6193d45ef27b7020780}
Helper function for computing the Jacobian matrix (using finite differences) for advancing the solution from time t(n) to t(n+1) using an implicit R\+K step on a system of equations \begin{DoxyReturn}{Returns}
(by reference) J the Jacobian for the Newton step 
\end{DoxyReturn}

\begin{DoxyParams}{Parameters}
{\em param} & structure containing number of equations, number of time steps, initial and final time, time step \\
\hline
{\em t} & current time step \\
\hline
{\em uprev} & function value at the previous (known) time step \\
\hline
{\em Kguess} & iterated guess for the stage values \\
\hline
{\em J} & Jacobian, returned by reference \\
\hline
{\em rk} & Butcher Tableau coefficients \\
\hline
\end{DoxyParams}


Definition at line 70 of file brusselator.\+cpp.



References P\+A\+R\+A\+M\+E\+T\+E\+R\+::neq, newt(), and B\+U\+T\+C\+H\+E\+R\+::\+S.



Referenced by Implicit\+M\+K\+L\+::step(), Brusselator\+\_\+\+M\+K\+L\+::step(), and step().

\index{ode.\+h@{ode.\+h}!newt@{newt}}
\index{newt@{newt}!ode.\+h@{ode.\+h}}
\paragraph[{newt(double t, double $\ast$uprev, double $\ast$\+Kguess, double $\ast$g, P\+A\+R\+A\+M\+E\+T\+E\+R param, B\+U\+T\+C\+H\+E\+R rk)}]{\setlength{\rightskip}{0pt plus 5cm}void newt (
\begin{DoxyParamCaption}
\item[{double}]{t, }
\item[{double $\ast$}]{uprev, }
\item[{double $\ast$}]{Kguess, }
\item[{double $\ast$}]{g, }
\item[{{\bf P\+A\+R\+A\+M\+E\+T\+E\+R}}]{param, }
\item[{{\bf B\+U\+T\+C\+H\+E\+R}}]{rk}
\end{DoxyParamCaption}
)}\label{ode_8h_aa04e20511f2366a5ec0bdff1064203d2}
Helper function for advancing the solution from time t(n) to t(n+1) using an implicit R\+K step on a non linear system using a Newton step. \begin{DoxyReturn}{Returns}
(by reference) g distance from the root, returned by reference 
\end{DoxyReturn}

\begin{DoxyParams}{Parameters}
{\em param} & structure containing number of equations, number of time steps, initial and final time, time step \\
\hline
{\em t} & current time step \\
\hline
{\em uprev} & function value at the previous (known) time step \\
\hline
{\em Kguess} & iterated guess for the stage values \\
\hline
{\em rk} & Butcher Tableau coefficients \\
\hline
{\em g} & distance from the root, returned by reference \\
\hline
\end{DoxyParams}


Definition at line 32 of file brusselator.\+cpp.



References B\+U\+T\+C\+H\+E\+R\+::\+A, B\+U\+T\+C\+H\+E\+R\+::c, P\+A\+R\+A\+M\+E\+T\+E\+R\+::dt, P\+A\+R\+A\+M\+E\+T\+E\+R\+::neq, rhs(), and B\+U\+T\+C\+H\+E\+R\+::\+S.



Referenced by jac(), Implicit\+M\+K\+L\+::step(), Brusselator\+\_\+\+M\+K\+L\+::step(), and step().

\index{ode.\+h@{ode.\+h}!rhs@{rhs}}
\index{rhs@{rhs}!ode.\+h@{ode.\+h}}
\paragraph[{rhs(double t, double $\ast$u, P\+A\+R\+A\+M\+E\+T\+E\+R param, double $\ast$f)}]{\setlength{\rightskip}{0pt plus 5cm}void rhs (
\begin{DoxyParamCaption}
\item[{double}]{t, }
\item[{double $\ast$}]{u, }
\item[{{\bf P\+A\+R\+A\+M\+E\+T\+E\+R}}]{param, }
\item[{double $\ast$}]{f}
\end{DoxyParamCaption}
)}\label{ode_8h_a85cca37916ac01b8648f8a864bafdae5}
rhs function, u\textquotesingle{}=rhs(t,u) \begin{DoxyReturn}{Returns}
(by reference) f rhs(t,u) 
\end{DoxyReturn}

\begin{DoxyParams}{Parameters}
{\em t} & current time step \\
\hline
{\em u} & solution u at time t \\
\hline
{\em f} & rhs(t,u) \\
\hline
{\em param} & structure containing number of equations, number of time steps, initial and final time, time step \\
\hline
\end{DoxyParams}


Definition at line 9 of file brusselator.\+cpp.



References P\+A\+R\+A\+M\+E\+T\+E\+R\+::neq.



Referenced by Implicit\+M\+K\+L\+::jac(), Brusselator\+\_\+\+M\+K\+L\+::jac(), newt(), Implicit\+M\+K\+L\+::newt(), Brusselator\+\_\+\+M\+K\+L\+::newt(), Explicit\+Ode\+::step(), Implicit\+Ode\+::step(), and step().

\index{ode.\+h@{ode.\+h}!step@{step}}
\index{step@{step}!ode.\+h@{ode.\+h}}
\paragraph[{step(double t, double $\ast$u, P\+A\+R\+A\+M\+E\+T\+E\+R param, double $\ast$unew, B\+U\+T\+C\+H\+E\+R rk)}]{\setlength{\rightskip}{0pt plus 5cm}void step (
\begin{DoxyParamCaption}
\item[{double}]{t, }
\item[{double $\ast$}]{u, }
\item[{{\bf P\+A\+R\+A\+M\+E\+T\+E\+R}}]{param, }
\item[{double $\ast$}]{unew, }
\item[{{\bf B\+U\+T\+C\+H\+E\+R}}]{rk}
\end{DoxyParamCaption}
)}\label{ode_8h_a02a2cfd5bf4a4c35f861e2c2d2dab18e}


Definition at line 105 of file brusselator.\+cpp.



References B\+U\+T\+C\+H\+E\+R\+::b, B\+U\+T\+C\+H\+E\+R\+::c, P\+A\+R\+A\+M\+E\+T\+E\+R\+::dt, jac(), P\+A\+R\+A\+M\+E\+T\+E\+R\+::neq, newt(), rhs(), and B\+U\+T\+C\+H\+E\+R\+::\+S.



Referenced by main().

