stud

study spacejunk
Log | Files | Refs | LICENSE

commit 8d62f68d0e87bced56db78546b085b28d46eb7a8 (tree)
parent 4a80c7ec167b0f2d23248dfd53403fd8cc81a3c3
Author: Motiejus Jakštys <motiejus@uber.com>
Date:   Sat, 17 Apr 2021 20:42:59 +0300

explanations

Diffstat:
MIV/mj-msc.tex | 14++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/IV/mj-msc.tex b/IV/mj-msc.tex @@ -418,14 +418,14 @@ following the rules of the article. \centering \begin{subfigure}[b]{.4\textwidth} \includegraphics[width=\textwidth]{fig6-selfcrossing-before} - \caption{Bend's baseline is crossing another bend} + \caption{Bend's baseline (dotted) is crossing a neighboring bend} \end{subfigure} \hfill \begin{subfigure}[b]{.4\textwidth} \includegraphics[width=\textwidth]{fig6-selfcrossing-after} - \caption{Self-crossing removed} + \caption{Self-crossing removed following the algorithm} \end{subfigure} - \caption{Originally Figure 6: self-line crossing} + \caption{Originally Figure 6: simple case of self-line crossing} \label{fig:fig6-selfcrossing} \end{figure} @@ -438,18 +438,20 @@ figure~\onpage{fig:selfcrossing-1-non-neighbor}. \centering \begin{subfigure}[b]{.4\textwidth} \includegraphics[width=\textwidth]{selfcrossing-1-before} - \caption{Bend's baseline is crossing a non-neighboring bend} + \caption{Bend's baseline (dotted) is crossing a non-neighboring bend} \end{subfigure} \hfill \begin{subfigure}[b]{.4\textwidth} \includegraphics[width=\textwidth]{selfcrossing-1-after} - \caption{Self-crossing removed} + \caption{Self-crossing removed following the algorithm} \end{subfigure} \caption{Self-crossing with non-neighboring bend} \label{fig:selfcrossing-1-non-neighbor} \end{figure} -Naively implemented, checking every bend with every bend is costs $O(n^2)$. +Naively implemented, checking every bend with every bend is costs $O(n^2)$. In +other words, the time it takes to run the algorithm grows quadratically with +the with the number of vertices. It is possible to optimize this step and skip checking some of the bends. Only bends whose sum of inner angles is $\pi$ can ever self-cross. If the value is