Fix issues with limited numerical precision and artifacts with big N.
This commit is contained in:
Binary file not shown.
@@ -243,7 +243,7 @@ Plotting the absolute error for different values of $N$ reveals the said converg
|
||||
\end{figure}
|
||||
|
||||
\subsection*{Subproblem (b)}
|
||||
Plotting the relative error for different values of $N$ reveals the increase of relative error as $u$ approaches 0 in the vicinity of the boundaries. This behavior is prevalent in all solutions as the limit of small divisors is approached. This behavior is quite logical, but it also shows, that not all uncertainties can be correctly minimized with an increase in resolution. The results are shown in \autoref{fig:rel_error_plot}. To overcome the division by zero issue for the relative error, only the values of $u > \num{1e-10}$ are considered.
|
||||
Plotting the relative error for different values of $N$ reveals a constant value for the relative error accross the entire domain of $x$. The relative error decreases by two orders of magnitude for every order of magnitude increase in $N$. The results are summarized in \autoref{fig:rel_error_plot}. To avoiud issues with divisions by zero, the points where $u(x) \leq \num{e-10}$ were omitted from the plot.
|
||||
|
||||
\begin{figure}
|
||||
\centering
|
||||
@@ -253,7 +253,7 @@ Plotting the relative error for different values of $N$ reveals the increase of
|
||||
\end{figure}
|
||||
|
||||
\subsection*{Subproblem (c)}
|
||||
The maximum relative errors are calculated directly using C++ as the output size scales linearly with $N$ and gets overwhelmingly large for bigger $N$. The results are output using the \texttt{std::cout} command and retrieved using GNU/Linux command line utilities. The code for calculating the maximum relative error $\max_i \frac{\delta v_i}{u_i}$ (see \eqref{eq:relerror}) is included in the C++ implementation. The results are summarized in \autoref{tab:rel_errors}. We see a steady decrease of the relative error up to $N = \num{100000}$, after which the relative error increases again. This will most likely be due to the artifacts seen in \autoref{fig:rel_error_plot} starting at $N = \num{10000}$. The source of these artifacts is not entirely clear.
|
||||
The maximum relative errors are calculated directly using C++ as the output size scales linearly with $N$ and gets overwhelmingly large for bigger $N$. The results are output using the \texttt{std::cout} command and retrieved using GNU/Linux command line utilities. The code for calculating the maximum relative error $\max_i \frac{\delta v_i}{u_i}$ (see \eqref{eq:relerror}) is included in the C++ implementation. The results are summarized in \autoref{tab:rel_errors}. We see a steady decrease of the relative error up to $N = \num{100000}$, after which the relative error increases again. This will most likely be due to the limited numerical precision of floating point numbers in C++ and associated numerical errors.
|
||||
|
||||
\begin{table}[H]
|
||||
\centering
|
||||
@@ -332,3 +332,4 @@ To evaluate the performance of the different algorithms, the algorithms were exe
|
||||
|
||||
\bibliography{include/citations}
|
||||
\end{document}
|
||||
|
||||
Reference in New Issue
Block a user