-
Notifications
You must be signed in to change notification settings - Fork 0
/
merge.tex
83 lines (64 loc) · 2.07 KB
/
merge.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
% \documentclass[]{minimal}
% \usepackage{tikz}
% \usetikzlibrary{positioning}
% \usetikzlibrary{arrows}
% \usetikzlibrary{patterns}
% \begin{document}
% \pagestyle{empty}
% \begin{tikzpicture}[scale=2.2]
% coordinates
\draw[->] (0,0) -- (0,3) node[pos=1,below left] {y};
\draw[-] (0,0) -- (.25,0);
\draw[dotted] (.25,0) -- (.5,0);
\draw[-] (.5,0) -- (5.5,0);
\draw[dotted] (5.5,0) -- (5.75,0);
\draw[->] (5.75,0) -- (6,0) node[pos=1,below left] {x};
% threads
\draw[loosely dashed] (1,0) -- (1,3.3);
\draw[loosely dashed] (3,0) -- (3,3.3);
\draw[loosely dashed] (5,0) -- (5,3.3);
\node[below] at (1,0) {$t_{i-1}$};
\node[below] at (3,0) {$t_{i}$};
\node[below] at (5,0) {$t_{i+1}$};
% exact
\draw[thick] (.5,-.3) parabola bend +(5,2.6) (5.5,2.3);
\begin{scope}[very thick]
% pCoarse
\begin{scope}[loosely dotted, color=blue]
\draw (1,.8) to[out=45,in=215] (3,2.6);
\draw (3,2.15) to[out=39,in=192] (5,2.95);
\end{scope}
% pFine
\begin{scope}[densely dotted, color=blue]
\draw (1,.8) to[out=44,in=212] (3,2.35);
\draw (3,2.15) to[out=28,in=186] (5,2.75);
\end{scope}
% coarse
\begin{scope}[loosely dotted, color=orange]
\draw (1,.5) to[out=45,in=215] (3,2.2);
\draw (3,1.95) to[out=32,in=188] (5,2.7);
\end{scope}
\end{scope}
% merges
\begin{scope}[red, ultra thick]
\draw[->, dashed] (2.96,2.6) -- (2.96,2.2);
\draw[->] (3.04,2.35) -- (3.04,1.95);
\draw[->, dashed] (4.96,2.95) -- (4.96,2.7);
\draw[->] (5.04,2.75) -- (5.04,2.5);
\end{scope}
%legend
\draw[] (3.25,.25) rectangle (4.75, 1.65);
\begin{scope}[anchor=west]
\node[] at (3.8,1.45) {\(\mathcal{F}\)};
\node[] at (3.8,1.25) {\(\mathcal{G}\)};
\node[] at (3.8,.95) {$i_k$};
\node[] at (3.8,.75) {$i_{k+1}$};
\node[] at (3.8,.45) {Korrektur};
\end{scope}
\draw[-, dotted,very thick] (3.4,1.45) -- (3.7,1.45);
\draw[-, loosely dotted,very thick] (3.4,1.25) -- (3.7,1.25);
\draw[pattern color=blue,pattern=north east lines] (3.4,.9) rectangle (3.7, 1);
\draw[pattern color=orange,pattern=north east lines] (3.4,.7) rectangle (3.7, .8);
\draw[->,red, ultra thick] (3.4,.45) -- (3.7,.45);
% \end{tikzpicture}
% \end{document}