diff --git a/build/stackchess32.exe b/build/stackchess32.exe
index 60b62a698ea14797dc363fee6fb5218df87ccffe..0c4484d2d709c1396059b9f3e9f815ba016ae3e9 100755
Binary files a/build/stackchess32.exe and b/build/stackchess32.exe differ
diff --git a/build/stackchess64.exe b/build/stackchess64.exe
index 8466206bc136277aa921a16a3ed92ae01f711ca5..b3f045d8e29ff4922633a4b7e1e417a2c6d17a1e 100755
Binary files a/build/stackchess64.exe and b/build/stackchess64.exe differ
diff --git a/doc/latex/_minted-rapport/976EF00D3AD9EFC6C12A065CC4510545C0F72903C94FBF5C8260FB7B691971A4.pygtex b/doc/latex/_minted-rapport/976EF00D3AD9EFC6C12A065CC4510545C0F72903C94FBF5C8260FB7B691971A4.pygtex
new file mode 100644
index 0000000000000000000000000000000000000000..2d763c0294a2d9e8ca07ec75dd215eda227996f9
--- /dev/null
+++ b/doc/latex/_minted-rapport/976EF00D3AD9EFC6C12A065CC4510545C0F72903C94FBF5C8260FB7B691971A4.pygtex
@@ -0,0 +1,14 @@
+\begin{Verbatim}[commandchars=\\\{\}]
+\PYG{c+c1}{//si on a une pièce noire sur une case noire :}
+\PYG{n}{printf}\PYG{p}{(}\PYG{n}{PNOIRE} \PYG{n}{NOIR} \PYG{l+s}{\PYGZdq{}\PYGZpc{}c \PYGZdq{}} \PYG{n}{RESET}\PYG{p}{,} \PYG{o}{*}\PYG{n}{sommet}\PYG{p}{(}\PYG{n}{tableau}\PYG{p}{[}\PYG{n}{i}\PYG{p}{][}\PYG{n}{j}\PYG{p}{]));}
+\PYG{c+c1}{//si on a une pièce blanche sur une case noire :}
+\PYG{n}{printf}\PYG{p}{(}\PYG{n}{PBLANCHE} \PYG{n}{NOIR}\PYG{l+s}{\PYGZdq{}\PYGZpc{}c \PYGZdq{}} \PYG{n}{RESET}\PYG{p}{,} \PYG{o}{*}\PYG{n}{sommet}\PYG{p}{(}\PYG{n}{tableau}\PYG{p}{[}\PYG{n}{i}\PYG{p}{][}\PYG{n}{j}\PYG{p}{]));}
+\PYG{c+c1}{//si on a une pièce noire sur une case blanche :}
+\PYG{n}{printf}\PYG{p}{(}\PYG{n}{PNOIRE} \PYG{n}{BLANC}\PYG{l+s}{\PYGZdq{}\PYGZpc{}c \PYGZdq{}} \PYG{n}{RESET}\PYG{p}{,} \PYG{o}{*}\PYG{n}{sommet}\PYG{p}{(}\PYG{n}{tableau}\PYG{p}{[}\PYG{n}{i}\PYG{p}{][}\PYG{n}{j}\PYG{p}{]));}
+\PYG{c+c1}{//si on a une pièce blanche sur une case blanche :}
+\PYG{n}{printf}\PYG{p}{(}\PYG{n}{PBLANCHE} \PYG{n}{BLANC}\PYG{l+s}{\PYGZdq{}\PYGZpc{}c \PYGZdq{}} \PYG{n}{RESET}\PYG{p}{,} \PYG{o}{*}\PYG{n}{sommet}\PYG{p}{(}\PYG{n}{tableau}\PYG{p}{[}\PYG{n}{i}\PYG{p}{][}\PYG{n}{j}\PYG{p}{]));}
+\PYG{c+c1}{//si on a une case blanche vide :}
+\PYG{n}{printf}\PYG{p}{(}\PYG{n}{BLANC} \PYG{l+s}{\PYGZdq{}  \PYGZdq{}} \PYG{n}{RESET}\PYG{p}{);}
+\PYG{c+c1}{//si on a une case noire vide :}
+\PYG{n}{printf}\PYG{p}{(}\PYG{n}{NOIR} \PYG{l+s}{\PYGZdq{}  \PYGZdq{}} \PYG{n}{RESET}\PYG{p}{);}
+\end{Verbatim}
diff --git a/doc/latex/_minted-rapport/C838B08CC24C4ADFA5937B04B1BA328DD8CA68773B7D6D064ED4DFDE91CAC7DA.pygtex b/doc/latex/_minted-rapport/C838B08CC24C4ADFA5937B04B1BA328DD8CA68773B7D6D064ED4DFDE91CAC7DA.pygtex
new file mode 100644
index 0000000000000000000000000000000000000000..df04919f07193158437275ec3df98b158a82a72f
--- /dev/null
+++ b/doc/latex/_minted-rapport/C838B08CC24C4ADFA5937B04B1BA328DD8CA68773B7D6D064ED4DFDE91CAC7DA.pygtex
@@ -0,0 +1,4 @@
+\begin{Verbatim}[commandchars=\\\{\}]
+\PYG{k}{typedef} \PYG{k}{struct} \PYG{n}{\PYGZus{}noeud} \PYG{o}{*} \PYG{n}{pile}\PYG{p}{;}
+\PYG{k}{struct} \PYG{n}{\PYGZus{}noeud}\PYG{p}{\PYGZob{}}\PYG{k+kt}{char} \PYG{o}{*}\PYG{n}{chaine}\PYG{p}{;}\PYG{n}{pile} \PYG{n}{next}\PYG{p}{;\PYGZcb{};}
+\end{Verbatim}
diff --git a/doc/latex/_minted-rapport/F19BC22B1642EBBBD81E44080E03002ED8CA68773B7D6D064ED4DFDE91CAC7DA.pygtex b/doc/latex/_minted-rapport/F19BC22B1642EBBBD81E44080E03002ED8CA68773B7D6D064ED4DFDE91CAC7DA.pygtex
new file mode 100644
index 0000000000000000000000000000000000000000..62cdae5aed8162265c035c627c28d2f5f4ccd0ee
--- /dev/null
+++ b/doc/latex/_minted-rapport/F19BC22B1642EBBBD81E44080E03002ED8CA68773B7D6D064ED4DFDE91CAC7DA.pygtex
@@ -0,0 +1,8 @@
+\begin{Verbatim}[commandchars=\\\{\}]
+\PYG{c+cp}{\PYGZsh{}define clrscr() printf(\PYGZdq{}\PYGZbs{}033[H\PYGZbs{}033[2J\PYGZdq{}) }\PYG{c+c1}{//rafraichi l\PYGZsq{}écran}
+\PYG{c+cp}{\PYGZsh{}define NOIR   \PYGZdq{}\PYGZbs{}x1B[48;2;0;0;0m\PYGZdq{}}\PYG{c+c1}{//colore le fond d\PYGZsq{}une case en noir}
+\PYG{c+cp}{\PYGZsh{}define PBLANCHE \PYGZdq{}\PYGZbs{}x1B[1;32m\PYGZdq{}}\PYG{c+c1}{//colore les charactères en gris}
+\PYG{c+cp}{\PYGZsh{}define PNOIRE \PYGZdq{}\PYGZbs{}x1B[1;31m\PYGZdq{} }\PYG{c+c1}{//colore les charactères en rouge}
+\PYG{c+cp}{\PYGZsh{}define BLANC   \PYGZdq{}\PYGZbs{}x1B[48;2;255;255;255m\PYGZdq{} }\PYG{c+c1}{//colore le fond d\PYGZsq{}une case en blanc}
+\PYG{c+cp}{\PYGZsh{}define RESET \PYGZdq{}\PYGZbs{}x1B[0m\PYGZdq{} }\PYG{c+c1}{//remet l\PYGZsq{}affichage par défaut du terminal}
+\end{Verbatim}
diff --git a/doc/latex/_minted-rapport/F1E7ACEB0A2BECBF7FBC94D6CB49EAC6D8CA68773B7D6D064ED4DFDE91CAC7DA.pygtex b/doc/latex/_minted-rapport/F1E7ACEB0A2BECBF7FBC94D6CB49EAC6D8CA68773B7D6D064ED4DFDE91CAC7DA.pygtex
new file mode 100644
index 0000000000000000000000000000000000000000..f303f0e2fff9a692dcd8c4b9ad2389b776ac2be3
--- /dev/null
+++ b/doc/latex/_minted-rapport/F1E7ACEB0A2BECBF7FBC94D6CB49EAC6D8CA68773B7D6D064ED4DFDE91CAC7DA.pygtex
@@ -0,0 +1,14 @@
+\begin{Verbatim}[commandchars=\\\{\}]
+\PYG{n}{pile} \PYG{o}{**}\PYG{n+nf}{initialisation}\PYG{p}{(}\PYG{k+kt}{int} \PYG{n}{N}\PYG{p}{)}
+\PYG{p}{\PYGZob{}}
+	\PYG{k+kt}{int} \PYG{n}{i}\PYG{p}{,}\PYG{n}{j}\PYG{p}{;}
+	\PYG{n}{pile} \PYG{o}{**} \PYG{n}{tableau}\PYG{p}{;}
+	\PYG{n}{tableau} \PYG{o}{=} \PYG{p}{(}\PYG{n}{pile}\PYG{o}{**}\PYG{p}{)} \PYG{n}{malloc}\PYG{p}{(}\PYG{n}{N}\PYG{o}{*}\PYG{k}{sizeof}\PYG{p}{(}\PYG{n}{pile}\PYG{o}{*}\PYG{p}{));}
+	\PYG{k}{for} \PYG{p}{(}\PYG{n}{i}\PYG{o}{=}\PYG{l+m+mi}{0} \PYG{p}{;} \PYG{n}{i}\PYG{o}{\PYGZlt{}}\PYG{n}{N} \PYG{p}{;} \PYG{n}{i}\PYG{o}{++}\PYG{p}{)\PYGZob{}}
+		\PYG{n}{tableau}\PYG{p}{[}\PYG{n}{i}\PYG{p}{]} \PYG{o}{=}\PYG{p}{(}\PYG{n}{pile}\PYG{o}{*}\PYG{p}{)}\PYG{n}{malloc}\PYG{p}{(}\PYG{n}{N}\PYG{o}{*}\PYG{k}{sizeof}\PYG{p}{(}\PYG{n}{pile}\PYG{p}{));}
+		\PYG{k}{for} \PYG{p}{(}\PYG{n}{j}\PYG{o}{=}\PYG{l+m+mi}{0} \PYG{p}{;} \PYG{n}{j}\PYG{o}{\PYGZlt{}}\PYG{n}{N} \PYG{p}{;} \PYG{n}{j}\PYG{o}{++}\PYG{p}{)}
+			\PYG{n}{tableau}\PYG{p}{[}\PYG{n}{i}\PYG{p}{][}\PYG{n}{j}\PYG{p}{]} \PYG{o}{=} \PYG{n+nb}{NULL}\PYG{p}{;}
+	\PYG{p}{\PYGZcb{}}
+	\PYG{k}{return} \PYG{n}{tableau}\PYG{p}{;}
+\PYG{p}{\PYGZcb{}}
+\end{Verbatim}
diff --git a/doc/latex/_minted-rapport/default-pyg-prefix.pygstyle b/doc/latex/_minted-rapport/default-pyg-prefix.pygstyle
new file mode 100644
index 0000000000000000000000000000000000000000..e94b107b1ef34cf22c33f3ec6d78b1dd0d0d20fe
--- /dev/null
+++ b/doc/latex/_minted-rapport/default-pyg-prefix.pygstyle
@@ -0,0 +1,101 @@
+
+\makeatletter
+\def\PYG@reset{\let\PYG@it=\relax \let\PYG@bf=\relax%
+    \let\PYG@ul=\relax \let\PYG@tc=\relax%
+    \let\PYG@bc=\relax \let\PYG@ff=\relax}
+\def\PYG@tok#1{\csname PYG@tok@#1\endcsname}
+\def\PYG@toks#1+{\ifx\relax#1\empty\else%
+    \PYG@tok{#1}\expandafter\PYG@toks\fi}
+\def\PYG@do#1{\PYG@bc{\PYG@tc{\PYG@ul{%
+    \PYG@it{\PYG@bf{\PYG@ff{#1}}}}}}}
+\def\PYG#1#2{\PYG@reset\PYG@toks#1+\relax+\PYG@do{#2}}
+
+\expandafter\def\csname PYG@tok@gd\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.63,0.00,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@gu\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.50,0.00,0.50}{##1}}}
+\expandafter\def\csname PYG@tok@gt\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.27,0.87}{##1}}}
+\expandafter\def\csname PYG@tok@gs\endcsname{\let\PYG@bf=\textbf}
+\expandafter\def\csname PYG@tok@gr\endcsname{\def\PYG@tc##1{\textcolor[rgb]{1.00,0.00,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@cm\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYG@tok@vg\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYG@tok@vi\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYG@tok@vm\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYG@tok@mh\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYG@tok@cs\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYG@tok@ge\endcsname{\let\PYG@it=\textit}
+\expandafter\def\csname PYG@tok@vc\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYG@tok@il\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYG@tok@go\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.53,0.53,0.53}{##1}}}
+\expandafter\def\csname PYG@tok@cp\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.74,0.48,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@gi\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.63,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@gh\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.00,0.50}{##1}}}
+\expandafter\def\csname PYG@tok@ni\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.60,0.60,0.60}{##1}}}
+\expandafter\def\csname PYG@tok@nl\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.63,0.63,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@nn\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.00,1.00}{##1}}}
+\expandafter\def\csname PYG@tok@no\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.53,0.00,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@na\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.49,0.56,0.16}{##1}}}
+\expandafter\def\csname PYG@tok@nb\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@nc\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.00,1.00}{##1}}}
+\expandafter\def\csname PYG@tok@nd\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.67,0.13,1.00}{##1}}}
+\expandafter\def\csname PYG@tok@ne\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.82,0.25,0.23}{##1}}}
+\expandafter\def\csname PYG@tok@nf\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.00,1.00}{##1}}}
+\expandafter\def\csname PYG@tok@si\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.73,0.40,0.53}{##1}}}
+\expandafter\def\csname PYG@tok@s2\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYG@tok@nt\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@nv\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYG@tok@s1\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYG@tok@dl\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYG@tok@ch\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYG@tok@m\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYG@tok@gp\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.00,0.50}{##1}}}
+\expandafter\def\csname PYG@tok@sh\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYG@tok@ow\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.67,0.13,1.00}{##1}}}
+\expandafter\def\csname PYG@tok@sx\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@bp\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@c1\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYG@tok@fm\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.00,1.00}{##1}}}
+\expandafter\def\csname PYG@tok@o\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYG@tok@kc\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@c\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYG@tok@mf\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYG@tok@err\endcsname{\def\PYG@bc##1{\setlength{\fboxsep}{0pt}\fcolorbox[rgb]{1.00,0.00,0.00}{1,1,1}{\strut ##1}}}
+\expandafter\def\csname PYG@tok@mb\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYG@tok@ss\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYG@tok@sr\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.40,0.53}{##1}}}
+\expandafter\def\csname PYG@tok@mo\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYG@tok@kd\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@mi\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYG@tok@kn\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@cpf\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYG@tok@kr\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@s\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYG@tok@kp\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@w\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.73,0.73}{##1}}}
+\expandafter\def\csname PYG@tok@kt\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.69,0.00,0.25}{##1}}}
+\expandafter\def\csname PYG@tok@sc\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYG@tok@sb\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYG@tok@sa\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYG@tok@k\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYG@tok@se\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.73,0.40,0.13}{##1}}}
+\expandafter\def\csname PYG@tok@sd\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+
+\def\PYGZbs{\char`\\}
+\def\PYGZus{\char`\_}
+\def\PYGZob{\char`\{}
+\def\PYGZcb{\char`\}}
+\def\PYGZca{\char`\^}
+\def\PYGZam{\char`\&}
+\def\PYGZlt{\char`\<}
+\def\PYGZgt{\char`\>}
+\def\PYGZsh{\char`\#}
+\def\PYGZpc{\char`\%}
+\def\PYGZdl{\char`\$}
+\def\PYGZhy{\char`\-}
+\def\PYGZsq{\char`\'}
+\def\PYGZdq{\char`\"}
+\def\PYGZti{\char`\~}
+% for compatibility with earlier versions
+\def\PYGZat{@}
+\def\PYGZlb{[}
+\def\PYGZrb{]}
+\makeatother
+
diff --git a/doc/latex/_minted-rapport/default.pygstyle b/doc/latex/_minted-rapport/default.pygstyle
new file mode 100644
index 0000000000000000000000000000000000000000..bf5e83020b2b1af08a42d37539e5f276c37a6f88
--- /dev/null
+++ b/doc/latex/_minted-rapport/default.pygstyle
@@ -0,0 +1,101 @@
+
+\makeatletter
+\def\PYGdefault@reset{\let\PYGdefault@it=\relax \let\PYGdefault@bf=\relax%
+    \let\PYGdefault@ul=\relax \let\PYGdefault@tc=\relax%
+    \let\PYGdefault@bc=\relax \let\PYGdefault@ff=\relax}
+\def\PYGdefault@tok#1{\csname PYGdefault@tok@#1\endcsname}
+\def\PYGdefault@toks#1+{\ifx\relax#1\empty\else%
+    \PYGdefault@tok{#1}\expandafter\PYGdefault@toks\fi}
+\def\PYGdefault@do#1{\PYGdefault@bc{\PYGdefault@tc{\PYGdefault@ul{%
+    \PYGdefault@it{\PYGdefault@bf{\PYGdefault@ff{#1}}}}}}}
+\def\PYGdefault#1#2{\PYGdefault@reset\PYGdefault@toks#1+\relax+\PYGdefault@do{#2}}
+
+\expandafter\def\csname PYGdefault@tok@gd\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.63,0.00,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@gu\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.50,0.00,0.50}{##1}}}
+\expandafter\def\csname PYGdefault@tok@gt\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.27,0.87}{##1}}}
+\expandafter\def\csname PYGdefault@tok@gs\endcsname{\let\PYGdefault@bf=\textbf}
+\expandafter\def\csname PYGdefault@tok@gr\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{1.00,0.00,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@cm\endcsname{\let\PYGdefault@it=\textit\def\PYGdefault@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYGdefault@tok@vg\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYGdefault@tok@vi\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYGdefault@tok@vm\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYGdefault@tok@mh\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYGdefault@tok@cs\endcsname{\let\PYGdefault@it=\textit\def\PYGdefault@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYGdefault@tok@ge\endcsname{\let\PYGdefault@it=\textit}
+\expandafter\def\csname PYGdefault@tok@vc\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYGdefault@tok@il\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYGdefault@tok@go\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.53,0.53,0.53}{##1}}}
+\expandafter\def\csname PYGdefault@tok@cp\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.74,0.48,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@gi\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.63,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@gh\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.00,0.50}{##1}}}
+\expandafter\def\csname PYGdefault@tok@ni\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.60,0.60,0.60}{##1}}}
+\expandafter\def\csname PYGdefault@tok@nl\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.63,0.63,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@nn\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.00,1.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@no\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.53,0.00,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@na\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.49,0.56,0.16}{##1}}}
+\expandafter\def\csname PYGdefault@tok@nb\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@nc\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.00,1.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@nd\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.67,0.13,1.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@ne\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.82,0.25,0.23}{##1}}}
+\expandafter\def\csname PYGdefault@tok@nf\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.00,1.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@si\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.40,0.53}{##1}}}
+\expandafter\def\csname PYGdefault@tok@s2\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYGdefault@tok@nt\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@nv\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYGdefault@tok@s1\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYGdefault@tok@dl\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYGdefault@tok@ch\endcsname{\let\PYGdefault@it=\textit\def\PYGdefault@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYGdefault@tok@m\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYGdefault@tok@gp\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.00,0.50}{##1}}}
+\expandafter\def\csname PYGdefault@tok@sh\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYGdefault@tok@ow\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.67,0.13,1.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@sx\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@bp\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@c1\endcsname{\let\PYGdefault@it=\textit\def\PYGdefault@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYGdefault@tok@fm\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.00,1.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@o\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYGdefault@tok@kc\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@c\endcsname{\let\PYGdefault@it=\textit\def\PYGdefault@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYGdefault@tok@mf\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYGdefault@tok@err\endcsname{\def\PYGdefault@bc##1{\setlength{\fboxsep}{0pt}\fcolorbox[rgb]{1.00,0.00,0.00}{1,1,1}{\strut ##1}}}
+\expandafter\def\csname PYGdefault@tok@mb\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYGdefault@tok@ss\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}}
+\expandafter\def\csname PYGdefault@tok@sr\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.40,0.53}{##1}}}
+\expandafter\def\csname PYGdefault@tok@mo\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYGdefault@tok@kd\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@mi\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
+\expandafter\def\csname PYGdefault@tok@kn\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@cpf\endcsname{\let\PYGdefault@it=\textit\def\PYGdefault@tc##1{\textcolor[rgb]{0.25,0.50,0.50}{##1}}}
+\expandafter\def\csname PYGdefault@tok@kr\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@s\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYGdefault@tok@kp\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@w\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.73,0.73}{##1}}}
+\expandafter\def\csname PYGdefault@tok@kt\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.69,0.00,0.25}{##1}}}
+\expandafter\def\csname PYGdefault@tok@sc\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYGdefault@tok@sb\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYGdefault@tok@sa\endcsname{\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+\expandafter\def\csname PYGdefault@tok@k\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}}
+\expandafter\def\csname PYGdefault@tok@se\endcsname{\let\PYGdefault@bf=\textbf\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.40,0.13}{##1}}}
+\expandafter\def\csname PYGdefault@tok@sd\endcsname{\let\PYGdefault@it=\textit\def\PYGdefault@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}}
+
+\def\PYGdefaultZbs{\char`\\}
+\def\PYGdefaultZus{\char`\_}
+\def\PYGdefaultZob{\char`\{}
+\def\PYGdefaultZcb{\char`\}}
+\def\PYGdefaultZca{\char`\^}
+\def\PYGdefaultZam{\char`\&}
+\def\PYGdefaultZlt{\char`\<}
+\def\PYGdefaultZgt{\char`\>}
+\def\PYGdefaultZsh{\char`\#}
+\def\PYGdefaultZpc{\char`\%}
+\def\PYGdefaultZdl{\char`\$}
+\def\PYGdefaultZhy{\char`\-}
+\def\PYGdefaultZsq{\char`\'}
+\def\PYGdefaultZdq{\char`\"}
+\def\PYGdefaultZti{\char`\~}
+% for compatibility with earlier versions
+\def\PYGdefaultZat{@}
+\def\PYGdefaultZlb{[}
+\def\PYGdefaultZrb{]}
+\makeatother
+
diff --git a/doc/latex/affichage.jpg b/doc/latex/affichage.jpg
new file mode 100644
index 0000000000000000000000000000000000000000..d3d876188980c00aba810a5131909cf4170be91c
Binary files /dev/null and b/doc/latex/affichage.jpg differ
diff --git a/doc/latex/deplacementillegal.jpg b/doc/latex/deplacementillegal.jpg
new file mode 100644
index 0000000000000000000000000000000000000000..2f7370073787d327ac79c99fb61a3388a7ff1b4f
Binary files /dev/null and b/doc/latex/deplacementillegal.jpg differ
diff --git a/doc/latex/nbpion.jpg b/doc/latex/nbpion.jpg
new file mode 100644
index 0000000000000000000000000000000000000000..bcd2790effdd212376e8ec15b24023015072ab16
Binary files /dev/null and b/doc/latex/nbpion.jpg differ
diff --git a/doc/latex/nombreinvalide.jpg b/doc/latex/nombreinvalide.jpg
new file mode 100644
index 0000000000000000000000000000000000000000..6c15c977c1495074c8bde1746c93378a2d5e84dc
Binary files /dev/null and b/doc/latex/nombreinvalide.jpg differ
diff --git a/doc/latex/rapport.pdf b/doc/latex/rapport.pdf
index 8c315c0bebd9c4a165a8b03da608ffcb201ecd6a..fa510694089958c2a435fb1626e230ebaa000361 100644
Binary files a/doc/latex/rapport.pdf and b/doc/latex/rapport.pdf differ
diff --git a/doc/latex/rapport.tex b/doc/latex/rapport.tex
index e310c40624ab3fc24a3f7213cd8faaeaedee9997..c5df54d287cbd55be29647e62316cbbf67051874 100644
--- a/doc/latex/rapport.tex
+++ b/doc/latex/rapport.tex
@@ -10,6 +10,9 @@
 \usepackage{hyperref}
 \usepackage{xcolor}
 \usepackage{graphicx}
+\usepackage[a4paper,left=2cm,right=2cm,top=2cm,bottom=2cm]{geometry}
+\usepackage{minted}
+
 \hypersetup{
 	colorlinks,
 	linkcolor={red!50!black},
@@ -17,7 +20,7 @@
 	urlcolor={blue!80!black}
 }
 \author{Loïc DUBARD}
-\title{Projet de programmation Impérative :\\ Stackchess}
+\title{Rapport du projet de programmation Impérative: Stackchess}
 
 \begin{document}
 \maketitle
@@ -27,8 +30,126 @@
 \section{Démarche générale}
 \subsection{Les principales structures de données  utilisées ainsi que les différentes opérations implémentées sur ces structures}
 \subsubsection*{Pile} 
+La pile est la structure la plus importante du jeu, puisque'elle constitue les cases du plateau. Pour l'implémenter, j'ai du choisir entre une structure de tableau de taille fixe et une structure de liste chainée. Par soucis d'optimisation mémoire j'ai donc choisi de la représenter sous la forme d'une liste chainée dont chaque maillons contient une pièce du jeu sous la forme d'une chaine de 2 charactères (ex : "PN" pour pion noir) : 
+\begin{minted}{C}
+typedef struct _noeud * pile;
+struct _noeud{char *chaine;pile next;};
+\end{minted}
+
+Les différentes opérations implémentées sur la pile sont :
+\begin{itemize}
+	\item savoir si une pile est vide
+	\item retourner le sommet d'une pile
+	\item empiler un nouvelle élément (= pièce) au dessus d'une pile (=case)
+	\item dépiler le sommet d'une pile
+	\item déterminer la longueur (nombre d'éléments) d'une pile
+	\item déterminer le nombre de pièce d'une même couleur donnée au dessus d'une pile
+	\item déterminer le nombre de cavaliers d'une même couleur donnée situés dans la pile
+	\item vider (ou désallouer) une pile
+\end{itemize}
+\subsubsection*{Plateau}
+J'ai ensuite choisi de représenter le plateau par un tableau de pile en deux dimensions que j'ai alloué dans une fonction d'initialisation.
+\begin{minted}{C}
+pile **initialisation(int N)
+{
+	int i,j;
+	pile ** tableau;
+	tableau = (pile**) malloc(N*sizeof(pile*));
+	for (i=0 ; i<N ; i++){
+		tableau[i] =(pile*)malloc(N*sizeof(pile));
+		for (j=0 ; j<N ; j++)
+			tableau[i][j] = NULL;
+	}
+	return tableau;
+}
+\end{minted}
+Les différentes opérations implémentées sur le plateau sont :
+\begin{itemize}
+	\item poser les pièces sur la bonne case du plateau en début de partie
+	\item nettoyer (ou desallouer) le plateau pour éviter les fuites de mémoire
+	\item parcourir le plateau pour déterminer si la partie est finie ou pas
+	\item determiner si un déplacement est légal
+	\item deplacer les pièces du plateau si le déplacement est légal
+\end{itemize}
 \subsection{La gestion de l'affichage}
+L'affichage se fait en mode terminal, en utilisant les séquences d'echappement ANSI pour avoir de la couleur : 
+\begin{minted}{C}
+#define clrscr() printf("\033[H\033[2J") //rafraichi l'écran
+#define NOIR   "\x1B[48;2;0;0;0m"//colore le fond d'une case en noir
+#define PBLANCHE "\x1B[1;32m"//colore les charactères en gris
+#define PNOIRE "\x1B[1;31m" //colore les charactères en rouge
+#define BLANC   "\x1B[48;2;255;255;255m" //colore le fond d'une case en blanc
+#define RESET "\x1B[0m" //remet l'affichage par défaut du terminal
+\end{minted}
+On parcours le plateau et par des test sur le sommet de chaque pile, on affiche pour chaque case :
+\begin{minted}{c}
+//si on a une pièce noire sur une case noire :
+printf(PNOIRE NOIR "%c " RESET, *sommet(tableau[i][j])); 
+//si on a une pièce blanche sur une case noire :
+printf(PBLANCHE NOIR"%c " RESET, *sommet(tableau[i][j]));
+//si on a une pièce noire sur une case blanche :
+printf(PNOIRE BLANC"%c " RESET, *sommet(tableau[i][j])); 
+//si on a une pièce blanche sur une case blanche :
+printf(PBLANCHE BLANC"%c " RESET, *sommet(tableau[i][j]));
+//si on a une case blanche vide :
+printf(BLANC "  " RESET); 
+//si on a une case noire vide :
+printf(NOIR "  " RESET); 
+\end{minted}
+
+\begin{figure}[H]
+	\centering
+	\includegraphics[scale=1]{affichage.jpg}
+\end{figure}
+L'affichage de la pile sur le côté se fait en testant à chaque ligne du tableau si l'on doit rajouter en fin de ligne les charactères (avec le bon espacement) correspondant à la pile selectionnée. La dernière ligne affichera toujours quelque chose en plus du tableau (soit : "Aucune selection", soit les coordonnées de la case selectionnée ainsi que le dernier element de cette case si elle n'est pas vide)
 \subsection{La fonction qui fait le lien entre l'utilisateur et le jeu}
+En utilisant un switch sur un scanf, on execute selon le cas : 
+\begin{itemize}
+	\item si le charactère entré est 'c' : un scanf sur la case à selectionner 
+	\item si le charactère entré est 'd' : on fait un appel à la fonction qui se charge du déplacement des pièces de la case préalablement selectionnée
+	\item si le charactère entré est 'a' : demande à l'utilisateur s'il souhaite abandonner et quitte le cas échéant en affichant le gagnant.
+	\item si les charactères entrés ne correspondent à aucun des cas précédents, l'écran est rafraichi et on redemande à l'utilisateur de rentrer un charactère. 
+\end{itemize}
 \subsection{Le calcul du déplacement d'une pièce ou d'une pile}
-\subsection{La recherche de fin de partie}
+La partie la plus complexe du programme est celle qui se charge de determiner si un déplacement est valable. Pour cela, l'utilisateur ayant déjà selectionné la case à deplacer, l'affichage est rafraichi et si la case contient les pièces de la bonne couleur on demande alors le nombre de pièces à déplacer :
+\begin{figure}[H]
+	\centering
+	\includegraphics[scale=1]{nbpion.jpg}
+\end{figure}
+Si ce nombre est inférieur ou égale au nombre de pièces de la case, le programme raffraichi l'écran et demande une case de destination à l'utilisateur. Puis viens la fonction qui:
+\begin{itemize}
+	\item regarde d'abord si le nombre de pièces à déplacer est supérieur strictement au nombre de pièces adverses de la case de destination. Si ce n'est pas le cas renvoie un message d'erreur.
+	\item si le nombre de cavaliers dans la pile à déplacer est supérieur ou égale à m/2 (où m désigne le nombre de pièces totale à déplacer) alors teste si le déplacement est valable pour un cavalier et l'effectue si c'est le cas. 
+	\item sinon teste pour chaque pièce à déplacer si ce déplacement est valable et si une de ces pièces ne convient pas, renvoie un message d'erreur. Sinon effectue le déplacement par désempilement/réempilement.\\
+\end{itemize} 
+
+Un exemple de message d'erreur lors de l'entrée d'un nombre de pièce à déplacer invalide : 
+\begin{figure}[H]
+	\centering
+	\includegraphics[scale=1]{nombreinvalide.jpg}
+\end{figure}
+
+Un exemple de message d'erreur lors d'un déplacement d'un fou : 
+\begin{figure}[H]
+	\centering
+	\includegraphics[scale=0.8]{deplacementillegal.jpg}
+\end{figure}
+
+
+
+
+ Les fonctions de tests de validité d'un déplacement pour chaque pièce regardent si les coordonnées de destination sont bien dans les intervales correspondants à chaque pièces et vérifient que l'on ne saute pas de pièce lors de ce déplacement.\\
+ 
+ Dans le cas du pion, la fonction de test associée différencie le cas où la case de destination contient au moins une pièce adverse et le cas où la case de destination ne contient aucune pièce adverse.
+ 
+\subsection{Le test de fin de partie}
+Les différents cas de fin de partie implémentés sont :
+\subsubsection*{Un des joueurs n'a plus aucune pièce sur le plateau}
+A chaque tour, on parcours le plateau et on incrémente la longueur des piles contenant les pièces d'une couleur donnée dans un compteur pour chaque joueur. Ensuite, il suffit de tester si un des compteur est nul.
+\subsubsection*{Il ne reste qu'une pièce chacun sur le plateau}
+En effet, pour "manger" des pièces adverses il faut empiler sur la case adverse strictement plus de pièce que celle-ci ne contient, ce qui est impossible dans ce cas. On se trouve alors dans un cas d'égalité.
+\subsubsection*{Il ne reste à chacun qu'un fou et une tour}
+Comme ces deux pièces n'ont aucun déplacement en commun, il est impossible de les empiler en même temps sur la tour ou le fou adverse. Pour detecter ce cas on regarde si le nombre de pièces totale sur le plateau est de 4 et en parcourant celui-ci on compte le nombre de fou et de tour de chaque couleur.
+\section{Fonctionnement général du jeu}
+
 \end{document}
\ No newline at end of file
diff --git a/src/affichage.h b/src/affichage.h
index 284776ac25fea4ac3b1f9445868c7bce1c752491..aee85fe738fc465400bc78576121700d00eb3dd0 100644
--- a/src/affichage.h
+++ b/src/affichage.h
@@ -35,7 +35,7 @@ void affichepion(char *pion,char* CASE);
 /*
  * @require
  * @assign
- * @ensure combine affichecouleur() et affichepile()
+ * @ensure combine affichetableau_pile_cote() et l'affichage du message destiné à l'utilisateur
  */
 void affichage(pile **tableau,int N,char *sel,int tour,char *message);
 #endif
diff --git a/src/couleur.h b/src/couleur.h
index 5aa752bc385ef54ffc3b9e2ffa13969a31e6614a..09bae72d825eec679c86039226c323fc8506d632 100644
--- a/src/couleur.h
+++ b/src/couleur.h
@@ -9,7 +9,7 @@
  * @file couleur.h
  * 
  * Ce fichier décrit un ensemble de fonctions concernant l'affichage interactif et amélioré du jeu.
- * Il contient 7 directives de préprocesseur.
+ * Il contient 6 directives de préprocesseur.
  * 
  */
 
@@ -45,10 +45,5 @@
  */
 #define RESET "\x1B[0m"
 
-/**
- * @brief cacher le curseur
- */
-#define HIDE "\e["
-
 
 #endif