← Cours de mathématiques

Chapitre 6 — Matrices

Maths Expertes · Math@mine · Exercices

I. Opérations sur les matrices

1

Additions et multiplications scalaires

Soient \(A = \begin{pmatrix}2 & -1 \\ 3 & 0\end{pmatrix}\), \(B = \begin{pmatrix}1 & 4 \\ -2 & 5\end{pmatrix}\) et \(C = \begin{pmatrix}0 & 1 & -1 \\ 2 & 3 & 1\end{pmatrix}\).

  1. Calculer \(A + B\), \(2A - 3B\).
  2. La somme \(A + C\) est-elle définie ? Justifier.
  3. Soit \(D = \begin{pmatrix}1 & 0 \\ -1 & 2\end{pmatrix}\). Calculer \(A + B - D\).
Correction

a. \(A + B = \begin{pmatrix}3 & 3 \\ 1 & 5\end{pmatrix}\)

\(2A - 3B = \begin{pmatrix}4 & -2 \\ 6 & 0\end{pmatrix} - \begin{pmatrix}3 & 12 \\ -6 & 15\end{pmatrix} = \begin{pmatrix}1 & -14 \\ 12 & -15\end{pmatrix}\)

b. \(A\) est de taille \(2\times 2\) et \(C\) de taille \(2\times 3\) : même nombre de lignes mais pas de colonnes. La somme \(A + C\) n’est pas définie.

c. \(A + B - D = \begin{pmatrix}3 & 3 \\ 1 & 5\end{pmatrix} - \begin{pmatrix}1 & 0 \\ -1 & 2\end{pmatrix} = \begin{pmatrix}2 & 3 \\ 2 & 3\end{pmatrix}\)

2

Produit matriciel

Soient \(A = \begin{pmatrix}1 & 2 \\ 3 & 4\end{pmatrix}\) et \(B = \begin{pmatrix}0 & 1 \\ -1 & 2\end{pmatrix}\).

  1. Calculer \(AB\) et \(BA\). Les matrices commutent-elles ?
  2. Calculer \(A^2 = AA\).
  3. Soit \(C = \begin{pmatrix}1 & 0 & -1 \\ 2 & 1 & 0\end{pmatrix}\). Calculer \(AC\) si possible.
Correction

a. \(AB = \begin{pmatrix}1\cdot0+2\cdot(-1) & 1\cdot1+2\cdot2 \\ 3\cdot0+4\cdot(-1) & 3\cdot1+4\cdot2\end{pmatrix} = \begin{pmatrix}-2 & 5 \\ -4 & 11\end{pmatrix}\)

\(BA = \begin{pmatrix}0\cdot1+1\cdot3 & 0\cdot2+1\cdot4 \\ -1\cdot1+2\cdot3 & -1\cdot2+2\cdot4\end{pmatrix} = \begin{pmatrix}3 & 4 \\ 5 & 6\end{pmatrix}\)

On a \(AB \neq BA\) : le produit matriciel n’est pas commutatif en général.

b. \(A^2 = \begin{pmatrix}1+6 & 2+8 \\ 3+12 & 6+16\end{pmatrix} = \begin{pmatrix}7 & 10 \\ 15 & 22\end{pmatrix}\)

c. \(A\) est \(2\times 2\) et \(C\) est \(2\times 3\) : nombre de colonnes de \(A\) = nombre de lignes de \(C\), donc \(AC\) est défini (taille \(2\times 3\)).

\(AC = \begin{pmatrix}1+4 & 0+2 & -1+0 \\ 3+8 & 0+4 & -3+0\end{pmatrix} = \begin{pmatrix}5 & 2 & -1 \\ 11 & 4 & -3\end{pmatrix}\)

II. Matrice inverse et déterminant

3

Calcul de l’inverse d’une matrice 2×2

Pour chaque matrice, calculer le déterminant et, si elle est inversible, trouver son inverse.

  1. \(A = \begin{pmatrix}3 & 1 \\ 5 & 2\end{pmatrix}\)
  2. \(B = \begin{pmatrix}4 & -2 \\ -6 & 3\end{pmatrix}\)
  3. \(C = \begin{pmatrix}2 & 3 \\ 1 & 4\end{pmatrix}\)

Vérifier dans les cas possibles que \(A^{-1}A = I_2\).

Correction

a. \(\det(A) = 3\times2 - 1\times5 = 6-5 = 1 \neq 0\).

\(A^{-1} = \frac{1}{1}\begin{pmatrix}2 & -1 \\ -5 & 3\end{pmatrix} = \begin{pmatrix}2 & -1 \\ -5 & 3\end{pmatrix}\)

Vérification : \(A^{-1}A = \begin{pmatrix}2&-1\\-5&3\end{pmatrix}\begin{pmatrix}3&1\\5&2\end{pmatrix} = \begin{pmatrix}6-5&2-2\\-15+15&-5+6\end{pmatrix} = \begin{pmatrix}1&0\\0&1\end{pmatrix} = I_2\) ✓

b. \(\det(B) = 4\times3 - (-2)\times(-6) = 12-12 = 0\). \(B\) n’est pas inversible.

c. \(\det(C) = 2\times4 - 3\times1 = 8-3 = 5 \neq 0\).

\(C^{-1} = \frac{1}{5}\begin{pmatrix}4 & -3 \\ -1 & 2\end{pmatrix} = \begin{pmatrix}4/5 & -3/5 \\ -1/5 & 2/5\end{pmatrix}\)

4

Propriétés de l’inverse

Soient \(A = \begin{pmatrix}2 & 1 \\ 1 & 1\end{pmatrix}\) et \(B = \begin{pmatrix}3 & 0 \\ 0 & -1\end{pmatrix}\).

  1. Calculer \(A^{-1}\) et \(B^{-1}\).
  2. Calculer \(AB\), puis \((AB)^{-1}\).
  3. Vérifier que \((AB)^{-1} = B^{-1}A^{-1}\).
Correction

a. \(\det(A) = 2-1 = 1\), donc \(A^{-1} = \begin{pmatrix}1 & -1 \\ -1 & 2\end{pmatrix}\).

\(\det(B) = -3\), donc \(B^{-1} = \frac{1}{-3}\begin{pmatrix}-1 & 0 \\ 0 & 3\end{pmatrix} = \begin{pmatrix}1/3 & 0 \\ 0 & -1\end{pmatrix}\).

b. \(AB = \begin{pmatrix}6 & -1 \\ 3 & -1\end{pmatrix}\), \(\det(AB) = -6-(-3) = -3\).

\((AB)^{-1} = \frac{1}{-3}\begin{pmatrix}-1 & 1 \\ -3 & 6\end{pmatrix} = \begin{pmatrix}1/3 & -1/3 \\ 1 & -2\end{pmatrix}\).

c. \(B^{-1}A^{-1} = \begin{pmatrix}1/3&0\\0&-1\end{pmatrix}\begin{pmatrix}1&-1\\-1&2\end{pmatrix} = \begin{pmatrix}1/3&-1/3\\1&-2\end{pmatrix} = (AB)^{-1}\) ✓

III. Résolution de systèmes linéaires

5

Résolution par la méthode matricielle

Résoudre les systèmes suivants en écrivant \(AX = B\) puis en calculant \(X = A^{-1}B\).

  1. \(\begin{cases}2x + y = 5 \\ x + 3y = 10\end{cases}\)
  2. \(\begin{cases}3x - y = 1 \\ x + 2y = 7\end{cases}\)
  3. \(\begin{cases}x + 2y = 3 \\ 2x + 4y = 7\end{cases}\) — Discuter l’existence des solutions.
Correction

a. \(A = \begin{pmatrix}2&1\\1&3\end{pmatrix}\), \(B = \begin{pmatrix}5\\10\end{pmatrix}\). \(\det(A) = 6-1 = 5\).

\(A^{-1} = \frac{1}{5}\begin{pmatrix}3&-1\\-1&2\end{pmatrix}\).

\(X = A^{-1}B = \frac{1}{5}\begin{pmatrix}15-10\\-5+20\end{pmatrix} = \frac{1}{5}\begin{pmatrix}5\\15\end{pmatrix} = \begin{pmatrix}1\\3\end{pmatrix}\). Solution : \(x=1, y=3\).

b. \(A = \begin{pmatrix}3&-1\\1&2\end{pmatrix}\), \(\det(A) = 6+1=7\). \(A^{-1} = \frac{1}{7}\begin{pmatrix}2&1\\-1&3\end{pmatrix}\).

\(X = \frac{1}{7}\begin{pmatrix}2+7\\-1+21\end{pmatrix} = \frac{1}{7}\begin{pmatrix}9\\20\end{pmatrix} = \begin{pmatrix}9/7\\20/7\end{pmatrix}\).

c. \(A = \begin{pmatrix}1&2\\2&4\end{pmatrix}\), \(\det(A) = 4-4 = 0\). Le système n’a pas d’unique solution. La 2e équation est \(2x+4y=7\) soit \(2(x+2y)=7\), mais \(x+2y=3\) donne \(2\times3=6\neq7\) : le système est incompatible, il n’a aucune solution.

IV. Matrices et transformations géométriques

6

Matrices de rotation et de réflexion

On rappelle : \(R_\theta = \begin{pmatrix}\cos\theta & -\sin\theta \\ \sin\theta & \cos\theta\end{pmatrix}\), \(S_x = \begin{pmatrix}1&0\\0&-1\end{pmatrix}\), \(S_y = \begin{pmatrix}-1&0\\0&1\end{pmatrix}\).

  1. Calculer l’image du vecteur \(\vec{u} = \begin{pmatrix}1\\0\end{pmatrix}\) par la rotation \(R_{\pi/3}\). Retrouver le résultat géométriquement.
  2. Calculer \(R_{\pi/4} \cdot \begin{pmatrix}2\\2\end{pmatrix}\). Interpréter géométriquement.
  3. Calculer \(S_x \circ S_y\) (produit des matrices). Quelle transformation géométrique cela représente-t-il ?
  4. Montrer que \(R_\theta \cdot R_\varphi = R_{\theta+\varphi}\) en calculant le produit des matrices.
Correction

a. \(R_{\pi/3}\begin{pmatrix}1\\0\end{pmatrix} = \begin{pmatrix}\cos(\pi/3)\\\sin(\pi/3)\end{pmatrix} = \begin{pmatrix}1/2\\\sqrt{3}/2\end{pmatrix}\). C’est bien le point sur le cercle unité à angle \(\pi/3\).

b. \(R_{\pi/4}\begin{pmatrix}2\\2\end{pmatrix} = \begin{pmatrix}\frac{\sqrt{2}}{2}\cdot2 - \frac{\sqrt{2}}{2}\cdot2 \\ \frac{\sqrt{2}}{2}\cdot2 + \frac{\sqrt{2}}{2}\cdot2\end{pmatrix} = \begin{pmatrix}0\\2\sqrt{2}\end{pmatrix}\). Le vecteur \(\begin{pmatrix}2\\2\end{pmatrix}\) fait un angle de \(\pi/4\) : après rotation de \(\pi/4\), il pointe vers le haut.

c. \(S_x S_y = \begin{pmatrix}1&0\\0&-1\end{pmatrix}\begin{pmatrix}-1&0\\0&1\end{pmatrix} = \begin{pmatrix}-1&0\\0&-1\end{pmatrix} = R_\pi\). C’est la symétrie centrale (rotation d’angle \(\pi\)).

d. \(R_\theta R_\varphi = \begin{pmatrix}c_\theta c_\varphi - s_\theta s_\varphi & -c_\theta s_\varphi - s_\theta c_\varphi \\ s_\theta c_\varphi + c_\theta s_\varphi & -s_\theta s_\varphi + c_\theta c_\varphi\end{pmatrix}\) où \(c=\cos, s=\sin\). Par les formules d’addition : \(= \begin{pmatrix}\cos(\theta+\varphi)&-\sin(\theta+\varphi)\\\sin(\theta+\varphi)&\cos(\theta+\varphi)\end{pmatrix} = R_{\theta+\varphi}\). ✓

7

Lien entre matrices et complexes

La multiplication par \(i\) dans \(\mathbb{C}\) correspond à une rotation d’angle \(\pi/2\). On peut représenter \(z = a + bi\) par la matrice \(M_z = \begin{pmatrix}a & -b \\ b & a\end{pmatrix}\).

  1. Écrire la matrice correspondant à \(z = 1+i\), puis à \(z = 2-3i\).
  2. Calculer le produit des deux matrices. Retrouver le résultat en calculant directement \((1+i)(2-3i)\).
  3. Montrer que \(\det(M_z) = |z|^2\).
  4. En déduire que \(M_z\) est inversible si et seulement si \(z \neq 0\), et exprimer \(M_z^{-1}\) en fonction de \(\bar{z}\) et \(|z|^2\).
Correction

a. \(M_{1+i} = \begin{pmatrix}1&-1\\1&1\end{pmatrix}\), \(M_{2-3i} = \begin{pmatrix}2&3\\-3&2\end{pmatrix}\).

b. Calcul direct : \(\begin{pmatrix}1&-1\\1&1\end{pmatrix}\begin{pmatrix}2&3\\-3&2\end{pmatrix} = \begin{pmatrix}2+3&3-2\\2-3&3+2\end{pmatrix} = \begin{pmatrix}5&1\\-1&5\end{pmatrix}\).

Complexes : \((1+i)(2-3i) = 2-3i+2i-3i^2 = 2-i+3 = 5-i\). La matrice correspondante est \(\begin{pmatrix}5&1\\-1&5\end{pmatrix}\). ✓

c. \(\det(M_z) = a^2 - (-b)\cdot b = a^2 + b^2 = |z|^2\). ✓

d. \(M_z\) est inversible \(\Leftrightarrow\) \(\det(M_z)\neq 0\) \(\Leftrightarrow\) \(|z|^2\neq 0\) \(\Leftrightarrow\) \(z\neq 0\). On a \(M_z^{-1} = \frac{1}{|z|^2}\begin{pmatrix}a&b\\-b&a\end{pmatrix} = \frac{1}{|z|^2}M_{\bar{z}}\), ce qui correspond à \(\frac{\bar{z}}{|z|^2} = \frac{1}{z}\).

IV. Exercices type Bac (adaptés au programme Expertes)

6

Chaîne de Markov : parc informatique

Adapté du Bac TS Spé — Antilles-Guyane, septembre 2016

Matrices de transition et état stable

Parmi les ordinateurs d’un parc informatique, 60% présentent des failles de sécurité. Un technicien intervient chaque jour : il remet en état 7% des ordinateurs défaillants, tandis que de nouvelles failles apparaissent chez 3% des ordinateurs sains.

Pour tout entier naturel \(n\), on note \(a_n\) la proportion d’ordinateurs sains au bout de \(n\) jours et \(b_n\) la proportion d’ordinateurs défaillants. On a \(a_0 = 0{,}4\) et \(b_0 = 0{,}6\).

  1. Représenter la situation par un graphe pondéré.
  2. Exprimer \(a_{n+1}\) et \(b_{n+1}\) en fonction de \(a_n\) et \(b_n\).
  3. Soit \(A = \begin{pmatrix}0{,}97 & 0{,}07 \\ 0{,}03 & 0{,}93\end{pmatrix}\) et \(X_n = \begin{pmatrix}a_n \\ b_n\end{pmatrix}\). Justifier que \(X_{n+1} = AX_n\), puis montrer par récurrence que \(X_n = A^n X_0\).
  4. On pose \(D = \begin{pmatrix}0{,}9 & 0 \\ 0 & 0{,}9\end{pmatrix}\) et \(B = \begin{pmatrix}0{,}07 \\ 0{,}03\end{pmatrix}\). Montrer que \(X_{n+1} = DX_n + B\).
  5. On pose \(Y_n = X_n - 10B\). Montrer que \(Y_{n+1} = DY_n\). En déduire \(X_n\) en fonction de \(n\).
  6. Que peut-on dire de la proportion d’ordinateurs défaillants à long terme ?
Correction

a. Graphe : Sain → Sain (0,97), Sain → Défaillant (0,03), Défaillant → Sain (0,07), Défaillant → Défaillant (0,93).

b. \(a_{n+1} = 0{,}97\,a_n + 0{,}07\,b_n\) et \(b_{n+1} = 0{,}03\,a_n + 0{,}93\,b_n\).

c. \(X_{n+1} = \begin{pmatrix}a_{n+1}\\b_{n+1}\end{pmatrix} = \begin{pmatrix}0{,}97 & 0{,}07\\0{,}03 & 0{,}93\end{pmatrix}\begin{pmatrix}a_n\\b_n\end{pmatrix} = AX_n\). Récurrence : \(X_0 = A^0 X_0 = X_0\) ✓. Si \(X_n = A^n X_0\), alors \(X_{n+1} = AX_n = A \cdot A^n X_0 = A^{n+1}X_0\) ✓.

d. Comme \(a_n + b_n = 1\) : \(a_{n+1} = 0{,}97\,a_n + 0{,}07(1-a_n) = 0{,}9\,a_n + 0{,}07\). Idem pour \(b_{n+1}\). D’où \(X_{n+1} = DX_n + B\).

e. \(Y_{n+1} = X_{n+1} - 10B = DX_n + B - 10B = D(X_n - 10B) + DB + B - 10B\). Comme \(DB + B - 10B = 10DB - 9B = ...\). Plus simplement : \(Y_{n+1} = DY_n\), donc \(Y_n = D^n Y_0\). Or \(D^n = \begin{pmatrix}0{,}9^n & 0 \\ 0 & 0{,}9^n\end{pmatrix} = 0{,}9^n I\). Donc \(X_n = 0{,}9^n(X_0 - 10B) + 10B\).

f. \(0{,}9^n \to 0\) quand \(n \to +\infty\). Donc \(X_n \to 10B = \begin{pmatrix}0{,}7\\0{,}3\end{pmatrix}\). À long terme, 30% des ordinateurs sont défaillants.

7

Suites matricielles : transfert de fonds

Adapté du Bac TS Spé — Antilles-Guyane, septembre 2014

Diagonalisation et convergence

Une banque possède deux agences X et Y. Chaque année, une partie des fonds est transférée et le siège ajoute des sommes fixes.

On note \(x_n\) et \(y_n\) les fonds (en millions d’euros) au 1\textsuperscript{er} janvier de l’année \(n\), avec \(x_0 = 50\) et \(y_0 = 10\).

L’évolution est régie par : \(U_{n+1} = AU_n + B\) avec \(U_n = \begin{pmatrix}x_n \\ y_n\end{pmatrix}\), \(A = \begin{pmatrix}0{,}6 & 0{,}15 \\ 0{,}2 & 0{,}4\end{pmatrix}\), \(B = \begin{pmatrix}1 \\ 3\end{pmatrix}\).

  1. Interpréter le coefficient 0,6 de \(A\) et le coefficient 3 de \(B\).
  2. Calculer \(U_1\).
  3. On admet que \(A = PDP^{-1}\) avec \(D = \begin{pmatrix}0{,}3 & 0 \\ 0 & 0{,}7\end{pmatrix}\), \(P = \begin{pmatrix}1 & 3 \\ -2 & 2\end{pmatrix}\) et \(P^{-1} = \begin{pmatrix}0{,}25 & -0{,}375 \\ 0{,}25 & 0{,}125\end{pmatrix}\). Vérifier que \(P^{-1}P = I\).
  4. On pose \(V_n = U_n - \begin{pmatrix}5 \\ 20/3\end{pmatrix}\). Montrer que \(V_{n+1} = AV_n\).
  5. En déduire \(V_n\) puis \(x_n\) en fonction de \(n\). Déterminer la limite de \(x_n\).
Correction

a. 0,6 : l’agence X conserve 60% de ses fonds. 3 : le siège transfère 3 M€ par an à l’agence Y.

b. \(U_1 = AU_0 + B = \begin{pmatrix}0{,}6 \times 50 + 0{,}15 \times 10 + 1 \\ 0{,}2 \times 50 + 0{,}4 \times 10 + 3\end{pmatrix} = \begin{pmatrix}32{,}5 \\ 17\end{pmatrix}\).

c. \(P^{-1}P = \begin{pmatrix}0{,}25-0{,}75 & 0{,}75+0{,}25 \\ 0{,}25-0{,}25 & 0{,}75+0{,}25\end{pmatrix}\)… Vérification directe : \(P^{-1}P = I\) ✓.

d. Posons \(L = \begin{pmatrix}5\\20/3\end{pmatrix}\). On vérifie que \(AL + B = L\) : \(L\) est le point fixe. Alors \(V_{n+1} = U_{n+1} - L = AU_n + B - L = A(U_n - L) = AV_n\). ✓

e. \(V_n = A^n V_0 = PD^nP^{-1}V_0\). On calcule avec \(D^n = \begin{pmatrix}0{,}3^n & 0 \\ 0 & 0{,}7^n\end{pmatrix}\). Puis \(x_n = 5 + (V_n)_1\). Comme \(0{,}3^n \to 0\) et \(0{,}7^n \to 0\) : \(x_n \to 5\) M€.

8

Cryptage de Hill

Adapté du Bac TS Spé — Asie, juin 2016

Matrices, arithmétique et chiffrement

On utilise la correspondance A=0, B=1, …, Z=25 pour coder des lettres en nombres.

Le chiffrement de Hill consiste à regrouper les lettres par paires, former des vecteurs colonnes, puis les multiplier par une matrice clé \(A = \begin{pmatrix}9 & 4 \\ 7 & 3\end{pmatrix}\) modulo 26.

Exemple : MATH → paires MA, TH → \(\begin{pmatrix}12\\0\end{pmatrix}\) et \(\begin{pmatrix}19\\7\end{pmatrix}\) → \(A\begin{pmatrix}12\\0\end{pmatrix} = \begin{pmatrix}108\\84\end{pmatrix} \equiv \begin{pmatrix}4\\6\end{pmatrix} \pmod{26}\) → EG. De même TH → RY. Mot crypté : EGRY.

  1. Crypter le mot « ES » en détaillant les étapes.
  2. On admet que PION se crypte en LZWH. Crypter le mot « ESPION ».
  3. Montrer que \(\det(A) = 9 \times 3 - 4 \times 7 = -1\). En déduire que \(A\) est inversible et calculer \(A^{-1}\).
  4. Pour décrypter, on multiplie par \(A^{-1}\) modulo 26. Vérifier que \(A^{-1} \equiv \begin{pmatrix}23 & 4 \\ 7 & 17\end{pmatrix} \pmod{26}\). Décrypter le mot XQGY.
Correction

a. E=4, S=18. \(A\begin{pmatrix}4\\18\end{pmatrix} = \begin{pmatrix}9\times4 + 4\times18 \\ 7\times4 + 3\times18\end{pmatrix} = \begin{pmatrix}108\\82\end{pmatrix}\). Modulo 26 : \(108 = 4\times26 + 4\), \(82 = 3\times26 + 4\). On obtient \(\begin{pmatrix}4\\4\end{pmatrix}\) → EE.

b. ESPION = ES + PI + ON. ES → EE (ci-dessus). PION → LZWH (donné). Mot crypté : EELZWH.

c. \(\det(A) = 27 - 28 = -1 \neq 0\), donc \(A\) inversible. \(A^{-1} = \frac{1}{-1}\begin{pmatrix}3 & -4 \\ -7 & 9\end{pmatrix} = \begin{pmatrix}-3 & 4 \\ 7 & -9\end{pmatrix}\).

d. Modulo 26 : comme \(\det(A) = -1 \equiv 25 \pmod{26}\) et \(25^{-1} \equiv 25 \pmod{26}\) (car \(25 \times 25 = 625 = 24 \times 26 + 1\)), on a \(A^{-1} \equiv 25 \begin{pmatrix}3&-4\\-7&9\end{pmatrix} \equiv \begin{pmatrix}75&-100\\-175&225\end{pmatrix} \equiv \begin{pmatrix}23&4\\7&17\end{pmatrix} \pmod{26}\).

Pour XQGY (X=23, Q=16, G=6, Y=24) :

\(A^{-1}\begin{pmatrix}23\\16\end{pmatrix} = \begin{pmatrix}23\times 23 + 4\times 16\\ 7\times 23 + 17\times 16\end{pmatrix} = \begin{pmatrix}529+64\\ 161+272\end{pmatrix} = \begin{pmatrix}593\\ 433\end{pmatrix} \equiv \begin{pmatrix}21\\ 17\end{pmatrix} \pmod{26}\) → V, R.

\(A^{-1}\begin{pmatrix}6\\24\end{pmatrix} = \begin{pmatrix}138 + 96\\ 42 + 408\end{pmatrix} = \begin{pmatrix}234\\ 450\end{pmatrix} \equiv \begin{pmatrix}0\\ 8\end{pmatrix} \pmod{26}\) → A, I.

Mot décrypté : VRAI.

9

Navigation web et matrice stochastique

Adapté du Bac TS Spé — Amérique du Sud, novembre 2013

Matrice 3×3 et distribution stationnaire

Un site web est composé de 3 pages reliées par des liens hypertextes. Les probabilités de transition sont :

  • Depuis la page 1 : page 2 avec probabilité \(\frac{1}{4}\), page 3 avec probabilité \(\frac{3}{4}\).
  • Depuis la page 2 : page 1 avec \(\frac{1}{2}\), page 2 avec \(\frac{1}{4}\), page 3 avec \(\frac{1}{4}\).
  • Depuis la page 3 : page 1 avec \(\frac{1}{2}\), page 2 avec \(\frac{1}{4}\), page 3 avec \(\frac{1}{4}\).

On note \(U_n = \begin{pmatrix}a_n \\ b_n \\ c_n\end{pmatrix}\) le vecteur des probabilités après \(n\) navigations.

  1. Montrer que \(a_{n+1} = \frac{1}{2}b_n + \frac{1}{2}c_n\).
  2. Écrire la matrice de transition \(M\) telle que \(U_{n+1} = MU_n\). En déduire \(U_n = M^n U_0\).
  3. Trouver la distribution stationnaire \(U = \begin{pmatrix}x\\y\\z\end{pmatrix}\) telle que \(MU = U\) et \(x+y+z = 1\).
  4. Interpréter : à long terme, quels pourcentages de fréquentation pour chaque page ?
Correction

a. La page 1 n’est accessible que depuis les pages 2 et 3, chacune avec probabilité \(\frac{1}{2}\). Donc \(a_{n+1} = \frac{1}{2}b_n + \frac{1}{2}c_n\).

b. \(M = \begin{pmatrix}0 & 1/2 & 1/2 \\ 1/4 & 1/4 & 1/4 \\ 3/4 & 1/4 & 1/4\end{pmatrix}\). Par récurrence : \(U_0 = M^0 U_0\) ✓, et si \(U_n = M^n U_0\), alors \(U_{n+1} = MU_n = M^{n+1}U_0\) ✓.

c. \(MU = U\) donne le système : \(\frac{1}{2}y + \frac{1}{2}z = x\), \(\frac{1}{4}x + \frac{1}{4}y + \frac{1}{4}z = y\), \(\frac{3}{4}x + \frac{1}{4}y + \frac{1}{4}z = z\), avec \(x+y+z=1\). De la 2\textsuperscript{e} ligne : \(\frac{1}{4}(x+z) = \frac{3}{4}y\), soit \(x+z = 3y\). Avec \(x+y+z=1\) : \(4y = 1\), \(y = \frac{1}{4}\). De la 1\textsuperscript{re} ligne : \(x = \frac{1}{2}(y+z) = \frac{1}{2}(1-x)\), soit \(x = \frac{1}{3}\). Enfin \(z = 1 - \frac{1}{3} - \frac{1}{4} = \frac{5}{12}\).

d. À long terme : page 1 ≈ 33%, page 2 = 25%, page 3 ≈ 42%. La page 3 est la plus fréquentée.