From 76f7d14092b3a28e46e1fc750beacc1c4439babc Mon Sep 17 00:00:00 2001 From: Florent Madelaine Date: Mon, 13 Oct 2025 12:11:04 +0200 Subject: [PATCH] correction ab --- 1-ComputationAndData/0Planning2025.md | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/1-ComputationAndData/0Planning2025.md b/1-ComputationAndData/0Planning2025.md index 6c84dbe..bc3d89e 100644 --- a/1-ComputationAndData/0Planning2025.md +++ b/1-ComputationAndData/0Planning2025.md @@ -243,7 +243,7 @@ Il suffit d'accepter ensuite. |:----------------|:---|:----| | q0 (initial) | qa | KO | | qa | KO | qab | -| qab (acceptant) | qab | qab | +| qab (acceptant) | **qab** | **qab** | | KO | KO | KO | Pour le mot aba : @@ -255,3 +255,26 @@ Pour le mot bab: $$q0 \xrightarrow{b}{} KO \xrightarrow{a}{} KO \xrightarrow{b}{} KO$$ KO est non-acceptant donc le mot bab est rejeté. + +###### Le langage des mots qui terminent par ab. + +Exemple pour le oui : aaabab + +Exemple pour le non : aa + +On peut proposer un automate déterministe en utilisant le principe qui consiste à mémoriser dans les états les deux dernières lettres lues. +Il est facile de mettre à jour les fenêtres quand on lit une nouvelle lettre à droite. + +Par exemple la fenêtre aa suivi de b devient la fenêtre ab. + +Pour le début du mot, il faut des fenêtres partielles pour le mot vite (état initial q0), la lettre a (état qa), la lettre b (état qb). + +| état | a | b | +|:----------------|:----|:----| +| q0 (initial) | qa | qb | +| qa | qaa | qab | +| qb | qba | qbb | +| qaa | qaa | qab | +| qab (acceptant) | qba | qbb | +| qba | qaa | qab | +| qbb | qba | qbb |