(* Content-type: application/vnd.wolfram.mathematica *) (*** Wolfram Notebook File ***) (* http://www.wolfram.com/nb *) (* CreatedBy='Mathematica 10.4' *) (*CacheID: 234*) (* Internal cache information: NotebookFileLineBreakTest NotebookFileLineBreakTest NotebookDataPosition[ 158, 7] NotebookDataLength[ 67701, 2009] NotebookOptionsPosition[ 62036, 1860] NotebookOutlinePosition[ 62410, 1876] CellTagsIndexPosition[ 62367, 1873] WindowFrame->Normal*) (* Beginning of Notebook Content *) Notebook[{ Cell[BoxData[{ RowBox[{"1", "+", "1"}], "\[IndentingNewLine]", RowBox[{"2", "+", "3"}]}], "Input", CellChangeTimes->{{3.6968462165235105`*^9, 3.6968462169299593`*^9}, { 3.6968463519305935`*^9, 3.696846353587426*^9}, {3.6968480525457897`*^9, 3.6968480554024973`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"a", "=", "2"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"b", "=", RowBox[{"a", "+", "3"}]}], ";"}], "\[IndentingNewLine]"}], "Input", CellChangeTimes->{{3.69684807135221*^9, 3.6968481324714146`*^9}, { 3.6968482260913415`*^9, 3.6968482532819977`*^9}, {3.6968483356430354`*^9, 3.6968483417788277`*^9}}], Cell[BoxData["b"], "Input", CellChangeTimes->{3.696848346309143*^9}], Cell[BoxData[ RowBox[{"d", "=", SuperscriptBox["b", "2"]}]], "Input", CellChangeTimes->{{3.696848392167918*^9, 3.6968484260851808`*^9}}], Cell[BoxData[ SuperscriptBox["5", "3"]], "Input", CellChangeTimes->{{3.6968484644731903`*^9, 3.6968484749088144`*^9}}], Cell[BoxData[ FractionBox["5", "7"]], "Input", CellChangeTimes->{{3.6968485952662144`*^9, 3.6968486136472125`*^9}}], Cell[BoxData[ SqrtBox["2"]], "Input", CellChangeTimes->{{3.696848662497203*^9, 3.696848664646633*^9}}], Cell[BoxData[ RowBox[{"Sin", "[", "\[Pi]", "]"}]], "Input", CellChangeTimes->{{3.696848740469494*^9, 3.696848745780074*^9}}], Cell[BoxData[ RowBox[{"Sin", "[", "5", "]"}]], "Input", CellChangeTimes->{{3.6968489294055176`*^9, 3.696848933098901*^9}}], Cell[BoxData[ RowBox[{"Sin", "[", "5.", "]"}]], "Input", CellChangeTimes->{{3.696849030814517*^9, 3.696849035668066*^9}}], Cell[BoxData[ RowBox[{"N", "[", "Pi", "]"}]], "Input", CellChangeTimes->{{3.6968490843842773`*^9, 3.6968490888286405`*^9}}], Cell[BoxData[ RowBox[{"N", "[", RowBox[{"Pi", ",", "100"}], "]"}]], "Input", CellChangeTimes->{{3.6968491295897055`*^9, 3.696849132845591*^9}}], Cell[BoxData[{ RowBox[{"N", "[", "Pi", "]"}], "\[IndentingNewLine]", RowBox[{"Pi", "//", "N"}], "\[IndentingNewLine]", RowBox[{"N", "@", "Pi"}]}], "Input", CellChangeTimes->{{3.6968492617069674`*^9, 3.6968493296557317`*^9}}], Cell[BoxData[ RowBox[{"kyncl", "*", "is", "*", "stupid", "*", "guy", " "}]], "Input", CellChangeTimes->{{3.696849446299182*^9, 3.6968494598812265`*^9}, { 3.696849508937941*^9, 3.69684951502584*^9}}], Cell[BoxData[ RowBox[{"12", "ape"}]], "Input", CellChangeTimes->{{3.696849617486929*^9, 3.696849620370715*^9}}], Cell[BoxData["ape12"], "Input", CellChangeTimes->{{3.696849647549472*^9, 3.6968496484020057`*^9}}], Cell[BoxData[ RowBox[{"?", "="}]], "Input", CellChangeTimes->{{3.6968497172859097`*^9, 3.696849723578883*^9}}], Cell[BoxData[ RowBox[{"x", "=", "3"}]], "Input", CellChangeTimes->{{3.696850102262042*^9, 3.696850104293092*^9}}], Cell[BoxData[{ RowBox[{"ClearAll", "[", "x", "]"}], "\[IndentingNewLine]", RowBox[{"Limit", "[", RowBox[{ FractionBox[ RowBox[{ SuperscriptBox["E", RowBox[{"2", "x"}]], "-", "1"}], RowBox[{"Sin", "[", "x", "]"}]], ",", RowBox[{"x", "->", "0"}]}], "]"}]}], "Input", CellChangeTimes->{{3.696849940066061*^9, 3.6968499490904627`*^9}, 3.696850068963701*^9, {3.6968501670912423`*^9, 3.6968501772722473`*^9}}], Cell[BoxData[ RowBox[{"DSolve", "[", RowBox[{ RowBox[{ RowBox[{ RowBox[{ RowBox[{"y", "''"}], "[", "x", "]"}], "+", RowBox[{"2", RowBox[{"y", "[", "x", "]"}]}]}], "\[Equal]", "0"}], ",", RowBox[{"y", "[", "x", "]"}], ",", "x"}], "]"}]], "Input", CellChangeTimes->{{3.696850474122587*^9, 3.696850508110987*^9}}], Cell[BoxData[ RowBox[{"Integrate", "[", RowBox[{ FractionBox[ RowBox[{"Sin", "[", SuperscriptBox["x", "2"], "]"}], SqrtBox["x"]], ",", "x"}], "]"}]], "Input", CellChangeTimes->{{3.6968507658778353`*^9, 3.696850789015236*^9}, { 3.696850857033679*^9, 3.696850863347165*^9}}], Cell[BoxData[ RowBox[{"?", "_"}]], "Input", CellChangeTimes->{{3.696852224443101*^9, 3.6968522262567167`*^9}}], Cell[BoxData[ RowBox[{"??", "__"}]], "Input", CellChangeTimes->{{3.6968522670586834`*^9, 3.696852268172044*^9}}], Cell[BoxData[ RowBox[{"?", "___"}]], "Input", CellChangeTimes->{{3.69685230494343*^9, 3.6968523062316074`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", RowBox[{"x", ":", "_"}], "]"}], ":=", SuperscriptBox["x", "2"]}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "[", "x", "]"}], "\[IndentingNewLine]"}], "Input", CellChangeTimes->{{3.6968524630327516`*^9, 3.696852497031474*^9}, { 3.696852576710023*^9, 3.696852581158638*^9}, 3.6968526156419992`*^9, { 3.6968526720148916`*^9, 3.6968526756392183`*^9}}], Cell[BoxData[ RowBox[{"?", ":="}]], "Input", CellChangeTimes->{3.69685295239743*^9}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", RowBox[{"1", "+", "1"}]}], "\[IndentingNewLine]", RowBox[{"?", "f"}], "\[IndentingNewLine]", RowBox[{"f", "[", "5", "]"}]}], "Input", CellChangeTimes->{ 3.6968528583284388`*^9, {3.696852896034748*^9, 3.696852898179462*^9}, { 3.696852989678875*^9, 3.696852999601266*^9}, {3.6968530356176414`*^9, 3.6968530374732714`*^9}, 3.6968530867562685`*^9}], Cell[BoxData[ RowBox[{"?", "="}]], "Input", CellChangeTimes->{{3.6968530572877975`*^9, 3.6968530587432065`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"f", "[", "x_", "]"}], "=", RowBox[{"1", "+", "1"}]}], "\[IndentingNewLine]", RowBox[{"?", "f"}]}], "Input", CellChangeTimes->{ 3.696852922725486*^9, {3.6968530821977277`*^9, 3.696853120045331*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"x", "=", "5"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", "x"}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "[", "\"\\"", "]"}]}], "Input", CellChangeTimes->{{3.6968531455614476`*^9, 3.696853146761115*^9}, { 3.696853313455125*^9, 3.6968533335563135`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"x", "=", "5"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], "=", "x"}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "[", "\"\\"", "]"}], "\[IndentingNewLine]", RowBox[{"?", "f"}]}], "Input", CellChangeTimes->{{3.6968532234236736`*^9, 3.6968533029607563`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{"f", ":=", RowBox[{"Random", "[", "]"}]}], "\[IndentingNewLine]", RowBox[{"{", RowBox[{"f", ",", "f", ",", "f", ",", "f", ",", "f", ",", "f"}], "}"}]}], "Input", CellChangeTimes->{{3.6968533678856373`*^9, 3.6968533959454894`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "=", RowBox[{"Random", "[", "]"}]}], "\[IndentingNewLine]", RowBox[{"{", RowBox[{"f", ",", "f", ",", "f", ",", "f", ",", "f", ",", "f"}], "}"}]}], "Input", CellChangeTimes->{3.696853447113858*^9}], Cell[BoxData[{ RowBox[{"ClearAll", "[", RowBox[{"f", ",", "x"}], "]"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", RowBox[{"\[Integral]", RowBox[{ RowBox[{"Sin", "[", "x", "]"}], RowBox[{"\[DifferentialD]", "x"}]}]}]}], "\[IndentingNewLine]", RowBox[{"f", "[", "5", "]"}]}], "Input", CellChangeTimes->{{3.696853548566837*^9, 3.696853588465273*^9}, { 3.6968537027731533`*^9, 3.696853703220398*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", RowBox[{"f", ",", "x"}], "]"}], "\[IndentingNewLine]"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"f", "[", "x_", "]"}], "=", RowBox[{"\[Integral]", RowBox[{ RowBox[{"Sin", "[", "x", "]"}], RowBox[{"\[DifferentialD]", "x"}]}]}]}], "\[IndentingNewLine]", RowBox[{"f", "[", "5", "]"}]}], "Input", CellChangeTimes->{{3.6968536845172133`*^9, 3.6968536979882326`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", RowBox[{"1", "+", "x"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", "1", "]"}], ":=", "7"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", RowBox[{"x_", ",", "y_"}], "]"}], ":=", SuperscriptBox["x", "y"]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", RowBox[{"4", ",", "y_"}], "]"}], ":=", SuperscriptBox["y", "2"]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", RowBox[{"{", RowBox[{"a_", ",", "b_"}], "}"}], "]"}], ":=", RowBox[{"{", RowBox[{"b", ",", "a"}], "}"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "[", RowBox[{"{", RowBox[{"1", ",", "5"}], "}"}], "]"}]}], "Input", CellChangeTimes->{{3.6968537842486467`*^9, 3.696853802415723*^9}, { 3.696853886872354*^9, 3.6968539288001685`*^9}, {3.696854065429911*^9, 3.6968540782547255`*^9}, {3.6968541128403177`*^9, 3.6968541185857086`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"$RecursionLimit", "=", SuperscriptBox["10", "6"]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"ClearAll", "[", "a", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"a", "[", "n_", "]"}], ":=", RowBox[{"n", "*", RowBox[{"a", "[", RowBox[{"n", "-", "1"}], "]"}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"a", "[", "0", "]"}], ":=", "1"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"Trace", "[", RowBox[{"a", "[", "3", "]"}], "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"Timing", "[", RowBox[{"Table", "[", RowBox[{ RowBox[{"a", "[", "i", "]"}], ",", RowBox[{"{", RowBox[{"i", ",", "1050"}], "}"}]}], "]"}], "]"}], "[", RowBox[{"[", "1", "]"}], "]"}], "\[IndentingNewLine]"}], "Input", CellChangeTimes->{{3.696854162442231*^9, 3.6968541884522266`*^9}, { 3.6968542285185413`*^9, 3.69685423303047*^9}, {3.696854490890506*^9, 3.696854548940681*^9}, {3.69685459437708*^9, 3.696854603184071*^9}, { 3.6968546548668222`*^9, 3.696854690987426*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "a", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"a", "[", "n_", "]"}], ":=", RowBox[{ RowBox[{"a", "[", "n", "]"}], "=", RowBox[{"n", "*", RowBox[{"a", "[", RowBox[{"n", "-", "1"}], "]"}]}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"a", "[", "0", "]"}], ":=", "1"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"Trace", "[", RowBox[{"a", "[", "3", "]"}], "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"Timing", "[", RowBox[{"Table", "[", RowBox[{ RowBox[{"a", "[", "i", "]"}], ",", RowBox[{"{", RowBox[{"i", ",", "1850"}], "}"}]}], "]"}], "]"}], "[", RowBox[{"[", "1", "]"}], "]"}], "\[IndentingNewLine]"}], "Input", CellChangeTimes->{{3.696854504210374*^9, 3.696854506515154*^9}, { 3.696854639072238*^9, 3.69685463954589*^9}, 3.6968546976283183`*^9}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "a", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"a", "[", "n_", "]"}], ":=", RowBox[{ RowBox[{"a", "[", "n", "]"}], "=", RowBox[{"n", "*", RowBox[{"a", "[", RowBox[{"n", "-", "1"}], "]"}]}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"a", "[", "0", "]"}], ":=", "1"}], ";"}], "\[IndentingNewLine]", RowBox[{"a", "[", "5", "]"}], "\[IndentingNewLine]", RowBox[{"Trace", "[", RowBox[{"a", "[", "6", "]"}], "]"}]}], "Input", CellChangeTimes->{{3.696854716036292*^9, 3.696854727796536*^9}, { 3.6968547903840413`*^9, 3.696854795007275*^9}}], Cell[BoxData[ RowBox[{"?", "/;"}]], "Input", CellChangeTimes->{{3.6968549793732696`*^9, 3.6968549826077943`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", RowBox[{ RowBox[{"1", "-", SuperscriptBox["x", "2"]}], "/;", RowBox[{ RowBox[{"-", "1"}], "<", "x", "\[LessEqual]", "1"}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", RowBox[{ RowBox[{"f", "[", RowBox[{"x", "-", "2"}], "]"}], "/;", RowBox[{"x", ">", "1"}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", RowBox[{ RowBox[{"f", "[", RowBox[{"x", "+", "2"}], "]"}], "/;", RowBox[{"x", "\[LessEqual]", "1"}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{"(*", RowBox[{"Plot", "[", RowBox[{ RowBox[{"f", "[", "x", "]"}], ",", RowBox[{"{", RowBox[{"x", ",", RowBox[{"-", "5"}], ",", "5"}], "}"}]}], "]"}], "*)"}]}], "\[IndentingNewLine]", RowBox[{ RowBox[{"Trace", "[", RowBox[{"f", "[", "4.56", "]"}], "]"}], ";"}]}], "Input", CellChangeTimes->{{3.696854968995963*^9, 3.69685497438286*^9}, { 3.696855019145131*^9, 3.6968550737655725`*^9}, {3.6968551095675125`*^9, 3.6968551445627623`*^9}, {3.6968551948743644`*^9, 3.6968552063018017`*^9}, 3.6968553073329053`*^9}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", RowBox[{"f", ",", "z", ",", "y"}], "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", RowBox[{"Module", "[", RowBox[{ RowBox[{"{", RowBox[{"y", ",", "z", ",", "w"}], "}"}], ",", "\[IndentingNewLine]", RowBox[{ RowBox[{"y", "=", SqrtBox["x"]}], ";", "\[IndentingNewLine]", RowBox[{"z", "=", RowBox[{ SubsuperscriptBox["\[Integral]", "1", "y"], RowBox[{ RowBox[{"Sin", "[", RowBox[{"t", "+", "x"}], "]"}], RowBox[{"\[DifferentialD]", "t"}]}]}]}], ";", "\[IndentingNewLine]", "w"}]}], "\[IndentingNewLine]", "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "[", "2", "]"}]}], "Input", CellChangeTimes->{{3.696855531487018*^9, 3.6968556966559105`*^9}, { 3.696855771077402*^9, 3.696855777445868*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", SuperscriptBox["x", "2"]}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "[", "5", "]"}]}], "Input", CellChangeTimes->{{3.6968559148967*^9, 3.6968559368684382`*^9}}], Cell[BoxData[ RowBox[{ RowBox[{ SuperscriptBox["#", "2"], "&"}], "[", "5", "]"}]], "Input", CellChangeTimes->{{3.696855960252364*^9, 3.696855976158377*^9}}], Cell[BoxData[ RowBox[{"\[IndentingNewLine]", RowBox[{"test", "[", RowBox[{"-", "5"}], "]"}]}]], "Input", CellChangeTimes->{{3.6968561209482355`*^9, 3.6968561276295595`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{ RowBox[{"test", "[", "x_", "]"}], ":=", RowBox[{"x", ">", "2"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"Select", "[", RowBox[{ RowBox[{"{", RowBox[{"1", ",", "2", ",", "4", ",", "7", ",", "6", ",", "2"}], "}"}], ",", "test"}], "]"}]}], "Input", CellChangeTimes->{{3.696856058894272*^9, 3.6968560777535443`*^9}}], Cell[BoxData[ RowBox[{"Select", "[", RowBox[{ RowBox[{"{", RowBox[{"1", ",", "2", ",", "4", ",", "7", ",", "6", ",", "2"}], "}"}], ",", RowBox[{ RowBox[{"#", ">", "2"}], "&"}]}], "]"}]], "Input", CellChangeTimes->{{3.696856029200917*^9, 3.6968560479976826`*^9}}], Cell[BoxData[{ RowBox[{"t", ":=", RowBox[{ RowBox[{ SuperscriptBox["#1", "2"], "-", "#2"}], "&"}]}], "\[IndentingNewLine]", RowBox[{"t", "[", RowBox[{"Pi", ",", "E"}], "]"}]}], "Input", CellChangeTimes->{{3.6968561963326426`*^9, 3.696856244744687*^9}}], Cell[BoxData[ RowBox[{"Options", "[", "Plot", "]"}]], "Input", CellChangeTimes->{{3.696856665426794*^9, 3.696856669129136*^9}}], Cell[BoxData[ RowBox[{"Plot", "[", RowBox[{ RowBox[{"Sin", "[", "x", "]"}], ",", RowBox[{"{", RowBox[{"x", ",", "0", ",", RowBox[{"6", "Pi"}]}], "}"}], ",", RowBox[{"AlignmentPoint", "\[Rule]", "Center"}], ",", RowBox[{"AspectRatio", "\[Rule]", FractionBox["1", "GoldenRatio"]}], ",", RowBox[{"Axes", "\[Rule]", "True"}], ",", RowBox[{"AxesLabel", "\[Rule]", "None"}], ",", RowBox[{"AxesOrigin", "\[Rule]", "Automatic"}], ",", RowBox[{"AxesStyle", "\[Rule]", RowBox[{"{", "}"}]}], ",", RowBox[{"Background", "\[Rule]", "None"}], ",", RowBox[{"BaselinePosition", "\[Rule]", "Automatic"}], ",", RowBox[{"BaseStyle", "\[Rule]", RowBox[{"{", "}"}]}], ",", RowBox[{"ClippingStyle", "\[Rule]", "None"}], ",", RowBox[{"ColorFunction", "\[Rule]", "Automatic"}], ",", RowBox[{"ColorFunctionScaling", "\[Rule]", "True"}], ",", RowBox[{"ColorOutput", "\[Rule]", "Automatic"}], ",", RowBox[{"ContentSelectable", "\[Rule]", "Automatic"}], ",", RowBox[{"CoordinatesToolOptions", "\[Rule]", "Automatic"}], ",", RowBox[{"DisplayFunction", "\[RuleDelayed]", "$DisplayFunction"}], ",", RowBox[{"Epilog", "\[Rule]", RowBox[{"{", "}"}]}], ",", RowBox[{"Evaluated", "\[Rule]", "Automatic"}], ",", RowBox[{"EvaluationMonitor", "\[Rule]", "None"}], ",", RowBox[{"Exclusions", "\[Rule]", "Automatic"}], ",", RowBox[{"ExclusionsStyle", "\[Rule]", "None"}], ",", RowBox[{"Filling", "\[Rule]", "None"}], ",", RowBox[{"FillingStyle", "\[Rule]", "Automatic"}], ",", RowBox[{"FormatType", "\[RuleDelayed]", "TraditionalForm"}], ",", RowBox[{"Frame", "\[Rule]", "False"}], ",", RowBox[{"FrameLabel", "\[Rule]", "None"}], ",", RowBox[{"FrameStyle", "\[Rule]", RowBox[{"{", "}"}]}], ",", RowBox[{"FrameTicks", "\[Rule]", "Automatic"}], ",", RowBox[{"FrameTicksStyle", "\[Rule]", RowBox[{"{", "}"}]}], ",", RowBox[{"GridLines", "\[Rule]", "None"}], ",", RowBox[{"GridLinesStyle", "\[Rule]", RowBox[{"{", "}"}]}], ",", RowBox[{"ImageMargins", "\[Rule]", "0.`"}], ",", RowBox[{"ImagePadding", "\[Rule]", "All"}], ",", RowBox[{"ImageSize", "\[Rule]", "Automatic"}], ",", RowBox[{"ImageSizeRaw", "\[Rule]", "Automatic"}], ",", RowBox[{"LabelStyle", "\[Rule]", RowBox[{"{", "}"}]}], ",", RowBox[{"MaxRecursion", "\[Rule]", "Automatic"}], ",", RowBox[{"Mesh", "\[Rule]", "None"}], ",", RowBox[{"MeshFunctions", "\[Rule]", RowBox[{"{", RowBox[{"#1", "&"}], "}"}]}], ",", RowBox[{"MeshShading", "\[Rule]", "None"}], ",", RowBox[{"MeshStyle", "\[Rule]", "Automatic"}], ",", RowBox[{"Method", "\[Rule]", "Automatic"}], ",", RowBox[{"PerformanceGoal", "\[RuleDelayed]", "$PerformanceGoal"}], ",", RowBox[{"PlotLabel", "\[Rule]", "None"}], ",", RowBox[{"PlotLabels", "\[Rule]", "None"}], ",", RowBox[{"PlotLegends", "\[Rule]", "None"}], ",", RowBox[{"PlotPoints", "\[Rule]", "Automatic"}], ",", RowBox[{"PlotRange", "\[Rule]", RowBox[{"{", RowBox[{"Full", ",", "Automatic"}], "}"}]}], ",", RowBox[{"PlotRangeClipping", "\[Rule]", "True"}], ",", RowBox[{"PlotRangePadding", "\[Rule]", "Automatic"}], ",", RowBox[{"PlotRegion", "\[Rule]", "Automatic"}], ",", RowBox[{"PlotStyle", "\[Rule]", "Automatic"}], ",", RowBox[{"PlotTheme", "\[RuleDelayed]", "$PlotTheme"}], ",", RowBox[{"PreserveImageOptions", "\[Rule]", "Automatic"}], ",", RowBox[{"Prolog", "\[Rule]", RowBox[{"{", "}"}]}], ",", RowBox[{"RegionFunction", "\[Rule]", RowBox[{"(", RowBox[{"True", "&"}], ")"}]}], ",", RowBox[{"RotateLabel", "\[Rule]", "True"}], ",", RowBox[{"TargetUnits", "\[Rule]", "Automatic"}], ",", RowBox[{"Ticks", "\[Rule]", "Automatic"}], ",", RowBox[{"TicksStyle", "\[Rule]", RowBox[{"{", "}"}]}], ",", RowBox[{"WorkingPrecision", "\[Rule]", "MachinePrecision"}]}], "]"}]], "Input", CellChangeTimes->{{3.6968563782342453`*^9, 3.69685637945308*^9}, 3.6968565281544333`*^9, {3.696856707996477*^9, 3.6968567131305456`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"x", "=", RowBox[{"10", "!"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"Plot", "[", RowBox[{ RowBox[{"Sin", "[", "x", "]"}], ",", RowBox[{"{", RowBox[{"x", ",", "0", ",", RowBox[{"6", "Pi"}]}], "}"}], ",", RowBox[{"AxesLabel", "\[Rule]", RowBox[{"{", RowBox[{"\"\\"", ",", "\"\\""}], "}"}]}]}], "]"}], ";"}]}], "Input", CellChangeTimes->{{3.6968568876302223`*^9, 3.696857035327629*^9}, { 3.696857072363805*^9, 3.6968571050667405`*^9}}], Cell[BoxData[ RowBox[{ RowBox[{"(*", RowBox[{ "Here", " ", "is", " ", "begining", " ", "second", " ", "lecture", " ", "2.3", ".2017"}], "*)"}], "\[IndentingNewLine]", RowBox[{"Plot", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"Sin", "[", "x", "]"}], ",", RowBox[{"Cos", "[", "x", "]"}], ",", RowBox[{"2", "*", RowBox[{"Sin", "[", RowBox[{"x", "+", "2"}], "]"}]}]}], "}"}], ",", RowBox[{"{", RowBox[{"x", ",", "0", ",", RowBox[{"6", "Pi"}]}], "}"}], ",", RowBox[{"PlotStyle", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"Red", ",", "Dashed"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"Hue", "[", "0.12", "]"}], ",", RowBox[{"Thickness", "[", "0.02", "]"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"RGBColor", "[", RowBox[{"1", ",", "0", ",", "1"}], "]"}], ",", "Thick"}], "}"}]}], "}"}]}]}], "]"}]}]], "Input", CellChangeTimes->{{3.697450548657158*^9, 3.697450588539073*^9}, 3.6974506403160453`*^9, {3.6974507137415743`*^9, 3.697450730660407*^9}, { 3.69745092810987*^9, 3.697450972550098*^9}, {3.6974510113663397`*^9, 3.6974510259424524`*^9}, {3.6974512286145887`*^9, 3.697451292989437*^9}, { 3.6974513560815067`*^9, 3.69745137937831*^9}, {3.6974514682262516`*^9, 3.6974514783149524`*^9}}], Cell[BoxData[""], "Input", CellChangeTimes->{{3.6974511590210733`*^9, 3.6974511644448795`*^9}, 3.697451736414878*^9}], Cell[BoxData[ RowBox[{"Manipulate", "[", RowBox[{ RowBox[{"Plot", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"a", "*", RowBox[{"Sin", "[", "x", "]"}]}], ",", RowBox[{"Cos", "[", RowBox[{"b", "+", "x"}], "]"}], ",", RowBox[{"2", "*", RowBox[{"Sin", "[", RowBox[{"x", "+", "2"}], "]"}]}]}], "}"}], ",", RowBox[{"{", RowBox[{"x", ",", "0", ",", RowBox[{"6", "Pi"}]}], "}"}], ",", RowBox[{"PlotStyle", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"Red", ",", "Dashed"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"Hue", "[", "a", "]"}], ",", RowBox[{"Thickness", "[", "0.02", "]"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"RGBColor", "[", RowBox[{"1", ",", "0", ",", "1"}], "]"}], ",", "Thick"}], "}"}]}], "}"}]}]}], "]"}], ",", RowBox[{"{", RowBox[{"a", ",", "0", ",", "1"}], "}"}], ",", RowBox[{"{", RowBox[{"b", ",", RowBox[{"-", "5"}], ",", "5", ",", "1"}], "}"}]}], "]"}]], "Input", CellChangeTimes->{{3.69745173867074*^9, 3.697451744351427*^9}, { 3.6974517967606754`*^9, 3.6974518146483955`*^9}, {3.697452058714704*^9, 3.6974520589070835`*^9}, {3.697452098515844*^9, 3.6974521288462334`*^9}}], Cell[BoxData[ RowBox[{"Manipulate", "[", RowBox[{ RowBox[{"LogLogPlot", "[", RowBox[{ RowBox[{"Abs", "[", RowBox[{"R", "+", RowBox[{"I", "*", "\[Omega]", "*", "L"}], "+", FractionBox["1", RowBox[{"I", "*", "\[Omega]", "*", "kap"}]]}], "]"}], ",", RowBox[{"{", RowBox[{"\[Omega]", ",", SuperscriptBox["10", RowBox[{"-", "8"}]], ",", SuperscriptBox["10", "10"]}], "}"}], ",", RowBox[{"PlotRange", "\[Rule]", RowBox[{"{", RowBox[{"Automatic", ",", RowBox[{"{", RowBox[{ SuperscriptBox["10", RowBox[{"-", "10"}]], ",", SuperscriptBox["10", "15"]}], "}"}]}], "}"}]}]}], "]"}], ",", RowBox[{"{", RowBox[{"R", ",", "0", ",", "1000000"}], "}"}], ",", RowBox[{"{", RowBox[{"L", ",", "0.001", ",", "1"}], "}"}], ",", RowBox[{"{", RowBox[{"kap", ",", RowBox[{"10", "*", SuperscriptBox["10", RowBox[{"-", "9"}]]}], ",", RowBox[{"10", "*", SuperscriptBox["10", RowBox[{"-", "3"}]]}]}], "}"}]}], "]"}]], "Input", CellChangeTimes->{{3.6974522676318655`*^9, 3.697452304571609*^9}, { 3.697452388302493*^9, 3.697452513412304*^9}, {3.6974526638180847`*^9, 3.6974526700700884`*^9}, {3.697453082013976*^9, 3.697453110538643*^9}}], Cell[BoxData[{ RowBox[{"ClearAll", "[", "f", "]"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", RowBox[{"x", ":", "_"}], "]"}], ":=", SuperscriptBox["x", "2"]}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "[", "5", "]"}]}], "Input", CellChangeTimes->{{3.697453435095379*^9, 3.6974534652333193`*^9}}], Cell[BoxData[{ RowBox[{"ClearAll", "[", "f", "]"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", SuperscriptBox["x", "2"]}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "[", "5", "]"}]}], "Input", CellChangeTimes->{3.6974535737347813`*^9}], Cell[BoxData[ RowBox[{"?", "/."}]], "Input", CellChangeTimes->{{3.6974535863261137`*^9, 3.6974535881269627`*^9}}], Cell[BoxData[ RowBox[{ RowBox[{ SuperscriptBox["x", "2"], "+", "1"}], "/.", RowBox[{"x", "\[Rule]", "4"}]}]], "Input", CellChangeTimes->{{3.697453668185858*^9, 3.6974536894119377`*^9}}], Cell[BoxData[ RowBox[{ RowBox[{"x", "\[Rule]", "4"}], "//", "TreeForm"}]], "Input", CellChangeTimes->{{3.697453788790318*^9, 3.6974537933470235`*^9}}], Cell[BoxData[ RowBox[{"Rule", "[", RowBox[{"x", ",", "4"}], "]"}]], "Input", CellChangeTimes->{{3.697453823358199*^9, 3.697453826686366*^9}}], Cell[BoxData[ RowBox[{ RowBox[{"x", "\[Rule]", "4"}], "//", "FullForm"}]], "Input", CellChangeTimes->{{3.6974538849997015`*^9, 3.697453891573042*^9}}], Cell[BoxData[ RowBox[{ RowBox[{ SuperscriptBox["x", "2"], "+", "1"}], "/.", RowBox[{"x", "\[Rule]", "4"}]}]], "Input"], Cell[BoxData[ RowBox[{ RowBox[{ SuperscriptBox["x", "2"], "+", "1"}], "/.", RowBox[{"{", RowBox[{ RowBox[{"x", "\[Rule]", "4"}], ",", RowBox[{"x", "\[Rule]", "5"}]}], "}"}]}]], "Input", CellChangeTimes->{{3.69745390997662*^9, 3.6974539162569838`*^9}}], Cell[BoxData[ RowBox[{ RowBox[{ SuperscriptBox["x", "2"], "+", "1"}], "/.", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"x", "\[Rule]", "4"}], "}"}], ",", RowBox[{"{", RowBox[{"x", "\[Rule]", "5"}], "}"}]}], "}"}]}]], "Input", CellChangeTimes->{{3.6974540382661457`*^9, 3.697454042954653*^9}}], Cell[BoxData[ RowBox[{ RowBox[{ SuperscriptBox["x", "2"], "+", "1", "+", "y"}], "/.", RowBox[{"{", RowBox[{ RowBox[{"x", "\[Rule]", "4"}], ",", RowBox[{"y", "\[Rule]", "5"}]}], "}"}]}]], "Input", CellChangeTimes->{{3.6974539564089236`*^9, 3.697453959865028*^9}}], Cell[BoxData[ RowBox[{ RowBox[{ SuperscriptBox["x", "2"], "+", "1"}], "/.", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"x", "\[Rule]", "4"}], "}"}], ",", RowBox[{"{", RowBox[{"x", "\[Rule]", "5"}], "}"}]}], "}"}]}]], "Input"], Cell[BoxData[ RowBox[{ RowBox[{ SuperscriptBox["x", "2"], "\[Equal]", "1"}], "//", "TreeForm"}]], "Input", CellChangeTimes->{{3.697454192884567*^9, 3.6974542028045645`*^9}, { 3.697454260524756*^9, 3.697454297811187*^9}}], Cell[BoxData[ RowBox[{"Equal", "[", RowBox[{"1", "\[Equal]", "2"}], "]"}]], "Input", CellChangeTimes->{{3.6974543597833643`*^9, 3.6974543693351994`*^9}}], Cell[BoxData[ RowBox[{"Equal", "[", RowBox[{"a", ",", "b"}], "]"}]], "Input", CellChangeTimes->{{3.6974543394091835`*^9, 3.697454344381872*^9}}], Cell[BoxData[ RowBox[{ RowBox[{"f", "[", "0", "]"}], "=", "5"}]], "Input", CellChangeTimes->{{3.697458211449796*^9, 3.697458218829773*^9}}], Cell[BoxData[ RowBox[{"Solve", "[", RowBox[{ SuperscriptBox["x", "2"], "\[Equal]", "1"}], "]"}]], "Input", CellChangeTimes->{{3.697454099306671*^9, 3.697454104709053*^9}}], Cell[BoxData[ RowBox[{"list", "[", RowBox[{"[", "0", "]"}], "]"}]], "Input", CellChangeTimes->{{3.697454774531251*^9, 3.6974547781309977`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"list", "=", RowBox[{"{", RowBox[{"me", ",", "you", ",", RowBox[{"{", RowBox[{"mother", ",", "father"}], "}"}]}], "}"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"list", "[", RowBox[{"[", "1", "]"}], "]"}], "\[IndentingNewLine]", RowBox[{"First", "[", "list", "]"}]}], "Input", CellChangeTimes->{{3.6974546001495123`*^9, 3.6974546673720913`*^9}, { 3.697454700094688*^9, 3.6974547076311197`*^9}}], Cell[BoxData[ RowBox[{"list", "[", RowBox[{"[", RowBox[{"3", ",", "1"}], "]"}], "]"}]], "Input", CellChangeTimes->{{3.6974548616714478`*^9, 3.697454909537631*^9}}], Cell[BoxData[ RowBox[{ RowBox[{"list", "[", RowBox[{"[", "3", "]"}], "]"}], "[", RowBox[{"[", "1", "]"}], "]"}]], "Input", CellChangeTimes->{{3.6974548220946736`*^9, 3.6974548516065907`*^9}}], Cell[BoxData[{ RowBox[{"list", "[", RowBox[{"[", RowBox[{"-", "1"}], "]"}], "]"}], "\[IndentingNewLine]", RowBox[{"Last", "[", "list", "]"}]}], "Input", CellChangeTimes->{{3.6974547202712765`*^9, 3.6974547515381455`*^9}}], Cell[BoxData[{ RowBox[{"SpokenString", "[", RowBox[{ SuperscriptBox["x", "2"], "+", RowBox[{"2", "a", "*", "x"}], "+", FractionBox["1", RowBox[{ SuperscriptBox["a", "2"], "+", "1"}]]}], "]"}], "\[IndentingNewLine]", RowBox[{"Speak", "[", "%", "]"}]}], "Input", CellChangeTimes->{{3.697455080517868*^9, 3.6974551049589663`*^9}}], Cell[BoxData[ RowBox[{"sol", "[", RowBox[{"[", "1", "]"}], "]"}]], "Input", CellChangeTimes->{{3.6974553808973846`*^9, 3.69745538335252*^9}}], Cell[BoxData[ RowBox[{"Remove", "[", "\"\\"", "]"}]], "Input", CellChangeTimes->{{3.6974556041067476`*^9, 3.69745560685141*^9}}], Cell[BoxData[{ RowBox[{"ClearAll", "[", "\"\\"", "]"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"eqn", "=", RowBox[{ RowBox[{ SuperscriptBox["x", "2"], "+", RowBox[{"2", "a", "*", "x"}], "+", FractionBox["1", RowBox[{ SuperscriptBox["a", "2"], "+", "1"}]]}], "\[Equal]", "0"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"sol", "=", RowBox[{"Solve", "[", RowBox[{"eqn", ",", "x"}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"x1", "=", RowBox[{ SuperscriptBox["E", RowBox[{"a", "*", RowBox[{"(", RowBox[{"x", "+", "1"}], ")"}]}]], "/.", RowBox[{"sol", "[", RowBox[{"[", "1", "]"}], "]"}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{"Plot", "[", RowBox[{"x1", ",", RowBox[{"{", RowBox[{"a", ",", "1", ",", "2"}], "}"}]}], "]"}]}], "Input", CellChangeTimes->{{3.6974550517797966`*^9, 3.697455071070351*^9}, { 3.697455119599972*^9, 3.6974551984975967`*^9}, {3.6974553204938183`*^9, 3.697455363582582*^9}, {3.6974553949113398`*^9, 3.697455434998934*^9}, { 3.6974554984532976`*^9, 3.697455546341873*^9}, 3.6974556157971983`*^9, { 3.697455664130039*^9, 3.697455668193821*^9}, {3.6974569033511596`*^9, 3.6974569092314014`*^9}}], Cell[BoxData[ RowBox[{ RowBox[{"a", "+", "b", "+", "c", "+", "d", "+", "e"}], "//", "TreeForm"}]], "Input", CellChangeTimes->{{3.697457219365831*^9, 3.6974572329762754`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"Range", "[", "10", "]"}], "/.", RowBox[{"List", "\[Rule]", "Times"}]}], "\[IndentingNewLine]", RowBox[{"10", "!"}]}], "Input", CellChangeTimes->{{3.6974571063738127`*^9, 3.6974571125847864`*^9}, { 3.697457155809705*^9, 3.6974571877523155`*^9}, {3.6974572914435005`*^9, 3.697457307219984*^9}, {3.697457403212884*^9, 3.6974574558216677`*^9}, { 3.697457504775236*^9, 3.6974575111270485`*^9}}], Cell[BoxData[ RowBox[{"FindRoot", "[", RowBox[{ RowBox[{ RowBox[{"Cos", "[", "x", "]"}], "\[Equal]", "x"}], ",", RowBox[{"{", RowBox[{"x", ",", "0"}], "}"}]}], "]"}]], "Input", CellChangeTimes->{{3.6974579331981044`*^9, 3.6974579556409273`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], "=", SuperscriptBox["x", "2"]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"lhs", "\[Equal]", "rhs"}], "/.", RowBox[{ RowBox[{"(", RowBox[{"a_", "\[Equal]", "b_"}], ")"}], "\[Rule]", RowBox[{"a", "-", "b"}]}]}]}], "Input", CellChangeTimes->{{3.697458595619155*^9, 3.6974586163802757`*^9}}], Cell[BoxData[ RowBox[{"\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", SuperscriptBox["x", "2"]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"lhs", "\[Equal]", "rhs"}], "/.", RowBox[{ RowBox[{"(", RowBox[{"a_", "\[Equal]", "b_"}], ")"}], "\[RuleDelayed]", RowBox[{"a", "-", "b"}]}]}]}]}]], "Input", CellChangeTimes->{{3.6974582339237328`*^9, 3.697458258318591*^9}, { 3.697458298416797*^9, 3.6974583235753465`*^9}, {3.6974585642167187`*^9, 3.6974585729770555`*^9}}], Cell[BoxData[{ RowBox[{"a", ":=", RowBox[{ "Random", "[", "]"}]}], "\[IndentingNewLine]", "a", "\[IndentingNewLine]"}], "Input", CellChangeTimes->{{3.6974583901846795`*^9, 3.6974584586436462`*^9}}], Cell[BoxData[{ RowBox[{"a", "=", RowBox[{"Random", "[", "]"}]}], "\[IndentingNewLine]", RowBox[{"?", "a"}]}], "Input", CellChangeTimes->{{3.697458475682948*^9, 3.6974584894510975`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"eqn", "=", RowBox[{ RowBox[{"Sin", "[", "x", "]"}], "\[Equal]", "1"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"sol", "=", RowBox[{"FindRoot", "[", RowBox[{"eqn", ",", RowBox[{"{", RowBox[{"x", ",", "10"}], "}"}]}], "]"}]}], "\[IndentingNewLine]", RowBox[{ RowBox[{"(", RowBox[{"eqn", "/.", RowBox[{ RowBox[{"a_", "\[Equal]", "b_"}], "\[RuleDelayed]", RowBox[{"a", "-", "b"}]}]}], ")"}], "/.", "sol"}]}], "Input", CellChangeTimes->{{3.697458689229787*^9, 3.69745870684227*^9}, { 3.6974587816401577`*^9, 3.697458810897989*^9}, {3.6974588434186068`*^9, 3.697458893756222*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", "x_Integer", "]"}], ":=", RowBox[{"x", "+", "1"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "[", "10", "]"}]}], "Input", CellChangeTimes->{{3.697459085331896*^9, 3.6974591381418934`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{ RowBox[{"test", "[", "x_", "]"}], ":=", RowBox[{"x", ">", "5"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", RowBox[{"x_", "?", "test"}], "]"}], ":=", RowBox[{"x", "+", "1"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "[", "4", "]"}]}], "Input", CellChangeTimes->{{3.6974591984296427`*^9, 3.697459260913733*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", RowBox[{"x_", "?", RowBox[{"(", RowBox[{ RowBox[{"#", ">", "5"}], "&"}], ")"}]}], "]"}], ":=", RowBox[{"x", "+", "1"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"f", "[", "4", "]"}]}], "Input", CellChangeTimes->{{3.6974593495664997`*^9, 3.6974593656616564`*^9}, { 3.697459410889244*^9, 3.6974594650163293`*^9}}], Cell[BoxData[ RowBox[{"Table", "[", RowBox[{"\"\\"", ",", RowBox[{"{", "10", "}"}]}], "]"}]], "Input", CellChangeTimes->{{3.697459508000615*^9, 3.697459523905297*^9}}], Cell[BoxData[ RowBox[{"Table", "[", RowBox[{"i", ",", RowBox[{"{", RowBox[{"i", ",", "10.999"}], "}"}]}], "]"}]], "Input", CellChangeTimes->{{3.6974596099101295`*^9, 3.6974596408623357`*^9}, { 3.697459699632879*^9, 3.6974597262421813`*^9}}], Cell[BoxData[ RowBox[{"Table", "[", RowBox[{"i", ",", RowBox[{"{", RowBox[{"i", ",", "0.2", ",", "5.3", ",", "0.7"}], "}"}]}], "]"}]], "Input", CellChangeTimes->{{3.6974597481296444`*^9, 3.697459776691168*^9}}], Cell[BoxData[{ RowBox[{"list", "=", RowBox[{"Table", "[", RowBox[{ SuperscriptBox["E", "i"], ",", RowBox[{"{", RowBox[{"i", ",", "1", ",", "10"}], "}"}]}], "]"}]}], "\[IndentingNewLine]", RowBox[{"list", "/.", RowBox[{ SuperscriptBox["a_", "b_"], "\[RuleDelayed]", SuperscriptBox["b", "a"]}]}]}], "Input", CellChangeTimes->{{3.6974598325962305`*^9, 3.697459848431522*^9}, { 3.6974599021768165`*^9, 3.6974599029854198`*^9}, {3.6974599828669834`*^9, 3.697459985408058*^9}, {3.697460018242732*^9, 3.6974601388478127`*^9}}], Cell[BoxData[{ RowBox[{"list", "=", RowBox[{"Table", "[", RowBox[{ SuperscriptBox["E", "i"], ",", RowBox[{"{", RowBox[{"i", ",", "2", ",", "10"}], "}"}]}], "]"}]}], "\[IndentingNewLine]", RowBox[{"list", "/.", RowBox[{ SuperscriptBox["a_", RowBox[{"b_", "?", RowBox[{"(", RowBox[{ RowBox[{"#", ">", "5"}], "&"}], ")"}]}]], "\[RuleDelayed]", SuperscriptBox["b", "a"]}]}]}], "Input", CellChangeTimes->{{3.6974601893576536`*^9, 3.6974602046782875`*^9}, { 3.6974603231670947`*^9, 3.697460352242893*^9}}], Cell[BoxData[ RowBox[{ RowBox[{ RowBox[{"f", "[", RowBox[{"x_", "?", RowBox[{"(", RowBox[{ RowBox[{"#", ">", "5"}], "&"}], ")"}]}], "]"}], ":=", RowBox[{"x", "+", "1"}]}], ";"}]], "Input"], Cell[BoxData[{ RowBox[{ RowBox[{"points", "=", RowBox[{"Table", "[", RowBox[{ RowBox[{"{", RowBox[{"x", ",", SuperscriptBox["x", "2"]}], "}"}], ",", RowBox[{"{", RowBox[{"x", ",", RowBox[{"-", "1"}], ",", "1", ",", "0.1"}], "}"}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"pl1", "=", RowBox[{"ListPlot", "[", "points", "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"pl1", "/.", RowBox[{ RowBox[{"{", RowBox[{"x_", ",", "y_"}], "}"}], "\[RuleDelayed]", RowBox[{"{", RowBox[{"y", ",", "x"}], "}"}]}]}], "\[IndentingNewLine]"}], "Input", CellChangeTimes->{{3.6974604915084734`*^9, 3.697460510343828*^9}, { 3.697460596177058*^9, 3.697460639986826*^9}, {3.697460670779648*^9, 3.6974606929159875`*^9}, {3.697460743710331*^9, 3.697460839136685*^9}, { 3.697460911282713*^9, 3.6974609194108105`*^9}}], Cell[BoxData[ RowBox[{"DSolve", "[", RowBox[{ RowBox[{ RowBox[{ RowBox[{"y", "'"}], "[", "x", "]"}], "\[Equal]", RowBox[{"-", RowBox[{"y", "[", "x", "]"}]}]}], ",", RowBox[{"y", "[", "x", "]"}], ",", "x"}], "]"}]], "Input", CellChangeTimes->{{3.6974609980257163`*^9, 3.6974610339756775`*^9}, { 3.6974613356068096`*^9, 3.697461340134246*^9}}], Cell[BoxData[ RowBox[{"sol", "=", RowBox[{"DSolve", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{ RowBox[{ RowBox[{"y", "'"}], "[", "x", "]"}], "\[Equal]", RowBox[{"-", RowBox[{"y", "[", "x", "]"}]}]}], ",", RowBox[{ RowBox[{"y", "[", "0", "]"}], "\[Equal]", "10"}]}], "}"}], ",", RowBox[{"y", "[", "x", "]"}], ",", "x"}], "]"}]}]], "Input", CellChangeTimes->{{3.6974613204522066`*^9, 3.697461322349705*^9}, { 3.697461457202059*^9, 3.6974615002185626`*^9}, {3.6974615347720113`*^9, 3.6974615356675367`*^9}, {3.6974617095285254`*^9, 3.6974617098634925`*^9}}], Cell[BoxData[ RowBox[{"Plot", "[", RowBox[{ RowBox[{ RowBox[{"y", "[", "x", "]"}], "/.", "sol"}], ",", RowBox[{"{", RowBox[{"x", ",", "0", ",", "5"}], "}"}]}], "]"}]], "Input", CellChangeTimes->{{3.697461728048438*^9, 3.697461769410598*^9}}], Cell[BoxData[ RowBox[{"(*", RowBox[{"1.", "test", " ", "9.3", ".2017"}], "*)"}]], "Input", CellChangeTimes->{{3.6980628123578033`*^9, 3.698062822905399*^9}}], Cell[BoxData[{ RowBox[{"sol", "=", RowBox[{"DSolve", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{ RowBox[{ RowBox[{ RowBox[{"y", "''"}], "[", "t", "]"}], "+", RowBox[{ FractionBox["1", RowBox[{ SuperscriptBox["t", "2"], "+", "1"}]], "*", RowBox[{"y", "[", "t", "]"}]}]}], "\[Equal]", "0"}], ",", RowBox[{ RowBox[{"y", "[", "0", "]"}], "\[Equal]", "0"}], ",", RowBox[{ RowBox[{ RowBox[{"y", "'"}], "[", "0", "]"}], "\[Equal]", "1"}]}], "}"}], ",", RowBox[{"y", "[", "t", "]"}], ",", "t"}], "]"}]}], "\[IndentingNewLine]", RowBox[{"Plot", "[", RowBox[{ RowBox[{ RowBox[{"y", "[", "t", "]"}], "/.", "sol"}], ",", RowBox[{"{", RowBox[{"t", ",", "0", ",", "12"}], "}"}], ",", RowBox[{"PlotStyle", "\[Rule]", RowBox[{"{", RowBox[{"Thick", ",", "Brown"}], "}"}]}], ",", RowBox[{"AxesLabel", "\[Rule]", RowBox[{"{", RowBox[{"\"\\"", ",", "\"\\""}], "}"}]}], ",", RowBox[{"GridLines", "\[Rule]", "Automatic"}]}], "]"}]}], "Input", CellChangeTimes->{{3.698061579101777*^9, 3.6980615831487284`*^9}, { 3.6980616716648693`*^9, 3.6980617731342688`*^9}, {3.698061847994167*^9, 3.698061922119626*^9}, {3.698061956338586*^9, 3.6980620491047754`*^9}, 3.698062104448804*^9}], Cell[BoxData[{ RowBox[{"sol2", "=", RowBox[{"Solve", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{ RowBox[{"a", "+", RowBox[{"2", "b"}]}], "\[Equal]", RowBox[{"Cos", "[", RowBox[{ RowBox[{"2", "x"}], "+", "1"}], "]"}]}], ",", RowBox[{ RowBox[{"a", "-", RowBox[{"7", "b"}]}], "\[Equal]", RowBox[{"Sin", "[", RowBox[{"x", "-", "1"}], "]"}]}]}], "}"}], ",", RowBox[{"{", RowBox[{"a", ",", "b"}], "}"}]}], "]"}]}], "\[IndentingNewLine]", RowBox[{"Plot", "[", RowBox[{ RowBox[{ RowBox[{ SuperscriptBox["a", "2"], "+", SuperscriptBox["b", "2"]}], "/.", "sol2"}], ",", RowBox[{"{", RowBox[{"x", ",", "0", ",", RowBox[{"4", "Pi"}]}], "}"}], ",", RowBox[{"PlotStyle", "\[Rule]", RowBox[{"{", RowBox[{"Thick", ",", "Red"}], "}"}]}], ",", RowBox[{"AxesLabel", "\[Rule]", RowBox[{"{", RowBox[{ "\"\\"", ",", "\"\<\!\(\*SuperscriptBox[\(a\), \(2\)]\)+\!\(\*SuperscriptBox[\(b\), \ \(2\)]\)\>\""}], "}"}]}]}], "]"}], "\[IndentingNewLine]"}], "Input", CellChangeTimes->{{3.6980622558560505`*^9, 3.698062260465455*^9}, { 3.6980623384346495`*^9, 3.6980623448878765`*^9}, {3.6980624196383643`*^9, 3.6980624766227407`*^9}, {3.698062534622746*^9, 3.6980626543946466`*^9}}], Cell[BoxData[ RowBox[{"(*", RowBox[{"Third", " ", "Lecture", " ", "9.3", ".2017"}], "*)"}]], "Input", CellChangeTimes->{{3.698062827405636*^9, 3.6980628464537764`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"data", "=", RowBox[{"Table", "[", RowBox[{ RowBox[{"{", RowBox[{"x", ",", RowBox[{"Sin", "[", "x", "]"}]}], "}"}], ",", RowBox[{"{", RowBox[{"x", ",", "0.", ",", RowBox[{"2", "Pi"}], ",", FractionBox["Pi", "5"]}], "}"}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"intSin", "=", RowBox[{"Interpolation", "[", RowBox[{"data", ",", RowBox[{"InterpolationOrder", "\[Rule]", "3"}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"intSin", "[", RowBox[{"[", RowBox[{"1", ",", "1"}], "]"}], "]"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"(*", RowBox[{ RowBox[{"Plot", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"intSin", "[", "x", "]"}], ",", RowBox[{"Sin", "[", "x", "]"}]}], "}"}], ",", RowBox[{"{", RowBox[{"x", ",", RowBox[{ RowBox[{"-", "2"}], "Pi"}], ",", RowBox[{"4", "Pi"}]}], "}"}]}], "]"}], ";"}], "*)"}]}]}], "Input", CellChangeTimes->{{3.698062989817951*^9, 3.698063038194523*^9}, { 3.6980631248691287`*^9, 3.698063137463273*^9}, {3.6980633852805567`*^9, 3.698063458359964*^9}, {3.698063503938975*^9, 3.698063551799229*^9}, { 3.698063592158515*^9, 3.6980636521264434`*^9}, {3.698063711313238*^9, 3.698063750109564*^9}, 3.698063924342369*^9, {3.6980639594674034`*^9, 3.698063976061141*^9}, 3.698064045857967*^9, {3.698064089248504*^9, 3.6980642003734884`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"data", "=", RowBox[{"Table", "[", RowBox[{ RowBox[{"{", RowBox[{"x", ",", RowBox[{"Sin", "[", "x", "]"}]}], "}"}], ",", RowBox[{"{", RowBox[{"x", ",", "0.", ",", RowBox[{"2", "Pi"}], ",", FractionBox["Pi", "5"]}], "}"}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"intSin", "=", RowBox[{"Interpolation", "[", RowBox[{"data", ",", RowBox[{"InterpolationOrder", "\[Rule]", "3"}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"{", RowBox[{"xmin", ",", "xmax"}], "}"}], "=", RowBox[{"intSin", "[", RowBox[{"[", RowBox[{"1", ",", "1"}], "]"}], "]"}]}], "\[IndentingNewLine]", RowBox[{"Plot", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"intSin", "[", "x", "]"}], ",", RowBox[{"Sin", "[", "x", "]"}]}], "}"}], ",", RowBox[{"{", RowBox[{"x", ",", "xmin", ",", "xmax"}], "}"}]}], "]"}]}], "Input", CellChangeTimes->{{3.6980642116859818`*^9, 3.698064230654722*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"x", "[", "y_", "]"}], ":=", RowBox[{"x", "/.", RowBox[{"FindRoot", "[", RowBox[{ RowBox[{"y", "\[Equal]", RowBox[{"x", "+", SuperscriptBox["E", "x"]}]}], ",", RowBox[{"{", RowBox[{"x", ",", "1"}], "}"}]}], "]"}]}]}], "\[IndentingNewLine]", RowBox[{"x", "[", "3", "]"}]}], "Input", CellChangeTimes->{{3.6980645801552954`*^9, 3.6980646619548454`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"dataYX", "=", RowBox[{"Table", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"x", "+", SuperscriptBox["E", "x"]}], ",", "x"}], "}"}], ",", RowBox[{"{", RowBox[{"x", ",", RowBox[{"-", "1."}], ",", "5", ",", "0.01"}], "}"}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"intx", "=", RowBox[{"Interpolation", "[", "dataYX", "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"intx", "[", "3", "]"}]}], "Input", CellChangeTimes->{{3.6980647343957176`*^9, 3.6980648129464755`*^9}}], Cell[BoxData[ RowBox[{ RowBox[{"Timing", "[", RowBox[{"Table", "[", RowBox[{ RowBox[{"x", "[", "y", "]"}], ",", RowBox[{"{", RowBox[{"y", ",", "1", ",", "3", ",", "0.0001"}], "}"}]}], "]"}], "]"}], "[", RowBox[{"[", "1", "]"}], "]"}]], "Input", CellChangeTimes->{3.6980649749216404`*^9}], Cell[BoxData[ RowBox[{ RowBox[{"Timing", "[", RowBox[{"Table", "[", RowBox[{ RowBox[{"intx", "[", "y", "]"}], ",", RowBox[{"{", RowBox[{"y", ",", "1", ",", "3", ",", "0.0001"}], "}"}]}], "]"}], "]"}], "[", RowBox[{"[", "1", "]"}], "]"}]], "Input", CellChangeTimes->{{3.6980649639526014`*^9, 3.698064986156352*^9}}], Cell[BoxData[ RowBox[{ RowBox[{"0.5", "*", SuperscriptBox[ RowBox[{"(", RowBox[{"x", "-", "2"}], ")"}], "2"]}], "//", "Expand"}]], "Input", CellChangeTimes->{{3.698065532560181*^9, 3.698065542747892*^9}}], Cell[BoxData[{ RowBox[{"ClearAll", "[", RowBox[{"x", ",", "noiseLevel"}], "]"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"pureSignal", "[", "x_", "]"}], ":=", RowBox[{"2.", "\[VeryThinSpace]", "-", RowBox[{"2.", " ", "x"}], "+", RowBox[{"0.5", " ", SuperscriptBox["x", "2"]}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"noiseLevel", "=", ".5"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"noise", ":=", RowBox[{"RandomReal", "[", RowBox[{"{", RowBox[{ RowBox[{"-", "noiseLevel"}], ",", "noiseLevel"}], "}"}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"signal", "[", "x_", "]"}], ":=", RowBox[{ RowBox[{"pureSignal", "[", "x", "]"}], "+", "noise"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"data", "=", RowBox[{"Table", "[", RowBox[{ RowBox[{"{", RowBox[{"x", ",", RowBox[{"signal", "[", "x", "]"}]}], "}"}], ",", RowBox[{"{", RowBox[{"x", ",", "0", ",", "4", ",", "0.001"}], "}"}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"pl1", "=", RowBox[{"ListPlot", "[", "data", "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"fit", "=", RowBox[{"Fit", "[", RowBox[{"data", ",", RowBox[{"{", RowBox[{"1", ",", "x", ",", SuperscriptBox["x", "2"]}], "}"}], ",", "x"}], "]"}]}], "\[IndentingNewLine]", RowBox[{"Show", "[", RowBox[{"pl1", ",", RowBox[{"Plot", "[", RowBox[{"fit", ",", RowBox[{"{", RowBox[{"x", ",", "0", ",", "4"}], "}"}], ",", RowBox[{"PlotStyle", "\[Rule]", "Red"}]}], "]"}]}], "]"}], "\[IndentingNewLine]"}], "Input", CellChangeTimes->{{3.698065502293878*^9, 3.6980656767811117`*^9}, { 3.6980659588772154`*^9, 3.6980660727693653`*^9}, {3.6980662978660507`*^9, 3.698066388211054*^9}, 3.698066504446937*^9}], Cell[BoxData[ RowBox[{"Length", "[", "data", "]"}]], "Input"], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", RowBox[{"{", RowBox[{"x_", ",", "y_"}], "}"}], "]"}], ":=", SuperscriptBox[ RowBox[{"(", RowBox[{"y", "-", RowBox[{"(", RowBox[{ RowBox[{"a", "*", SuperscriptBox["x", "2"]}], "+", RowBox[{"b", "*", "x"}], "+", "c"}], ")"}]}], ")"}], "2"]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"totalErr1", "=", RowBox[{ UnderoverscriptBox["\[Sum]", RowBox[{"i", "=", "1"}], RowBox[{"Length", "[", "data", "]"}]], RowBox[{"f", "[", RowBox[{"data", "[", RowBox[{"[", "i", "]"}], "]"}], "]"}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"totalErr2", "=", RowBox[{"Total", "[", RowBox[{"f", "/@", "data"}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"eqns", "=", RowBox[{ RowBox[{ RowBox[{"0", "\[Equal]", RowBox[{"D", "[", RowBox[{"totalErr2", ",", "#"}], "]"}]}], "&"}], "/@", RowBox[{"{", RowBox[{"a", ",", "b", ",", "c"}], "}"}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{"Solve", "[", "eqns", "]"}], "\[IndentingNewLine]", "fit"}], "Input", CellChangeTimes->{{3.698661356734391*^9, 3.698661396945691*^9}, { 3.6986614594590664`*^9, 3.6986615135221267`*^9}, {3.6986615885472913`*^9, 3.6986617439405003`*^9}, {3.6986618425250645`*^9, 3.698661885350093*^9}, 3.698661984101676*^9, {3.6986621849101315`*^9, 3.698662204025168*^9}, 3.698662291968799*^9}], Cell[BoxData[ RowBox[{"eqns", "=", RowBox[{"{", RowBox[{ RowBox[{"0", "==", RowBox[{"D", "[", RowBox[{ RowBox[{"h", "[", RowBox[{"a", ",", "b", ",", "c"}], "]"}], ",", "a"}], "]"}]}], ",", RowBox[{"0", "==", RowBox[{"D", "[", RowBox[{ RowBox[{"h", "[", RowBox[{"a", ",", "b", ",", "c"}], "]"}], ",", "b"}], "]"}]}], ",", RowBox[{"0", "==", RowBox[{"D", "[", RowBox[{ RowBox[{"h", "[", RowBox[{"a", ",", "b", ",", "c"}], "]"}], ",", "c"}], "]"}]}]}], "}"}]}]], "Input", CellChangeTimes->{{3.698662100105836*^9, 3.698662136448646*^9}}], Cell[BoxData[ RowBox[{ RowBox[{ RowBox[{"0", "\[Equal]", RowBox[{"D", "[", RowBox[{ RowBox[{"h", "[", RowBox[{"a", ",", "b", ",", "c"}], "]"}], ",", "#"}], "]"}]}], "&"}], "/@", RowBox[{"{", RowBox[{"a", ",", "b", ",", "c"}], "}"}]}]], "Input", CellChangeTimes->{{3.698661989532352*^9, 3.6986619957403736`*^9}}], Cell[BoxData[{ RowBox[{"g", "/@", RowBox[{"{", RowBox[{"a", ",", "b", ",", "c"}], "}"}]}], "\[IndentingNewLine]", RowBox[{"Total", "[", RowBox[{"g", "/@", RowBox[{"{", RowBox[{"a", ",", "b", ",", "c"}], "}"}]}], "]"}]}], "Input", CellChangeTimes->{{3.698661782010672*^9, 3.698661808598446*^9}}], Cell[BoxData[{ RowBox[{"Off", "[", StyleBox[ RowBox[{"FindMinimum", "::", "lstol"}], "MessageName"], "]"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"nPoints", "=", "10"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"randomInteger", ":=", RowBox[{"{", RowBox[{ RowBox[{"RandomInteger", "[", RowBox[{"{", RowBox[{ RowBox[{"-", "10"}], ",", "10"}], "}"}], "]"}], ",", RowBox[{"RandomInteger", "[", RowBox[{"{", RowBox[{ RowBox[{"-", "10"}], ",", "10"}], "}"}], "]"}]}], "}"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"points", "=", RowBox[{"Table", "[", RowBox[{"randomInteger", ",", RowBox[{"{", "nPoints", "}"}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", RowBox[{"{", RowBox[{"xp_", ",", "yp_"}], "}"}], "]"}], ":=", SqrtBox[ RowBox[{ SuperscriptBox[ RowBox[{"(", RowBox[{"x", "-", "xp"}], ")"}], "2"], "+", SuperscriptBox[ RowBox[{"(", RowBox[{"y", "-", "yp"}], ")"}], "2"]}]]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"totalDistance", "=", RowBox[{"Total", "[", RowBox[{"f", "/@", "points"}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"minimumResult", "=", RowBox[{"FindMinimum", "[", RowBox[{"totalDistance", ",", RowBox[{"{", RowBox[{"x", ",", "y"}], "}"}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"pl1", "=", RowBox[{"ListPlot", "[", RowBox[{"points", ",", RowBox[{"PlotStyle", "\[Rule]", RowBox[{"{", RowBox[{"Large", ",", "Red"}], "}"}]}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"desiredPoint", "=", RowBox[{ RowBox[{"{", RowBox[{"x", ",", "y"}], "}"}], "/.", RowBox[{"minimumResult", "[", RowBox[{"[", "2", "]"}], "]"}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"pl2", "=", RowBox[{"ListPlot", "[", RowBox[{ RowBox[{"{", "desiredPoint", "}"}], ",", RowBox[{"PlotStyle", "\[Rule]", RowBox[{"{", RowBox[{"Large", ",", "Blue"}], "}"}]}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"Show", "[", RowBox[{"pl1", ",", "pl2", ",", RowBox[{"PlotRange", "\[Rule]", "All"}]}], "]"}]}], "Input", CellChangeTimes->{{3.698662820753127*^9, 3.6986629194892654`*^9}, { 3.6986630321952505`*^9, 3.698663064963092*^9}, {3.698663323096307*^9, 3.698663425450321*^9}, 3.6986634657145815`*^9, {3.6986635197397904`*^9, 3.698663556628024*^9}, {3.6986635866294413`*^9, 3.698663591069936*^9}, { 3.698663630126172*^9, 3.6986636686784925`*^9}, {3.69866392189845*^9, 3.6986639259453325`*^9}, {3.698664131708093*^9, 3.6986641329327126`*^9}, { 3.698664255182525*^9, 3.69866432022449*^9}, {3.6986644134504642`*^9, 3.698664415721981*^9}, {3.698664481626954*^9, 3.6986645190042086`*^9}, { 3.6986646446692977`*^9, 3.698664722942398*^9}, 3.6986647940465083`*^9}], Cell[BoxData[ RowBox[{"pl1", "=", RowBox[{"ListPlot", "[", "points", "]"}]}]], "Input", CellChangeTimes->{{3.6986640676958513`*^9, 3.698664072161703*^9}, { 3.6986641083319235`*^9, 3.6986641257070675`*^9}}], Cell[BoxData["MapThread"], "Input", CellChangeTimes->{{3.698663883312451*^9, 3.698663887332965*^9}}], Cell[BoxData[{"points", "\[IndentingNewLine]", RowBox[{"f", "/@", "points"}]}], "Input", CellChangeTimes->{{3.69866377456811*^9, 3.698663776407958*^9}}], Cell[BoxData[ RowBox[{"funct", "/@", "points"}]], "Input", CellChangeTimes->{{3.698663728085617*^9, 3.698663746495799*^9}}], Cell[BoxData[""], "Input", CellChangeTimes->{{3.6986633135951953`*^9, 3.69866332180332*^9}}], Cell[BoxData[ RowBox[{"f", "[", RowBox[{"{", RowBox[{"1", ",", "2"}], "}"}], "]"}]], "Input", CellChangeTimes->{{3.698663428219898*^9, 3.698663430858604*^9}}], Cell[BoxData[ RowBox[{"(*", RowBox[{"here", " ", "the", " ", "5", "th", " ", "lesson", " ", "starts"}], "*)"}]], "Input", CellChangeTimes->{{3.699272040389786*^9, 3.699272054041253*^9}}], Cell[BoxData[ RowBox[{"Remove", "[", "\"\\"", "]"}]], "Input"], Cell[BoxData[ RowBox[{"NestWhileList", "[", RowBox[{ RowBox[{ RowBox[{"#", "/", "2"}], "&"}], ",", "123456", ",", "EvenQ"}], "]"}]], "Input", CellChangeTimes->{{3.699272472387144*^9, 3.6992724866882973`*^9}}], Cell[BoxData[ RowBox[{"{", RowBox[{ RowBox[{"EvenQ", "[", "1", "]"}], ",", RowBox[{"EvenQ", "[", "2", "]"}]}], "}"}]], "Input", CellChangeTimes->{{3.6992726606363063`*^9, 3.6992726715232773`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{ RowBox[{"function", "[", "x_", "]"}], ":=", FractionBox["x", "2"]}], ";"}], "\[IndentingNewLine]", RowBox[{"NestWhileList", "[", RowBox[{"function", ",", "123456", ",", "EvenQ"}], "]"}]}], "Input", CellChangeTimes->{{3.6992725638260975`*^9, 3.699272587193902*^9}}], Cell[BoxData[ RowBox[{"NestList", "[", RowBox[{"f", ",", "xStart", ",", "5"}], "]"}]], "Input", CellChangeTimes->{{3.6992722650486393`*^9, 3.6992722935421295`*^9}}], Cell[BoxData[ RowBox[{"Series", "[", RowBox[{ RowBox[{"y", "[", RowBox[{"t", "+", "\[CapitalDelta]t"}], "]"}], ",", RowBox[{"{", RowBox[{"\[CapitalDelta]t", ",", "0", ",", "5"}], "}"}]}], "]"}]], "Input", CellChangeTimes->{{3.699273041060109*^9, 3.699273130039713*^9}, 3.6992731846817303`*^9}], Cell[BoxData[{ RowBox[{ RowBox[{"f", "[", RowBox[{"x", ":", "_"}], "]"}], ":=", SuperscriptBox["x", "2"]}], "\[IndentingNewLine]", RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", SuperscriptBox["x", "2"]}]}], "Input", CellChangeTimes->{{3.6992739526841326`*^9, 3.6992739769128723`*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{ RowBox[{"derivative", "[", RowBox[{"{", RowBox[{"t_", ",", "y_"}], "}"}], "]"}], ":=", RowBox[{"-", FractionBox[ RowBox[{"Tanh", "[", RowBox[{ SuperscriptBox["y", "2"], "+", RowBox[{"t", "*", "y"}]}], "]"}], RowBox[{"1", "+", RowBox[{"Log", "[", RowBox[{ SuperscriptBox["y", "2"], "+", "t"}], "]"}]}]]}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"tStart", "=", "1."}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"tEnd", "=", "10"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"nSteps", "=", "50"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"\[CapitalDelta]t", "=", FractionBox[ RowBox[{"tEnd", "-", "tStart"}], "nSteps"]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"yStart", "=", "15"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"EulerianStep", "[", RowBox[{"state", ":", RowBox[{"{", RowBox[{"t_", ",", "y_"}], "}"}]}], "]"}], ":=", RowBox[{"{", RowBox[{ RowBox[{"t", "+", "\[CapitalDelta]t"}], ",", RowBox[{"y", "+", RowBox[{"derivative", "[", "state", "]"}]}]}], "}"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"solution", "=", RowBox[{"NestList", "[", RowBox[{"EulerianStep", ",", RowBox[{"{", RowBox[{"tStart", ",", "yStart"}], "}"}], ",", "nSteps"}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"ListPlot", "[", "solution", "]"}], "\[IndentingNewLine]"}], "Input", CellChangeTimes->{{3.6992734921920376`*^9, 3.6992734963317146`*^9}, { 3.699273548662213*^9, 3.699273623948951*^9}, {3.69927370670158*^9, 3.699273759134633*^9}, {3.6992737915909586`*^9, 3.6992739417689967`*^9}, { 3.699274009962205*^9, 3.6992740603877892`*^9}, {3.6992741039324136`*^9, 3.699274120453128*^9}, {3.699274274599017*^9, 3.699274347198285*^9}}], Cell[BoxData[{ RowBox[{ RowBox[{"ClearAll", "[", "f", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"f", "[", "x_", "]"}], ":=", RowBox[{"x", "+", RowBox[{"0.5", SuperscriptBox["x", "2"], "*", RowBox[{"Exp", "[", RowBox[{"0.5", "x"}], "]"}]}], "-", "15"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"Plot", "[", RowBox[{ RowBox[{"f", "[", "x", "]"}], ",", RowBox[{"{", RowBox[{"x", ",", "0", ",", "4"}], "}"}]}], "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"step", "[", "x_", "]"}], ":=", RowBox[{"x", "-", FractionBox[ RowBox[{"f", "[", "x", "]"}], RowBox[{ RowBox[{"f", "'"}], "[", "x", "]"}]]}]}], ";"}], "\[IndentingNewLine]", RowBox[{"NestList", "[", RowBox[{"step", ",", "4", ",", "4"}], "]"}]}], "Input", CellChangeTimes->{{3.6992761818530045`*^9, 3.6992763187605524`*^9}}] }, WindowSize->{1772, 891}, WindowMargins->{{0, Automatic}, {Automatic, 0}}, Magnification:>3. Inherited, FrontEndVersion->"10.4 for Microsoft Windows (64-bit) (February 25, 2016)", StyleDefinitions->"Default.nb" ] (* End of Notebook Content *) (* Internal cache information *) (*CellTagsOutline CellTagsIndex->{} *) (*CellTagsIndex CellTagsIndex->{} *) (*NotebookFileOutline Notebook[{ Cell[558, 20, 275, 5, 150, "Input"], Cell[836, 27, 357, 8, 208, "Input"], Cell[1196, 37, 69, 1, 91, "Input"], Cell[1268, 40, 141, 3, 91, "Input"], Cell[1412, 45, 120, 2, 91, "Input"], Cell[1535, 49, 117, 2, 129, "Input"], Cell[1655, 53, 104, 2, 100, "Input"], Cell[1762, 57, 126, 2, 90, "Input"], Cell[1891, 61, 124, 2, 90, "Input"], Cell[2018, 65, 123, 2, 90, "Input"], Cell[2144, 69, 125, 2, 90, "Input"], Cell[2272, 73, 148, 3, 90, "Input"], Cell[2423, 78, 230, 4, 209, "Input"], Cell[2656, 84, 202, 3, 90, "Input"], Cell[2861, 89, 113, 2, 90, "Input"], Cell[2977, 93, 99, 1, 90, "Input"], Cell[3079, 96, 112, 2, 90, "Input"], Cell[3194, 100, 115, 2, 90, "Input"], Cell[3312, 104, 442, 11, 215, "Input"], Cell[3757, 117, 350, 10, 90, "Input"], Cell[4110, 129, 297, 8, 166, "Input"], Cell[4410, 139, 112, 2, 90, "Input"], Cell[4525, 143, 114, 2, 90, "Input"], Cell[4642, 147, 113, 2, 90, "Input"], Cell[4758, 151, 503, 11, 269, "Input"], Cell[5264, 164, 86, 2, 90, "Input"], Cell[5353, 168, 505, 11, 267, "Input"], Cell[5861, 181, 114, 2, 90, "Input"], Cell[5978, 185, 321, 8, 209, "Input"], Cell[6302, 195, 435, 10, 267, "Input"], Cell[6740, 207, 430, 10, 326, "Input"], Cell[7173, 219, 346, 8, 209, "Input"], Cell[7522, 229, 317, 8, 209, "Input"], Cell[7842, 239, 452, 11, 258, "Input"], Cell[8297, 252, 444, 12, 316, "Input"], Cell[8744, 266, 1123, 32, 444, "Input"], Cell[9870, 300, 1114, 29, 446, "Input"], Cell[10987, 331, 939, 26, 384, "Input"], Cell[11929, 359, 674, 18, 326, "Input"], Cell[12606, 379, 115, 2, 90, "Input"], Cell[12724, 383, 1356, 41, 386, "Input"], Cell[14083, 426, 917, 24, 550, "Input"], Cell[15003, 452, 326, 8, 210, "Input"], Cell[15332, 462, 163, 4, 93, "Input"], Cell[15498, 468, 182, 4, 150, "Input"], Cell[15683, 474, 374, 10, 150, "Input"], Cell[16060, 486, 287, 8, 90, "Input"], Cell[16350, 496, 269, 7, 153, "Input"], Cell[16622, 505, 129, 2, 90, "Input"], Cell[16754, 509, 4114, 86, 1038, "Input"], Cell[20871, 597, 550, 16, 150, "Input"], Cell[21424, 615, 1425, 37, 209, "Input"], Cell[22852, 654, 122, 2, 90, "Input"], Cell[22977, 658, 1372, 38, 209, "Input"], Cell[24352, 698, 1343, 37, 229, "Input"], Cell[25698, 737, 334, 8, 210, "Input"], Cell[26035, 747, 286, 7, 210, "Input"], Cell[26324, 756, 115, 2, 165, "Input"], Cell[26442, 760, 195, 5, 171, "Input"], Cell[26640, 767, 154, 3, 165, "Input"], Cell[26797, 772, 146, 3, 165, "Input"], Cell[26946, 777, 154, 3, 165, "Input"], Cell[27103, 782, 127, 4, 171, "Input"], Cell[27233, 788, 274, 8, 93, "Input"], Cell[27510, 798, 327, 10, 93, "Input"], Cell[27840, 810, 285, 8, 93, "Input"], Cell[28128, 820, 259, 9, 93, "Input"], Cell[28390, 831, 229, 5, 93, "Input"], Cell[28622, 838, 158, 3, 90, "Input"], Cell[28783, 843, 149, 3, 90, "Input"], Cell[28935, 848, 143, 3, 89, "Input"], Cell[29081, 853, 179, 4, 99, "Input"], Cell[29263, 859, 148, 3, 89, "Input"], Cell[29414, 864, 464, 12, 203, "Input"], Cell[29881, 878, 172, 4, 89, "Input"], Cell[30056, 884, 202, 5, 89, "Input"], Cell[30261, 891, 232, 5, 147, "Input"], Cell[30496, 898, 355, 9, 201, "Input"], Cell[30854, 909, 146, 3, 89, "Input"], Cell[31003, 914, 141, 2, 89, "Input"], Cell[31147, 918, 1285, 34, 376, "Input"], Cell[32435, 954, 181, 4, 89, "Input"], Cell[32619, 960, 438, 8, 147, "Input"], Cell[33060, 970, 266, 7, 89, "Input"], Cell[33329, 979, 388, 11, 150, "Input"], Cell[33720, 992, 566, 15, 205, "Input"], Cell[34289, 1009, 208, 5, 203, "Input"], Cell[34500, 1016, 192, 4, 147, "Input"], Cell[34695, 1022, 671, 19, 203, "Input"], Cell[35369, 1043, 335, 8, 203, "Input"], Cell[35707, 1053, 481, 13, 259, "Input"], Cell[36191, 1068, 481, 13, 203, "Input"], Cell[36675, 1083, 182, 4, 89, "Input"], Cell[36860, 1089, 256, 6, 89, "Input"], Cell[37119, 1097, 227, 6, 89, "Input"], Cell[37349, 1105, 564, 14, 155, "Input"], Cell[37916, 1121, 566, 17, 157, "Input"], Cell[38485, 1140, 223, 8, 89, "Input"], Cell[38711, 1150, 903, 24, 268, "Input"], Cell[39617, 1176, 375, 10, 89, "Input"], Cell[39995, 1188, 637, 16, 89, "Input"], Cell[40635, 1206, 262, 7, 89, "Input"], Cell[40900, 1215, 162, 3, 89, "Input"], Cell[41065, 1220, 1372, 37, 257, "Input"], Cell[42440, 1259, 1358, 39, 275, "Input"], Cell[43801, 1300, 173, 3, 89, "Input"], Cell[43977, 1305, 1526, 42, 310, "Input"], Cell[45506, 1349, 1057, 33, 310, "Input"], Cell[46566, 1384, 433, 12, 147, "Input"], Cell[47002, 1398, 594, 18, 203, "Input"], Cell[47599, 1418, 324, 10, 89, "Input"], Cell[47926, 1430, 351, 10, 89, "Input"], Cell[48280, 1442, 222, 6, 93, "Input"], Cell[48505, 1450, 1895, 55, 607, "Input"], Cell[50403, 1507, 62, 1, 89, "Input"], Cell[50468, 1510, 1589, 45, 538, "Input"], Cell[52060, 1557, 647, 20, 89, "Input"], Cell[52710, 1579, 350, 10, 89, "Input"], Cell[53063, 1591, 317, 8, 147, "Input"], Cell[53383, 1601, 3093, 86, 818, "Input"], Cell[56479, 1689, 212, 4, 91, "Input"], Cell[56694, 1695, 101, 1, 91, "Input"], Cell[56798, 1698, 155, 2, 150, "Input"], Cell[56956, 1702, 125, 2, 91, "Input"], Cell[57084, 1706, 93, 1, 91, "Input"], Cell[57180, 1709, 167, 4, 91, "Input"], Cell[57350, 1715, 194, 4, 91, "Input"], Cell[57547, 1721, 74, 1, 129, "Input"], Cell[57624, 1724, 223, 6, 129, "Input"], Cell[57850, 1732, 208, 5, 129, "Input"], Cell[58061, 1739, 313, 7, 221, "Input"], Cell[58377, 1748, 169, 3, 129, "Input"], Cell[58549, 1753, 319, 8, 129, "Input"], Cell[58871, 1763, 302, 8, 150, "Input"], Cell[59176, 1773, 1924, 54, 766, "Input"], Cell[61103, 1829, 929, 29, 416, "Input"] } ] *)