Une fonction booléenne est une fonction de $$\{0, 1\}^n\rightarrow \{0, 1\}$$
Ex : $$f: \left\{\begin{align}\{0, 1\}^3 &\rightarrow \{0, 1\}\\ x, y, z &\mapsto x(y + z) \mod 2 \end{align}\right.$$
| \(x\) | \(y\) | \(z\) | \(f(x, y, z)\) |
|---|---|---|---|
| 0 | 0 | 0 | 0 |
| 0 | 0 | 1 | 0 |
| 0 | 1 | 0 | 0 |
| 0 | 1 | 1 | 0 |
| 1 | 0 | 0 | 0 |
| 1 | 0 | 1 | 1 |
| 1 | 1 | 0 | 1 |
| 1 | 1 | 1 | 0 |
Porte NON :
| \(x\) | \(\neg x\) |
|---|---|
| 0 | 1 |
| 1 | 0 |
Porte ET :
| \(x\) | \(y\) | \(x\wedge y\) |
|---|---|---|
| 0 | 0 | 0 |
| 0 | 1 | 0 |
| 1 | 0 | 0 |
| 1 | 1 | 1 |
Porte OU :
| \(x\) | \(y\) | \(x\vee y\) |
|---|---|---|
| 0 | 0 | 0 |
| 0 | 1 | 1 |
| 1 | 0 | 1 |
| 1 | 1 | 1 |
Porte XOR (ou exclusif) :
| \(x\) | \(y\) | \(x\oplus y\) |
|---|---|---|
| 0 | 0 | 0 |
| 0 | 1 | 1 |
| 1 | 0 | 1 |
| 1 | 1 | 0 |
On construit les fonctions logiques à partir de portes logiques élémentaires
Les portes logiques élémentaires sont :
On peut utiliser des portes NON pour réaliser le complément à un d'un nombre

On peut enchaîner les portes ET, OU et XOR

Rmq : La réciproque est évidente
Forme normale disjonctive →
Forme normale conjonctive →
| \(x\) | \(y\) | \(z\) | \(f(x, y, z)\) |
|---|---|---|---|
| 0 | 0 | 0 | 0 |
| 0 | 0 | 1 | 1 |
| 0 | 1 | 0 | 1 |
| 0 | 1 | 1 | 0 |
| 1 | 0 | 0 | 0 |
| 1 | 0 | 1 | 0 |
| 1 | 1 | 0 | 1 |
| 1 | 1 | 1 | 0 |
| \(x\) | \(y\) | \(z\) | \(f(x, y, z)\) |
|---|---|---|---|
| 0 | 0 | 0 | 0 |
| 0 | 0 | 1 | 1 |
| 0 | 1 | 0 | 1 |
| 0 | 1 | 1 | 0 |
| 1 | 0 | 0 | 0 |
| 1 | 0 | 1 | 0 |
| 1 | 1 | 0 | 1 |
| 1 | 1 | 1 | 0 |
| \(x\) | \(y\) | \(z\) | \(f(x, y, z)\) |
|---|---|---|---|
| 0 | 0 | 0 | 0 |
| 0 | 0 | 1 | 1 |
| 0 | 1 | 0 | 1 |
| 0 | 1 | 1 | 0 |
| 1 | 0 | 0 | 0 |
| 1 | 0 | 1 | 0 |
| 1 | 1 | 0 | 1 |
| 1 | 1 | 1 | 0 |
$$\begin{align}f(x, y, z) = &(\neg x\wedge \neg y\wedge z)\\ &\vee (\neg x\wedge y\wedge \neg z)\\ &\vee (x\wedge y\wedge \neg z) \end{align}$$
$$\begin{align}f(x, y, z) = &(x\vee y\vee z)\\ &\wedge (x\vee \neg y\vee \neg z)\\ &\wedge (\neg x\vee y\vee z)\\ &\wedge (\neg x\vee y\vee \neg z)\\ &\wedge (\neg x\vee \neg y\vee \neg z)\\ \end{align}$$
Pour réaliser les fonctionnalités d’un ordinateur (en particulier l'unité centrale), on a besoin de nombreux circuits :

On va décrire un circuit qui réalise l'addition binaire sur \(n\) bits
On travaille chiffre par chiffre
Entrées :
Sorties :
| \(x\) | \(y\) | \(x+y\) | \(c_{out}\) |
|---|---|---|---|
| 0 | 0 | 0 | 0 |
| 0 | 1 | 1 | 0 |
| 1 | 0 | 1 | 0 |
| 1 | 1 | 0 | 1 |



On ajoute une retenue entrante (\(c_{in}\))
Entrées :
Sorties :
| \(x\) | \(y\) | \(c_{in}\) | \(s\) | \(c_{out}\) |
|---|---|---|---|---|
| 0 | 0 | 0 | 0 | 0 |
| 0 | 0 | 1 | 1 | 0 |
| 0 | 1 | 0 | 1 | 0 |
| 0 | 1 | 1 | 0 | 1 |
| 1 | 0 | 0 | 1 | 0 |
| 1 | 0 | 1 | 0 | 1 |
| 1 | 1 | 0 | 0 | 1 |
| 1 | 1 | 1 | 1 | 1 |
On peut combiner \(n\) full-adders pour obtenir un additionneur à \(n\) bits

On peut faire la même chose pour la soustraction :
Ou bien, si en complément à 2 (mod \(2^n\)) :$$\begin{align} x - y &= x + (2^n - y) \\ &= x + (2^n-1 - y) + 1 \\ &= x + \neg y + 1 \end{align}$$
→ On peut réutiliser le circuit de l'additionneur



On peut utiliser des circuits pour stocker des données
Rmq : Pour stocker de manière non volatile, on peut utiliser des supports de stockage (magnétique, optique, etc.)
Exemple : Bascule RS (RS latch)

| S | R | Q' | Action |
|---|---|---|---|
| 0 | 0 | Q | Conserver |
| 1 | 0 | 1 | Set |
| 0 | 1 | 0 | Reset |
| 1 | 1 | ❌ | Non autorisé |
Attention : La mémoire ne contient que des suites de bits
01000110 01000010 01010000 00000000int)$$2^{12} + 2^{14} + 2^{17} + 2^{22} + 2^{25} + 2^{26} + 2^{30} = 1178750976$$float)$$\simeq 1,5.2^{-57} \simeq 1,172.10^{-18}$$char *) : "FBP\0"On veut échanger des données d'un circuit à un autre
Série



Parallèle



