         %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
         % Information sheet for the Matlab lab - Maths 6111 %
         %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass[10pt]{article} 
\input ma_no_html_header

\usepackage{color}
\usepackage{hyperref}
\hypersetup{breaklinks=true,colorlinks=true}
%\input ma_header
\setlength{\parindent}{0pt}
\pagestyle{myheadings}
% \markright{
% \protect {\protect \epsfxsize=0.2 true cm \protect \epsffile {dolph.line.eps}}
% \it Maths 3018/6111 - Numerical methods \hfill}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\begin{document}

\thispagestyle{empty}
\begin{center}
\textbf{\Large Maths 3018/6111 - Numerical Methods \\*[8mm]
Worksheet 2}\\*[.8cm]
\end{center}

\section*{Theory}

\begin{enumerate}
\item Perform the $LU$ decomposition of
  \begin{equation*}
    A =
    \begin{pmatrix}
      1 & 3 \\ 4 & 16
    \end{pmatrix}.
  \end{equation*}
  Use both standard factorisation methods.
\item{} [Additional] Write out the Thomas algorithm for a tridiagonal
  system.
\item Write down the general framework for iterative methods for
  linear systems. Give the convergence matrix. If the linear system
  uses the matrix $A$ above, will an iterative method converge? [Hint:
  remember what to do with the diagonal entries]
\item Check which of the matrices on this sheet are diagonally dominant.
\item Briefly explain what is meant by quadrature methods based on
  polynomial interpolation.
\item{} [3018 only] Write down the contraction mapping theorem. Check
  that $g(x) = \cos(x)$ is contracting on the unit interval.
\end{enumerate}

\section*{Coding}

\begin{enumerate}
\item Write a code to do $LU$ decomposition. Check the decomposition of
  \begin{equation*}
    B =
    \begin{pmatrix}
      64 & 8 & 48 \\
      24 & 28 & 53 \\
      32 & 49 & 91
    \end{pmatrix}.
  \end{equation*}
\item{} [Additional] Implement the Thomas algorithm for a tridiagonal
  system.
\item Implement the Jacobi method for linear systems. Investigate the
  behaviour of the method for the problem
  \begin{equation*}
    B {\bf x} =
    \begin{pmatrix}
      3 \\ 2 \\ 1
    \end{pmatrix}
  \end{equation*}
  starting from the trivial initial guess. Should this be expected?
  [Hint: Check the convergence theorem] Try instead the matrix
  \begin{equation*}
    C =
    \begin{pmatrix}
      \frac{119}{108} & -\frac{14}{27} & -\frac{8}{9} \\
      \frac{7}{54} & \frac{46}{27} & \frac{7}{9} \\
      \frac{5}{108} & \frac{1}{27} & \frac{23}{18} 
    \end{pmatrix}.
  \end{equation*}
\item Implement the Gauss-Seidel method, applying it to the
  convergent problem above. Compare the convergence rate to Jacobi.
\item {} [3018 only] Implement the chord method to find the root of
  \begin{equation*}
    f(x) = \tan x - e^{-x}, \quad x \in [0,1].
  \end{equation*}
\end{enumerate}

\end{document}

