(************** Content-type: application/mathematica ************** CreatedBy='Mathematica 5.0' Mathematica-Compatible Notebook This notebook can be used with any Mathematica-compatible application, such as Mathematica, MathReader or Publicon. The data for the notebook starts with the line containing stars above. To get the notebook into a Mathematica-compatible application, do one of the following: * Save the data starting with the line of stars above into a file with a name ending in .nb, then open the file inside the application; * Copy the data starting with the line of stars above to the clipboard, then use the Paste menu command inside the application. Data for notebooks contains only printable 7-bit ASCII and can be sent directly in email or through ftp in text mode. Newlines can be CR, LF or CRLF (Unix, Macintosh or MS-DOS style). NOTE: If you modify the data for this notebook not in a Mathematica- compatible application, you must delete the line below containing the word CacheID, otherwise Mathematica-compatible applications may try to use invalid cache data. For more information on notebooks and Mathematica-compatible applications, contact Wolfram Research: web: http://www.wolfram.com email: info@wolfram.com phone: +1-217-398-0700 (U.S.) Notebook reader applications are available free of charge from Wolfram Research. *******************************************************************) (*CacheID: 232*) (*NotebookFileLineBreakTest NotebookFileLineBreakTest*) (*NotebookOptionsPosition[ 29056, 742]*) (*NotebookOutlinePosition[ 29701, 764]*) (* CellTagsIndexPosition[ 29657, 760]*) (*WindowFrame->Normal*) Notebook[{ Cell[BoxData[ StyleBox[\( (*\ \ \ \ \ Numerik\ : \ \ Aufgabe\ \ 2\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ SS\ 2005\ \ \ \ \ \ *) \), "Subtitle", FontColor->RGBColor[1, 0, 0]]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[ \(Off[General::spell]; \ \ \ Off[General::spell1];\)], "Input"], Cell[BoxData[ RowBox[{" ", StyleBox[\( (*\ Achtung : \ \[IndentingNewLine]\ \ Bitte\ nach\ jeder\ \(F unktion\)\ die\ Ergebnisse\ \(abspeichern\ !\)\ *) \), "Subtitle", FontColor->RGBColor[1, 0, 0]], StyleBox["\[IndentingNewLine]", "Subtitle", FontColor->RGBColor[1, 0, 0]], StyleBox[" ", "Subtitle", FontColor->RGBColor[1, 0, 0]], StyleBox[\( (*\ \ Anschlie\[SZ]end\ istgen\ = \ 0\ setzen, \ siehe\ Programmende\ \ *) \), "Subtitle", FontColor->RGBColor[1, 0, 0]], "\[IndentingNewLine]", " ", StyleBox[\( (*\ Dann\ mit\ neuer\ Funktion\ \(\(weiter arbeiten\)\(.\)\)\ *) \), "Subtitle", FontColor->RGBColor[1, 0, 0]], "\[IndentingNewLine]", StyleBox[" ", "Subsubtitle", FontColor->RGBColor[1, 0, 0]], StyleBox[\( (*\ \ \ D . h . \ das\ Programm\ mit\ verschiedener\ Genauigkeit\ \ \((\ igen\ = \ 1, \ 2, \ 3, \ 4, \ und\ 5\ )\)\ \ und\ \ *) \), "Section", FontColor->RGBColor[1, 0, 0]], StyleBox[" ", "Section", FontColor->RGBColor[1, 0, 0]], StyleBox[\( (*\ mit\ jeweils\ zwei\ oder\ drei\ verschiedenen\ Startwerten\ \((\ siehe\ Graphik\ )\)\ laufen\ lassen\ \ \ *) \), "Section", FontColor->RGBColor[1, 0, 0]], " "}]], "Input", Background->RGBColor[0, 0, 1]], Cell[BoxData[ StyleBox[\( (*\ \ \ \ \ \ \ \ \ \ \ Berechnung\ \ der\ \ Nullstellen\ \ einer\ \ Funktion\ \ \ y\ = \ f \((x)\)\ \ \ \ \ \ \ \ \ *) \), "Section", FontColor->RGBColor[1, 0, 0]]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[{\(listgen = {8, 16, 24, 36, 48};\), "\n", RowBox[{ RowBox[{\(igen = 1\), ";", " ", StyleBox[\( (*\ \ \ Bitte\ \ Rechnergenauigkeit\ \ w\[ADoubleDot]hlen\ \ igen\ = \ 1, \ 2, \ 3, \ 4\ \(u nd\)\ 5\ \ *) \), "Subsection", FontColor->RGBColor[1, 0, 0], Background->RGBColor[1, 1, 0]], "\[IndentingNewLine]", \(ista\ = \ 0\), ";"}], " "}], "\n", \(genist[0]\ = \ 0;\), "\n", \(gen = \ listgen[\([\)\(igen\)\(]\)];\), "\n", RowBox[{\(If\ \ [\ gen\ < \ $MinPrecision, $MaxPrecision = \ \($MinPrecision = gen\), \[IndentingNewLine]$MinPrecision = \ \($MaxPrecision = gen\)];\), " "}]}], "Input"], Cell[BoxData[ StyleBox[\( (*\ \ \ \ \ \ 1. \ \ \ \ Definition\ \ der\ \ Beispielfunktionen\ \ \ einschlie\[SZ]\ lich\ \ ihrer\ \ Ableitungen\ \ \ \ \ \ \ \ *) \), "Subsubtitle", FontColor->RGBColor[1, 0, 0]]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[ RowBox[{\(ifunk\ = \ 1\), " ", ";", " ", StyleBox[\( (*\ \ Bitte\ Funktion\ ausw\[ADoubleDot]hlen\ \ ifunk\ = \ 1, \ 2, \ 3\ und\ 4\ *) \), "Subsection", FontColor->RGBColor[1, 0, 0], Background->RGBColor[1, 1, 0]], StyleBox[" ", "Subsection"]}]], "Input"], Cell[BoxData[ RowBox[{" ", StyleBox[\( (*\ \ \ \ B\ e\ i\ s\ p\ i\ e\ l\ f\ u\ n\ k\ t\ i\ o\ \ n\ \ 1\ \ \ \ \ *) \), "Subsubsection", FontColor->RGBColor[1, 0, 0]]}]], "Input", Background->RGBColor[1, 1, 0]], Cell[BoxData[{ \(\(If[\ ifunk \[Equal] 1, {\(funk[1]\)[x_] := SetPrecision[1. , gen] - SetPrecision[1. , gen]/x - SetPrecision[2. , gen]*Log[x]; \ \(abl1funk[1]\)[ x_] := \(funk[1]'\)[x]; \[IndentingNewLine]\(abl2funk[1]\)[ x_] := \(funk[1]''\)[x]}];\)\), "\n", \(If[ifunk \[Equal] 1, {\(funk[1]\)[x], \(abl1funk[1]\)[x], \(abl2funk[1]\)[ x]}]\), "\n", \(If[ifunk \[Equal] 1, PaddedForm[ SetPrecision[\(funk[1]\)[3], gen], {gen + 2, gen}]]\)}], "Input"], Cell[BoxData[ RowBox[{" ", StyleBox[\( (*\ \ \ \ B\ e\ i\ s\ p\ i\ e\ l\ f\ u\ n\ k\ t\ i\ o\ \ n\ \ 2\ \ \ \ \ *) \), "Subsubsection", FontColor->RGBColor[1, 0, 0]]}]], "Input", Background->RGBColor[1, 1, 0]], Cell[BoxData[{ \(\(If[ ifunk \[Equal] 2, {\(funk[2]\)[x_] := SetPrecision[1. , gen]/x - SetPrecision[1. , gen] - Sin[x]; \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(abl1funk[2]\)[x_] := \(funk[2]'\)[x]; \ \ \(abl2funk[2]\)[ x_] := \(funk[2]''\)[x]; }];\)\), "\n", \(If[ifunk \[Equal] 2, {\(funk[2]\)[x], \(abl1funk[2]\)[x], \(abl2funk[2]\)[ x]}]\), "\n", \(If[ifunk \[Equal] 2, PaddedForm[ SetPrecision[\(abl1funk[2]\)[3], gen], {gen + 2, gen}]]\)}], "Input"], Cell[BoxData[ RowBox[{" ", StyleBox[\( (*\ \ \ \ B\ e\ i\ s\ p\ i\ e\ l\ f\ u\ n\ k\ t\ i\ o\ \ n\ \ 3\ \ \ \ \ *) \), "Subsubsection", FontColor->RGBColor[1, 0, 0]]}]], "Input", Background->RGBColor[1, 1, 0]], Cell[BoxData[{ \(\(If[ ifunk \[Equal] 3, {\(funk[3]\)[x_] := SetPrecision[1. , gen] + Sin[x]; \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(abl1funk[3]\)[x_] := \(funk[3]'\)[ x]; \[IndentingNewLine]\ \ \(abl2funk[3]\)[x_] := \(funk[3]''\)[ x]; }];\)\), "\n", \(If[ifunk \[Equal] 3, {\(funk[3]\)[x], \(abl1funk[3]\)[x], \(abl2funk[3]\)[ x]}]\), "\n", \(If[ifunk \[Equal] 3, PaddedForm[ SetPrecision[\(funk[3]\)[3], gen], {gen + 2, gen}]]\)}], "Input"], Cell[BoxData[ RowBox[{" ", StyleBox[\( (*\ \ \ \ B\ e\ i\ s\ p\ i\ e\ l\ f\ u\ n\ k\ t\ i\ o\ \ n\ \ 4\ \ \ \ \ *) \), "Subsubsection", FontColor->RGBColor[1, 0, 0]]}]], "Input", Background->RGBColor[1, 1, 0]], Cell[BoxData[{ \(\(If[ ifunk \[Equal] 4, {\(funk[4]\)[x_] := SetPrecision[\[Pi], gen] - x - \ Sin[x]; \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \(abl1funk[4]\)[x_] := \(funk[4]'\)[x]; \ \ \(abl2funk[4]\)[ x_] := \(funk[4]''\)[x]; }];\)\), "\n", \(If[ifunk \[Equal] 4, PaddedForm[ SetPrecision[\(abl1funk[4]\)[3], gen], {gen + 2, gen}]]\)}], "Input"], Cell[BoxData[ RowBox[{" ", StyleBox[\( (*\ \ \ \ \(If\)\([\)\(ifunk \[Equal] 2, \ \ 2. \ \ \ Schaubilder\ \ der\ \ \ Beispielfunktionen\)\(\ \ \ \ \ \ \ \ \)*) \), "Subsubtitle", FontColor->RGBColor[1, 0, 0]]}]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[ RowBox[{"<<", "Graphics`Colors`", StyleBox[ RowBox[{" ", StyleBox[" ", Background->RGBColor[1, 1, 0]]}]], StyleBox[\( (*\ \ Package\ zur\ Farbdefinition\ in\ der\ Graphik\ \ *) \ \), FontColor->RGBColor[1, 0, 1], Background->RGBColor[1, 1, 0]]}]], "Input"], Cell[BoxData[ RowBox[{" ", RowBox[{ StyleBox["(*", "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[ StyleBox[ RowBox[{" ", StyleBox[" ", "Subsubsection", FontColor->RGBColor[1, 0, 1]]}]], "Subsection"], RowBox[{ StyleBox[\(Funktion\ 1\), "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[" ", "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[":", "Subsection", FontColor->RGBColor[1, 0, 1]], " ", StyleBox[\(Grenzen\ \ f\[UDoubleDot]r\ \ die\ \ x - Werte\ und\ \ die\ \ y - Werte\ \ setzen\), "Subsubsection", FontColor->RGBColor[1, 0, 1]]}], StyleBox[" ", "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox["*)", "Subsection", FontColor->RGBColor[1, 0, 1]]}]}]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[ RowBox[{ RowBox[{"If", "[", RowBox[{\(ifunk \[Equal] 1\), ",", RowBox[{"{", RowBox[{\(xmin = 0.01\), ";", " ", \(xmax = 5\), ";", " ", \(ymin = \(-3\)\), ";", " ", \(ymax = 1\), ";", "\n", RowBox[{ StyleBox["Plot", "Subsubtitle", FontColor->RGBColor[1, 0, 0]], "[", " ", \(\(funk[1]\)[x], {x, xmin, xmax}, PlotRange -> {{xmin - 1, xmax}, {ymin, ymax}}, AspectRatio \[Rule] 0.6, \[IndentingNewLine]PlotPoints \[Rule] 40, AxesLabel \[Rule] {\ "\<-> X\>", "\< ^ Y\>"}, \ PlotStyle -> Green\), "]"}]}], "}"}]}], "]"}], ";"}]], "Input"], Cell[BoxData[ RowBox[{" ", RowBox[{ StyleBox["(*", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox[ RowBox[{" ", StyleBox[" ", "Subsubsection"], StyleBox[" ", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox[" ", "Subsection", FontColor->RGBColor[1, 0, 1]]}]], RowBox[{ StyleBox[\(Funktion\ 2\), "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[" ", "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[":", "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[" ", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox[\(Grenzen\ \ f\[UDoubleDot]r\ \ die\ \ x - Werte\ und\ \ die\ \ y - Werte\ \ setzen\), "Subsubsection", FontColor->RGBColor[1, 0, 1]]}], StyleBox[" ", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox["*)", "Subsubsection", FontColor->RGBColor[1, 0, 1]]}]}]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[ RowBox[{"If", "[", RowBox[{\(ifunk \[Equal] 2\), ",", RowBox[{"{", RowBox[{\(xmin = \(-9. \)\), ";", " ", \(xmax = 18\), ";", " ", \(ymin = \(-3\)\), ";", " ", \(ymax = 2\), ";", "\n", RowBox[{ StyleBox["Plot", "Subsubtitle", FontColor->RGBColor[1, 0, 0]], "[", " ", \(\(funk[2]\)[x], {x, xmin, xmax}, PlotRange -> {{xmin, xmax}, {ymin, ymax}}, AspectRatio \[Rule] 0.6, \[IndentingNewLine]PlotPoints \[Rule] 40, AxesLabel \[Rule] {\ "\<-> X\>", "\< ^ Y\>"}, \ PlotStyle \[Rule] Red\), "]"}]}], "}"}]}], "]"}]], "Input"], Cell[BoxData[ RowBox[{" ", RowBox[{ StyleBox["(*", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox[ RowBox[{" ", StyleBox[" ", "Subsubsection"], StyleBox[" ", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox[" ", "Subsection", FontColor->RGBColor[1, 0, 1]]}]], RowBox[{ StyleBox[\(Funktion\ 3\), "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[" ", "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[":", "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[" ", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox[\(Grenzen\ \ f\[UDoubleDot]r\ \ die\ \ x - Werte\ und\ \ die\ \ y - Werte\ \ setzen\), "Subsubsection", FontColor->RGBColor[1, 0, 1]]}], StyleBox[" ", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox["*)", "Subsubsection", FontColor->RGBColor[1, 0, 1]]}]}]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[ RowBox[{"If", "[", RowBox[{\(ifunk \[Equal] 3\), ",", RowBox[{"{", RowBox[{\(xmin = \(-3.0\)\), ";", " ", \(xmax = 15\), ";", " ", \(ymin = \(-0.5\)\), ";", " ", \(ymax = 2.5\), ";", "\n", RowBox[{ StyleBox["Plot", "Subsubtitle", FontColor->RGBColor[1, 0, 0]], "[", " ", \(\(funk[3]\)[x], {x, xmin, xmax}, PlotRange -> {{xmin, xmax}, {ymin, ymax}}, AspectRatio \[Rule] 0.6, \[IndentingNewLine]PlotPoints \[Rule] 40, AxesLabel \[Rule] {\ "\<-> X\>", "\< ^ Y\>"}, \ PlotStyle \[Rule] Brown\), "]"}]}], "}"}]}], "]"}]], "Input"], Cell[BoxData[ RowBox[{" ", RowBox[{ StyleBox["(*", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox[ RowBox[{" ", StyleBox[" ", "Subsubsection"], StyleBox[" ", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox[" ", "Subsection", FontColor->RGBColor[1, 0, 1]]}]], RowBox[{ StyleBox[\(Funktion\ 4\), "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[" ", "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[":", "Subsection", FontColor->RGBColor[1, 0, 1]], StyleBox[" ", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox[\(Grenzen\ \ f\[UDoubleDot]r\ \ die\ \ x - Werte\ und\ \ die\ \ y - Werte\ \ setzen\), "Subsubsection", FontColor->RGBColor[1, 0, 1]]}], StyleBox[" ", "Subsubsection", FontColor->RGBColor[1, 0, 1]], StyleBox["*)", "Subsubsection", FontColor->RGBColor[1, 0, 1]]}]}]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[ RowBox[{"If", "[", RowBox[{\(ifunk \[Equal] 4\), ",", RowBox[{"{", RowBox[{\(xmin = \(-6.0\)\), ";", " ", \(xmax = 15\), ";", " ", \(ymin = \(-9\)\), ";", " ", \(ymax = 9\), ";", "\n", RowBox[{ StyleBox["Plot", "Subsubtitle", FontColor->RGBColor[1, 0, 0]], "[", " ", \(\(funk[4]\)[x], {x, xmin, xmax}, PlotRange -> {{xmin, xmax}, {ymin, ymax}}, AspectRatio \[Rule] 0.6, \[IndentingNewLine]PlotPoints \[Rule] 40, AxesLabel \[Rule] {\ "\<-> X\>", "\< ^ Y\>"}, \ PlotStyle \[Rule] Blue\), "]"}]}], "}"}]}], "]"}]], "Input"], Cell[BoxData[ RowBox[{" ", StyleBox[\( (*\ \ \ \ \ \ 3. \ \ \ \ Verfahren\ \ von\ \ Newton\ \ zur\ \ Nullstellenbestimmumg\ \ \ \ \ \ \ \ *) \), "Subsubtitle", FontColor->RGBColor[1, 0, 0]]}]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[ RowBox[{" ", StyleBox[\( (*\ \ \ \ Hier\ wird\ die\ Beipielfunktion\ \ ifunk\ \ eingesetzt\ \ \ \ \ \ \ \ \ *) \), "Subsubtitle", FontColor->RGBColor[1, 0, 0]]}]], "Input", Background->RGBColor[1, 1, 0]], Cell[BoxData[{ \(funktion[x_] := \(funk[ifunk]\)[x]; \ \ \ abl1funktion[ x_] := \ \(abl1funk[ifunk]\)[x]; \ \ \ abl2funktion[ x_] := \(abl2funk[ifunk]\)[x]\), "\n", \(\(genaus[igen] = gen;\)\)}], "Input"], Cell[BoxData[ RowBox[{ StyleBox[ RowBox[{" ", StyleBox[" ", "Subsubtitle"]}]], StyleBox[\( (*\ \ \ \ H\ i\ e\ r\ \ S\ t\ a\ r\ t\ w\ e\ r\ t\ e\ \ f\ \ \[UDoubleDot]\ r\ \ d\ a\ s\ \ j\ e\ w\ e\ i\ l\ i\ g\ e\ \ B\ e\ i\ s\ p\ i\ \ e\ l\ \ e\ i\ n\ s\ e\ t\ z\ e\ n\ \ \ \ *) \), "Subsubsection", FontColor->RGBColor[1, 0, 0]], StyleBox[" ", "Subsubtitle"], "\[IndentingNewLine]", " ", StyleBox[\( (*\ Achtung\ Programm\ von\ hier\ aus\ laufen\ \(\(lassen\ !!\)!\)\ \ Nicht\ von\ oben\ \(starten\ !\)\ *) \), "Subsubtitle", FontColor->RGBColor[1, 0, 0]]}]], "Input", Background->RGBColor[1, 1, 0]], Cell[BoxData[{ RowBox[{ RowBox[{ RowBox[{\(Tabnew[0, 1]\), "=", "\"\<\!\(\* StyleBox[\"FuNr\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\>\""}], ";", RowBox[{\(Tabnew[0, 2]\), "=", "\"\<\!\(\* StyleBox[\"Gen\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\>\""}], " ", ";", RowBox[{\(Tabnew[0, 3]\), "=", "\"\<\!\(\* StyleBox[\"St\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\".\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\"Nr\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\".\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\>\""}], ";", RowBox[{\(Tabnew[0, 4]\), "=", "\"\<\!\(\* StyleBox[\"Verf\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\".\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\>\""}], ";", RowBox[{\(Tabnew[0, 5]\), "=", "\"\< \!\(\* StyleBox[\"Startw\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\".\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\>\""}], ";", RowBox[{\(Tabnew[0, 6]\), "=", "\"\< \!\(\* StyleBox[\"L\[ODoubleDot]sung\",\nFontSize->14,\nFontColor->RGBColor[1, 0, \ 0]]\)\>\""}], ";", RowBox[{\(Tabnew[0, 7]\), "=", " ", "\"\< \!\(\* StyleBox[\"Funktionsw\",\nFontSize->14,\nFontColor->RGBColor[1, 0, \ 0]]\)\!\(\* StyleBox[\".\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\>\""}], ";", RowBox[{\(Tabnew[0, 8]\), "=", " ", "\"\<\!\(\* StyleBox[\"It\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\".\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\"Schr\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\".\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\>\""}], ";"}], " "}], "\[IndentingNewLine]", \(\(Tabmod[0, 1] = "\< \>"\)\(;\)\(Tabmod[0, 2] = "\< \>"\)\(\ \)\(;\)\(Tabmod[0, 3] = "\< \>"\)\(;\)\(Tabmod[0, 4] = "\< \>"\)\(;\)\(Tabmod[ 0, 5] = "\< \>"\)\(;\)\(Tabmod[0, 6] = "\< \>"\)\(;\)\(Tabmod[0, 7] = \ "\< \>"\)\(;\)\(Tabmod[0, 8] = \ "\< \>"\)\(;\)\(\ \ \ \ \ \)\)}], "Input"], Cell[BoxData[ RowBox[{" ", StyleBox[\( (*\ \ \ \ \ \ Klassisches\ \ Newton\ - \ Verfahren\ \ \ \ \ \ \ \ *) \), "Subsubtitle", FontColor->RGBColor[1, 0, 0]]}]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[{ RowBox[{\(xx = SetPrecision[2, gen]\ *10^\(-1\)\), StyleBox[ RowBox[{" ", StyleBox[" ", Background->RGBColor[1, 1, 0]]}]], StyleBox[\( (*\ \ \ Startwert\ \ \[ADoubleDot]ndern\ \(?? ?\)\ \ *) \), FontSize->16, FontColor->RGBColor[1, 0, 0], Background->RGBColor[1, 1, 0]]}], "\n", \(xstart = PaddedForm[xx, 6];\), "\n", RowBox[{\(ista = ista\ + \ 1\), ";", " ", StyleBox[\( (*\ \ Nummer\ des\ Startwertes\ \(\(erh\[ODoubleDot]hen\ \ !!\)!\)\ \ *) \), FontColor->RGBColor[1, 0, 0], Background->RGBColor[1, 1, 0]], "\n", \(genist[igen]\ = \ ista\), ";"}], "\n", \(sumgen\ = \ 0; Do[sumgen\ = \ sumgen\ + \ genist[ig - 1], {ig, 1, igen}];\), "\n", \(istgen\ = \ sumgen\ + \ ista;\), "\n", \(mod = 0; \ nschr\ = \ 99;\), "\n", RowBox[{\(Do[{\ xx\ = \ SetPrecision[xx\ - \ funktion[xx]/abl1funktion[xx], gen], Print["\", n, "\< xx = \>", AccountingForm[ PaddedForm[xx, {gen + 1, gen}]], "\< , f(xx) = \>", \ ScientificForm[ PaddedForm[funktion[xx], {7, 6}]], "\< , f'(xx) = \>", \ ScientificForm[PaddedForm[abl1funktion[xx], {7, 6}]]], If[Abs[funktion[xx]] < 10^\(-gen\), \ {nschr\ = \ n, Break[]}]}, {n, 1, nschr}];\), " "}], "\n", \(Tabnew[istgen, 1] = ifunk; Tabnew[istgen, 2] = igen; Tabnew[istgen, 3] = ista; Tabnew[istgen, 4] = "\"; Tabnew[istgen, 5] = xstart; Tabnew[istgen, 6] = xx; Tabnew[istgen, 8] = PaddedForm[nschr, 3]; Tabnew[istgen, 7] = ScientificForm[PaddedForm[funktion[xx], {7, 6}]];\)}], "Input"], Cell[BoxData[ StyleBox[\( (*\ \ \ \ \ \ Tabelle\ der\ Nullstellen\ f\[UDoubleDot]r\ \ vesch . \ Funktionen\ und\ vesch . \ Genauigkeiten\ \ \ \ \ \ *) \), "Subsection", FontColor->RGBColor[1, 0, 1]]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[ \(TableForm[Table[Tabnew[isg, j], {isg, 1, istgen}, \n\t\t{j, 1, 8}], TableSpacing -> {2, 1}]\)], "Input"], Cell[BoxData[ RowBox[{" ", StyleBox[\( (*\ \ \ \ 4. \ \ \ Modifiziertes\ \ Newton\ - \ Verfahren\ \ \ \ f\[UDoubleDot]r\ \ \ mehrfache\ \ \ Nullstellen\ \ \ \ \ *) \), "Subsubtitle", FontColor->RGBColor[1, 0, 0]]}]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[ RowBox[{" ", StyleBox[\( (*\ \ \ \ H\ i\ e\ r\ \ S\ t\ a\ r\ t\ w\ e\ rt\ e\ \ f\ \ \[UDoubleDot]\ r\ \ d\ a\ s\ \ j\ e\ w\ e\ i\ l\ i\ g\ e\ \ B\ e\ i\ s\ p\ i\ \ e\ l\ \ e\ i\ n\ s\ e\ t\ z\ e\ n\ \ \ \ *) \), "Subsubsection", FontColor->RGBColor[1, 0, 0]], " "}]], "Input", Background->RGBColor[1, 1, 0]], Cell[BoxData[{ RowBox[{\(xx = SetPrecision[2, gen]*10^\(-1\)\), StyleBox[ RowBox[{" ", StyleBox[" ", Background->RGBColor[1, 1, 0]]}]], StyleBox[\( (*\ \ \ Startwert\ \ \[ADoubleDot]ndern\ \(?? ?\)\ \ *) \), FontSize->16, FontColor->RGBColor[1, 0, 0], Background->RGBColor[1, 1, 0]]}], "\n", \(xstart\ = \ PaddedForm[xx, 6];\), "\n", \(mod\ = 1; \ nschr\ = \ 50;\), "\n", \(q[x_] := funktion[x]*abl2funktion[x]/abl1funktion[x]^2. ; \ \ \ \ \ \ \ p[x_] := SetPrecision[\ 1. , gen]/\((SetPrecision[1. , gen] - q[x])\);\), "\n", \(Do[\ \ {\[IndentingNewLine]xx\ = \ xx\ - SetPrecision[\ p[xx]*funktion[xx]/abl1funktion[xx], gen], Print["\", n, "\< xx = \>", AccountingForm[ PaddedForm[Re[xx], {gen + 1, gen}]], "\< , f(xx) = \>", ScientificForm[ PaddedForm[Re[funktion[xx]], {7, 6}]], "\< , f'(xx) = \>", \ ScientificForm[ PaddedForm[ Re[abl1funktion[xx]], {7, 6}]], "\< f''(xx) = \>"\ , \ ScientificForm[ PaddedForm[ Re[abl2funktion[xx]], {7, 6}]], "\< , q(xx) = \>", \ ScientificForm[ PaddedForm[Re[q[xx]], {7, 6}]], "\< , p(xx) = \>", \ AccountingForm[PaddedForm[Re[p[xx]], {7, 6}]]], If[Abs[funktion[xx]] < 10^\(-gen\), \ {nschr\ = \ n, Break[]}]}, {n, 1, nschr}];\), "\n", \(Tabmod[istgen, 1] = ifunk; Tabmod[istgen, 2] = igen; Tabmod[istgen, 3] = ista; Tabmod[istgen, 4] = "\"; Tabmod[istgen, 5] = xstart; Tabmod[istgen, 6] = Re[xx]; Tabmod[istgen, 8] = \ PaddedForm[nschr, 3]; Tabmod[istgen, 7] = ScientificForm[PaddedForm[Re[funktion[xx]], {7, 6}]];\)}], "Input"], Cell[BoxData[ StyleBox[\( (*\ \ \ \ \ \ Tabelle\ der\ Nullstellen\ f\[UDoubleDot]r\ \ vesch . \ Funktionen\ und\ vesch . \ Genauigkeiten\ \ \ \ \ \ *) \), "Subsection", FontColor->RGBColor[1, 0, 1]]], "Input", Background->RGBColor[0, 1, 0]], Cell[BoxData[{ RowBox[{ RowBox[{"Print", "[", "\"\< \!\(\* StyleBox[\"Ergebnisse\",\nFontSize->14,\nFontColor->RGBColor[1, 0, \ 0]]\)\!\(\* StyleBox[\" \",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\"der\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\" \",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\"beiden\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\" \",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\"Verfahren\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\" \",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\"mit\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\" \",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\"allen\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\" \",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\"Genauigkeiten\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\ \(\* StyleBox[\" \",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\"und\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\" \",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\"verschiedenen\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\ \(\* StyleBox[\" \",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\)\!\(\* StyleBox[\"Startwerten\",\nFontSize->14,\nFontColor->RGBColor[1, 0, 0]]\) \ \>\"", "]"}], ";"}], "\[IndentingNewLine]", \(If[ifunk \[Equal] 1, Print[\*"\"\< Funktion 1: f(x) = 1 - \!\(1\/x\) - 2 \ Log(x)\>\""]];\), "\[IndentingNewLine]", RowBox[{ " ", \(If[ifunk \[Equal] 2, Print[\*"\"\< Funktion 2: f(x) = \!\(1\/x\) - 1 - \ Sin(x)\>\""]];\)}], "\[IndentingNewLine]", RowBox[{ " ", \(If[ifunk == 3, Print["\< Funktion 3: f(x) = 1 + Sin(x) , X = \>"\ \ , \ \ SetPrecision[3 Pi/2, gen]]];\), "\[IndentingNewLine]"}], "\[IndentingNewLine]", RowBox[{ " ", \(If[ifunk\ \[Equal] 4, Print["\< Funktion 4: f(x) = \[Pi] - x - Sin(x) , X = \ \>"\ \ , \ \ SetPrecision[Pi, gen]]];\), "\[IndentingNewLine]"}], "\n", RowBox[{\(TableForm[ Table[{Tabnew[isg, j], Tabmod[isg, j]}, {isg, 0, istgen}, \n\t{j, 1, 8}], TableSpacing -> {2, 1}]\), " "}]}], "Input"], Cell[BoxData[ \(\(\(\ \ \ \ \)\( (*\ \ \ \ istgen\ = \ 0\ \ *) \)\)\)], "Input"] }, FrontEndVersion->"5.0 for Microsoft Windows", ScreenRectangle->{{0, 1024}, {0, 695}}, WindowSize->{1012, 653}, WindowMargins->{{Automatic, -2}, {4, Automatic}} ] (******************************************************************* Cached data follows. If you edit this Notebook file directly, not using Mathematica, you must remove the line containing CacheID at the top of the file. The cache data will then be recreated when you save this file from within Mathematica. *******************************************************************) (*CellTagsOutline CellTagsIndex->{} *) (*CellTagsIndex CellTagsIndex->{} *) (*NotebookFileOutline Notebook[{ Cell[1754, 51, 258, 6, 59, "Input"], Cell[2015, 59, 81, 1, 30, "Input"], Cell[2099, 62, 1538, 38, 182, "Input"], Cell[3640, 102, 262, 6, 54, "Input"], Cell[3905, 110, 733, 14, 150, "Input"], Cell[4641, 126, 267, 6, 49, "Input"], Cell[4911, 134, 338, 8, 30, "Input"], Cell[5252, 144, 282, 6, 46, "Input"], Cell[5537, 152, 577, 13, 110, "Input"], Cell[6117, 167, 282, 6, 46, "Input"], Cell[6402, 175, 574, 13, 90, "Input"], Cell[6979, 190, 282, 6, 46, "Input"], Cell[7264, 198, 605, 14, 90, "Input"], Cell[7872, 214, 282, 6, 46, "Input"], Cell[8157, 222, 458, 10, 70, "Input"], Cell[8618, 234, 325, 7, 46, "Input"], Cell[8946, 243, 356, 9, 30, "Input"], Cell[9305, 254, 1096, 34, 46, "Input"], Cell[10404, 290, 810, 18, 72, "Input"], Cell[11217, 310, 1312, 40, 46, "Input"], Cell[12532, 352, 732, 15, 72, "Input"], Cell[13267, 369, 1312, 40, 46, "Input"], Cell[14582, 411, 751, 16, 72, "Input"], Cell[15336, 429, 1312, 40, 46, "Input"], Cell[16651, 471, 733, 15, 72, "Input"], Cell[17387, 488, 291, 7, 46, "Input"], Cell[17681, 497, 275, 6, 46, "Input"], Cell[17959, 505, 229, 4, 50, "Input"], Cell[18191, 511, 757, 18, 66, "Input"], Cell[18951, 531, 2232, 39, 110, "Input"], Cell[21186, 572, 272, 6, 46, "Input"], Cell[21461, 580, 1832, 36, 290, "Input"], Cell[23296, 618, 258, 5, 46, "Input"], Cell[23557, 625, 131, 2, 50, "Input"], Cell[23691, 629, 308, 7, 46, "Input"], Cell[24002, 638, 374, 7, 46, "Input"], Cell[24379, 647, 1921, 37, 310, "Input"], Cell[26303, 686, 258, 5, 46, "Input"], Cell[26564, 693, 2400, 44, 218, "Input"], Cell[28967, 739, 85, 1, 30, "Input"] } ] *) (******************************************************************* End of Mathematica Notebook file. *******************************************************************)