diff options
20 files changed, 689 insertions, 0 deletions
diff --git a/Info/11/NTG/1/Intro/.gitignore b/Info/11/NTG/1/Intro/.gitignore new file mode 100644 index 00000000..72a05a96 --- /dev/null +++ b/Info/11/NTG/1/Intro/.gitignore @@ -0,0 +1,4 @@ +digraph.pdf +graph.pdf +weighted_graph.pdf +plots/ diff --git a/Info/11/NTG/1/Intro/digraph.tex b/Info/11/NTG/1/Intro/digraph.tex new file mode 100644 index 00000000..ffadad9d --- /dev/null +++ b/Info/11/NTG/1/Intro/digraph.tex @@ -0,0 +1,10 @@ +\documentclass{standalone} +\usepackage{tikz} +\usetikzlibrary{positioning, arrows.meta} +\begin{document} +\tikzstyle{edge} = [-Latex] +\tikzstyle{path} = [] +\tikzstyle{cycle} = [] +\tikzstyle{blocked} = [] +\input{graph.tikz} +\end{document} diff --git a/Info/11/NTG/1/Intro/graph.tex b/Info/11/NTG/1/Intro/graph.tex new file mode 100644 index 00000000..346d3f1c --- /dev/null +++ b/Info/11/NTG/1/Intro/graph.tex @@ -0,0 +1,10 @@ +\documentclass{standalone} +\usepackage{tikz} +\usetikzlibrary{positioning} +\begin{document} +\tikzstyle{edge} = [] +\tikzstyle{path} = [] +\tikzstyle{cycle} = [] +\tikzstyle{blocked} = [] +\input{graph.tikz} +\end{document} diff --git a/Info/11/NTG/1/Intro/graph.tikz b/Info/11/NTG/1/Intro/graph.tikz new file mode 100644 index 00000000..26c1af20 --- /dev/null +++ b/Info/11/NTG/1/Intro/graph.tikz @@ -0,0 +1,30 @@ +\begin{tikzpicture}[node/.style={rounded corners=2pt, draw}] +\node[node] (nuernberg) {Nürnberg}; +\node[node, below right=0.5cm of nuernberg] (feucht) {Feucht}; +\node[node, below left=0.7cm and -0.3cm of nuernberg] (wendelstein) {Wendelstein}; +\draw[edge, path, cycle] (nuernberg) -- (wendelstein); +\draw[edge, cycle] (nuernberg) -- (feucht); +\draw[edge, cycle] (wendelstein) -- (feucht); +\node[node, below left=0.4 and -0.4cm of wendelstein] (schwanstein) {Schwanstein}; +\draw[edge] (wendelstein) -- (schwanstein); +\node[node, below right=0.1cm and 0.6cm of schwanstein] (postbauerHeng) {Postbauer Heng}; +\draw[edge, path] (wendelstein) -- (postbauerHeng); +\draw[edge] (feucht) -- (postbauerHeng); +\node[node, align=center, below right=-0.3cm and 0.6cm of postbauerHeng] (neumarkt) {Neumarkt i. d. \\ Oberpfalz}; +\draw[edge] (wendelstein) -- (neumarkt); +\draw[edge] (feucht) -- (neumarkt); +\draw[edge] (postbauerHeng) -- (neumarkt); +\node[node, below=1.5cm of schwanstein] (creding) {Creding}; +\draw[edge, blocked] (schwanstein) -- (creding); +\node[node, below right=1 and -1.5cm of postbauerHeng] (beilngries) {Beilngries}; +\draw[edge, path, blocked] (postbauerHeng) -- (beilngries); +\draw[edge, blocked] (neumarkt) -- (beilngries); +\node[node, below left=of beilngries] (ingolstadt) {Ingolstadt}; +\draw[edge, path] (beilngries) -- (ingolstadt); +\draw[edge] (creding) -- (ingolstadt); +\node[node, below right=of beilngries] (kelheim) {Kelheim}; +\draw[edge] (beilngries) -- (kelheim); +\node[node, below right=of ingolstadt] (muenchen) {München}; +\draw[edge] (kelheim) -- (muenchen); +\draw[edge, path] (ingolstadt) -- (muenchen); +\end{tikzpicture} diff --git a/Info/11/NTG/1/Intro/img/Graphen.jpg b/Info/11/NTG/1/Intro/img/Graphen.jpg Binary files differnew file mode 100644 index 00000000..3811804a --- /dev/null +++ b/Info/11/NTG/1/Intro/img/Graphen.jpg diff --git a/Info/11/NTG/1/Intro/img/Vlad_Tepes_002.jpg b/Info/11/NTG/1/Intro/img/Vlad_Tepes_002.jpg Binary files differnew file mode 100644 index 00000000..7c3745ad --- /dev/null +++ b/Info/11/NTG/1/Intro/img/Vlad_Tepes_002.jpg diff --git a/Info/11/NTG/1/Intro/img/bike.png b/Info/11/NTG/1/Intro/img/bike.png Binary files differnew file mode 100644 index 00000000..a936b36f --- /dev/null +++ b/Info/11/NTG/1/Intro/img/bike.png diff --git a/Info/11/NTG/1/Intro/quiz/.gitignore b/Info/11/NTG/1/Intro/quiz/.gitignore new file mode 100644 index 00000000..ecf5e870 --- /dev/null +++ b/Info/11/NTG/1/Intro/quiz/.gitignore @@ -0,0 +1,2 @@ +*.pdf +*.png diff --git a/Info/11/NTG/1/Intro/quiz/Graphen Eigenschaften-20_9_2024.json b/Info/11/NTG/1/Intro/quiz/Graphen Eigenschaften-20_9_2024.json new file mode 100644 index 00000000..da057490 --- /dev/null +++ b/Info/11/NTG/1/Intro/quiz/Graphen Eigenschaften-20_9_2024.json @@ -0,0 +1 @@ +{"name":"Graphen Eigenschaften","currentQuestionIndex":-1,"questionList":[{"questionText":"Welche **Eigenschaften** besitzt folgender Graph:\n","timer":30,"displayAnswerText":true,"tags":["Klasse 11","Graphen","Informatik"],"requiredForToken":true,"difficulty":3,"answerOptionList":[{"answerText":"Vollständig","isCorrect":true,"TYPE":"DefaultAnswerOption"},{"answerText":"Gerichtet","isCorrect":false,"TYPE":"DefaultAnswerOption"},{"answerText":"Zyklenfrei","isCorrect":false,"TYPE":"DefaultAnswerOption"},{"answerText":"Zusammenhängend","isCorrect":true,"TYPE":"DefaultAnswerOption"}],"showOneAnswerPerRow":true,"TYPE":"MultipleChoiceQuestion"},{"questionText":"Welche **Eigenschaft** besitzt folgender Graph:\n","timer":30,"displayAnswerText":true,"tags":["Klasse 11","Graphen","Informatik"],"requiredForToken":true,"difficulty":4,"answerOptionList":[{"answerText":"Zyklenfrei","isCorrect":true,"TYPE":"DefaultAnswerOption"},{"answerText":"Ungerichtet","isCorrect":false,"TYPE":"DefaultAnswerOption"},{"answerText":"Unzusammenhängend","isCorrect":false,"TYPE":"DefaultAnswerOption"},{"answerText":"Vollständig ","isCorrect":false,"TYPE":"DefaultAnswerOption"}],"showOneAnswerPerRow":true,"TYPE":"SingleChoiceQuestion"},{"questionText":"Sind folgende Graphen identisch?\n","timer":30,"displayAnswerText":true,"tags":["Klasse 11","Informatik","Graphen"],"requiredForToken":true,"difficulty":3,"answerOptionList":[{"answerText":"Ja","isCorrect":true,"TYPE":"DefaultAnswerOption"},{"answerText":"Nein","isCorrect":false,"TYPE":"DefaultAnswerOption"}],"showOneAnswerPerRow":true,"TYPE":"YesNoSingleChoiceQuestion"},{"questionText":"Finde den **kürzesten** Pfad von **A** nach **F**.\n","timer":30,"displayAnswerText":true,"tags":["Klasse 11","Informatik","Graphen"],"requiredForToken":true,"difficulty":5,"answerOptionList":[{"answerText":"A/B/C/D/F","isCorrect":false,"TYPE":"DefaultAnswerOption"},{"answerText":"A/C/F","isCorrect":false,"TYPE":"DefaultAnswerOption"},{"answerText":"A/C/D/F","isCorrect":true,"TYPE":"DefaultAnswerOption"},{"answerText":"A/C/E/F","isCorrect":false,"TYPE":"DefaultAnswerOption"}],"showOneAnswerPerRow":true,"TYPE":"SingleChoiceQuestion"}],"sessionConfig":{"theme":"Material","readingConfirmationEnabled":false,"showResponseProgress":true,"confidenceSliderEnabled":false,"music":{"enabled":{"lobby":true,"countdownRunning":true,"countdownEnd":true},"shared":{"lobby":false,"countdownRunning":false,"countdownEnd":false},"volumeConfig":{"global":60,"lobby":60,"countdownRunning":60,"countdownEnd":60,"useGlobalVolume":true},"titleConfig":{"lobby":"Song3","countdownRunning":"Song1","countdownEnd":"Song1"}},"nicks":{"memberGroups":[],"maxMembersPerGroup":10,"autoJoinToGroup":false,"selectedNicks":[],"blockIllegalNicks":true}},"state":"Inactive","currentStartTimestamp":-1}
\ No newline at end of file diff --git a/Info/11/NTG/1/Intro/quiz/Makefile b/Info/11/NTG/1/Intro/quiz/Makefile new file mode 100644 index 00000000..6dd6e184 --- /dev/null +++ b/Info/11/NTG/1/Intro/quiz/Makefile @@ -0,0 +1,18 @@ +GRAPHS = $(wildcard *.dot) +PDFS = $(GRAPHS:.dot=.pdf) +PNGS = $(GRAPHS:.dot=.png) + +DOT_ENGINE ?= dot + +.PHONY: all +all: $(PDFS) $(PNGS) + +%.pdf: %.dot + $(DOT_ENGINE) $< -Tpdf -o $@ + +%.png: %.dot + $(DOT_ENGINE) $< -Tpng -o $@ + +.PHONY: clean +clean: + rm -f $(PDFS) $(PNGS) diff --git a/Info/11/NTG/1/Intro/quiz/equivalent.dot b/Info/11/NTG/1/Intro/quiz/equivalent.dot new file mode 100644 index 00000000..bea22741 --- /dev/null +++ b/Info/11/NTG/1/Intro/quiz/equivalent.dot @@ -0,0 +1,14 @@ +digraph{ + A -> B + B -> A + B -> C + C -> D + D -> A + A -> D + + + A2 -> B2 [dir=none] + B2 -> C2 + C2 -> D2 + D2 -> A2 [dir=none] +} diff --git a/Info/11/NTG/1/Intro/quiz/gewichtet_gerichtet_zusammenhaengend.dot b/Info/11/NTG/1/Intro/quiz/gewichtet_gerichtet_zusammenhaengend.dot new file mode 100644 index 00000000..fc2b604e --- /dev/null +++ b/Info/11/NTG/1/Intro/quiz/gewichtet_gerichtet_zusammenhaengend.dot @@ -0,0 +1,6 @@ +digraph { + A -> B [label=2, weight=2] + B -> C [label=5, weight=5] + A -> C [label=2, weight=2] + D -> A [label=3, weight=3] +} diff --git a/Info/11/NTG/1/Intro/quiz/kuerzester_pfad.dot b/Info/11/NTG/1/Intro/quiz/kuerzester_pfad.dot new file mode 100644 index 00000000..695bf56a --- /dev/null +++ b/Info/11/NTG/1/Intro/quiz/kuerzester_pfad.dot @@ -0,0 +1,12 @@ +graph { + A [color="green"] + F [color="orange"] + A -- B [label=2, weight=2] + A -- C [label=2, weight=2] + B -- C [label=1, weight=1] + C -- D [label=2, weight=2] + C -- E [label=3, weight=3] + C -- F [label=5, weight=5] + D -- F [label=2, weight=2] + E -- F [label=5, weight=5] +} diff --git a/Info/11/NTG/1/Intro/quiz/unzusammenhaengend.dot b/Info/11/NTG/1/Intro/quiz/unzusammenhaengend.dot new file mode 100644 index 00000000..38fe95e0 --- /dev/null +++ b/Info/11/NTG/1/Intro/quiz/unzusammenhaengend.dot @@ -0,0 +1,7 @@ +graph { + A -- B + B -- C + A -- C + D -- A + E -- F +} diff --git a/Info/11/NTG/1/Intro/quiz/vollstaendig.dot b/Info/11/NTG/1/Intro/quiz/vollstaendig.dot new file mode 100644 index 00000000..19798b41 --- /dev/null +++ b/Info/11/NTG/1/Intro/quiz/vollstaendig.dot @@ -0,0 +1,5 @@ +graph { + A -- B + B -- C + C -- A +} diff --git a/Info/11/NTG/1/Intro/slides.md b/Info/11/NTG/1/Intro/slides.md new file mode 100644 index 00000000..54cf01c8 --- /dev/null +++ b/Info/11/NTG/1/Intro/slides.md @@ -0,0 +1,495 @@ +--- +header-includes: | + \makeatletter + \beamer@ignorenonframefalse + \makeatother + \usepackage[most]{tcolorbox} + \usetikzlibrary {decorations.markings} +--- + +## \faIcon{hands-helping} / \faIcon{chalkboard} Arbeitsauftrag: Fachbegriffe \hfill{} 1/5 + +### Diskutiert folgende Aussage: + +\vspace{1cm} +> Damit der Computer sich etwas merken kann, muss eine Variable oder ein Attribut zuerst **initialisiert** und dann **deklariert** werden. +> Die beiden Schritten sind [immer]{.underline} von einander getrennt und dürfen [niemals]{.niemals} in der selben Zeile stehen. + +## \faIcon{hands-helping} / \faIcon{chalkboard} Arbeitsauftrag: Objekt Erzeugung \hfill{} 2/5 + +### Diskutiert folgende Aussage: + +\vspace{1cm} +> Die besondere Methode, die Objekte einer Klasse erzeugt, heißt **Konstruktor**, weil sie ein neues Objekt *konstruiert*. +> In Java hat der Konstruktor immer den Namen `new`{.java}, da ein **neues** Objekt erzeugt wird. + +## \faIcon{hands-helping} / \faIcon{chalkboard} Arbeitsauftrag: Felder \hfill{} 3/5 + +### Diskutiert folgende Aussage: + +\vspace{1cm} +> Im folgenden Klassendiagramm erbt die Klasse `Person` von der Klasse `Lebewesen` und die Klasse `Gruppe` erbt von der Klasse `Person`. + +\begin{center} +\begin{tikzpicture} +\begin{class}[text width=3cm]{Lebewesen}{0, 3} +\attribute{alter} +\operation{bewegen()} +\end{class} + +\begin{class}[text width=3cm]{Person}{0, 0} +\attribute{name} +\inherit{Lebewesen} +\end{class} + +\begin{class}[text width=3cm]{Gruppe}{6, 0} +\attribute{mitglieder} +\end{class} + +\association{Person}{}{0..n}{Gruppe}{2..*}{}; +\end{tikzpicture} +\end{center} + +## \faIcon{hands-helping} / \faIcon{chalkboard} Arbeitsauftrag: Code verstehen \hfill{} 4/5 + +### Diskutiert folgende Aussage: + +::: {.columns} +:::: {.column width=45%} +```java +int[] zahlen = {3, 6, 2, 7, 1}; +for (int i = zahlen.length - 1; i > 1; i--) { + println(zahlen[i]); +} + +``` +:::: + +:::: {.column width=55%} +\vspace{2.5cm} +> Der Code gibt [alle]{.underline} Einträge des Arrays `zahlen` absteigend sortiert aus. +:::: +::: + +## \faIcon{hands-helping} / \faIcon{chalkboard} Arbeitsauftrag: Vererbung \hfill{} 5/5 + +### Diskutiert folgende Aussage: + +::: {.columns} +:::: {.column width=45%} +```java +class A { + int a; + A() { a = 42; } + void gibAus() { + println(a); + } +} +``` +:::: + +:::: {.column width=55%} +```java +class B extends A { + B(int b) { + super(b); + gibAus(); + } +} +``` +:::: +::: + +\vspace{1cm} +> Dieser Code ist ein korrektes Java Programm! + + +## Worum gehts heute? + +\begin{center} +\begin{tikzpicture} +\only<1> { + \node[rotate=-2] {\Huge{Grafen}}; +} +\only<2,3>{ + \node[rotate=3] at (0, 0) {\includegraphics[keepaspectratio, width=6cm]{img/vlad_tepes_002.jpg}}; +} +\only<4> { \node[rotate=-1] {\Huge{Graph\underline{en}}}; +} +\only<5,6> { + \node[rotate=-2] {\includegraphics[keepaspectratio, width=8cm]{img/graphen.jpg}}; +} +\only<3, 6> { + \draw[red, line width=2pt] (-3.5, -3.5) -- (3.5, 3.5) (3.5, -3.5) -- (-3.5, 3.5); +} +\end{tikzpicture} +\end{center} + +## + +{.center} + +## + +\begin{center} +\begin{tikzpicture}[edge/.style = {}, path/.style={}, cycle/.style={}, blocked/.style={}] +\node[draw, thick] at (0, 0) {\includegraphics[keepaspectratio=FALSE, height=8cm, width=4.5cm]{img/Copyrighted/navi.png}}; +\node[draw, thick] at (4.75, 0) {\includegraphics[keepaspectratio=FALSE, height=8cm, width=4.5cm]{img/Copyrighted/route.png}}; +\node[draw, thick] at (9.5, 0) {\includegraphics[keepaspectratio=FALSE, height=8cm, width=4.5cm]{img/Copyrighted/graph.png}}; +%\node[draw, thick] at (9.5, 0) {\resizebox{4.5cm}{8cm}{\input{graph.tikz}}}; +\end{tikzpicture} +\end{center} + +## \faIcon{pencil-alt} Graphen + +\pause +Ein \boldred{Graph} besteht aus einer endlichen Menge von \boldred{Knoten V} (engl. vertices) und einer endlichen Menge von \boldred{Kanten E} (engl. edges). + +\pause + +\vspace{0.5cm} +Jede Kante verbindet **genau zwei** \boldred{Knoten}, die man auch als \boldred{Nachbarknoten} bezeichnet. + +## Beispiele {.standout} + +Was lässt sich als Graph darstellen? + +## \faIcon{pencil-alt} Beispiel + +\begin{tikzpicture}[edge/.style = {}, path/.style={}, cycle/.style={}, blocked/.style={}] +\node[align=center] at (10, 5) {\begin{tabular}{r l} \textbf{V} = & \{Nürnberg, \\ & Feucht, \\ & Wendelstein, \\ & ..., München\} \end{tabular}}; +\node at (5, 4) {\resizebox{!}{7cm}{\input{graph.tikz}}}; +\node[align=center] at (0, 2) {\begin{tabular}{r l} \textbf{E} = & \{Nürnberg- \\ &Wendelstein, \\ & Nürnberg- \\ & Feucht, ... \} \end{tabular}}; +\end{tikzpicture} + +## Wege durch Graphen + +::: {.columns align=center} +:::: {.column width=50%} +Manchmal gibt es nur in eine Richtung einen Radweg und das Fahren in der Gegenrichtung wäre zu gefährlich. + +\vspace{0.5cm} +Beschreibe wie sich diese Gegebenheit mithilfe des Graphen darstellen ließe. + +\vspace{0.5cm} +\only<1>{ + {\Large \phantom{$\Rightarrow$ Graph mit \boldred{gerichteten} Kanten}} +} +\only<2>{ + {\Large $\Rightarrow$ Graph mit \boldred{gerichteten} Kanten} +} +:::: + +:::: {.column width=50%} + +\resizebox{\textwidth}{!}{ + \tikzstyle{path} = [] + \tikzstyle{cycle} = [] + \tikzstyle{blocked} = [] +\only<1> { + \tikzstyle{edge} = [] + \input{graph.tikz} +} +\only<2> { + \tikzstyle{edge} = [-Latex] + \input{graph.tikz} +} +} + +:::: +::: + +## Wege durch Graphen +::: {.columns align=center} +:::: {.column width=50%} +Aufgrund von unterschiedlichen Distanzen zwischen zwei Orten und Steigungen/Gefällen benötigt ein Radfahrer unterschiedlich lange für die verschiedenen Fahrten zwischen zwei Orten. + +\vspace{0.5cm} +Beschreibe wie sich diese Gegebenheit mithilfe des Graphen darstellen ließe. + +\vspace{0.5cm} +\only<1>{ + {\Large \phantom{$\Rightarrow$ \boldred{Kantengewichte}}} +} +\only<2>{ + {\Large $\Rightarrow$ \boldred{Kantengewichte}} +} +:::: + +:::: {.column width=50%} + +\resizebox{\textwidth}{!}{ +\only<1> { + \tikzstyle{blocked} = [] + \tikzstyle{path} = [] + \tikzstyle{cycle} = [] + \tikzstyle{edge} = [-Latex] + \input{graph.tikz} +} +\only<2> { + \input{weighted_graph.tikz} +} +} + +:::: +::: + +## \faIcon{pencil-alt} Kanten von Graphen + +Die Kanten eines Graphen können ... + +* \boldred{gerichtet} oder \boldred{ungerichtet} sein. +* eine \boldred{Gewichtung} haben oder nicht. + +\pause +\vspace{0.2cm} +{.center} + +<!-- ::: {.columns} --> +<!-- :::: {.column width=33%} --> +<!-- \begin{center} --> +<!-- \textbf{ungerichtet} --> + +<!-- \begin{tikzpicture}[vert/.style={draw, circle}] --> +<!-- \node[vert] (a) {A}; --> +<!-- \node[vert, below left=of a] (b) {B}; --> +<!-- \draw (a) -- (b); --> +<!-- \node[vert, right=of b] (c) {C}; --> +<!-- \draw (a) -- (c); --> +<!-- \node[vert, right=of c] (d) {D}; --> +<!-- \draw (a) -- (d); --> +<!-- \node[vert, below=of c] (e) {E}; --> +<!-- \draw (c) -- (e); --> +<!-- \node[vert, below=of d] (f) {F}; --> +<!-- \draw (d) -- (f); --> +<!-- \end{tikzpicture} --> +<!-- \end{center} --> +<!-- :::: --> + +<!-- :::: {.column width=33%} --> +<!-- **gerichtet** --> +<!-- ```{.graphviz} --> +<!-- digraph { --> + <!-- bgcolor=transparent --> + <!-- size=5 --> + <!-- A -> B --> + <!-- A -> C --> + <!-- A -> D --> + <!-- C -> E --> + <!-- E -> C --> + <!-- D -> F --> + <!-- F -> D --> +<!-- } --> +<!-- ``` --> +<!-- :::: --> + +<!-- :::: {.column width=33%} --> +<!-- **gewichtet** --> +<!-- ```{.graphviz} --> +<!-- graph { --> + <!-- bgcolor=transparent --> + <!-- size=5 --> + <!-- A -- B [label=10, len=1] --> + <!-- A -- C [label=15, len=1] --> + <!-- A -- D [label=20, len=1] --> + <!-- C -- E [label=30, len=1] --> + <!-- D -- F [label=20, len=1] --> +<!-- } --> +<!-- ``` --> +<!-- :::: --> +<!-- ::: --> + +## Wege durch Graphen + +::: {.columns align=center} +:::: {.column width=50%} +Ein \boldred{Pfad (bzw. Weg)} ist eine Folge von Knoten, wobei aufeinanderfolgende Knoten +durch eine Kante miteinander verbunden sind. +:::: + +:::: {.column width=50%} + +\resizebox{\textwidth}{!}{ + \tikzstyle{edge} = [] + \tikzstyle{path} = [draw=blue, thick] + \tikzstyle{cycle} = [] + \tikzstyle{blocked} = [] + \input{graph.tikz} +} +:::: +::: + +## Wege durch Graphen + +Als \boldred{Länge} eines Pfades bezeichnet man bei ... + +* \boldred{ungewichteten} Graphen die Anzahl der durchlaufenden Kanten +* \boldred{gewichteten} Graphen die Summe der Kantengewichte der durchlaufenden Kanten + +## Beispiele + +::: {.columns} +:::: {.column width=55%} +Gib die Länge folgender Pfade an: + +\begin{tcolorbox}[enhanced,title=1, + attach boxed title to top left={yshift=-\tcboxedtitleheight/2}, + boxed title style={size=small,colback=blue}] +Wendelstein - Postbauer-Heng - \\ Beilngries - Ingolstadt - Greding +\end{tcolorbox} + +\begin{tcolorbox}[enhanced,title=2, + attach boxed title to top left={yshift=-\tcboxedtitleheight/2}, + boxed title style={size=small,colback=blue}] +Feucht - Neumark i. d. O. - Beilngries~- Kelheim - München - Ingolstadt - Greding +\end{tcolorbox} +:::: + +:::: {.column width=45%} +\resizebox{\textwidth}{!}{ + \tikzstyle{edge} = [] + \tikzstyle{path} = [] + \tikzstyle{cycle} = [] + \tikzstyle{blocked} = [] + \input{graph.tikz} +} +:::: +::: + +## Beispiele + +::: {.columns} +:::: {.column width=55%} +Gib die Länge folgender Pfade an: + +\begin{tcolorbox}[enhanced,title=1, + attach boxed title to top left={yshift=-\tcboxedtitleheight/2}, + boxed title style={size=small,colback=blue}] +Nürnberg – Wendelstein – Schwanstetten +\end{tcolorbox} + +\begin{tcolorbox}[enhanced,title=2, + attach boxed title to top left={yshift=-\tcboxedtitleheight/2}, + boxed title style={size=small,colback=blue}] +Nürnberg – Wendelstein – \\ Feucht – Nürnberg +\end{tcolorbox} + +:::: + +:::: {.column width=45%} +\resizebox{\textwidth}{!}{ + \input{weighted_graph.tikz} +} +:::: +::: + +## Wege durch Graphen + +::: {.columns align=center} +:::: {.column width=50%} +Ein \boldred{Zyklus (bzw. Kreis)} ist ein einfacher Pfad, bei dem Start- und Zielknoten identisch sind. +:::: + +:::: {.column width=50%} + +\resizebox{\textwidth}{!}{ + \tikzstyle{edge} = [] + \tikzstyle{path} = [] + \tikzstyle{cycle} = [draw=orange, thick] + \tikzstyle{blocked} = [] + \input{graph.tikz} +} +:::: +::: + +## Wege durch Graphen + +::: {.columns align=center} +:::: {.column width=50%} +Marie hat sich für das Wochenende vorgenommen von Nürnberg nach Kelheim zu radeln. +Am Morgen liest sie jedoch, dass es mehrere Baumaßnahmen gibt: + +* Schwanstetten – Greding +* Postbauer-Heng – Beilngries +* Neumarkt i. d. Oberpfalz – Beilngries + +sind gesperrt. + +Gib an, ob sie ihr Vorhaben dennoch umsetzen kann. + +\vspace{0.5cm} +\only<1>{ + {\Huge \phantom{$\Rightarrow$ Nein!}} +} +\only<2>{ + {\Huge $\Rightarrow$ Nein!} +} +:::: + +:::: {.column width=50%} +\resizebox{\textwidth}{!}{ + \tikzstyle{edge} = [] + \tikzstyle{path} = [] + \tikzstyle{cycle} = [] + \only<1> { + \tikzstyle{blocked} = [] + \input{graph.tikz} + } + \only<2> { + \tikzstyle{blocked} = [red, dashed, thick] + \input{graph.tikz} + } +} +:::: +::: + +## \faIcon{pencil-alt} Grundbegriffe und Definitionen + +Ein Graph heißt ... + +* \boldred{zusammenhängend}, wenn von jedem Knoten zu jedem anderen Knoten mindestens ein Pfad existiert. + +{.center width=70%} + +## \faIcon{hands-helping} Grundbegriffe und Definitionen + +Fünf Freunde treffen sich auf einer Party und jeder schüttelt jedem die Hand. + +Stellen Sie die beschriebene Situation in einem Graphen dar und geben Sie an, wie viele Händeschüttler es gibt. + +\pause + +\begin{center} +\begin{tikzpicture}[vert/.style={fill=black, circle, inner sep=0pt, minimum size=0.2cm}] +\node[vert] (a) {}; +\node[vert, below left = 0.7cm and 0.7cm of a] (b) {}; +\node[vert, below right = 0.7cm and 0.7cm of a] (c) {}; +\node[vert, below right = 0.7cm and 0.3cm of b] (d) {}; +\node[vert, below left = 0.7cm and 0.3cm of c] (e) {}; +\draw (a) -- (b); +\draw (a) -- (c); +\draw (a) -- (d); +\draw (a) -- (e); +\draw (b) -- (c); +\draw (b) -- (d); +\draw (b) -- (e); +\draw (c) -- (d); +\draw (c) -- (e); +\draw (d) -- (e); +\end{tikzpicture} +\end{center} + +## \faIcon{pencil-alt} Grundbegriffe und Definitionen + +Ein Graph heißt ... + +* \boldred{zusammenhängend}, wenn von jedem Knoten zu jedem anderen Knoten mindestens ein Pfad existiert. +* \boldred{vollständig}, wenn je zwei Knoten durch genau eine Kante direkt miteinander verbunden sind. + +## \faIcon{desktop} Big Bad Joe + +[https://www.matheprisma.uni-wuppertal.de/Module/Graphen/index.htm?3](https://www.matheprisma.uni-wuppertal.de/Module/Graphen/index.htm?3) + +## \faIcon{desktop} Was haben wir gelernt? {.standout} + +\Huge QUIZ diff --git a/Info/11/NTG/1/Intro/weighted_graph.tex b/Info/11/NTG/1/Intro/weighted_graph.tex new file mode 100644 index 00000000..5dfa36e7 --- /dev/null +++ b/Info/11/NTG/1/Intro/weighted_graph.tex @@ -0,0 +1,6 @@ +\documentclass{standalone} +\usepackage{tikz} +\usetikzlibrary{positioning, arrows.meta} +\begin{document} +\input{weighted_graph.tikz} +\end{document} diff --git a/Info/11/NTG/1/Intro/weighted_graph.tikz b/Info/11/NTG/1/Intro/weighted_graph.tikz new file mode 100644 index 00000000..68550ab7 --- /dev/null +++ b/Info/11/NTG/1/Intro/weighted_graph.tikz @@ -0,0 +1,30 @@ +\begin{tikzpicture}[node/.style={rounded corners=2pt, draw}, edge/.style={-Latex}] +\node[node] (nuernberg) {Nürnberg}; +\node[node, below right=0.5cm of nuernberg] (feucht) {Feucht}; +\node[node, below left=0.7cm and -0.3cm of nuernberg] (wendelstein) {Wendelstein}; +\draw[edge] (nuernberg) edge node[left, midway] {20} (wendelstein); +\draw[edge] (nuernberg) edge node[right, midway] {30} (feucht); +\draw[edge] (wendelstein) edge node[above] {15} (feucht); +\node[node, below left=0.4 and -0.4cm of wendelstein] (schwanstein) {Schwanstein}; +\draw[edge] (wendelstein) edge node[left, midway] {5} (schwanstein); +\node[node, below right=0.1cm and 0.6cm of schwanstein] (postbauerHeng) {Postbauer Heng}; +\draw[edge] (wendelstein) edge node[right, midway] {20} (postbauerHeng); +\draw[edge] (feucht) edge node[right] {25} (postbauerHeng); +\node[node, align=center, below right=-0.3cm and 0.6cm of postbauerHeng] (neumarkt) {Neumarkt i. d. \\ Oberpfalz}; +\draw[edge] (wendelstein) edge node[above, midway] {40} (neumarkt); +\draw[edge] (feucht) edge node[right, midway] {20} (neumarkt); +\draw[edge] (postbauerHeng) edge node[below] {5} (neumarkt); +\node[node, below=1.5cm of schwanstein] (creding) {Creding}; +\draw[edge] (schwanstein) edge node[right, midway] {45} (creding); +\node[node, below right=1 and -1.5cm of postbauerHeng] (beilngries) {Beilngries}; +\draw[edge] (postbauerHeng) edge node[left, midway] {35} (beilngries); +\draw[edge] (neumarkt) edge node[below] {25} (beilngries); +\node[node, below left=of beilngries] (ingolstadt) {Ingolstadt}; +\draw[edge] (beilngries) edge node[left, midway] {45} (ingolstadt); +\draw[edge] (creding) edge node[right, midway] {30} (ingolstadt); +\node[node, below right=of beilngries] (kelheim) {Kelheim}; +\draw[edge] (beilngries) edge node[right, midway] {25} (kelheim); +\node[node, below right=of ingolstadt] (muenchen) {München}; +\draw[edge] (kelheim) edge node[right, midway] {55} (muenchen); +\draw[edge] (ingolstadt) edge node[right, midway] {45} (muenchen); +\end{tikzpicture} diff --git a/Info/24_25/09/23/11C/schedule.md b/Info/24_25/09/23/11C/schedule.md new file mode 100644 index 00000000..05ec690f --- /dev/null +++ b/Info/24_25/09/23/11C/schedule.md @@ -0,0 +1,38 @@ +--- +lang: de +geometry: margin=2cm +--- +# Graphen + +* **Klasse**: 11C +* **Datum**: 23.09 + +## Lernziele + +## Verlaufplan + +--------------------------------------------------------------------------------------------------- +Zeit Phase Unterrichtsgeschehen Ziel Methode Medien +----- --------------- -------------------------------------------- ----------- ---------- --------- +5 Orga Strom/Sicherungen, Kommunikation LV + +10 Wdh SuS diskutieren Aussagen PA/UG + +5 Erarbeitung SuS stellen vernetze Informationen PA + graphisch dar + +10 Sicherung Definition von Graphen UG AB + gewichtet / gerichtet + +5 Sicherung Mathematische Notation UG AB + +5 Erarbeitung Zusammenhängend PA AB + +5 Erarbeitung Vollständig PA AB + +30 Übung SuS üben eigenständig [1] PA + +10 Übung Graphen Quiz EA/UG +--------------------------------------------------------------------------------------------------- + +[1]: http://www.matheprisma.uni-wuppertal.de/Module/Graphen/index.htm?3 diff --git a/Info/24_25/09/23/11C/topic b/Info/24_25/09/23/11C/topic new file mode 120000 index 00000000..a8b8febc --- /dev/null +++ b/Info/24_25/09/23/11C/topic @@ -0,0 +1 @@ +../../../../11/NTG/Graphen/Intro/
\ No newline at end of file |
