\langchapter{Logique}{Logic} %TODO Complete chapter La logique consiste en des opérations effectuées uniquement sur des variables (notées $P,Q,R$) n'ayant pour valeur soit Vrai (noté \true), soit Faux (noté \false). %Logic consists of operations done on sole values : True $T$ and False $F$. \langsection{Principle de tiers exclu}{Excluding middle} $\true \equivalence \lnot \false$ $\false \equivalence \lnot \true$ \langsection{Relation Binaires}{Binary relations} %TODO Complete section \langsubsection{Réflexion}{Reflexivity} \label{definition:reflexivity} % TODO Complete subsection Une relation $\Rel$ sur $E$ est dite \textbf{réflexive} si et seulement si $\forall a \in E, a \Rel a$. \langsubsection{Transitivité}{Transitivity} \label{definition:transitivity} % TODO Complete subsection Une relation $\Rel$ sur $E$ est dite \textbf{transitive} si et seulement si $\forall (a,b) \in E$, $a \Rel b \land b \Rel c \equivalence a \Rel c$. \langsubsection{Associativité}{Associativity} \label{definition:associativity} % TODO Complete subsection Une relation $\Rel$ sur $E$ est dite \textbf{associative} si et seulement si $\forall (a,b) \in E$, $(a \Rel b) \Rel c \equivalence a \Rel (b \Rel c) \Leftrightarrow a \Rel b \Rel c$. \langsubsection{Commutativité}{Commutativity} \label{definition:commutativity} % TODO Complete subsection Une relation $\Rel$ sur $E$ est dite \textbf{commutative} si et seulement si $\forall (a,b) \in E, a \Rel b = b \Rel a$. \langsection{Opérateurs}{Operators} %TODO Complete section \langsubsection{NON}{NOT} % TODO Complete subsection $P \equivalence \lnot \lnot P$ \langsubsubsection{Table de vérité}{Truth table} \begin{tabular}{|c|c|} \hline P & $\lnot P$ \\ \hline \false & \true \\ \hline \true & \false \\ \hline \end{tabular} \langsubsection{ET}{AND} %TODO Complete subsection $P \land Q \equivalence \lnot P \lor \lnot Q$ \begin{tabular}{|c|c||c|} \hline P & Q & P $\land$ Q \\ \hline \false & \false & \false \\ \hline \true & \false & \false \\ \hline \false & \true & \false \\ \hline \true & \true & \true \\ \hline \end{tabular} \langsubsection{OU}{OR} % TODO Complete subsection $P \lor Q \equivalence \lnot P \land \lnot Q$ \medskip \begin{tabular}{|c|c||c|} \hline P & Q & P $\lor$ Q \\ \hline \false & \false & \false \\ \hline \true & \false & \true \\ \hline \false & \true & \true \\ \hline \true & \true & \true \\ \hline \end{tabular} \subsection{Implication} %TODO Complete subsection \begin{tabular}{|c|c||c|} \hline P & Q & P $\Rightarrow$ Q \\ \hline \false & \false & \true \\ \hline \true & \false & \false \\ \hline \false & \true & \true \\ \hline \true & \true & \true \\ \hline \end{tabular} \lang{Contraposée}{Contraposition } : \ $\lnot Q \implies \lnot P$ \langsubsection{Équivalence}{Equivalence} % TODO Complete subsection \begin{tabular}{|c|c||c|} \hline $P$ & $Q$ & $P \equivalence Q$ \\ \hline \false & \false & \true \\ \hline \true & \false & \false \\ \hline \false & \true & \false \\ \hline \true & \true & \true \\ \hline \end{tabular} \langsubsection{OU exclusif / XOR}{Exclusive OR / XOR} %TODO Complete subsection $P \oplus Q \equivalence (P \lor Q) \land \lnot (P \land Q)$ \begin{tabular}{|c|c||c|} \hline P & Q & $P \oplus Q$ \\ \hline \false & \false & \false \\ \hline \true & \false & \true \\ \hline \false & \true & \true \\ \hline \true & \true & \false \\ \hline \end{tabular}