Fiche 02 correction : Langage rationnel
Automate Fini D´eterministe
Licence 3 informatique 2017 / 2018
Exercice 1 : Langage, expression r´ eguli` ere, AFD
1. ( (a+b+c) (a+b+c) )*
1 2
a,b,c a,b,c
2. ((a+c)* b (a+c)* b (a+c)* b)* (a+c)*
2
0 b 1 b
b
a,c a,c a,c
Le num´ero de l’´etat correspond au nombre debmodulo 3.
3. (a+b+c)* b
1 b 2
a,b,c
OU 1 b 2
b a,c
a,c
4. ((a+b+c)* (a+c))*
1 2
a,c b
b a,c
5. (a+b+c)* (a+c)
1 2
b a,c
b a,c
6. (a+c)* b (a+b+c)*
1 b 2
a,c a,b,c
1
7. (a+c)* (b + (a+c)*) (a+c)*
a,b,c
0 b 1
a,c a,c
b 2+
8. (a+c)* b (a+c)*
a,b,c
0 b 1
a,c a,c
b 2+
9. (a+c)*
1 b 2
a,c a,b,c
OU 1
a,c
10. (b+c)* a ((a+b)(a+b+c)*)*
1 2
b,c
a a,b 3
a,b,c 4 c
11. (a+b+c)* (a+c) (a+b+c)2
7 a,c
a,b,c
b b
b a,c
b
a,c
a,c b a,c
a,c a,c
b b
b b
2 1
0 3
4 5
6
12. Le num´ero de l’´etat correspond au nombre 2|u|a+|u|b modulo 3.
a
0 b 1
b 2
c c c
a
a
b
13. (a+b+c)* (ab)2 (a+b+c)*
a
1 2
a,b,c
3 4 5
a b a b
b,c a
c
b,c c
2
Exercice 2 : ER et AFD
a- Les mots sur {0,1}dont la derni`ere lettre est le bit de parit´e : 0∗1(0∗10∗10∗)∗1 + (0∗10∗10∗)∗0
1 1 2 1 3
0
0
1
4
0 0
1
b- Les suites altern´ees de 0 et 1 : (01)∗+ (10)∗
1 2 3
1 0 1
4 0
0
1 5
c- Les mots contenant la s´equenceAT A sur l’alphabet{A, T, C, G} : (A+T+C+G)∗AT A(A+T+C+G)∗
1 A 2 T 3
C,G A
T,C,G 4
A A,T,C,G
1 T,C,G
3