Merge pull request #21 from FYS3150-G2-2023/coryab/implement-problem-5

Coryab/implement problem 5
This commit is contained in:
Cory Balaton 2023-09-10 13:06:48 +02:00 committed by GitHub Enterprise
commit fd04f740fd
6 changed files with 7 additions and 5 deletions

BIN
latex/assignment_1.pdf Normal file

Binary file not shown.

View File

@ -80,7 +80,7 @@
\begin{document} \begin{document}
\title{Project 1} % self-explanatory \title{Project 1} % self-explanatory
\author{Cory Balaton \& Janita Willumsen} % self-explanatory \author{Cory Alexander Balaton \& Janita Ovidie Sandtrøen Willumsen} % self-explanatory
\date{\today} % self-explanatory \date{\today} % self-explanatory
\noaffiliation % ignore this, but keep it. \noaffiliation % ignore this, but keep it.
@ -107,4 +107,6 @@
\input{problems/problem9} \input{problems/problem9}
\input{problems/problem10}
\end{document} \end{document}

View File

@ -40,5 +40,5 @@ Using the values that we found for $c_1$ and $c_2$, we get
\begin{align*} \begin{align*}
u(x) &= -e^{-10x} + (e^{-10} - 1) x + 1 \\ u(x) &= -e^{-10x} + (e^{-10} - 1) x + 1 \\
&= 1 - (1 - e^{-10}) - e^{-10x} &= 1 - (1 - e^{-10})x - e^{-10x}
\end{align*} \end{align*}

View File

@ -1,6 +1,6 @@
\section*{Problem 5} \section*{Problem 5}
\subsection*{a)} \subsection*{a \& b)}
\subsection*{b)} $n = m - 2$ since when solving for $\vec{v}$, we are finding the solutions for all the points that are in between the boundaries and not the boundaries themselves. $\vec{v}^*$ on the other hand includes the boundary points.

View File

@ -44,4 +44,4 @@ Following Thomas algorithm for gaussian elimination, we first perform a forward
Counting the number of FLOPs for the general algorithm by looking at one procedure at a time. Counting the number of FLOPs for the general algorithm by looking at one procedure at a time.
For every iteration of i in forward sweep we have 1 division, 2 multiplications, and 2 subtractions, resulting in $5(n-1)$ FLOPs. For every iteration of i in forward sweep we have 1 division, 2 multiplications, and 2 subtractions, resulting in $5(n-1)$ FLOPs.
For backward sweep we have 1 division, and for every iteration of i we have 1 subtraction, 1 multiplication, and 1 division, resulting in $3(n-1)+1$ FLOPs. For backward sweep we have 1 division, and for every iteration of i we have 1 subtraction, 1 multiplication, and 1 division, resulting in $3(n-1)+1$ FLOPs.
Total FLOPs for the general algorithm is $8(n-1)+1$. Total FLOPs for the general algorithm is $8(n-1)+1$.

View File