summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/tkz/tkz-graph/doc/latex/TKZdoc-gr-Welsh.tex
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2021-01-22 03:00:46 +0000
committerNorbert Preining <norbert@preining.info>2021-01-22 03:00:46 +0000
commite1a7798f45cd37c0aa0bfaaef5f0acb4e48bc867 (patch)
treed2bbebcdb7bcb8fe013a9d3cbd2cff880b18afbf /macros/latex/contrib/tkz/tkz-graph/doc/latex/TKZdoc-gr-Welsh.tex
parent37cb9bbabbfe1a8d0d1334832814ccbefcf9ac0a (diff)
CTAN sync 202101220300
Diffstat (limited to 'macros/latex/contrib/tkz/tkz-graph/doc/latex/TKZdoc-gr-Welsh.tex')
-rw-r--r--macros/latex/contrib/tkz/tkz-graph/doc/latex/TKZdoc-gr-Welsh.tex246
1 files changed, 246 insertions, 0 deletions
diff --git a/macros/latex/contrib/tkz/tkz-graph/doc/latex/TKZdoc-gr-Welsh.tex b/macros/latex/contrib/tkz/tkz-graph/doc/latex/TKZdoc-gr-Welsh.tex
new file mode 100644
index 0000000000..842b22c8b1
--- /dev/null
+++ b/macros/latex/contrib/tkz/tkz-graph/doc/latex/TKZdoc-gr-Welsh.tex
@@ -0,0 +1,246 @@
+\section{Colorisation Welsh}
+%<–––––––––––––––––––––––––– graphs with colors ––––––––––––––––––––––––––—––>
+Ce chapitre montre comment colorer des sommets. Le plus simple est d'utiliser le style \tkzname{Welsh} et la macro \tkzcname{AddVertexColor} afin de colorer les sommets.
+
+\subsection{La macro \tkzcname{AddVertexColor} }
+
+\begin{NewMacroBox}{AddVertexColor}{\var{color}\var{List of vertices}}
+
+\medskip
+\emph{Cette macro permet de colorer des sommets. Le premier argument est la couleur, le second une liste de sommets.}
+\end{NewMacroBox}
+
+\subsection{Exemple d'utilisation }
+
+\medskip
+Une compagnie aérienne propose des vols directs entre certaines villes, notées A, B, C, D, E, F et G. Cela conduit au graphe $\mathcal{G}$ suivant, dont les sommets sont les villes et les arêtes représentent les liaisons aériennes :
+
+ \begin{center}
+\begin{tikzpicture}
+\renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A) \Edges(B,E)
+\end{tikzpicture}
+\end{center}
+
+\begin{enumerate}
+
+\item Sur les cartes d'embarquement, la compagnie attribue à chaque aéroport une couleur, de sorte que deux aéroports liés par un vol direct aient des couleurs différentes.
+
+ Proposer un coloriage adapté‚ cette condition.
+\item Que peut-on en déduire sur le nombre chromatique de $\mathcal{G}$ ?
+\end{enumerate}
+
+
+
+\begin{center}
+\begin{tkzltxexample}[]
+\begin{tikzpicture}
+\renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A) \Edges(B,E)
+\end{tikzpicture}
+\end{tkzltxexample}
+\end{center}
+
+\bigskip
+\begin{minipage}{7cm}
+ \begin{tikzpicture}
+\renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A) \Edges(B,E)
+ \end{tikzpicture}
+\end{minipage}
+\hfill
+\begin{minipage}{7cm}
+ \begin{tabular}{cc}
+ \hline
+ \itshape Sommet & \itshape Degré \\
+ \hline
+ B & $5$ \\
+ E & $5$ \\
+ C & $4$ \\
+ D & $4$ \\
+ A & $3$ \\
+ G & $3$ \\
+ F & $2$ \\
+ \hline
+ \end{tabular}
+\end{minipage}
+
+\begin{tkzltxexample}[]
+ \begin{tikzpicture}
+\renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A) \Edges(B,E)
+\end{tikzpicture}
+\end{tkzltxexample}
+
+\bigskip
+\begin{minipage}{7cm}
+ \begin{tikzpicture}
+ \renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \SetVertexNoLabel
+ \AddVertexColor{red}{B,F}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A) \Edges(B,E)
+\end{tikzpicture}
+\end{minipage}
+\hfill
+\begin{minipage}{7cm}
+\begin{tabular}{ccc}
+\hline
+\itshape Sommet & \itshape Degré & \itshape Couleur\\
+\hline
+B & $5$ & rouge\\
+E & $5$ & \\
+C & $4$ & \\
+D & $4$ & \\
+A & $3$ & \\
+G & $3$ & \\
+F & $2$ & rouge\\
+\hline
+\end{tabular}
+\end{minipage}
+
+\begin{tkzltxexample}[]
+\begin{tikzpicture}
+ \renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \SetVertexNoLabel
+ \AddVertexColor{red}{B,F}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A) \Edges(B,E)
+\end{tikzpicture}
+\end{tkzltxexample}
+
+\bigskip
+\begin{minipage}{7cm}
+ \begin{tikzpicture}
+ \renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \SetVertexNoLabel
+ \AddVertexColor{red}{B,F} \AddVertexColor{blue}{E,A}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A) \Edges(B,E)
+\end{tikzpicture}
+\end{minipage}
+\hfill
+\begin{minipage}{7cm}
+\begin{tabular}{ccc}
+\hline
+\itshape Sommet & \itshape Degré & \itshape Couleur\\
+\hline
+B & $5$ & rouge\\
+E & $5$ & bleu\\
+C & $4$ & \\
+D & $4$ & \\
+A & $3$ & bleu\\
+G & $3$ & \\
+F & $2$ & rouge\\
+\hline
+\end{tabular}
+\end{minipage}
+
+\begin{tkzltxexample}[]
+\begin{tikzpicture}
+ \renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \SetVertexNoLabel
+ \AddVertexColor{red}{B,F}
+ \AddVertexColor{blue}{E,A}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A)
+ \Edges(B,E)
+\end{tikzpicture}
+\end{tkzltxexample}
+
+\bigskip
+\begin{minipage}{7cm}
+\begin{tikzpicture}
+ \renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \SetVertexNoLabel
+ \AddVertexColor{red}{B,F} \AddVertexColor{blue}{E,A}
+ \AddVertexColor{green}{C,G}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A) \Edges(B,E)
+\end{tikzpicture}
+\end{minipage}
+\hfill
+\begin{minipage}{7cm}
+\begin{tabular}{ccc}
+\hline
+\itshape Sommet & \itshape Degré & \itshape Couleur\\
+\hline
+B & $5$ & rouge\\
+E & $5$ & bleu\\
+C & $4$ & vert\\
+D & $4$ & \\
+A & $3$ & bleu\\
+G & $3$ & vert\\
+F & $2$ & rouge\\
+\hline
+\end{tabular}
+\end{minipage}
+
+\begin{tkzltxexample}[]
+\begin{tikzpicture}
+ \renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \SetVertexNoLabel
+ \AddVertexColor{red}{B,F} \AddVertexColor{blue}{E,A}
+ \AddVertexColor{green}{C,G}
+ \Vertex[Node]{D}}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A) \Edges(B,E)
+\end{tikzpicture}
+\end{tkzltxexample}
+
+\bigskip
+\begin{minipage}{7cm}
+\begin{tikzpicture}
+ \renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \SetVertexNoLabel
+ \AddVertexColor{red}{B,F} \AddVertexColor{blue}{E,A}
+ \AddVertexColor{green}{C,G} \AddVertexColor{yellow}{D}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A) \Edges(B,E)
+\end{tikzpicture}
+\end{minipage}
+\hfill
+\begin{minipage}{7cm}
+\begin{tabular}{ccc}
+\hline
+\itshape Sommet & \itshape Degré & \itshape Couleur\\
+\hline
+B & $5$ & rouge\\
+E & $5$ & bleu\\
+C & $4$ & vert\\
+D & $4$ & jaune\\
+A & $3$ & bleu\\
+G & $3$ & vert\\
+F & $2$ & rouge\\
+\hline
+\end{tabular}
+\end{minipage}
+
+\begin{tkzltxexample}[]
+ \begin{tikzpicture}
+ \renewcommand*{\VertexLineWidth}{2pt}
+ \GraphInit[vstyle=Welsh]
+ \Vertices[unit=3]{circle}{A,B,C,D,E,F,G}
+ \SetVertexNoLabel
+ \AddVertexColor{red}{B,F} \AddVertexColor{blue}{E,A}
+ \AddVertexColor{green}{C,G}\AddVertexColor{yellow}{D}
+ \Vertex[Node]{D}}
+ \Edges(G,E,F,G,B,D,E,C,D,A,C,B,A)\Edges(B,E)
+\end{tikzpicture}
+\end{tkzltxexample}
+\endinput \ No newline at end of file