1) a)
$\dfrac{\partial f}{\partial x}=2(x-2)+2(x-2y^2)=0\qquad (1)$
$\dfrac{\partial f}{\partial y}=2(x-2y^2)(-4y)=0\qquad (2)$
$(2)\Longrightarrow y=0$ veya $x=2y^2$
$(1)\Longrightarrow y=0$ ise $2(x-2)+2(x)=0 \Longrightarrow x=1$
$(1)\Longrightarrow x=y^2$ icin cozum yok. O zaman kritik noktalarimiz
$(2)\, x=1 \Longrightarrow 2(1-2y^2)(-4y)=0\Longrightarrow y=0$ veya $y\mp\dfrac{\sqrt{2}}{2}$
$(1)\, x=1 \Longrightarrow 2(1-2)+2(1-2y^2)=0\Longrightarrow y=0$
$(1,0),(1,\dfrac{\sqrt{2}}{2}),(1,-\dfrac{\sqrt{2}}{2})$ olur.
2) $V=\pi r^2 h=20\pi$. Maliyet $M$ olsun. O zaman
$M=(2\pi r^2)10+(2\pi r h)8$ olur. Mailyeti minimize etmemiz lazim. Oncelikle yukaridaki iliskiyi kullanarak bir $M$'yi bir degiskene dusurelim.
$\pi r^2 h=20\pi \Longrightarrow h=\dfrac{20}{r^2}$, $M$'de yerine koyalaim.
$M=(2\pi r^2)10+(2\pi r\dfrac{20}{r^2})8=20\pi r^2+ \dfrac{320\pi}{r}$
$\dfrac{dM}{dr}=40\pi r-\dfrac{320\pi}{r^2}=0$
$\dfrac{40\pi r^3-320\pi}{r^2}=0\Longrightarrow 40\pi r^3-320\pi=0\Longrightarrow r^3=8\Longrightarrow r=2$. $r=2$'nin gercekten maliyeti minimize eden deger oldugunu gostermek icin $M''(2)$ isaretine bakilabilir veya birinci turevde tablo yapilabilir ($r=0$'i da goz onune alarak). Bunu size birakiyorum.
$h=\dfrac{20}{2^2}=5$
3) Once Newton metodunu 1 degiskenli fonksiyonlar icin hatirlayalim. Newton methodu, $x_0$ noktasini baslangic olarak alan ve itarasyon ile $f(x)=0$ fonsiyonun kokunu bulan bir metod.
$x_{n+1}=x_n-\dfrac{f(x_n)}{f'(x_n)}\qquad n=0,1,\dots$
$n=0:\qquad x_{1}=x_0-\dfrac{f(x_0)}{f'(x_0)}$
Cok degiskenlilerde ise formul su haldedir. $J=\left[
\begin{array}{ccc}
\dfrac{\partial f_1}{\partial x_1} & \dots & \dfrac{\partial f_1}{\partial x_N} \\
\vdots & \ddots & \vdots \\
\dfrac{\partial f_N}{\partial x_1} & \dots & \dfrac{\partial f_N}{\partial x_N}\\
\end{array}
\right]$ Jacobian matrix olmak uzere
$\mathbf{x}_{n+1}=\mathbf{x}_{n}-J(\mathbf{x}_{n})^{-1}f(\mathbf{x}_{n})$ dir.
2 degiskenliler icin yazalim.
$\left[
\begin{array}{c}
x_{n+1} \\
y_{n+1} \\
\end{array}
\right]=\left[
\begin{array}{c}
x_{n} \\
y_{n} \\
\end{array}
\right]-\left[
\begin{array}{cc}
\dfrac{\partial f_1}{\partial x}( x_{n}) & \dfrac{\partial f_1}{\partial y}( x_{n}) \\
\dfrac{\partial f_2}{\partial x}(y_{n}) & \dfrac{\partial f_2}{\partial y}( y_{n}) \\
\end{array}
\right]^{-1}\left[
\begin{array}{c}
f_1( x_{n}) \\
f_2(y_{n}) \\
\end{array}
\right]$
Sizin sorunuza gelince, $(x_0,y_0)=(1,1)$
$F(x,y)=\left[
\begin{array}{c}
f_1(x,y) \\
f_2(x,y) \\
\end{array}
\right]=\left[
\begin{array}{c}
x^2+y^2+3 \\
-2x^2-\dfrac{1}{2}y^2 +2\\
\end{array}
\right]$
$J=\left[
\begin{array}{cc}
\dfrac{\partial f_1}{\partial x} & \dfrac{\partial f_1}{\partial y} \\
\dfrac{\partial f_2}{\partial x} & \dfrac{\partial f_2}{\partial y} \\
\end{array}
\right]=\left[
\begin{array}{cc}
2x &2y \\
-4x & -y \\
\end{array}
\right]$
$J^{-1}=\left[
\begin{array}{cc}
-\dfrac{1}{6 x} & -\dfrac{1}{3 x} \\
\dfrac{2}{3 y} & \dfrac{1}{3 y} \\
\end{array}
\right]$
$\left[
\begin{array}{c}
x_{n+1} \\
y_{n+1} \\
\end{array}
\right]=\left[
\begin{array}{c}
x_{n} \\
y_{n} \\
\end{array}
\right]-\left[
\begin{array}{cc}
-\dfrac{1}{6 x}(x_n) & -\dfrac{1}{3 x} (x_n)\\
\dfrac{2}{3 y}(y_n) & \dfrac{1}{3 y}(y_n) \\
\end{array}
\right]\left[
\begin{array}{c}
f_1( x_{n}) \\
f_2(y_{n}) \\
\end{array}
\right]$
n=0: $(x_0,y_0)=(1,1)$
$\left[
\begin{array}{c}
x_{1} \\
y_{1} \\
\end{array}
\right]=\left[
\begin{array}{c}
x_0 \\
y_0 \\
\end{array}
\right]-\left[
\begin{array}{cc}
-\dfrac{1}{6 x}(x_0,y_0) & -\dfrac{1}{3 x} (x_0,y_0)\\
\dfrac{2}{3 y}(x_0,y_0) & \dfrac{1}{3 y}(x_0,y_0) \\
\end{array}
\right]\left[
\begin{array}{c}
f_1( x_0,y_0) \\
f_2(x_0,y_0) \\
\end{array}
\right]$
$\left[
\begin{array}{c}
x_{1} \\
y_{1} \\
\end{array}
\right]=\left[
\begin{array}{c}
1 \\
1 \\
\end{array}
\right]-\left[
\begin{array}{cc}
-\dfrac{1}{6 x}(1,1) & -\dfrac{1}{3 x} (1,1)\\
\dfrac{2}{3 y}(1,1) & \dfrac{1}{3 y}(1,1) \\
\end{array}
\right]\left[
\begin{array}{c}
f_1( 1,1) \\
f_2(1,1) \\
\end{array}
\right]$
$\left[
\begin{array}{c}
x_{1} \\
y_{1} \\
\end{array}
\right]=\left[
\begin{array}{c}
1 \\
1 \\
\end{array}
\right]-\left[
\begin{array}{cc}
-\dfrac{1}{6} & -\dfrac{1}{3} \\
\dfrac{2}{3} & \dfrac{1}{3} \\
\end{array}
\right]\left[
\begin{array}{c}
-1 \\
-\dfrac{1}{2} \\
\end{array}
\right]$
$\left[
\begin{array}{c}
x_{1} \\
y_{1} \\
\end{array}
\right]=\left[
\begin{array}{c}
1 \\
1 \\
\end{array}
\right]-\left[
\begin{array}{c}
\dfrac{1}{3} \\
-\dfrac{5}{6}\\
\end{array}
\right]$
$\left[
\begin{array}{c}
x_{1} \\
y_{1} \\
\end{array}
\right]=\left[
\begin{array}{c}
\dfrac{2}{3} \\
\dfrac{11}{6}\\
\end{array}
\right]$
Siyah noktada baslayip ilk iterasyonla magenta noktasina geldik, bence bir iterasyon icin cok iyi. Amacimiz en yakin kirmizi koktaya ulasmak.
Mathematica programi:
ClearAll["Global`*"]
val = Values@NSolve[{x^2 + y^2 - 3, -2 x^2 - y^2/2 + 2}, {x, y}];
F = {x^2 + y^2 - 3, -2 x^2 - y^2/2 + 2};
b = {x, y};
MatrixForm[J = Grad[F, b]];
MatrixForm[Jinv = Inverse[J]];
{x[0], y[0]} = {2, 1};
val2 = Prepend[Table[
{x[n + 1],
y[n + 1]} = {x[n],
y[n]} - (Jinv /. {x -> x[n], y -> y[n]}).(F /. {x -> x[n],
y -> y[n]}), {n, 0, 2}], {x[0], y[0]}] // N
{{2., 1.}, {1.08333, 1.83333}, {0.695513, 1.64394}, {0.587388, 1.63303}}