Cvičný test 3

Čas: 60 minut
Celkem: 20 bodů
Bodování: 1) 3b   2) 3b   3) 3b   4) 5b   5) 3b   6) 3b
60:00

Otázka 1 — Slovní úloha (3 body)

Investor rozděluje $100\,000$ Kč mezi tři typy investic. První přináší roční výnos $5\%$, druhá $8\%$ a třetí $12\%$. Do třetí investice vloží o $10\,000$ Kč více než do první. Celkový roční výnos má být $8\,600$ Kč. Kolik vloží do každé investice?

Krok 1: Sestavení soustavy

Označme $x_1, x_2, x_3$ investované částky (v tisících Kč).

$$\begin{aligned} x_1 + x_2 + x_3 &= 100 \quad \text{(celkem)} \\ 0{,}05x_1 + 0{,}08x_2 + 0{,}12x_3 &= 8{,}6 \quad \text{(výnos)} \\ x_3 - x_1 &= 10 \quad \text{(podmínka)} \end{aligned}$$

Druhou rovnici vynásobíme 100:

$$\begin{aligned} x_1 + x_2 + x_3 &= 100 \\ 5x_1 + 8x_2 + 12x_3 &= 860 \\ -x_1 + 0x_2 + x_3 &= 10 \end{aligned}$$
Krok 2: Gaussova eliminace
$$\left(\begin{array}{ccc|c} 1 & 1 & 1 & 100 \\ 5 & 8 & 12 & 860 \\ -1 & 0 & 1 & 10 \end{array}\right)$$

$R_2 \leftarrow R_2 - 5R_1$, $R_3 \leftarrow R_3 + R_1$:

$$\left(\begin{array}{ccc|c} 1 & 1 & 1 & 100 \\ 0 & 3 & 7 & 360 \\ 0 & 1 & 2 & 110 \end{array}\right)$$

$R_2 \leftarrow R_2 - 3R_3$:

$$\left(\begin{array}{ccc|c} 1 & 1 & 1 & 100 \\ 0 & 0 & 1 & 30 \\ 0 & 1 & 2 & 110 \end{array}\right)$$

Prohodíme $R_2 \leftrightarrow R_3$:

$$\left(\begin{array}{ccc|c} 1 & 1 & 1 & 100 \\ 0 & 1 & 2 & 110 \\ 0 & 0 & 1 & 30 \end{array}\right)$$
Krok 3: Zpětná substituce

$x_3 = 30$

$x_2 + 60 = 110 \Rightarrow x_2 = 50$

$x_1 + 50 + 30 = 100 \Rightarrow x_1 = 20$

Výsledek

Do první investice: 20 000 Kč, do druhé: 50 000 Kč, do třetí: 30 000 Kč.

Ověření: $30 - 20 = 10$ (OK), $0{,}05 \cdot 20 + 0{,}08 \cdot 50 + 0{,}12 \cdot 30 = 1 + 4 + 3{,}6 = 8{,}6$ tis. Kč.

Otázka 2 — Soustava s parametrickým řešením (3 body)

Řešte soustavu lineárních rovnic:

$$\begin{aligned} x_1 + 2x_2 - x_3 + x_4 &= 3 \\ 2x_1 + 4x_2 + x_3 - 2x_4 &= 1 \\ 3x_1 + 6x_2 - 4x_3 + 4x_4 &= 10 \end{aligned}$$
Krok 1: Rozšířená matice soustavy
$$\left(\begin{array}{cccc|c} 1 & 2 & -1 & 1 & 3 \\ 2 & 4 & 1 & -2 & 1 \\ 3 & 6 & -4 & 4 & 10 \end{array}\right)$$
Krok 2: GEM

$R_2 \leftarrow R_2 - 2R_1$, $R_3 \leftarrow R_3 - 3R_1$:

$$\left(\begin{array}{cccc|c} 1 & 2 & -1 & 1 & 3 \\ 0 & 0 & 3 & -4 & -5 \\ 0 & 0 & -1 & 1 & 1 \end{array}\right)$$

$R_3 \leftarrow 3R_3 + R_2$:

$$\left(\begin{array}{cccc|c} 1 & 2 & -1 & 1 & 3 \\ 0 & 0 & 3 & -4 & -5 \\ 0 & 0 & 0 & -1 & -2 \end{array}\right)$$
Krok 3: Zpětná substituce

Hodnost matice je 3, máme 4 neznámé — $x_2$ je volná proměnná. Položme $x_2 = t$, $t \in \mathbb{R}$.

$-x_4 = -2 \Rightarrow x_4 = 2$

$3x_3 - 8 = -5 \Rightarrow 3x_3 = 3 \Rightarrow x_3 = 1$

$x_1 + 2t - 1 + 2 = 3 \Rightarrow x_1 = 2 - 2t$

Výsledek

Soustava má nekonečně mnoho řešení závislých na parametru $t \in \mathbb{R}$:

$$\vec{x} = \begin{pmatrix} 2 \\ 0 \\ 1 \\ 2 \end{pmatrix} + t \begin{pmatrix} -2 \\ 1 \\ 0 \\ 0 \end{pmatrix}, \quad t \in \mathbb{R}$$

Otázka 3 — Cramerovo pravidlo (3 body)

Pomocí Cramerova pravidla řešte soustavu:

$$\begin{aligned} 2x + y - z &= 3 \\ x - y + 2z &= -1 \\ 3x + 2y + z &= 4 \end{aligned}$$
Krok 1: Determinant matice soustavy
$$D = \begin{vmatrix} 2 & 1 & -1 \\ 1 & -1 & 2 \\ 3 & 2 & 1 \end{vmatrix}$$ $$= 2(-1-4) - 1(1-6) + (-1)(2+3)$$ $$= 2(-5) - 1(-5) - 5 = -10 + 5 - 5 = -10$$
Krok 2: Determinanty $D_x, D_y, D_z$
$$D_x = \begin{vmatrix} 3 & 1 & -1 \\ -1 & -1 & 2 \\ 4 & 2 & 1 \end{vmatrix} = 3(-1-4) - 1(-1-8) + (-1)(-2+4)$$ $$= -15 + 9 - 2 = -8$$ $$D_y = \begin{vmatrix} 2 & 3 & -1 \\ 1 & -1 & 2 \\ 3 & 4 & 1 \end{vmatrix} = 2(-1-8) - 3(1-6) + (-1)(4+3)$$ $$= -18 + 15 - 7 = -10$$ $$D_z = \begin{vmatrix} 2 & 1 & 3 \\ 1 & -1 & -1 \\ 3 & 2 & 4 \end{vmatrix} = 2(-4+2) - 1(4+3) + 3(2+3)$$ $$= -4 - 7 + 15 = 4$$
Krok 3: Výpočet neznámých
$$x = \frac{D_x}{D} = \frac{-8}{-10} = \frac{4}{5}$$ $$y = \frac{D_y}{D} = \frac{-10}{-10} = 1$$ $$z = \frac{D_z}{D} = \frac{4}{-10} = -\frac{2}{5}$$
Výsledek
$$x = \frac{4}{5}, \quad y = 1, \quad z = -\frac{2}{5}$$

Otázka 4 — Složené lineární zobrazení (5 bodů)

Jsou dána lineární zobrazení $f: \mathbb{R}^2 \to \mathbb{R}^3$ a $g: \mathbb{R}^3 \to \mathbb{R}^2$ s maticemi ve standardních bázích:

$$\mathbf{F} = \begin{pmatrix} 1 & 2 \\ -1 & 0 \\ 3 & 1 \end{pmatrix}, \qquad \mathbf{G} = \begin{pmatrix} 2 & 0 & 1 \\ -1 & 3 & 2 \end{pmatrix}$$

a) Najděte matici složeného zobrazení $g \circ f$.

b) Najděte $(g \circ f)(1, -1)^T$.

c) Je zobrazení $g \circ f$ invertibilní?

Krok 1 (a): Matice složeného zobrazení

Matice $g \circ f$ je součin $\mathbf{G} \cdot \mathbf{F}$:

$$\mathbf{G} \cdot \mathbf{F} = \begin{pmatrix} 2 & 0 & 1 \\ -1 & 3 & 2 \end{pmatrix} \begin{pmatrix} 1 & 2 \\ -1 & 0 \\ 3 & 1 \end{pmatrix}$$ $$= \begin{pmatrix} 2+0+3 & 4+0+1 \\ -1-3+6 & -2+0+2 \end{pmatrix} = \begin{pmatrix} 5 & 5 \\ 2 & 0 \end{pmatrix}$$
Krok 2 (b): Obraz vektoru
$$(g \circ f)(1, -1)^T = \begin{pmatrix} 5 & 5 \\ 2 & 0 \end{pmatrix} \begin{pmatrix} 1 \\ -1 \end{pmatrix} = \begin{pmatrix} 0 \\ 2 \end{pmatrix}$$
Krok 3 (c): Invertibilita

$\det(\mathbf{G}\mathbf{F}) = 5 \cdot 0 - 5 \cdot 2 = -10 \neq 0$

Determinant je nenulový, matice je regulární, zobrazení $g \circ f: \mathbb{R}^2 \to \mathbb{R}^2$ je invertibilní.

Inverzní matice:

$$(g \circ f)^{-1} = \frac{1}{-10}\begin{pmatrix} 0 & -5 \\ -2 & 5 \end{pmatrix} = \begin{pmatrix} 0 & \frac{1}{2} \\ \frac{1}{5} & -\frac{1}{2} \end{pmatrix}$$
Výsledek

a) Matice $g \circ f$: $\begin{pmatrix} 5 & 5 \\ 2 & 0 \end{pmatrix}$

b) $(g \circ f)(1,-1)^T = (0, 2)^T$

c) Ano, $g \circ f$ je invertibilní ($\det = -10 \neq 0$).

Otázka 5 — Inverzní matice (3 body)

Najděte inverzní matici k matici:

$$\mathbf{A} = \begin{pmatrix} 1 & 1 & 2 \\ 1 & 2 & 3 \\ 1 & 1 & 4 \end{pmatrix}$$
Krok 1: Sestavení rozšířené matice $(\mathbf{A} | \mathbf{E})$
$$\left(\begin{array}{ccc|ccc} 1 & 1 & 2 & 1 & 0 & 0 \\ 1 & 2 & 3 & 0 & 1 & 0 \\ 1 & 1 & 4 & 0 & 0 & 1 \end{array}\right)$$
Krok 2: Eliminace pod hlavní diagonálou

$R_2 \leftarrow R_2 - R_1$, $R_3 \leftarrow R_3 - R_1$:

$$\left(\begin{array}{ccc|ccc} 1 & 1 & 2 & 1 & 0 & 0 \\ 0 & 1 & 1 & -1 & 1 & 0 \\ 0 & 0 & 2 & -1 & 0 & 1 \end{array}\right)$$
Krok 3: Eliminace nad hlavní diagonálou

$R_3 \leftarrow \frac{1}{2}R_3$:

$$\left(\begin{array}{ccc|ccc} 1 & 1 & 2 & 1 & 0 & 0 \\ 0 & 1 & 1 & -1 & 1 & 0 \\ 0 & 0 & 1 & -\frac{1}{2} & 0 & \frac{1}{2} \end{array}\right)$$

$R_2 \leftarrow R_2 - R_3$, $R_1 \leftarrow R_1 - 2R_3$:

$$\left(\begin{array}{ccc|ccc} 1 & 1 & 0 & 2 & 0 & -1 \\ 0 & 1 & 0 & -\frac{1}{2} & 1 & -\frac{1}{2} \\ 0 & 0 & 1 & -\frac{1}{2} & 0 & \frac{1}{2} \end{array}\right)$$

$R_1 \leftarrow R_1 - R_2$:

$$\left(\begin{array}{ccc|ccc} 1 & 0 & 0 & \frac{5}{2} & -1 & -\frac{1}{2} \\ 0 & 1 & 0 & -\frac{1}{2} & 1 & -\frac{1}{2} \\ 0 & 0 & 1 & -\frac{1}{2} & 0 & \frac{1}{2} \end{array}\right)$$
Výsledek
$$\mathbf{A}^{-1} = \begin{pmatrix} \frac{5}{2} & -1 & -\frac{1}{2} \\ -\frac{1}{2} & 1 & -\frac{1}{2} \\ -\frac{1}{2} & 0 & \frac{1}{2} \end{pmatrix}$$

Ověření: $\mathbf{A} \cdot \mathbf{A}^{-1} = \mathbf{E}$.

Otázka 6 — Determinant s parametrem (3 body)

Spočítejte determinant matice v závislosti na parametru $t$ a najděte hodnoty $t$, pro které je determinant nulový:

$$\begin{vmatrix} t & 1 & 0 & 0 \\ 0 & t & 1 & 0 \\ 0 & 0 & t & 1 \\ 1 & 0 & 0 & t \end{vmatrix}$$
Krok 1: Rozvoj podle prvního sloupce

V prvním sloupci jsou nenulové pouze prvky na pozicích $(1,1)$ a $(4,1)$:

$$= t \cdot \begin{vmatrix} t & 1 & 0 \\ 0 & t & 1 \\ 0 & 0 & t \end{vmatrix} + (-1)^{4+1} \cdot 1 \cdot \begin{vmatrix} 1 & 0 & 0 \\ t & 1 & 0 \\ 0 & t & 1 \end{vmatrix}$$
Krok 2: Výpočet subdeterminantů

První subdeterminant — horní trojúhelníková matice:

$$\begin{vmatrix} t & 1 & 0 \\ 0 & t & 1 \\ 0 & 0 & t \end{vmatrix} = t^3$$

Druhý subdeterminant — dolní trojúhelníková matice:

$$\begin{vmatrix} 1 & 0 & 0 \\ t & 1 & 0 \\ 0 & t & 1 \end{vmatrix} = 1$$
Krok 3: Celkový determinant
$$\det = t \cdot t^3 + (-1) \cdot 1 = t^4 - 1$$
Krok 4: Řešení $t^4 - 1 = 0$
$$t^4 = 1 \Rightarrow t = \pm 1$$

(V reálných číslech. Nad $\mathbb{C}$ by platilo také $t = \pm i$.)

Výsledek

$\det = t^4 - 1$. Determinant je nulový pro $t = 1$ a $t = -1$.