From dfb2320877bb0ee8effcf6844c543ce46867cc17 Mon Sep 17 00:00:00 2001 From: arnekeller Date: Sat, 6 Apr 2019 11:02:26 +0200 Subject: [PATCH] More examples and docs --- DokumentationAufgabe1.tex | 36 +++ run_all.sh | 19 +- welt3.svg | 171 ++++++++++ welt3.tkz | 62 ++++ welt4.svg | 656 ++++++++++++++++++++++++++++++++++++++ welt5.svg | 128 ++++++++ welt6.svg | 166 ++++++++++ welt7b.svg | 294 +++++++++++++++++ 8 files changed, 1526 insertions(+), 6 deletions(-) create mode 100644 welt3.svg create mode 100644 welt3.tkz create mode 100644 welt4.svg create mode 100644 welt5.svg create mode 100644 welt6.svg create mode 100644 welt7b.svg diff --git a/DokumentationAufgabe1.tex b/DokumentationAufgabe1.tex index ddac0e7..99ada98 100644 --- a/DokumentationAufgabe1.tex +++ b/DokumentationAufgabe1.tex @@ -277,6 +277,42 @@ Alle Beispiele sind im Maßstab 1:70m. \caption{Beispiel 5} \label{fig:bsp5} \end{figure} +\subsection{Eigene Beispiele} +\lstinputlisting[caption=Lösung für Abb. \ref{fig:ebsp2},frame=single,breaklines=true]{runwelt3.txt} +\begin{figure}[H] +\centering +\input{welt3.tkz} +\caption{Heuristikfalle} +\label{fig:ebsp2} +\end{figure} +\lstinputlisting[caption=Lösung für Abb. \ref{fig:ebsp3},frame=single,breaklines=true]{runwelt4.txt} +\begin{figure}[H] +\centering +\input{welt4.tkz} +\caption{Angriff der Dreiecksgrundstücke (aus Aufgabe 2 entflohen)} +\label{fig:ebsp3} +\end{figure} +\lstinputlisting[caption=Lösung für Abb. \ref{fig:ebsp4},frame=single,breaklines=true]{runwelt7b.txt} +\begin{figure}[H] +\centering +\input{welt7b.tkz} +\caption{Text} +\label{fig:ebsp4} +\end{figure} +\lstinputlisting[caption=Lösung für Abb. \ref{fig:ebsp5},frame=single,breaklines=true]{runwelt5.txt} +\begin{figure}[H] +\centering +\input{welt5.tkz} +\caption{Mauern} +\label{fig:ebsp5} +\end{figure} +\lstinputlisting[caption=Lösung für Abb. \ref{fig:ebsp6},frame=single,breaklines=true]{runwelt6.txt} +\begin{figure}[H] +\centering +\input{welt6.tkz} +\caption{Oktagone} +\label{fig:ebsp6} +\end{figure} \section{Quellcode (Hauptalgorithmus)} \lstinputlisting[frame=single,language=Rust,breaklines=true]{src/main.rs} diff --git a/run_all.sh b/run_all.sh index c301dd3..365de74 100755 --- a/run_all.sh +++ b/run_all.sh @@ -1,6 +1,13 @@ -cargo run --release -- -t < lisarennt1.txt > run1.tkz -cargo run --release -- -t < lisarennt2.txt > run2.tkz -cargo run --release -- -t < lisarennt3.txt > run3.tkz -cargo run --release -- -t < lisarennt4.txt > run4.tkz -cargo run --release -- -t < lisarennt5.txt > run5.tkz -cargo run --release -- -h > help.txt +#!/usr/bin/zsh +cargo build --release +target/release/aufgabe1 -h > help.txt +target/release/aufgabe1 -t < lisarennt1.txt > >(tee lisarennt1.tkz) 2> >(tee run1.txt >&2) +target/release/aufgabe1 -t < lisarennt2.txt > >(tee lisarennt2.tkz) 2> >(tee run2.txt >&2) +target/release/aufgabe1 -t < lisarennt3.txt > >(tee lisarennt3.tkz) 2> >(tee run3.txt >&2) +target/release/aufgabe1 -t < lisarennt4.txt > >(tee lisarennt4.tkz) 2> >(tee run4.txt >&2) +target/release/aufgabe1 -t < lisarennt5.txt > >(tee lisarennt5.tkz) 2> >(tee run5.txt >&2) +target/release/aufgabe1 -t < welt3.svg > >(tee /dev/null) 2> >(tee runwelt3.txt >&2) +target/release/aufgabe1 -t < welt4.svg > >(tee welt4.tkz) 2> >(tee runwelt4.txt >&2) +target/release/aufgabe1 -t < welt5.svg > >(tee welt5.tkz) 2> >(tee runwelt5.txt >&2) +target/release/aufgabe1 -t < welt6.svg > >(tee welt6.tkz) 2> >(tee runwelt6.txt >&2) +target/release/aufgabe1 -t < welt7b.svg > >(tee welt7b.tkz) 2> >(tee runwelt7b.txt >&2) diff --git a/welt3.svg b/welt3.svg new file mode 100644 index 0000000..8e47cc6 --- /dev/null +++ b/welt3.svg @@ -0,0 +1,171 @@ + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/welt3.tkz b/welt3.tkz new file mode 100644 index 0000000..2a1f382 --- /dev/null +++ b/welt3.tkz @@ -0,0 +1,62 @@ +\begin{tikzpicture} +\tkzInit[xmax=10.615672,ymax=9.042646] +\tkzAxeXY +\tkzGrid +\tkzDefPoints{2.4023376/4.7303762/P0_0,2.4023376/4.210283/P0_1,2.9471977/4.259815/P0_2,2.897665/4.70561/P0_3,2.4023376/4.7303762/P0_4} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P0_0,P0_1,P0_2,P0_3,P0_4) +\tkzDefPoints{3.2443938/0.9658883/P1_0,3.6901891/1.9070103/P1_1,4.6065445/1.8327113/P1_2,5.077105/1.0154209/P1_3,4.581778/0.27243042/P1_4,3.7892544/0.42102835/P1_5,3.2443938/0.9658883/P1_6} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P1_0,P1_1,P1_2,P1_3,P1_4,P1_5,P1_6) +\tkzDefPoints{1.411683/1.6593462/P2_0,1.411683/2.4023376/P2_1,1.7831783/3.0214965/P2_2,2.7985997/3.764488/P2_3,3.4425251/3.6901891/P2_4,4.804675/3.368226/P2_5,3.6158895/3.2443943/P2_6,2.7985997/2.897665/P2_7,2.2537396/2.129908/P2_8,2.476637/1.4364493/P2_9,2.7985997/0.941122/P2_10,1.411683/1.6593462/P2_11} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P2_0,P2_1,P2_2,P2_3,P2_4,P2_5,P2_6,P2_7,P2_8,P2_9,P2_10,P2_11) +\tkzDefPoints{0.8420564/0.6191589/P3_0,1.2630849/1.0897199/P3_1,1.4364493/0.37149572/P3_2,0.8420564/0.6191589/P3_3} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P3_0,P3_1,P3_2,P3_3) +\tkzDefPoints{4.43318/4.210283/P4_0,4.6808434/5.9191623/P4_1,3.442525/6.0677605/P4_2,3.5663567/6.736452/P4_3,6.3154235/6.265891/P4_4,6.1668253/5.4486012/P4_5,5.275236/5.6962647/P4_6,5.077105/4.1855164/P4_7,4.43318/4.210283/P4_8} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P4_0,P4_1,P4_2,P4_3,P4_4,P4_5,P4_6,P4_7,P4_8) +\tkzDefPoints{6.117293/1.807945/P5_0,5.5971994/2.3280387/P5_1,5.448601/3.0214965/P5_2,5.473367/3.442525/P5_3,5.745797/3.838787/P5_4,6.0677605/3.8140206/P5_5,6.216358/3.4177587/P5_6,6.265891/2.9967303/P5_7,6.5383215/3.4672914/P5_8,6.761218/3.6901891/P5_9,7.132714/3.6901891/P5_10,7.405144/3.0214965/P5_11,7.3060784/2.6004682/P5_12,6.885051/2.1794407/P5_13,6.4392557/1.9317766/P5_14,6.117293/1.807945/P5_15} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P5_0,P5_1,P5_2,P5_3,P5_4,P5_5,P5_6,P5_7,P5_8,P5_9,P5_10,P5_11,P5_12,P5_13,P5_14,P5_15) +\tkzDefPoints{0.9044522/3.9131365/P6_0,0.9044522/3.3930428/P6_1,1.4493121/3.4425755/P6_2,1.3997796/3.8883703/P6_3,0.9044522/3.9131365/P6_4} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P6_0,P6_1,P6_2,P6_3,P6_4) +\tkzDefPoints{1.1273493/5.844913/P7_0,1.5731443/6.786035/P7_1,2.4894998/6.711736/P7_2,2.9600604/5.894446/P7_3,2.4647334/5.1514554/P7_4,1.6722096/5.300053/P7_5,1.1273493/5.844913/P7_6} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P7_0,P7_1,P7_2,P7_3,P7_4,P7_5,P7_6) +\tkzDefPoints{6.92268/4.829492/P8_0,6.92268/5.5724835/P8_1,7.294175/6.1916428/P8_2,8.309596/6.9346333/P8_3,8.953522/6.860334/P8_4,10.315672/6.538372/P8_5,9.126886/6.4145393/P8_6,8.309596/6.067811/P8_7,7.7647367/5.300053/P8_8,7.987633/4.6065955/P8_9,8.309596/4.111267/P8_10,6.92268/4.829492/P8_11} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P8_0,P8_1,P8_2,P8_3,P8_4,P8_5,P8_6,P8_7,P8_8,P8_9,P8_10,P8_11) +\tkzDefPoints{3.7773507/2.4519207/P9_0,4.198379/2.9224818/P9_1,4.3717437/2.2042577/P9_2,3.7773507/2.4519207/P9_3} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P9_0,P9_1,P9_2,P9_3) +\tkzDefPoints{0.44602993/1.7456455/P10_0,0.86705834/2.2162066/P10_1,1.0404228/1.4979824/P10_2,0.44602993/1.7456455/P10_3} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P10_0,P10_1,P10_2,P10_3) +\tkzDefPoints{2.006311/0.43302786/P11_0,2.4273396/0.9035897/P11_1,2.6007042/0.18536465/P11_2,2.006311/0.43302786/P11_3} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P11_0,P11_1,P11_2,P11_3) +\tkzDefPoints{5.4488363/1.151253/P12_0,5.869865/1.621814/P12_1,6.043229/0.9035889/P12_2,5.4488363/1.151253/P12_3} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P12_0,P12_1,P12_2,P12_3) +\tkzDefPoints{0.17336456/3.0957963/P13_0,0.2228973/6.513555/P13_1,1.0897201/8.024303/P13_2,2.8481324/8.172901/P13_3,4.235049/7.9500046/P13_4,3.7892544/7.454677/P13_5,2.1299076/7.6528077/P13_6,0.8420565/6.835518/P13_7,0.7677574/5.621966/P13_8,0.56962645/4.2845817/P13_9,0.17336456/3.0957963/P13_10} +\tkzDrawPolygon[fill=orange,line width=1pt,opacity=0.5](P13_0,P13_1,P13_2,P13_3,P13_4,P13_5,P13_6,P13_7,P13_8,P13_9,P13_10) +\tkzDefPoints{5.857208/6.7118044/P14_0,5.3371143/7.2318983/P14_1,5.1885157/7.9253564/P14_2,5.213282/8.346385/P14_3,5.485712/8.742646/P14_4,5.8076754/8.71788/P14_5,5.956273/8.321619/P14_6,6.005806/7.9005904/P14_7,6.2782364/8.371151/P14_8,6.501133/8.5940485/P14_9,6.8726287/8.5940485/P14_10,7.145059/7.9253564/P14_11,7.0459933/7.5043283/P14_12,6.6249657/7.0833/P14_13,6.1791706/6.8356366/P14_14,5.857208/6.7118044/P14_15} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P14_0,P14_1,P14_2,P14_3,P14_4,P14_5,P14_6,P14_7,P14_8,P14_9,P14_10,P14_11,P14_12,P14_13,P14_14,P14_15) +\tkzDefPoints{6.885286/1.151253/P15_0,7.306314/1.621814/P15_1,7.4796786/0.9035889/P15_2,6.885286/1.151253/P15_3} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P15_0,P15_1,P15_2,P15_3) +\tkzDefPoints{7.7025757/2.8353665/P16_0,8.123604/3.3059273/P16_1,8.296968/2.5877023/P16_2,7.7025757/2.8353665/P16_3} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P16_0,P16_1,P16_2,P16_3) +\tkzDefPoints{5.597435/4.4204135/P17_0,6.018463/4.8909745/P17_1,6.1918273/4.1727495/P17_2,5.597435/4.4204135/P17_3} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P17_0,P17_1,P17_2,P17_3) +\tkzDefPoints{8.940894/5.212938/P18_0,9.361923/5.683499/P18_1,9.535287/4.9652734/P18_2,8.940894/5.212938/P18_3} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P18_0,P18_1,P18_2,P18_3) +\tkzDefPoints{5.176406/0.28442994/P19_0,5.597435/0.75499094/P19_1,5.770799/0.036765832/P19_2,5.176406/0.28442994/P19_3} +\tkzDrawPolygon[fill=black,line width=1pt,opacity=0.5](P19_0,P19_1,P19_2,P19_3) +\tkzDefPoint(8.423665,0.5451468){R0} +\tkzDefPoint(5.770799,0.036765832){R1} +\tkzDefPoint(3.7892544,0.42102835){R2} +\tkzDefPoint(1.411683,1.6593462){R3} +\tkzDefPoint(0.86705834,2.2162066){R4} +\tkzDefPoint(0,2.716803){R5} +\tkzDrawSegment(R0,R1) +\tkzDrawSegment(R1,R2) +\tkzDrawSegment(R2,R3) +\tkzDrawSegment(R3,R4) +\tkzDrawSegment(R4,R5) +\tkzDrawPoint[fill=green,color=black,size=13](R0) +\tkzDrawPoint[fill=red,color=black,size=13](R1) +\tkzDrawPoint[fill=red,color=black,size=13](R2) +\tkzDrawPoint[fill=red,color=black,size=13](R3) +\tkzDrawPoint[fill=red,color=black,size=13](R4) +\tkzDrawPoint[fill=green,color=black,size=13](R5) +\end{tikzpicture} diff --git a/welt4.svg b/welt4.svg new file mode 100644 index 0000000..15c142e --- /dev/null +++ b/welt4.svg @@ -0,0 +1,656 @@ + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/welt5.svg b/welt5.svg new file mode 100644 index 0000000..d15b75b --- /dev/null +++ b/welt5.svg @@ -0,0 +1,128 @@ + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/welt6.svg b/welt6.svg new file mode 100644 index 0000000..a8fc6c5 --- /dev/null +++ b/welt6.svg @@ -0,0 +1,166 @@ + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + diff --git a/welt7b.svg b/welt7b.svg new file mode 100644 index 0000000..d9f7892 --- /dev/null +++ b/welt7b.svg @@ -0,0 +1,294 @@ + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +