diff --git a/comparison_2D_data_interpolation.py b/comparison_2D_data_interpolation.py index af498a2..8fefcea 100755 --- a/comparison_2D_data_interpolation.py +++ b/comparison_2D_data_interpolation.py @@ -1,3 +1,5 @@ +import os + import numpy as np from matplotlib import pyplot as plt from matplotlib.cm import ScalarMappable @@ -5,6 +7,7 @@ from functions_2D import interpolate_discretized_data, plot_contours from helpers.save_figure_position import ShowLastPos +from mayavi import mlab """ This script implements a comparative test for 2D interpolation techniques @@ -13,6 +16,8 @@ block_stride = 1 height_levels = 50 +dim_x = 10 * 1e3 +dim_y = 10 * 1e3 def mean_square_error(original_datagrid, interpolated_datagrid): @@ -34,31 +39,75 @@ def test_epsilons_for_method(xo, yo, original_datagrid, x, y, datagrid, epsilons plt.show() -def test_methods(xo, yo, original_datagrid, x, y, datagrid, plot): +def test_methods(plot): def plot_result(): - fig = plt.figure(figsize=(16, 9)) - axes = fig.subplots(1, 4, subplot_kw={"aspect": "equal"}) - plt.tight_layout() + # Set up Figure + plt.rc("text", usetex=True) + plt.rc("font", family="serif") + size = 1 + fig = plt.figure(figsize=(16 * size, 9 * size)) + fig.tight_layout() + axes = fig.subplots( + 1, + 4, + sharex="all", + sharey="all", + subplot_kw={ + "adjustable": "box", + "aspect": "equal", + "xticks": [i for i in np.linspace(0, dim_x, 6)], + "yticks": [i for i in np.linspace(0, dim_y, 6)], + "xticklabels": [f"{i:d} km" for i in np.linspace(0, dim_x / 1e3, 6, dtype=int)], + "yticklabels": [f"{i:d} km" for i in np.linspace(0, dim_x / 1e3, 6, dtype=int)], + "xlim": (0, dim_x), + "ylim": (0, dim_y), + }, + gridspec_kw={"hspace": 0.3}, + ) + axes[0].pcolormesh(xo, yo, original_datagrid, cmap=cmap, norm=norm) + axes[0].set_title("Original Raster") axes[1].pcolormesh(x, y, datagrid, cmap=cmap, norm=norm) + axes[1].set_title("Discretized Raster") axes[2].pcolormesh(xo, yo, interpolated_datagrid, cmap=cmap, norm=norm) - plt.colorbar(colors, ticks=levels, ax=axes[0:3].ravel().tolist()) + axes[2].set_title(f"Interpolated Raster, using\n{method_name}") + plt.colorbar(colors, ticks=levels, ax=axes[0:3].ravel().tolist(), shrink=0.4, aspect=15) + mlab.figure(bgcolor=(1, 1, 1)) + mlab.surf( + yo, + xo, + np.rot90(interpolated_datagrid.T), + warp_scale=5, + colormap="terrain", + vmin=vmin, + vmax=vmax, + ) + filename = method_name.replace("\n", " ").replace(" ", "_") + mlab.savefig(f"images/differences/{filename}_3D.png", magnification=10) + # Use ImageMagick to remove background from image. + os.system( + f"convert images/differences/{filename}_3D.png -transparent white images/differences/{filename}_3D.png" + ) diff = np.nan_to_num(interpolated_datagrid - original_datagrid) cmap_diff = plt.get_cmap("coolwarm") norm_diff = Normalize(-np.max(abs(diff)), np.max(abs(diff))) colors_diff = ScalarMappable(cmap=cmap_diff, norm=norm_diff) axes[3].pcolormesh(xo, yo, diff, cmap=cmap_diff, norm=norm_diff) - plt.colorbar(colors_diff, ax=axes[3]) - plt.show() - - for method in [ - "linear", # The spline interpolator don't work well - "cubic", - "rbf_linear", - "rbf_thin_plate_spline", - "rbf_cubic", - "rbf_quintic", + axes[3].set_title("Difference of Interpolated\nand Original Raster") + plt.colorbar(colors_diff, ax=axes[3], fraction=0.05, pad=0.1) + plt.savefig(f"images/differences/{filename})_2D.png") + + for method, method_name in [ + [ + "linear", + "Delaunay Triangulation\n and Barycentric Interpolation", + ], # The spline interpolators don't work well + ["cubic", "Delaunay Triangulation\n and Clough-Tocher scheme"], + # ["rbf_linear", "Radial Basis\nLinear Function"], + ["rbf_thin_plate_spline", "Radial Basis\nThin Plate Spline"], + # ["rbf_cubic", "Radial Basis\nCubic Function"], + # ["rbf_quintic", "Radial Basis\nQuintic Function"], ]: interpolated_datagrid = interpolate_discretized_data( x, @@ -71,13 +120,15 @@ def plot_result(): print(f"Method: {method}, Mean Error: {mean_square_error(original_datagrid, interpolated_datagrid)}.") if plot: plot_result() - for epsilon, method in [ - [3, "rbf_multiquadric"], # Still not sure what value for epsilon is the best - [10, "rbf_multiquadric"], - [30, "rbf_multiquadric"], - [100, "rbf_multiquadric"], - [10, "rbf_inverse_multiquadric"], # Inverse methods don't work well in sparse places. - [3.5, "rbf_inverse_quadratic"], + for epsilon, method, method_name in [ + # Still not sure what value for epsilon is the best + # [3, "rbf_multiquadric", "Radial Basis\nMultiquadric Function"], + # [10, "rbf_multiquadric", "Radial Basis\nMultiquadric Function"], + # [30, "rbf_multiquadric", "Radial Basis\nMultiquadric Function"], + # [100, "rbf_multiquadric", "Radial Basis\nMultiquadric Function"], + # Inverse methods don't work well in sparse places. + # [10, "rbf_inverse_multiquadric", "Radial Basis\nInverse Multiquadric Function"], + # [3.5, "rbf_inverse_quadratic", "Radial Basis\nInverse Quadratic Function"], ]: interpolated_datagrid = interpolate_discretized_data( x, @@ -95,23 +146,25 @@ def plot_result(): plot_result() -# for tile in ["NN17"]: -for tile in ["NN17", "NO33", "NO44", "NO51"]: +for tile in ["NO44"]: + # for tile in ["NN17", "NO33", "NO44", "NO51"]: print(f"Tile name: {tile}.") original_datagrid = np.loadtxt(f"data/{tile}.asc", skiprows=5)[::-1, :] # Each tile is of dimension 10km x 10km, sampled by 50m, thus we have 200 x 200 samples - xo = np.linspace(0, 10, original_datagrid.shape[1]) - yo = np.linspace(0, 10, original_datagrid.shape[0]) - maximum = int(np.ceil(np.max(original_datagrid))) - levels = [i for i in range(0, maximum + height_levels, height_levels)] - maximum = levels[-1] + xo = np.linspace(0, dim_x, original_datagrid.shape[1]) + yo = np.linspace(0, dim_y, original_datagrid.shape[0]) + minimum = int(np.floor(np.min(original_datagrid) / height_levels) * height_levels) + maximum = int(np.ceil(np.max(original_datagrid) / height_levels) * height_levels) + levels = np.arange(minimum, maximum + 1e-10, height_levels, dtype=int) + # Set up Colormaps cmap = plt.get_cmap("terrain") - norm = Normalize( - min(np.min(original_datagrid) * 1.1, -10), maximum * 1.1 - ) # Leave extra 10% for interpolation overshoot + vmin = -0.25 * maximum * 1.1 + vmax = maximum * 1.1 + norm = Normalize(vmin, vmax) # Leave extra 10% for interpolation overshoot colors = ScalarMappable(norm=norm, cmap=cmap) + datagrid = height_levels * np.floor(original_datagrid[::block_stride, ::block_stride] / height_levels) - x = np.linspace(0, 10, datagrid.shape[1]) - y = np.linspace(0, 10, datagrid.shape[0]) - test_methods(xo, yo, original_datagrid, x, y, datagrid, plot=False) + x = np.linspace(0, dim_x, datagrid.shape[1]) + y = np.linspace(0, dim_y, datagrid.shape[0]) + test_methods(plot=True) diff --git a/contour_example.py b/contour_example.py index a528105..a57b003 100755 --- a/contour_example.py +++ b/contour_example.py @@ -10,7 +10,7 @@ # Set up Figure plt.rc("text", usetex=True) -plt.rc("font", family="serif") +plt.rc("font", family="serif", size=25) size = 0.7 fig = plt.figure(figsize=(16 * size, 9 * size)) fig.tight_layout() @@ -18,7 +18,8 @@ # Load and plot the original contour contour = np.loadtxt("data/RealContour1A.txt") -axes[0].plot(contour[:, 0], contour[:, 1], color=plt.get_cmap("tab10")(0)) +axes[0].plot(contour[:, 0], contour[:, 1], "o", markersize=1, color=plt.get_cmap("tab10")(0)) +# axes[0].plot(contour[:, 0], contour[:, 1], color=plt.get_cmap("tab10")(0)) axes[0].set_title("Terraced contour") cubic_spline = smooth_contour(contour, collinearity_tol=1e-2) @@ -35,5 +36,5 @@ # plt.plot(line[:, 0], line[:, 1], "gx", markersize=10) # plt.plot(isolated_points[:, 0], isolated_points[:, 1], "ro") -plt.savefig("images/2D_Contour.png") +# plt.savefig("images/2D_Contour.png") plt.show() diff --git a/function_example.py b/function_example.py index f7b1d26..0b404f1 100755 --- a/function_example.py +++ b/function_example.py @@ -11,7 +11,7 @@ # Set up Figure plt.rc("text", usetex=True) -plt.rc("font", family="serif") +plt.rc("font", family="serif", size=16) size = 0.5 fig = plt.figure(figsize=(16 * size, 9 * size)) fig.tight_layout() @@ -20,7 +20,12 @@ # Load and plot the original function line = np.loadtxt("data/Simple_Line1A.txt") -plt.plot(line[:, 0], line[:, 1]) +plt.plot(line[:100, 0], line[:100, 1], "o", markersize=2) +plt.legend(["Original line"], frameon=False) +plt.savefig("images/1D_Function.png") +plt.show() + +fig = plt.figure(figsize=(16 * size, 9 * size)) # Isolate points from collinear segments isolated_points = isolate_from_collinear(line) @@ -31,6 +36,7 @@ ) x = np.linspace(line[0, 0], line[-1, 0], 1000) y = cubic_spline(x) +plt.plot(line[:, 0], line[:, 1], "o", markersize=2) plt.plot(x, y) # BEZIER CURVE @@ -41,7 +47,7 @@ # Plot line points and isolated points # plt.plot(line[:, 0], line[:, 1], "gx", markersize=10) -# plt.plot(isolated_points[:, 0], isolated_points[:, 1], 'ro') +plt.plot(isolated_points[:, 0], isolated_points[:, 1], "ro", markersize=3) -plt.savefig("images/1D_Function.png") +plt.savefig("images/1D_Function_Interpolated.png") plt.show() diff --git a/functions_1D.py b/functions_1D.py index a08aafd..d29f9d6 100755 --- a/functions_1D.py +++ b/functions_1D.py @@ -71,7 +71,7 @@ def add_point(points: np.ndarray, point: np.ndarray): i += 1 continue - if check_half_plane( + if points.shape[1] == 2 and check_half_plane( path[[firstpoint, lastpoint]], path[[firstpoint - 1, min(lastpoint + 1, path.shape[0] - 1)]] ): points = add_point(points, 2 / 3 * path[firstpoint] + 1 / 3 * path[lastpoint]) diff --git a/images/1D_Function.png b/images/1D_Function.png index 4b56508..61bd7b9 100755 Binary files a/images/1D_Function.png and b/images/1D_Function.png differ diff --git a/images/1D_Function_Interpolated.png b/images/1D_Function_Interpolated.png new file mode 100755 index 0000000..4b6f7b7 Binary files /dev/null and b/images/1D_Function_Interpolated.png differ diff --git a/images/1D_Function_Interpolated_Zoomed.png b/images/1D_Function_Interpolated_Zoomed.png new file mode 100755 index 0000000..6964cf2 Binary files /dev/null and b/images/1D_Function_Interpolated_Zoomed.png differ diff --git a/images/2D_Contour.png b/images/2D_Contour.png index 778ff50..e686705 100755 Binary files a/images/2D_Contour.png and b/images/2D_Contour.png differ diff --git a/images/2D_Contour_Zoomed.png b/images/2D_Contour_Zoomed.png index c28b469..eb68732 100755 Binary files a/images/2D_Contour_Zoomed.png and b/images/2D_Contour_Zoomed.png differ diff --git a/images/NO44/2D_Contour_Interpolation.png b/images/NO44/2D_Contour_Interpolation.png index 0d5c4a9..eabc5c9 100755 Binary files a/images/NO44/2D_Contour_Interpolation.png and b/images/NO44/2D_Contour_Interpolation.png differ diff --git a/images/differences/Delaunay_Triangulation__and_Barycentric_Interpolation)_2D.png b/images/differences/Delaunay_Triangulation__and_Barycentric_Interpolation)_2D.png new file mode 100755 index 0000000..e196dc5 Binary files /dev/null and b/images/differences/Delaunay_Triangulation__and_Barycentric_Interpolation)_2D.png differ diff --git a/images/differences/Delaunay_Triangulation__and_Barycentric_Interpolation_3D.png b/images/differences/Delaunay_Triangulation__and_Barycentric_Interpolation_3D.png new file mode 100755 index 0000000..c1a217d Binary files /dev/null and b/images/differences/Delaunay_Triangulation__and_Barycentric_Interpolation_3D.png differ diff --git a/images/differences/Delaunay_Triangulation__and_Clough-Tocher_scheme)_2D.png b/images/differences/Delaunay_Triangulation__and_Clough-Tocher_scheme)_2D.png new file mode 100755 index 0000000..da10bb9 Binary files /dev/null and b/images/differences/Delaunay_Triangulation__and_Clough-Tocher_scheme)_2D.png differ diff --git a/images/differences/Delaunay_Triangulation__and_Clough-Tocher_scheme_3D.png b/images/differences/Delaunay_Triangulation__and_Clough-Tocher_scheme_3D.png new file mode 100755 index 0000000..127ce8c Binary files /dev/null and b/images/differences/Delaunay_Triangulation__and_Clough-Tocher_scheme_3D.png differ diff --git a/images/differences/Radial_Basis_Thin_Plate_Spline)_2D.png b/images/differences/Radial_Basis_Thin_Plate_Spline)_2D.png new file mode 100755 index 0000000..35d84e0 Binary files /dev/null and b/images/differences/Radial_Basis_Thin_Plate_Spline)_2D.png differ diff --git a/images/differences/Radial_Basis_Thin_Plate_Spline_3D.png b/images/differences/Radial_Basis_Thin_Plate_Spline_3D.png new file mode 100755 index 0000000..f681a07 Binary files /dev/null and b/images/differences/Radial_Basis_Thin_Plate_Spline_3D.png differ diff --git a/interpolating_2D_contours.py b/interpolating_2D_contours.py index 0b637f1..1c83da6 100755 --- a/interpolating_2D_contours.py +++ b/interpolating_2D_contours.py @@ -13,6 +13,7 @@ height_levels = 50 # NN17 - Fort William, NO44 - north of Dundee, NO51 - in St Andrews, NO33 - in Dundee, NH52 - Drumnadrochit tile = "NO44" +tile_name = "South of Forfar" dim_x = 10 * 1e3 # Dimensions of loaded data in m dim_y = 10 * 1e3 # Dimensions of loaded data in m @@ -31,10 +32,10 @@ subplot_kw={ "adjustable": "box", "aspect": "equal", - "xticks": [x for x in np.linspace(0, dim_x, 6)], - "yticks": [y for y in np.linspace(0, dim_y, 6)], - "xticklabels": [f"{x:d} km" for x in np.linspace(0, dim_x / 1e3, 6, dtype=int)], - "yticklabels": [f"{y:d} km" for y in np.linspace(0, dim_x / 1e3, 6, dtype=int)], + "xticks": [i for i in np.linspace(0, dim_x, 6)], + "yticks": [i for i in np.linspace(0, dim_y, 6)], + "xticklabels": [f"{i:d} km" for i in np.linspace(0, dim_x / 1e3, 6, dtype=int)], + "yticklabels": [f"{i:d} km" for i in np.linspace(0, dim_x / 1e3, 6, dtype=int)], "xlim": (0, dim_x), "ylim": (0, dim_y), }, @@ -102,7 +103,7 @@ def plot_contours_wrap(x, y, datagrid, axes, plot_title, levels=None, discretize axes[0].set_title(plot_title) -plot_contours_wrap(x, y, datagrid, axes[:, 0], "Original Data", levels=levels) +plot_contours_wrap(x, y, datagrid, axes[:, 0], plot_title=f"{tile_name}\n50m Resolution Raster", levels=levels) # Lower Spatial Resolution low_spatial_res_datagrid = datagrid[::block_stride, ::block_stride] diff --git a/interpolating_2D_data.py b/interpolating_2D_data.py index b24b77f..b1438ed 100755 --- a/interpolating_2D_data.py +++ b/interpolating_2D_data.py @@ -37,10 +37,10 @@ subplot_kw={ "adjustable": "box", "aspect": "equal", - "xticks": [x for x in np.linspace(0, dim_x, 6)], - "yticks": [y for y in np.linspace(0, dim_y, 6)], - "xticklabels": [f"{x:d} km" for x in np.linspace(0, dim_x / 1e3, 6, dtype=int)], - "yticklabels": [f"{y:d} km" for y in np.linspace(0, dim_x / 1e3, 6, dtype=int)], + "xticks": [i for i in np.linspace(0, dim_x, 6)], + "yticks": [i for i in np.linspace(0, dim_y, 6)], + "xticklabels": [f"{i:d} km" for i in np.linspace(0, dim_x / 1e3, 6, dtype=int)], + "yticklabels": [f"{i:d} km" for i in np.linspace(0, dim_x / 1e3, 6, dtype=int)], "xlim": (0, dim_x), "ylim": (0, dim_y), }, diff --git a/report/Report.aux b/report/Report.aux new file mode 100755 index 0000000..1a18e19 --- /dev/null +++ b/report/Report.aux @@ -0,0 +1,34 @@ +\relax +\@writefile{tdo}{\contentsline {todo}{Add abstract}{1}{}\protected@file@percent } +\pgfsyspdfmark {pgfid1}{3729359}{34316829} +\pgfsyspdfmark {pgfid4}{38001205}{34329117} +\pgfsyspdfmark {pgfid5}{39852597}{34105203} +\@writefile{toc}{\contentsline {chapter}{\numberline {1}Introduction}{1}{}\protected@file@percent } +\@writefile{lof}{\addvspace {10\p@ }} +\@writefile{lot}{\addvspace {10\p@ }} +\@writefile{tdo}{\contentsline {todo}{Add introduction.}{1}{}\protected@file@percent } +\pgfsyspdfmark {pgfid6}{3729359}{40394457} +\pgfsyspdfmark {pgfid9}{38001205}{40406745} +\pgfsyspdfmark {pgfid10}{39852597}{40182831} +\@writefile{toc}{\contentsline {chapter}{\numberline {2}Interpolation in 1D}{2}{}\protected@file@percent } +\@writefile{lof}{\addvspace {10\p@ }} +\@writefile{lot}{\addvspace {10\p@ }} +\@writefile{tdo}{\contentsline {todo}{Possibly add a bit of theory to splines.}{2}{}\protected@file@percent } +\pgfsyspdfmark {pgfid11}{3729359}{38035161} +\pgfsyspdfmark {pgfid14}{38001205}{38047449} +\pgfsyspdfmark {pgfid15}{39852597}{37823535} +\@writefile{lof}{\contentsline {figure}{\numberline {2.1}{\ignorespaces An example of discretized 1D data.\relax }}{2}{}\protected@file@percent } +\providecommand*\caption@xref[2]{\@setref\relax\@undefined{#1}} +\newlabel{fig:1D_fun}{{2.1}{2}} +\@writefile{lof}{\contentsline {figure}{\numberline {2.2}{\ignorespaces An example of curves interpolated from discretized 1D data.\relax }}{3}{}\protected@file@percent } +\newlabel{fig:1D_fun_interpolated}{{2.2}{3}} +\@writefile{toc}{\contentsline {chapter}{\numberline {3}Interpolation in 2D}{4}{}\protected@file@percent } +\@writefile{lof}{\addvspace {10\p@ }} +\@writefile{lot}{\addvspace {10\p@ }} +\@writefile{toc}{\contentsline {section}{\numberline {3.1}Parametric Curves}{4}{}\protected@file@percent } +\@writefile{lof}{\contentsline {figure}{\numberline {3.1}{\ignorespaces An example of parametric curves interpolated from discretized parametric 1D curve in 2D.\relax }}{4}{}\protected@file@percent } +\newlabel{fig:2D_parametric_curve}{{3.1}{4}} +\@writefile{toc}{\contentsline {section}{\numberline {3.2}Countour lines}{4}{}\protected@file@percent } +\newlabel{fig:2D_contour}{{\caption@xref {fig:2D_contour}{ on input line 87}}{5}} +\@writefile{lof}{\contentsline {figure}{\numberline {3.2}{\ignorespaces Contour interpolation from data with various resolution.\relax }}{5}{}\protected@file@percent } +\gdef \@abspage@last{7} diff --git a/report/Report.log b/report/Report.log new file mode 100755 index 0000000..0ad5b63 --- /dev/null +++ b/report/Report.log @@ -0,0 +1,642 @@ +This is pdfTeX, Version 3.141592653-2.6-1.40.24 (TeX Live 2022/Arch Linux) (preloaded format=pdflatex 2022.5.30) 14 JUN 2022 11:23 +entering extended mode + restricted \write18 enabled. + %&-line parsing enabled. +**Report.tex +(./Report.tex +LaTeX2e <2021-11-15> patch level 1 +L3 programming layer <2022-04-10> +(/usr/share/texmf-dist/tex/latex/base/report.cls +Document Class: report 2021/10/04 v1.4n Standard LaTeX document class +(/usr/share/texmf-dist/tex/latex/base/size10.clo +File: size10.clo 2021/10/04 v1.4n Standard LaTeX file (size option) +) +\c@part=\count185 +\c@chapter=\count186 +\c@section=\count187 +\c@subsection=\count188 +\c@subsubsection=\count189 +\c@paragraph=\count190 +\c@subparagraph=\count191 +\c@figure=\count192 +\c@table=\count193 +\abovecaptionskip=\skip47 +\belowcaptionskip=\skip48 +\bibindent=\dimen138 +) +(/usr/share/texmf-dist/tex/latex/base/inputenc.sty +Package: inputenc 2021/02/14 v1.3d Input encoding file +\inpenc@prehook=\toks16 +\inpenc@posthook=\toks17 +) +(/usr/share/texmf-dist/tex/latex/amsmath/amsmath.sty +Package: amsmath 2021/10/15 v2.17l AMS math features +\@mathmargin=\skip49 + +For additional information on amsmath, use the `?' option. +(/usr/share/texmf-dist/tex/latex/amsmath/amstext.sty +Package: amstext 2021/08/26 v2.01 AMS text + +(/usr/share/texmf-dist/tex/latex/amsmath/amsgen.sty +File: amsgen.sty 1999/11/30 v2.0 generic functions +\@emptytoks=\toks18 +\ex@=\dimen139 +)) +(/usr/share/texmf-dist/tex/latex/amsmath/amsbsy.sty +Package: amsbsy 1999/11/29 v1.2d Bold Symbols +\pmbraise@=\dimen140 +) +(/usr/share/texmf-dist/tex/latex/amsmath/amsopn.sty +Package: amsopn 2021/08/26 v2.02 operator names +) +\inf@bad=\count194 +LaTeX Info: Redefining \frac on input line 234. +\uproot@=\count195 +\leftroot@=\count196 +LaTeX Info: Redefining \overline on input line 399. +\classnum@=\count197 +\DOTSCASE@=\count198 +LaTeX Info: Redefining \ldots on input line 496. +LaTeX Info: Redefining \dots on input line 499. +LaTeX Info: Redefining \cdots on input line 620. +\Mathstrutbox@=\box50 +\strutbox@=\box51 +\big@size=\dimen141 +LaTeX Font Info: Redeclaring font encoding OML on input line 743. +LaTeX Font Info: Redeclaring font encoding OMS on input line 744. +\macc@depth=\count199 +\c@MaxMatrixCols=\count266 +\dotsspace@=\muskip16 +\c@parentequation=\count267 +\dspbrk@lvl=\count268 +\tag@help=\toks19 +\row@=\count269 +\column@=\count270 +\maxfields@=\count271 +\andhelp@=\toks20 +\eqnshift@=\dimen142 +\alignsep@=\dimen143 +\tagshift@=\dimen144 +\tagwidth@=\dimen145 +\totwidth@=\dimen146 +\lineht@=\dimen147 +\@envbody=\toks21 +\multlinegap=\skip50 +\multlinetaggap=\skip51 +\mathdisplay@stack=\toks22 +LaTeX Info: Redefining \[ on input line 2938. +LaTeX Info: Redefining \] on input line 2939. +) +(/usr/share/texmf-dist/tex/latex/amsfonts/amsfonts.sty +Package: amsfonts 2013/01/14 v3.01 Basic AMSFonts support +\symAMSa=\mathgroup4 +\symAMSb=\mathgroup5 +LaTeX Font Info: Redeclaring math symbol \hbar on input line 98. +LaTeX Font Info: Overwriting math alphabet `\mathfrak' in version `bold' +(Font) U/euf/m/n --> U/euf/b/n on input line 106. +) +(/usr/share/texmf-dist/tex/latex/amsfonts/amssymb.sty +Package: amssymb 2013/01/14 v3.01 AMS font symbols +) +(/usr/share/texmf-dist/tex/latex/geometry/geometry.sty +Package: geometry 2020/01/02 v5.9 Page Geometry + +(/usr/share/texmf-dist/tex/latex/graphics/keyval.sty +Package: keyval 2014/10/28 v1.15 key=value parser (DPC) +\KV@toks@=\toks23 +) +(/usr/share/texmf-dist/tex/generic/iftex/ifvtex.sty +Package: ifvtex 2019/10/25 v1.7 ifvtex legacy package. Use iftex instead. + +(/usr/share/texmf-dist/tex/generic/iftex/iftex.sty +Package: iftex 2022/02/03 v1.0f TeX engine tests +)) +\Gm@cnth=\count272 +\Gm@cntv=\count273 +\c@Gm@tempcnt=\count274 +\Gm@bindingoffset=\dimen148 +\Gm@wd@mp=\dimen149 +\Gm@odd@mp=\dimen150 +\Gm@even@mp=\dimen151 +\Gm@layoutwidth=\dimen152 +\Gm@layoutheight=\dimen153 +\Gm@layouthoffset=\dimen154 +\Gm@layoutvoffset=\dimen155 +\Gm@dimlist=\toks24 +) +(/usr/share/texmf-dist/tex/latex/tools/indentfirst.sty +Package: indentfirst 1995/11/23 v1.03 Indent first paragraph (DPC) +) +(/usr/share/texmf-dist/tex/latex/caption/subcaption.sty +Package: subcaption 2022/01/07 v1.5 Sub-captions (AR) + +(/usr/share/texmf-dist/tex/latex/caption/caption.sty +Package: caption 2022/03/01 v3.6b Customizing captions (AR) + +(/usr/share/texmf-dist/tex/latex/caption/caption3.sty +Package: caption3 2022/03/17 v2.3b caption3 kernel (AR) +\caption@tempdima=\dimen156 +\captionmargin=\dimen157 +\caption@leftmargin=\dimen158 +\caption@rightmargin=\dimen159 +\caption@width=\dimen160 +\caption@indent=\dimen161 +\caption@parindent=\dimen162 +\caption@hangindent=\dimen163 +Package caption Info: Standard document class detected. +) +\c@caption@flags=\count275 +\c@continuedfloat=\count276 +) +\c@subfigure=\count277 +\c@subtable=\count278 +) +(/usr/share/texmf-dist/tex/latex/graphics/graphicx.sty +Package: graphicx 2021/09/16 v1.2d Enhanced LaTeX Graphics (DPC,SPQR) + +(/usr/share/texmf-dist/tex/latex/graphics/graphics.sty +Package: graphics 2021/03/04 v1.4d Standard LaTeX Graphics (DPC,SPQR) + +(/usr/share/texmf-dist/tex/latex/graphics/trig.sty +Package: trig 2021/08/11 v1.11 sin cos tan (DPC) +) +(/usr/share/texmf-dist/tex/latex/graphics-cfg/graphics.cfg +File: graphics.cfg 2016/06/04 v1.11 sample graphics configuration +) +Package graphics Info: Driver file: pdftex.def on input line 107. + +(/usr/share/texmf-dist/tex/latex/graphics-def/pdftex.def +File: pdftex.def 2020/10/05 v1.2a Graphics/color driver for pdftex +)) +\Gin@req@height=\dimen164 +\Gin@req@width=\dimen165 +) +(/usr/share/texmf-dist/tex/latex/float/float.sty +Package: float 2001/11/08 v1.3d Float enhancements (AL) +\c@float@type=\count279 +\float@exts=\toks25 +\float@box=\box52 +\@float@everytoks=\toks26 +\@floatcapt=\box53 +) +(/usr/share/texmf-dist/tex/latex/todonotes/todonotes.sty +Package: todonotes 2021/06/04 v1.1.5 Todonotes source and documentation. +Package: todonotes 2021/06/04 + +(/usr/share/texmf-dist/tex/latex/base/ifthen.sty +Package: ifthen 2020/11/24 v1.1c Standard LaTeX ifthen package (DPC) +) +(/usr/share/texmf-dist/tex/latex/xkeyval/xkeyval.sty +Package: xkeyval 2020/11/20 v2.8 package option processing (HA) + +(/usr/share/texmf-dist/tex/generic/xkeyval/xkeyval.tex +(/usr/share/texmf-dist/tex/generic/xkeyval/xkvutils.tex +\XKV@toks=\toks27 +\XKV@tempa@toks=\toks28 +) +\XKV@depth=\count280 +File: xkeyval.tex 2014/12/03 v2.7a key=value parser (HA) +)) +(/usr/share/texmf-dist/tex/latex/xcolor/xcolor.sty +Package: xcolor 2021/10/31 v2.13 LaTeX color extensions (UK) + +(/usr/share/texmf-dist/tex/latex/graphics-cfg/color.cfg +File: color.cfg 2016/01/02 v1.6 sample color configuration +) +Package xcolor Info: Driver file: pdftex.def on input line 227. +Package xcolor Info: Model `cmy' substituted by `cmy0' on input line 1352. +Package xcolor Info: Model `hsb' substituted by `rgb' on input line 1356. +Package xcolor Info: Model `RGB' extended on input line 1368. +Package xcolor Info: Model `HTML' substituted by `rgb' on input line 1370. +Package xcolor Info: Model `Hsb' substituted by `hsb' on input line 1371. +Package xcolor Info: Model `tHsb' substituted by `hsb' on input line 1372. +Package xcolor Info: Model `HSB' substituted by `hsb' on input line 1373. +Package xcolor Info: Model `Gray' substituted by `gray' on input line 1374. +Package xcolor Info: Model `wave' substituted by `hsb' on input line 1375. +) +(/usr/share/texmf-dist/tex/latex/pgf/frontendlayer/tikz.sty +(/usr/share/texmf-dist/tex/latex/pgf/basiclayer/pgf.sty +(/usr/share/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty +(/usr/share/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.tex +\pgfutil@everybye=\toks29 +\pgfutil@tempdima=\dimen166 +\pgfutil@tempdimb=\dimen167 + +(/usr/share/texmf-dist/tex/generic/pgf/utilities/pgfutil-common-lists.tex)) +(/usr/share/texmf-dist/tex/generic/pgf/utilities/pgfutil-latex.def +\pgfutil@abb=\box54 +) +(/usr/share/texmf-dist/tex/generic/pgf/utilities/pgfrcs.code.tex +(/usr/share/texmf-dist/tex/generic/pgf/pgf.revision.tex) +Package: pgfrcs 2021/05/15 v3.1.9a (3.1.9a) +)) +Package: pgf 2021/05/15 v3.1.9a (3.1.9a) + +(/usr/share/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty +(/usr/share/texmf-dist/tex/latex/pgf/systemlayer/pgfsys.sty +(/usr/share/texmf-dist/tex/generic/pgf/systemlayer/pgfsys.code.tex +Package: pgfsys 2021/05/15 v3.1.9a (3.1.9a) + +(/usr/share/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex +\pgfkeys@pathtoks=\toks30 +\pgfkeys@temptoks=\toks31 + +(/usr/share/texmf-dist/tex/generic/pgf/utilities/pgfkeysfiltered.code.tex +\pgfkeys@tmptoks=\toks32 +)) +\pgf@x=\dimen168 +\pgf@y=\dimen169 +\pgf@xa=\dimen170 +\pgf@ya=\dimen171 +\pgf@xb=\dimen172 +\pgf@yb=\dimen173 +\pgf@xc=\dimen174 +\pgf@yc=\dimen175 +\pgf@xd=\dimen176 +\pgf@yd=\dimen177 +\w@pgf@writea=\write3 +\r@pgf@reada=\read2 +\c@pgf@counta=\count281 +\c@pgf@countb=\count282 +\c@pgf@countc=\count283 +\c@pgf@countd=\count284 +\t@pgf@toka=\toks33 +\t@pgf@tokb=\toks34 +\t@pgf@tokc=\toks35 +\pgf@sys@id@count=\count285 + +(/usr/share/texmf-dist/tex/generic/pgf/systemlayer/pgf.cfg +File: pgf.cfg 2021/05/15 v3.1.9a (3.1.9a) +) +Driver file for pgf: pgfsys-pdftex.def + +(/usr/share/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-pdftex.def +File: pgfsys-pdftex.def 2021/05/15 v3.1.9a (3.1.9a) + +(/usr/share/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-common-pdf.def +File: pgfsys-common-pdf.def 2021/05/15 v3.1.9a (3.1.9a) +))) +(/usr/share/texmf-dist/tex/generic/pgf/systemlayer/pgfsyssoftpath.code.tex +File: pgfsyssoftpath.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgfsyssoftpath@smallbuffer@items=\count286 +\pgfsyssoftpath@bigbuffer@items=\count287 +) +(/usr/share/texmf-dist/tex/generic/pgf/systemlayer/pgfsysprotocol.code.tex +File: pgfsysprotocol.code.tex 2021/05/15 v3.1.9a (3.1.9a) +)) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcore.code.tex +Package: pgfcore 2021/05/15 v3.1.9a (3.1.9a) + +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmath.code.tex +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathcalc.code.tex +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathutil.code.tex) +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathparser.code.tex +\pgfmath@dimen=\dimen178 +\pgfmath@count=\count288 +\pgfmath@box=\box55 +\pgfmath@toks=\toks36 +\pgfmath@stack@operand=\toks37 +\pgfmath@stack@operation=\toks38 +) +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.code.tex +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.basic.code.tex) +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.trigonometric.code +.tex) +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.random.code.tex) +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.comparison.code.te +x) (/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.base.code.tex) +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.round.code.tex) +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.misc.code.tex) +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.integerarithmetics +.code.tex))) (/usr/share/texmf-dist/tex/generic/pgf/math/pgfmathfloat.code.tex +\c@pgfmathroundto@lastzeros=\count289 +)) (/usr/share/texmf-dist/tex/generic/pgf/math/pgfint.code.tex) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepoints.code.tex +File: pgfcorepoints.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgf@picminx=\dimen179 +\pgf@picmaxx=\dimen180 +\pgf@picminy=\dimen181 +\pgf@picmaxy=\dimen182 +\pgf@pathminx=\dimen183 +\pgf@pathmaxx=\dimen184 +\pgf@pathminy=\dimen185 +\pgf@pathmaxy=\dimen186 +\pgf@xx=\dimen187 +\pgf@xy=\dimen188 +\pgf@yx=\dimen189 +\pgf@yy=\dimen190 +\pgf@zx=\dimen191 +\pgf@zy=\dimen192 +) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathconstruct.code.tex +File: pgfcorepathconstruct.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgf@path@lastx=\dimen193 +\pgf@path@lasty=\dimen194 +) (/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathusage.code.tex +File: pgfcorepathusage.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgf@shorten@end@additional=\dimen195 +\pgf@shorten@start@additional=\dimen196 +) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcorescopes.code.tex +File: pgfcorescopes.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgfpic=\box56 +\pgf@hbox=\box57 +\pgf@layerbox@main=\box58 +\pgf@picture@serial@count=\count290 +) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcoregraphicstate.code.tex +File: pgfcoregraphicstate.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgflinewidth=\dimen197 +) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcoretransformations.code.t +ex +File: pgfcoretransformations.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgf@pt@x=\dimen198 +\pgf@pt@y=\dimen199 +\pgf@pt@temp=\dimen256 +) (/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcorequick.code.tex +File: pgfcorequick.code.tex 2021/05/15 v3.1.9a (3.1.9a) +) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreobjects.code.tex +File: pgfcoreobjects.code.tex 2021/05/15 v3.1.9a (3.1.9a) +) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepathprocessing.code.te +x +File: pgfcorepathprocessing.code.tex 2021/05/15 v3.1.9a (3.1.9a) +) (/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcorearrows.code.tex +File: pgfcorearrows.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgfarrowsep=\dimen257 +) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreshade.code.tex +File: pgfcoreshade.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgf@max=\dimen258 +\pgf@sys@shading@range@num=\count291 +\pgf@shadingcount=\count292 +) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreimage.code.tex +File: pgfcoreimage.code.tex 2021/05/15 v3.1.9a (3.1.9a) + +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreexternal.code.tex +File: pgfcoreexternal.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgfexternal@startupbox=\box59 +)) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcorelayers.code.tex +File: pgfcorelayers.code.tex 2021/05/15 v3.1.9a (3.1.9a) +) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcoretransparency.code.tex +File: pgfcoretransparency.code.tex 2021/05/15 v3.1.9a (3.1.9a) +) (/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcorepatterns.code.tex +File: pgfcorepatterns.code.tex 2021/05/15 v3.1.9a (3.1.9a) +) +(/usr/share/texmf-dist/tex/generic/pgf/basiclayer/pgfcorerdf.code.tex +File: pgfcorerdf.code.tex 2021/05/15 v3.1.9a (3.1.9a) +))) +(/usr/share/texmf-dist/tex/generic/pgf/modules/pgfmoduleshapes.code.tex +File: pgfmoduleshapes.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgfnodeparttextbox=\box60 +) +(/usr/share/texmf-dist/tex/generic/pgf/modules/pgfmoduleplot.code.tex +File: pgfmoduleplot.code.tex 2021/05/15 v3.1.9a (3.1.9a) +) +(/usr/share/texmf-dist/tex/latex/pgf/compatibility/pgfcomp-version-0-65.sty +Package: pgfcomp-version-0-65 2021/05/15 v3.1.9a (3.1.9a) +\pgf@nodesepstart=\dimen259 +\pgf@nodesepend=\dimen260 +) +(/usr/share/texmf-dist/tex/latex/pgf/compatibility/pgfcomp-version-1-18.sty +Package: pgfcomp-version-1-18 2021/05/15 v3.1.9a (3.1.9a) +)) +(/usr/share/texmf-dist/tex/latex/pgf/utilities/pgffor.sty +(/usr/share/texmf-dist/tex/latex/pgf/utilities/pgfkeys.sty +(/usr/share/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex)) +(/usr/share/texmf-dist/tex/latex/pgf/math/pgfmath.sty +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmath.code.tex)) +(/usr/share/texmf-dist/tex/generic/pgf/utilities/pgffor.code.tex +Package: pgffor 2021/05/15 v3.1.9a (3.1.9a) + +(/usr/share/texmf-dist/tex/generic/pgf/math/pgfmath.code.tex) +\pgffor@iter=\dimen261 +\pgffor@skip=\dimen262 +\pgffor@stack=\toks39 +\pgffor@toks=\toks40 +)) +(/usr/share/texmf-dist/tex/generic/pgf/frontendlayer/tikz/tikz.code.tex +Package: tikz 2021/05/15 v3.1.9a (3.1.9a) + +(/usr/share/texmf-dist/tex/generic/pgf/libraries/pgflibraryplothandlers.code.te +x +File: pgflibraryplothandlers.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgf@plot@mark@count=\count293 +\pgfplotmarksize=\dimen263 +) +\tikz@lastx=\dimen264 +\tikz@lasty=\dimen265 +\tikz@lastxsaved=\dimen266 +\tikz@lastysaved=\dimen267 +\tikz@lastmovetox=\dimen268 +\tikz@lastmovetoy=\dimen269 +\tikzleveldistance=\dimen270 +\tikzsiblingdistance=\dimen271 +\tikz@figbox=\box61 +\tikz@figbox@bg=\box62 +\tikz@tempbox=\box63 +\tikz@tempbox@bg=\box64 +\tikztreelevel=\count294 +\tikznumberofchildren=\count295 +\tikznumberofcurrentchild=\count296 +\tikz@fig@count=\count297 + (/usr/share/texmf-dist/tex/generic/pgf/modules/pgfmodulematrix.code.tex +File: pgfmodulematrix.code.tex 2021/05/15 v3.1.9a (3.1.9a) +\pgfmatrixcurrentrow=\count298 +\pgfmatrixcurrentcolumn=\count299 +\pgf@matrix@numberofcolumns=\count300 +) +\tikz@expandcount=\count301 + +(/usr/share/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrary +topaths.code.tex +File: tikzlibrarytopaths.code.tex 2021/05/15 v3.1.9a (3.1.9a) +))) +(/usr/share/texmf-dist/tex/generic/pgf/frontendlayer/tikz/libraries/tikzlibrary +positioning.code.tex +File: tikzlibrarypositioning.code.tex 2021/05/15 v3.1.9a (3.1.9a) +) (/usr/share/texmf-dist/tex/latex/tools/calc.sty +Package: calc 2017/05/25 v4.3 Infix arithmetic (KKT,FJ) +\calc@Acount=\count302 +\calc@Bcount=\count303 +\calc@Adimen=\dimen272 +\calc@Bdimen=\dimen273 +\calc@Askip=\skip52 +\calc@Bskip=\skip53 +LaTeX Info: Redefining \setlength on input line 80. +LaTeX Info: Redefining \addtolength on input line 81. +\calc@Ccount=\count304 +\calc@Cskip=\skip54 +) +\c@@todonotes@numberoftodonotes=\count305 +) +(/usr/share/texmf-dist/tex/latex/l3backend/l3backend-pdftex.def +File: l3backend-pdftex.def 2022-04-14 L3 backend support: PDF output (pdfTeX) +\l__color_backend_stack_int=\count306 +\l__pdf_internal_box=\box65 +) (./Report.aux) +\openout1 = `Report.aux'. + +LaTeX Font Info: Checking defaults for OML/cmm/m/it on input line 14. +LaTeX Font Info: ... okay on input line 14. +LaTeX Font Info: Checking defaults for OMS/cmsy/m/n on input line 14. +LaTeX Font Info: ... okay on input line 14. +LaTeX Font Info: Checking defaults for OT1/cmr/m/n on input line 14. +LaTeX Font Info: ... okay on input line 14. +LaTeX Font Info: Checking defaults for T1/cmr/m/n on input line 14. +LaTeX Font Info: ... okay on input line 14. +LaTeX Font Info: Checking defaults for TS1/cmr/m/n on input line 14. +LaTeX Font Info: ... okay on input line 14. +LaTeX Font Info: Checking defaults for OMX/cmex/m/n on input line 14. +LaTeX Font Info: ... okay on input line 14. +LaTeX Font Info: Checking defaults for U/cmr/m/n on input line 14. +LaTeX Font Info: ... okay on input line 14. +*geometry* driver: auto-detecting +*geometry* detected driver: pdftex +*geometry* verbose mode - [ preamble ] result: +* driver: pdftex +* paper: a4paper +* layout: +* layoutoffset:(h,v)=(0.0pt,0.0pt) +* modes: +* h-part:(L,W,R)=(56.9055pt, 483.69687pt, 56.9055pt) +* v-part:(T,H,B)=(56.9055pt, 731.23584pt, 56.9055pt) +* \paperwidth=597.50787pt +* \paperheight=845.04684pt +* \textwidth=483.69687pt +* \textheight=731.23584pt +* \oddsidemargin=-15.36449pt +* \evensidemargin=-15.36449pt +* \topmargin=-52.36449pt +* \headheight=12.0pt +* \headsep=25.0pt +* \topskip=10.0pt +* \footskip=30.0pt +* \marginparwidth=57.0pt +* \marginparsep=11.0pt +* \columnsep=10.0pt +* \skip\footins=9.0pt plus 4.0pt minus 2.0pt +* \hoffset=0.0pt +* \voffset=0.0pt +* \mag=1000 +* \@twocolumnfalse +* \@twosidefalse +* \@mparswitchfalse +* \@reversemarginfalse +* (1in=72.27pt=25.4mm, 1cm=28.453pt) + +Package caption Info: Begin \AtBeginDocument code. +Package caption Info: float package is loaded. +Package caption Info: End \AtBeginDocument code. +(/usr/share/texmf-dist/tex/context/base/mkii/supp-pdf.mkii +[Loading MPS to PDF converter (version 2006.09.02).] +\scratchcounter=\count307 +\scratchdimen=\dimen274 +\scratchbox=\box66 +\nofMPsegments=\count308 +\nofMParguments=\count309 +\everyMPshowfont=\toks41 +\MPscratchCnt=\count310 +\MPscratchDim=\dimen275 +\MPnumerator=\count311 +\makeMPintoPDFobject=\count312 +\everyMPtoPDFconversion=\toks42 +) (/usr/share/texmf-dist/tex/latex/epstopdf-pkg/epstopdf-base.sty +Package: epstopdf-base 2020-01-24 v2.11 Base part for package epstopdf +Package epstopdf-base Info: Redefining graphics rule for `.eps' on input line 4 +85. + +(/usr/share/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg +File: epstopdf-sys.cfg 2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Liv +e +)) +LaTeX Font Info: Trying to load font information for U+msa on input line 15. + + +(/usr/share/texmf-dist/tex/latex/amsfonts/umsa.fd +File: umsa.fd 2013/01/14 v3.01 AMS symbols A +) +LaTeX Font Info: Trying to load font information for U+msb on input line 15. + + +(/usr/share/texmf-dist/tex/latex/amsfonts/umsb.fd +File: umsb.fd 2013/01/14 v3.01 AMS symbols B +) [1 + +{/var/lib/texmf/fonts/map/pdftex/updmap/pdftex.map}] [1] +Chapter 1. +[1 + +] +Chapter 2. +<../images/1D_Function.png, id=20, 578.16pt x 325.215pt> +File: ../images/1D_Function.png Graphic file (type png) + +Package pdftex.def Info: ../images/1D_Function.png used on input line 32. +(pdftex.def) Requested size: 290.22107pt x 163.24724pt. +<../images/1D_Function_Interpolated.png, id=22, 578.16pt x 325.215pt> +File: ../images/1D_Function_Interpolated.png Graphic file (type png) + +Package pdftex.def Info: ../images/1D_Function_Interpolated.png used on input +line 46. +(pdftex.def) Requested size: 290.22107pt x 163.24724pt. +<../images/1D_Function_Interpolated_Zoomed.png, id=23, 375.0813pt x 325.215pt> +File: ../images/1D_Function_Interpolated_Zoomed.png Graphic file (type png) + +Package pdftex.def Info: ../images/1D_Function_Interpolated_Zoomed.png used on + input line 51. +(pdftex.def) Requested size: 188.64148pt x 163.55988pt. +[2 + + <../images/1D_Function.png>] [3 <../images/1D_Function_Interpolated.png> <../i +mages/1D_Function_Interpolated_Zoomed.png>] +Chapter 3. +<../images/2D_Contour.png, id=36, 652.5981pt x 401.0985pt> +File: ../images/2D_Contour.png Graphic file (type png) + +Package pdftex.def Info: ../images/2D_Contour.png used on input line 66. +(pdftex.def) Requested size: 237.01411pt x 145.66835pt. +<../images/2D_Contour_Zoomed.png, id=37, 652.5981pt x 401.0985pt> +File: ../images/2D_Contour_Zoomed.png Graphic file (type png) + +Package pdftex.def Info: ../images/2D_Contour_Zoomed.png used on input line 70 +. +(pdftex.def) Requested size: 237.01411pt x 145.66835pt. +<../images/NO44/2D_Contour_Interpolation.png, id=38, 1156.32pt x 650.43pt> +File: ../images/NO44/2D_Contour_Interpolation.png Graphic file (type png) + +Package pdftex.def Info: ../images/NO44/2D_Contour_Interpolation.png used on i +nput line 85. +(pdftex.def) Requested size: 483.69687pt x 272.07709pt. +[4 + + <../images/2D_Contour.png> <../images/2D_Contour_Zoomed.png>] [5 <../images/NO +44/2D_Contour_Interpolation.png>] (./Report.aux) ) +Here is how much of TeX's memory you used: + 15943 strings out of 478238 + 317659 string characters out of 5850456 + 578609 words of memory out of 5000000 + 33904 multiletter control sequences out of 15000+600000 + 478074 words of font info for 62 fonts, out of 8000000 for 9000 + 1141 hyphenation exceptions out of 8191 + 99i,9n,94p,636b,974s stack positions out of 5000i,500n,10000p,200000b,80000s + +Output written on Report.pdf (7 pages, 367098 bytes). +PDF statistics: + 84 PDF objects out of 1000 (max. 8388607) + 46 compressed objects within 1 object stream + 0 named destinations out of 1000 (max. 500000) + 43 words of extra memory for PDF output out of 10000 (max. 10000000) + diff --git a/report/Report.pdf b/report/Report.pdf new file mode 100755 index 0000000..f033f28 Binary files /dev/null and b/report/Report.pdf differ diff --git a/report/Report.synctex.gz b/report/Report.synctex.gz new file mode 100755 index 0000000..c9d9af1 Binary files /dev/null and b/report/Report.synctex.gz differ diff --git a/report/Report.tex b/report/Report.tex new file mode 100755 index 0000000..050ae3e --- /dev/null +++ b/report/Report.tex @@ -0,0 +1,92 @@ +\documentclass[a4paper,10pt]{report} +\usepackage[utf8]{inputenc} +\usepackage{amsmath,amsfonts,amssymb} +\usepackage[margin=2cm]{geometry} +\usepackage{indentfirst} +\usepackage{subcaption,graphicx,float} +\usepackage{todonotes} + +% Title Page +\title{Interpolation of Discretized Data} +\author{Milos Micik} + + +\begin{document} +\maketitle + +\begin{abstract} +\todo{Add abstract} +\end{abstract} + +\chapter{Introduction} +\todo{Add introduction.} + +\chapter{Interpolation in 1D} +In one dimensional interpolation we have decided to compare interpolation methods using Bezier curves and cubic polynomial splines. Both methods use piecewise polynomials to trace a curve defined by knot points and information about the first derivatives. + +\todo{Possibly add a bit of theory to splines.} + +In 1D, the interpolation task is nearly straightforward. The only issue that can arise is when the data to be interpolated is discretized. This could occur for example when collecting data from a measurement where the measuring device has a finite precision and can only detect change in the observed quantity in steps. +\begin{figure}[h] + \centering + \includegraphics[width=.6\textwidth]{../images/1D_Function.png} + % 1D_Function.png: 800x450 px, 100dpi, 20.32x11.43 cm, bb=0 0 576 324 + \caption{An example of discretized 1D data.} + \label{fig:1D_fun} +\end{figure} + +If we were to run the interpolation on such data without any adjustments, the polynomials would try to fit every single point in the collinear segments, producing a curve not too different from what we started with. Therefore in this case pre-processing of the data is required. + +The pre-processing we have chosen assumes that the discretized data is obtained by rounding the real-data observation. For example, in Figure \ref{fig:1D_fun}, the collinear segment from $x\approx0.15$ to $x\approx0.55$ is represented in the data with $y$ value $1.0$, however by our assumption we know that the real values could have been anywhere in the interval $[0.75, 1.25)$. The pre-processing algorithm simply isolates a midpoint from a collinear region of points. Where the collinear region is a local maximum or minimum, we isolate two point instead, $1/3$ and $2/3$ along the collinear segment. + +Using this algorithm, we can now interpolate any discretized curves in 1D. An example of it working in action can be seen in Figure \ref{fig:1D_fun_interpolated}: +\begin{figure}[H] + \centering + \begin{subfigure}{0.6\textwidth} + \includegraphics[width=\textwidth]{../images/1D_Function_Interpolated.png} + % 1D_Function_Interpolated.png: 800x450 px, 100dpi, 20.32x11.43 cm, bb=0 0 576 324 + \end{subfigure} + \hfill + \begin{subfigure}{0.39\textwidth} + \includegraphics[width=\textwidth]{../images/1D_Function_Interpolated_Zoomed.png} + % 1D_Function_Interpolated_Zoomed.png: 800x450 px, 100dpi, 20.32x11.43 cm, bb=0 0 576 324 + \end{subfigure} + \caption{An example of curves interpolated from discretized 1D data.} + \label{fig:1D_fun_interpolated} +\end{figure} + +Note the subtle difference between the Bezier curve and the cubic spline. In segments which are relatively straight, their shape is very similar. However, the difference at places where the curve takes sharper turn is more noticeable. The cubic spline seems to achieve much better results, introducing less irregularities and copying the original data curve more smoothly. This does not come as a surprise, as cubic splines are expected to have \textit{$C^2$} continuity, whereas Bezier curves are only \textit{$C^1$} continuous. + +\chapter{Interpolation in 2D} +\section{Parametric Curves} +Interpolating parametric curves in 2D (technically in any dimension) is very similar to interpolating in 1D. It might require different functions when implementing these in a programming language, but the algorithm is the same - if the data is discretized, we need to first isolate points from collinear segments. +\begin{figure}[H] + \centering + \begin{subfigure}{0.49\textwidth} + \includegraphics[width=\textwidth]{../images/2D_Contour.png} + \end{subfigure} + \hfill + \begin{subfigure}{0.49\textwidth} + \includegraphics[width=\textwidth]{../images/2D_Contour_Zoomed.png} + \end{subfigure} + \caption{An example of parametric curves interpolated from discretized parametric 1D curve in 2D.} + \label{fig:2D_parametric_curve} +\end{figure} + +The same observation about the continuity holds in this case - cubic splines produce curves which look more natural. + +\section{Countour lines} +Interpolating contour lines of 2D functions can be done by representing the contours as parametric curves. As an example, we will use digital elevation maps of regions from Scotland. + + + +\begin{figure}[H] + \centering + \includegraphics[width=1\textwidth]{../images/NO44/2D_Contour_Interpolation.png} + % 2D_Contour_Interpolation.png: 1600x900 px, 100dpi, 40.64x22.86 cm, bb=0 0 1152 648 + \label{fig:2D_contour} + \caption{Contour interpolation from data with various resolution.} +\end{figure} + + +\end{document}