uni/optimierung/Uebungsblatt1.tex

157 lines
6.9 KiB
TeX

\documentclass[10pt,a4paper,oneside,ngerman,numbers=noenddot]{scrartcl}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[ngerman]{babel}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{paralist}
\usepackage{gauss}
\usepackage{pgfplots}
\usepackage[locale=DE,exponent-product=\cdot,detect-all]{siunitx}
\usepackage{tikz}
\usetikzlibrary{matrix,fadings,calc,positioning,decorations.pathreplacing,arrows,decorations.markings}
\usepackage{polynom}
\polyset{style=C, div=:,vars=x}
\pgfplotsset{compat=1.8}
\pagenumbering{arabic}
\def\thesection{\arabic{section})}
\def\thesubsection{\alph{subsection})}
\def\thesubsubsection{(\roman{subsubsection})}
\makeatletter
\renewcommand*\env@matrix[1][*\c@MaxMatrixCols c]{%
\hskip -\arraycolsep
\let\@ifnextchar\new@ifnextchar
\array{#1}}
\makeatother
\begin{document}
\author{Jan Branitz (6326955), Jim Martens (6420323),\\
Stephan Niendorf (6242417)}
\title{Hausaufgaben zum 21. Oktober}
\maketitle
\section{} %1
\subsection{} %a
\subsubsection{} %i
Die Zielfunktion muss in Standardform maximiert werden. Um dies zu erreichen, wird mit $-1$ multipliziert. Die erste Nebenbedingung wird auf gleiche Weise umgeformt. Die dritte Nebenbedingung wird durch zwei Bedingungen ersetzt.
\begin{alignat*}{5}
\text{maximiere} -& 2x_{1} &-& x_{2} &+& x_{3} &-& 2x_{4} && \\
\multicolumn{10}{l}{\text{unter den Nebenbedingungen}} && \\
& 3x_{1} &+& x_{2} &-& x_{3} && &\leq & -2 \\
-& 7x_{1} &-& x_{2} && &+& x_{4} &\leq &\, 3 \\
& && x_{2} &+& x_{3} &-& x_{4} &\leq &\, 7 \\
& &-& x_{2} &-& x_{3} &+& x_{4} &\leq & -7 \\
\multicolumn{8}{r}{$x_{1}, x_{2}, x_{3}, x_{4}$} \,&\geq &\, 0
\end{alignat*}
\subsubsection{} %ii
Die erste Nebenbedingung wird mit $-1$ multipliziert. Auch wird die dritte Nebenbedingung durch zwei Bedingungen ersetzt. Da $x_{1}$ in der Nichtnegativitätsbedingung fehlt, werden zwei Variablen $x_{1}^{'}, x_{1}^{''}$ erzeugt, die je den positiven bzw. negativen Teil von $x_{1}$ darstellen.
\begin{alignat*}{6}
\text{maximiere}\; & 2x_{1}^{'} &-& 2x_{1}^{''} &+& x_{2} &-& x_{3} &+& 2x_{4} && \\
\multicolumn{12}{l}{\text{unter den Nebenbedingungen}} && \\
& 3x_{1}^{'} &-& 3x_{1}^{''} &+& x_{2} &-& x_{3} && &\leq & -2 \\
-& 7x_{1}^{'} &+& 7x_{1}^{''} &-& x_{2} && &+& x_{4} &\leq &\, 3 \\
& && && x_{2} &+& x_{3} &-& x_{4} &\leq &\, 7 \\
& && &-& x_{2} &-& x_{3} &+& x_{4} &\leq & -7 \\
& && && && && x_{4} &\leq & 9 \\
\multicolumn{10}{r}{$x_{1}^{'}, x_{1}^{''}, x_{2}, x_{3}, x_{4}$} \,&\geq &\, 0
\end{alignat*}
\subsection{} %b
Es gilt das folgende Problem mit der grafischen Methode zu lösen.
\begin{alignat*}{3}
\text{maximiere}\; & 2x_{1} &+& 5x_{2}&& \\
\multicolumn{6}{l}{\text{unter den Nebenbedingungen}} && \\
& 3x_{1} &-& 2x_{2} &\leq &\, 6 \\
& x_{1} &+& x_{2} &\leq &\, 6 \\
-& 2x_{1} &+& 6x_{2} &\leq &\, 18 \\
\multicolumn{4}{r}{$x_{1}, x_{2}$} \,&\geq &\, 0
\end{alignat*}
Nach Umstellen der Nebenbedingungen nach $x_{2}$ ergibt sich dieses:
\begin{alignat*}{3}
x_{2} &\geq & \frac{3}{2}x_{1} &-& 3 \\
x_{2} &\leq & -x_{1} &+& 6 \\
x_{2} &\leq & \frac{1}{3}x_{1} &+& 3
\end{alignat*}
Daraus lässt sich die Fläche aller gültigen Werte zeichnen.
\begin{tikzpicture}[>=stealth]
\begin{axis}[
ymin=0,ymax=7,
x=1cm,
y=1cm,
axis x line=middle,
axis y line=middle,
axis line style=->,
xlabel={$x_{1}$},
ylabel={$x_{2}$},
xmin=0,xmax=7
]
\addplot[no marks, black, -] expression[domain=2:6,samples=100]{1.5*x - 3} node[pos=0.65,anchor=north]{};
\addplot[no marks, black, -] expression[domain=0:6,samples=100]{-1*x + 6} node[pos=0.65,anchor=north]{};
\addplot[no marks, black, -] expression[domain=0:6,samples=100]{0.3333333333333*x + 3} node[pos=0.65,anchor=north]{};
\addplot[no marks, black, -] expression[domain=0:7,samples=100]{-0.4*x + 4.65} node[pos=0.65,anchor=north]{};
\node at (axis cs: 2.5,4.5) {(2.25,3.75)};
\node at (axis cs: 6,2) {z};
%\draw[>=stealth] (axis cs:1,0) -- (axis cs:1,-6) node [pos=0.65,anchor=north]{};
\end{axis}
\end{tikzpicture}\\
Das optimale Ergebnis kann folgendermaßen bestimmt werden:
\begin{alignat*}{5}
I &-&\; 2x_{1} &+& 6x_{2} &=& 18 && \;| + 2II\\
II &&\; x_{1} &+& x_{2} &=& 6 && \\
\overset{I+2II}{\Rightarrow} &&\; && 8x_{2} &=& 30 && \;| \cdot \frac{1}{8} \\
\Leftrightarrow &&\; && x_{2} &=& \frac{30}{8} = \frac{15}{4} &&
\intertext{Einsetzen in II}
\overset{II}{\Rightarrow} &&\; x_{1} &+& \frac{15}{4} &=& 6 &&\;| - \frac{15}{4} \\
&&\; x_{1} && &=& \frac{24}{4} - \frac{15}{4} = \frac{9}{4} &&
\end{alignat*}
Anhand der beiden $x$-Werte kann nun der Wert der Zielfunktion berechnet werden.
\[
2 \cdot \frac{9}{4} + 5 \cdot \frac{15}{4} = \frac{18}{4} + \frac{75}{4} = \frac{93}{4} = 23,25
\]
Damit ist $\frac{93}{4}$ das optimale Ergebnis für die Zielfunktion $2x_{1} + 5x_{2}$ unter den gegebenen Nebenbedingungen.
\section{} %2
\subsection{} %a
Pauls Diätproblem:\\
\begin{alignat*}{7}
\text{maximiere}\; -& 3x_{1} &-& 24x_{2} &-& 13x_{3} &-& 9x_{4} &-& 20x_{5} &-& 19x_{6} && \\
\multicolumn{14}{l}{\text{unter den Nebenbedingungen}} && \\
- & 110x_{1} &-& 205x_{2} &-& 160x_{3} &-& 160x_{4} &-& 420x_{5} &-& 260x_{6} &\leq & -2000 \\
-& 4x_{1} &-& 32x_{2} &-& 13x_{3} &-& 8x_{4} &-& 4x_{5} &-& 14x_{6} &\leq & -55 \\
-& 2x_{1} &-& 12x_{2} &-& 54x_{3} &-& 285x_{4} &-& 22x_{5} &-& 80x_{6} &\leq & -800 \\
& x_{1} && && && && && &\leq &\, 4 \\
& && x_{2} && && && && &\leq &\, 3 \\
& && && x_{3} && && && &\leq &\, 2 \\
& && && && x_{4} && && &\leq &\, 8 \\
& && && && && x_{5} && &\leq &\, 2 \\
& && && && && && x_{6} &\leq &\, 2 \\
\multicolumn{12}{r}{$x_{1}, x_{2}, x_{3}, x_{4}, x_{5}, x_{6}$} \,&\geq &\, 0
\end{alignat*}
Problem (1.2) in Standardform:\\
\begin{alignat*}{7}
\text{maximiere}\; & 3x_{1}^{'} &-& 3x_{1}^{''} &+& x_{2} && && && \\
\multicolumn{14}{l}{\text{unter den Nebenbedingungen}} && \\
& x_{1}^{'} &-& x_{1}^{''} &-& 6x_{2} &+& x_{3} &-& x_{4}^{'} &+& x_{4}^{''} &\leq &\, 3 \\
& && && 7x_{2} && &-& 2x_{4}^{'} &+& 2x_{4}^{''} &\leq &\, 5 \\
& && &-& 7x_{2} && &+& 2x_{4}^{'} &-& 2x_{4}^{''} &\leq & -5 \\
-& x_{1}^{'} &+& x_{1}^{''} &+& x_{2} &+& x_{3} && && &\leq &\, 1 \\
& x_{1}^{'} &-& x_{1}^{''} &-& x_{2} &-& x_{3} && && &\leq & -1 \\
& && && && x_{3} &-& x_{4}^{'} &+& x_{4}^{''} &\leq &\, 2 \\
\multicolumn{12}{r}{$x_{1}^{'}, x_{1}^{''}, x_{2}, x_{3}, x_{4}^{'}, x_{4}^{''}$} \,&\geq &\, 0
\end{alignat*}
\subsection{} %b
\begin{alignat*}{7}
\text{maximiere}\; & 8a_{1} &+& 3a_{2} &+& 6b_{1} &+& 3b_{2} &+& 9c_{1} &+& 5c_{2} && \\
\multicolumn{14}{l}{\text{unter den Nebenbedingungen}} && \\
& a_{1} &+& a_{2} && && && && &\leq &\, 400 \\
& && && b_{1} &+& b_{2} && && &\leq &\, 480 \\
& && && && && c_{1} &+& c_{2} &\leq &\, 230 \\
& a_{1} && &+& b_{1} && &+& c_{1} && &\leq &\, 420 \\
& && a_{2} && &+& b_{2} && &+& c_{2} &\leq &\, 250 \\
\multicolumn{12}{r}{$a_{1}, a_{2}, b_{1}, b_{2}, c_{1}, c_{2}$} \,&\geq &\, 0
\end{alignat*}
\end{document}