2
0
Fork 0
mirror of https://github.com/MartinThoma/LaTeX-examples.git synced 2025-04-26 06:48:04 +02:00

Peters Änderungsvorschläge eingepflegt

This commit is contained in:
Martin Thoma 2013-09-11 17:27:22 +02:00
parent f6dd0c9104
commit b2870f7dce
10 changed files with 168 additions and 155 deletions

View file

@ -13,19 +13,24 @@
\textbf{Lösung:}
\[P =
\begin{pmatrix}
0 & 1 & 0 \\
1 & 0 & 0 \\
0 & 0 & 1
\end{pmatrix}\]
durch scharfes hinsehen.
Nun $L, R$ berechnen:
\begin{align}
&\begin{gmatrix}[p]
\begin{align*}
&
&
A^{(0)} &= \begin{gmatrix}[p]
3 & 15 & 13 \\
6 & 6 & 6 \\
2 & 8 & 19
\rowops
\swap{0}{1}
\end{gmatrix}
&\\
P^{(1)} &= \begin{pmatrix}
0 & 1 & 0\\
1 & 0 & 0\\
0 & 0 & 1
\end{pmatrix},
&
A^{(1)} &= \begin{gmatrix}[p]
6 & 6 & 6 \\
3 & 15 & 13 \\
2 & 8 & 19
@ -33,128 +38,48 @@ Nun $L, R$ berechnen:
\add[\cdot (-\frac{1}{2})]{0}{1}
\add[\cdot (-\frac{1}{3})]{0}{2}
\end{gmatrix}
\\
= \begin{pmatrix}
1 & 0 & 0 \\
-\frac{1}{2} & 1 & 0 \\
-\frac{1}{3} & 0 & 1
\end{pmatrix} \cdot
&\begin{gmatrix}[p]
&\\
L^{(2)} &= \begin{pmatrix}
1 & 0 & 0\\
-\frac{1}{2} & 1 & 0\\
-\frac{1}{3} & 0 & 1
\end{pmatrix},
&
A^{(2)} &= \begin{gmatrix}[p]
6 & 6 & 6 \\
0 & 12 & 10 \\
0 & 6 & 17
\rowops
\add[\cdot (-\frac{1}{2})]{1}{2}
\end{gmatrix}
\\
= \begin{pmatrix}
1 & 0 & 0 \\
0 & 1 & 0 \\
0 & -\frac{1}{2} & 1
\end{pmatrix} \cdot
\begin{pmatrix}
1 & 0 & 0 \\
-\frac{1}{2} & 1 & 0 \\
-\frac{1}{3} & 0 & 1
\end{pmatrix} \cdot
&\begin{gmatrix}[p]
&\\
L^{(3)} &= \begin{pmatrix}
1 & 0 & 0\\
0 & 1 & 0\\
0 & -\frac{1}{2} & 1
\end{pmatrix},
&
A^{(3)} &= \begin{gmatrix}[p]
6 & 6 & 6 \\
0 & 12 & 10 \\
0 & 0 & 12
\colops
\add[\cdot (-1)]{0}{1}
\add[\cdot (-1)]{0}{2}
\end{gmatrix}
\\
= \begin{pmatrix}
1 & 0 & 0 \\
-\frac{1}{2} & 1 & 0 \\
-\frac{1}{12} & - \frac{1}{2} & 1
\end{pmatrix} \cdot
&\begin{gmatrix}[p]
6 & 0 & 0 \\
0 & 12 & 10 \\
0 & 0 & 12
\colops
\add[\cdot (-\frac{10}{12})]{1}{2}
\end{gmatrix}
\cdot
\begin{pmatrix}
1 & -1 & -1 \\
0 & 1 & 0 \\
0 & 0 & 1
\end{align*}
Es gilt:
\begin{align}
L^{(3)} \cdot L^{(2)} \cdot \underbrace{P^{(1)}}_{=: P} \cdot A^{0} &= \underbrace{A^{(3)}}_{=: R}\\
\Leftrightarrow P A &= (L^{(3)} \cdot L^{(2)})^{-1} \cdot R \\
\Rightarrow L &= (L^{(3)} \cdot L^{(2)})^{-1}\\
&= \begin{pmatrix}
1 & 0 & 0\\
\frac{1}{2} & 1 & 0\\
\frac{1}{3} & \frac{1}{2} & 1
\end{pmatrix}
\\
= \begin{pmatrix}
1 & 0 & 0 \\
-\frac{1}{2} & 1 & 0 \\
-\frac{1}{12} & - \frac{1}{2} & 1
\end{pmatrix} \cdot
&\begin{gmatrix}[p]
6 & 0 & 0 \\
0 & 12 & 0 \\
0 & 0 & 12
\colops
\mult{0}{\cdot \frac{1}{6}}
\mult{1}{\cdot \frac{1}{12}}
\mult{2}{\cdot \frac{1}{12}}
\end{gmatrix}
\cdot
\begin{pmatrix}
1 & -1 & -1 \\
0 & 1 & 0 \\
0 & 0 & 1
\end{pmatrix}
\cdot
\begin{pmatrix}
1 & 0 & 0 \\
0 & 1 & -\frac{10}{12} \\
0 & 0 & 1
\end{pmatrix}
\\
= \begin{pmatrix}
1 & 0 & 0 \\
-\frac{1}{2} & 1 & 0 \\
-\frac{1}{12} & - \frac{1}{2} & 1
\end{pmatrix} \cdot
&\begin{gmatrix}[p]
1 & 0 & 0 \\
0 & 1 & 0 \\
0 & 0 & 1
\end{gmatrix}
\cdot
\begin{pmatrix}
1 & -1 & -\frac{1}{6} \\
0 & 1 & -\frac{5}{6} \\
0 & 0 & 1
\end{pmatrix}
\cdot
\begin{pmatrix}
\frac{1}{6} & 0 & 0 \\
0 & \frac{1}{12} & 0 \\
0 & 0 & \frac{1}{12}
\end{pmatrix}
\\
= \underbrace{\begin{pmatrix}
1 & 0 & 0 \\
-\frac{1}{2} & 1 & 0 \\
-\frac{1}{12} & - \frac{1}{2} & 1
\end{pmatrix}}_L \cdot
&\begin{gmatrix}[p]
1 & 0 & 0 \\
0 & 1 & 0 \\
0 & 0 & 1
\end{gmatrix}
\cdot \underbrace{\frac{1}{72}
\begin{pmatrix}
12 & -6 & -1 \\
0 & 6 & -5 \\
0 & 0 & 6
\end{pmatrix}}_R
\end{align}
ACHTUNG: Ich habe mich irgendwo verrechnet!
Siehe \href{http://www.wolframalpha.com/input/?i=%7B%7B1%2C0%2C0%7D%2C%7B-1%2F2%2C1%2C0%7D%2C%7B-1%2F12%2C-1%2F2%2C1%7D%7D*%7B%7B12%2C-6%2C-1%7D%2C%7B0%2C6%2C-5%7D%2C%7B0%2C0%2C6%7D%7D}{WolframAlpha}
Nun gilt: $P A = L R = A^{(1)}$ (Kontrolle mit \href{http://www.wolframalpha.com/input/?i=%7B%7B1%2C0%2C0%7D%2C%7B0.5%2C1%2C0%7D%2C%7B1%2F3%2C0.5%2C1%7D%7D*%7B%7B6%2C6%2C6%7D%2C%7B0%2C12%2C10%7D%2C%7B0%2C0%2C12%7D%7D}{Wolfram|Alpha})
\subsection*{Teilaufgabe b}
@ -182,7 +107,7 @@ Falls $A$ symmetrisch ist, gilt:
& \Leftrightarrow \text{es gibt eine Cholesky-Zerlegung $A=GG^T$ mit $G$ ist reguläre untere Dreiecksmatrix}\\
\end{align*}
Mit dem Hauptminor-Kriterium gilt:
\subsubsection*{Lösung 1: Hauptminor-Kriterium}
\begin{align}
\det(A_1) &= 9 > 0\\
@ -193,3 +118,15 @@ Mit dem Hauptminor-Kriterium gilt:
\end{vmatrix} = 9 - 16 < 0\\
&\Rightarrow \text{$A$ ist nicht positiv definit}
\end{align}
\subsubsection*{Lösung 2: Cholesky-Zerlegung}
\begin{align}
l_{11} &= \sqrt{a_{11}} = 3\\
l_{21} &= \frac{a_{21}}{l_{11}} = \frac{4}{3}\\
l_{31} &= \frac{a_{31}}{l_{11}} = 4\\
l_{22} &= \sqrt{a_{21} - {l_{21}}^2} = \frac{2 \sqrt{5}}{3}\\
\dots
\end{align}
ACHTUNG: Noch nicht fertig! Irgendwo muss was negatives unter einer
Wurzel kommen!

View file

@ -7,43 +7,35 @@ wobei $L$ eine invertierbare, untere Dreiecksmatrix ist.
Geben Sie die Formel zur Berechnung von $y_i$ an.
\textbf{Lösung:} TODO! %TODO!
\textbf{Lösung:}
\[y_i = \frac{b_i - \sum_{k=i}^{i-1} l_{ik} \cdot y_k}{l_{ii}}\]
\subsection*{Teilaufgabe b}
\[Ax = b ? PAx = Pb ? LRx = Pb \]
Pseudocode:
\begin{algorithm}[H]
\begin{algorithmic}
\Require $p \in \mathbb{P}, a \in \mathbb{Z}, p \geq 3$
\Procedure{CalculateLegendre}{$a$, $p$}
\If{$a \geq p$ or $a < 0$}\Comment{rule (III)}
\State \Return $\Call{CalculateLegendre}{a \mod p, p}$ \Comment{now: $a \in [0, \dots, p-1]$}
\ElsIf{$a == 0$ or $a == 1$}
\State \Return $a$ \Comment{now: $a \in [2, \dots, p-1]$}
\ElsIf{$a == 2$} \Comment{rule (VII)}
\If{$p \equiv \pm 1 \mod 8$}
\State \Return 1
\Else
\State \Return -1
\EndIf \Comment{now: $a \in [3, \dots, p-1]$}
\ElsIf{$a == p-1$} \Comment{rule (VI)}
\If{$p \equiv 1 \mod 4$}
\State \Return 1
\Else
\State \Return -1
\EndIf \Comment{now: $a \in [3, \dots, p-2]$}
\ElsIf{!$\Call{isPrime}{a}$} \Comment{rule (II)}
\State $p_1, p_2, \dots, p_n \gets \Call{Factorize}{a}$
\State \Return $\prod_{i=1}^n \Call{CalculateLegendre}{p_i, p}$
\Else \Comment{now: $a \in \mathbb{P}, \sqrt{p-2} \geq a \geq 3$}
\If{$\frac{p-1}{2} \equiv 0 \mod 2$ or $\frac{a-1}{2} \equiv 0 \mod 2$}
\State \Return $\Call{CalculateLegendre}{p, a}$
\Else
\State \Return $(-1) \cdot \Call{CalculateLegendre}{p, a}$
\EndIf
\EndIf
\Require Matrix $A$, Vektor $b$
\Procedure{CalculateLegendre}{$A$, $b$}
\State $P, L, R \gets \Call{LRZerlegung}{A}$
\State $b^* \gets Pb$
\State $c \gets \Call{VorwärtsSubstitution}{L, b^*}$
\State $x \gets \Call{RückwärtsSubstitution}{R, c}$
\State \Return $x$
\EndProcedure
\end{algorithmic}
\caption{Calculate Legendre symbol}
\label{alg:calculateLegendreSymbol}
\caption{Calculate TODO}
\label{alg:TODO}
\end{algorithm}
\subsection*{Teilaufgabe b}
\subsection*{Teilaufgabe c}
Der Gesamtaufwand ist:
\begin{itemize}
\item LR-Zerlegung, $\frac{1}{3}n^3 - \frac{1}{3} n^2$
\item Vektormultiplikation, $2n$
\item Vorwärtssubstitution, $\frac{1}{2} n^2$
\item Rückwärtssubstitution, $\frac{1}{2} n^2$
\end{itemize}

View file

@ -1 +1,20 @@
\section*{Aufgabe 3}
\[f' (x,y) = \begin{pmatrix}
3 & \cos y\\
3 x^2 & e^y
\end{pmatrix}\]
Und jetzt die Berechnung
\[f'(x, y) \cdot (x_0, y_0) = f(x,y)\]
LR-Zerlegung für $f'(x, y)$:
\begin{align}
L &= \begin{pmatrix}1 &0 \\ \frac{1}{9} & 1\end{pmatrix}\\
R &= \begin{pmatrix}3 & \cos y \\ 0 & e^y - x^2 \cos y\end{pmatrix}\\
P &= I_2\\
-f ( \frac{-1}{3}, 0) &= \begin{pmatrix} 2\\ -\frac{1}{27}\end{pmatrix}\\
c &= \begin{pmatrix} 2\\ \frac{7}{27} \end{pmatrix}\\
(x_1, y_1) &= \begin{pmatrix} \frac{5}{3}\\ \frac{7}{27}\end{pmatrix}
\end{align}

View file

@ -1 +1,7 @@
\section*{Aufgabe 5}
\subsection*{Teilaufgabe a}
Die Ordnung $n$ einer Quadraturformel gibt an, dass diese Polynome
bis zum Grad $\leq n - 1$ exakt löst.
\subsection*{Teilaufgabe b}
\subsection*{Teilaufgabe c}