From 091a90dcff4a7786a54ccb75f0864da1026302ac Mon Sep 17 00:00:00 2001 From: Mart Lubbers Date: Fri, 20 Jun 2014 20:52:57 +0200 Subject: [PATCH] final commit, project finished --- LubbersReport.tex | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/LubbersReport.tex b/LubbersReport.tex index ceaa068..01dd403 100644 --- a/LubbersReport.tex +++ b/LubbersReport.tex @@ -73,10 +73,10 @@ suffice. This corresponds with the pseudocode specified together with a rough estimate of the complexity in Listing~\ref{lst:improved}. The algorithm has a complexity lies in the $\mathcal{O}(nm)$ because the main loop repeats at maximum $n$ or $m$ times and the searching within the loop has a complexity of -$n$ if the loop runs $m$ times and $m$ otherwise. +$n$ if the loop runs $m$ times and $m$ otherwise. The polynomial growth allows +the algorithm to be scaled relatively well. \begin{lstlisting}[caption={Improved approach}, label={lst:improved}, - keywords={[3]while,create,put,return,find,remove} -] + keywords={[3]while,create,put,return,find,remove}] n - create list result of length n and initialize with -1 n+m - create list rows/columns that contain pairs of indices and sums of values nlgn - sort the rows and columns list on ascending sum @@ -89,8 +89,6 @@ c3 - put the row/column pair in the results list c4 - return the results list \end{lstlisting} -\section{Conclusion} - \newpage \section{Appendices} \subsection{\textit{\href{http://www.java.com}{Java}} source} -- 2.20.1