(* Content-type: application/vnd.wolfram.mathematica *) (*** Wolfram Notebook File ***) (* http://www.wolfram.com/nb *) (* CreatedBy='Mathematica 10.0' *) (*CacheID: 234*) (* Internal cache information: NotebookFileLineBreakTest NotebookFileLineBreakTest NotebookDataPosition[ 158, 7] NotebookDataLength[ 3679, 128] NotebookOptionsPosition[ 3067, 101] NotebookOutlinePosition[ 3403, 116] CellTagsIndexPosition[ 3360, 113] WindowFrame->Normal*) (* Beginning of Notebook Content *) Notebook[{ Cell[CellGroupData[{ Cell["Solving linear systems Ax = b", "Subsection", CellChangeTimes->{{3.623597453741329*^9, 3.6235974603416653`*^9}}], Cell[CellGroupData[{ Cell["\<\ The coefficient matrix and the data - change to suit yourself - enclosing things in the \[OpenCurlyQuote]MatrixForm\[CloseCurlyQuote] \ command is just to format output nicely. Try removing this command to see \ what the output looks like\ \>", "Subsubsection", CellChangeTimes->{{3.623597468869657*^9, 3.623597477141539*^9}, { 3.623597538597054*^9, 3.623597543020605*^9}, {3.6235975929726458`*^9, 3.623597674212007*^9}}], Cell[BoxData[{ RowBox[{"MatrixForm", "[", RowBox[{"A", "=", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"2", ",", RowBox[{"-", "2"}], ",", "4"}], "}"}], ",", RowBox[{"{", RowBox[{"1", ",", "1", ",", RowBox[{"-", "2"}]}], "}"}], ",", RowBox[{"{", RowBox[{"3", ",", RowBox[{"-", "3"}], ",", "6"}], "}"}]}], "}"}]}], "]"}], "\[IndentingNewLine]", RowBox[{"MatrixForm", "[", RowBox[{"b", "=", RowBox[{"{", RowBox[{"1", ",", "0", ",", RowBox[{"-", "1"}]}], "}"}]}], "]"}]}], "Input", CellChangeTimes->{{3.623583784494707*^9, 3.623583786153963*^9}, { 3.623583836680983*^9, 3.623583936778503*^9}, {3.623597678641959*^9, 3.623597682064383*^9}}] }, Open ]], Cell[CellGroupData[{ Cell[TextData[{ "The augmented matrix (I\[CloseCurlyQuote]d love to have a better way to do \ this in ", StyleBox["Mathematica", FontSlant->"Italic"], ")" }], "Subsubsection", CellChangeTimes->{{3.62359748586097*^9, 3.623597527386042*^9}}], Cell[BoxData[ RowBox[{"MatrixForm", "[", RowBox[{"Aaug", " ", "=", " ", RowBox[{"Transpose", "[", RowBox[{"Append", "[", RowBox[{ RowBox[{"Transpose", "[", "A", "]"}], ",", "b"}], "]"}], "]"}]}], "]"}]], "Input", CellChangeTimes->{{3.6235835418816223`*^9, 3.6235835745152473`*^9}, { 3.6235837598752747`*^9, 3.623583763122698*^9}}] }, Open ]] }, Open ]], Cell[CellGroupData[{ Cell[" Put the matrix in reduced echelon form.", "Subsection", CellChangeTimes->{{3.623583494262176*^9, 3.623583494843442*^9}, { 3.623597552732716*^9, 3.6235975897482023`*^9}}], Cell[BoxData[ RowBox[{"MatrixForm", "[", RowBox[{"RowReduce", "[", "Aaug", "]"}], "]"}]], "Input", CellChangeTimes->{{3.62358351619282*^9, 3.6235835283636227`*^9}, { 3.623583768675399*^9, 3.623583768963379*^9}, {3.623583915513896*^9, 3.623583920377685*^9}}] }, Open ]] }, WindowSize->{808, 911}, WindowMargins->{{552, Automatic}, {102, Automatic}}, FrontEndVersion->"10.0 for Linux x86 (64-bit) (June 27, 2014)", StyleDefinitions->"Default.nb" ] (* End of Notebook Content *) (* Internal cache information *) (*CellTagsOutline CellTagsIndex->{} *) (*CellTagsIndex CellTagsIndex->{} *) (*NotebookFileOutline Notebook[{ Cell[CellGroupData[{ Cell[580, 22, 119, 1, 47, "Subsection"], Cell[CellGroupData[{ Cell[724, 27, 439, 9, 115, "Subsubsection"], Cell[1166, 38, 739, 22, 55, "Input"] }, Open ]], Cell[CellGroupData[{ Cell[1942, 65, 245, 7, 63, "Subsubsection"], Cell[2190, 74, 361, 9, 32, "Input"] }, Open ]] }, Open ]], Cell[CellGroupData[{ Cell[2600, 89, 181, 2, 47, "Subsection"], Cell[2784, 93, 267, 5, 32, "Input"] }, Open ]] } ] *) (* End of internal cache information *)