(* Content-type: application/mathematica *) (*** Wolfram Notebook File ***) (* http://www.wolfram.com/nb *) (* CreatedBy='Mathematica 6.0' *) (*CacheID: 234*) (* Internal cache information: NotebookFileLineBreakTest NotebookFileLineBreakTest NotebookDataPosition[ 145, 7] NotebookDataLength[ 32137, 951] NotebookOptionsPosition[ 30339, 883] NotebookOutlinePosition[ 30833, 903] CellTagsIndexPosition[ 30790, 900] WindowFrame->Normal ContainsDynamic->False*) (* Beginning of Notebook Content *) Notebook[{ Cell[CellGroupData[{ Cell["mQhull:voronoiDiagram Example", "Title"], Cell[TextData[{ "19 Nov 2007 Verified in ", StyleBox["Mathematica", FontSlant->"Italic"], " Version 6" }], "Text", CellChangeTimes->{{3.404500011772622*^9, 3.4045000224580917`*^9}}], Cell[CellGroupData[{ Cell["\<\ \[Copyright]2006 (click to the right for licensing information and details)\ \>", "Subsubsection"], Cell[TextData[{ "\[Copyright]2006 California Institute of Technology.\nAll Rights Reserved.\n\ \n", StyleBox["This library is free software; you can redistribute it and/or \ modify it under the terms of the GNU Lesser Public License as published by \ the Free Software Foundation; either version 2.1 of the License, or any later \ version.\n\nThis library is distributed in the hope that it will be useful, \ but WITHOUT ANY WARRANTY, WITHOUT EVEN THE IMPLIED WARRANTY OF \ MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. The software and \ documentation provided hereunder is on an \"as is\" basis, and the \ California Institute of Technology has no obligations to provide maintenance, \ support, updates, enhancements or modifications. In no event shall the \ California Institute of Technology be liable to any party for direct, \ indirect, special, incidental or consequential damages, including lost \ profits, arising out of the use of this software and its documentation, even \ if the California Institute of Technology have been advised of the \ possibility of such damage. See the GNU Lesser General Public License for \ more details.\n\nYou should have received a copy of the GNU Lesser General \ Public License along with this library; if not, write to the Free Software \ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.\n\n \ The original code contained here was initially developed by:\n\n \tBruce E. \ Shapiro\n \tBiological Network Modeling Center\n \tDivision of Biology, Mail \ Code 139-74\n \tCalifornia Institute of Technology\n \tPasadena, CA, 91125, \ USA\n \tbshapiro at caltech dot edu", FontSize->12] }], "Text"] }, Closed]], Cell[CellGroupData[{ Cell["voronoiDiagram", "Section"], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"points", "=", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}], ",", RowBox[{"{", RowBox[{"6.8", ",", "7.4"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "3."}], ",", "9.6"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "9.3"}], ",", RowBox[{"-", "6.9"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "0.4"}], ",", RowBox[{"-", "7.3"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.9", ",", RowBox[{"-", "7.1"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "10.6"}], ",", RowBox[{"-", "17.5"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "1."}], ",", RowBox[{"-", "17.5"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.2", ",", RowBox[{"-", "17.5"}]}], "}"}]}], "}"}], " "}]], "Input"], Cell[BoxData[ RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}], ",", RowBox[{"{", RowBox[{"6.8`", ",", "7.4`"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "3.`"}], ",", "9.6`"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "9.3`"}], ",", RowBox[{"-", "6.9`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "0.4`"}], ",", RowBox[{"-", "7.3`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.9`", ",", RowBox[{"-", "7.1`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "10.6`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "1.`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.2`", ",", RowBox[{"-", "17.5`"}]}], "}"}]}], "}"}]], "Output", CellChangeTimes->{3.4044998879829273`*^9}] }, Open ]], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"pointsplot", "=", RowBox[{"ListPlot", "[", RowBox[{"points", ",", " ", RowBox[{"PlotStyle", "\[Rule]", " ", RowBox[{"{", RowBox[{ RowBox[{"Hue", "[", ".65", "]"}], ",", RowBox[{"PointSize", "[", ".05", "]"}]}], "}"}]}], ",", RowBox[{"Axes", "\[Rule]", " ", "False"}], ",", RowBox[{"PlotRange", "\[Rule]", " ", RowBox[{"{", RowBox[{ RowBox[{"-", "20"}], ",", "12"}], "}"}]}], ",", " ", RowBox[{"ImageSize", "\[Rule]", " ", "400"}]}], "]"}]}]], "Input", CellChangeTimes->{3.404499890371447*^9}], Cell[BoxData[ GraphicsBox[ {Hue[0.65], PointSize[0.05], PointBox[{{0., 0.}, {6.8, 7.4}, {-3., 9.6}, {-9.3, -6.9}, {-0.4, -7.3}, { 10.9, -7.1}, {-10.6, -17.5}, {-1., -17.5}, {10.2, -17.5}}]}, AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], ImageSize->400, PlotRange->{-20, 12}, PlotRangeClipping->True]], "Output", CellChangeTimes->{3.4044998909134502`*^9}] }, Open ]], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"vd", "=", RowBox[{"voronoiDiagram", "[", RowBox[{"points", ",", RowBox[{"voronoiFormat", "\[Rule]", " ", RowBox[{"{", RowBox[{ RowBox[{"regionCoordinates", "\[Rule]", " ", "True"}], ",", RowBox[{"keepVerticesAtInfinity", "\[Rule]", " ", "False"}]}], "}"}]}]}], "]"}]}]], "Input"], Cell[BoxData[ RowBox[{"{", RowBox[{ RowBox[{"vertices", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"7.636606173413991`", ",", RowBox[{"-", "0.1930975647588031`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"1.263237311385459`", ",", "5.663511659807957`"}], "}"}], ",", RowBox[{"{", RowBox[{"5.192397767261253`", ",", RowBox[{"-", "3.945473850260891`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"5.334051797580507`", ",", RowBox[{"-", "11.94892656329869`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "4.683901427913404`"}], ",", RowBox[{"-", "3.404306771073237`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "9.026022913256954`"}], ",", "2.448117839607198`"}], "}"}], ",", RowBox[{"{", RowBox[{"4.600000000000001`", ",", RowBox[{"-", "12.71176470588235`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "5.800000000000001`"}], ",", RowBox[{"-", "12.70896226415094`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "5.076631509558339`"}], ",", RowBox[{"-", "12.14255108767304`"}]}], "}"}]}], "}"}]}], ",", RowBox[{"regions", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"6", ",", "2", ",", "1", ",", "3", ",", "5", ",", "6"}], "}"}], ",", RowBox[{"{", RowBox[{"9", ",", "5", ",", "3", ",", "4", ",", "7", ",", "9"}], "}"}]}], "}"}]}], ",", RowBox[{"regionCoordinates", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "9.026022913256954`"}], ",", "2.448117839607198`"}], "}"}], ",", RowBox[{"{", RowBox[{"1.263237311385459`", ",", "5.663511659807957`"}], "}"}], ",", RowBox[{"{", RowBox[{"7.636606173413991`", ",", RowBox[{"-", "0.1930975647588031`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"5.192397767261253`", ",", RowBox[{"-", "3.945473850260891`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "4.683901427913404`"}], ",", RowBox[{"-", "3.404306771073237`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "9.026022913256954`"}], ",", "2.448117839607198`"}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "5.076631509558339`"}], ",", RowBox[{"-", "12.14255108767304`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "4.683901427913404`"}], ",", RowBox[{"-", "3.404306771073237`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"5.192397767261253`", ",", RowBox[{"-", "3.945473850260891`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"5.334051797580507`", ",", RowBox[{"-", "11.94892656329869`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"4.600000000000001`", ",", RowBox[{"-", "12.71176470588235`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "5.076631509558339`"}], ",", RowBox[{"-", "12.14255108767304`"}]}], "}"}]}], "}"}]}], "}"}]}]}], "}"}]], "Output", CellChangeTimes->{3.404499894497663*^9}] }, Open ]], Cell[BoxData[ RowBox[{ RowBox[{"vdplot", "=", RowBox[{"Show", "[", RowBox[{ RowBox[{"Graphics", "[", RowBox[{"{", RowBox[{ RowBox[{"RGBColor", "[", RowBox[{"0.2", ",", "0.7", ",", "0.7"}], "]"}], ",", RowBox[{"Thickness", "[", ".007", "]"}], ",", RowBox[{"Line", "/@", RowBox[{"(", RowBox[{"regionCoordinates", "/.", "vd"}], ")"}]}]}], "}"}], "]"}], ",", RowBox[{"ImageSize", "\[Rule]", " ", "400"}]}], "]"}]}], ";"}]], "Input"], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"voronoiPointPlot", "=", RowBox[{"Show", "[", RowBox[{"pointsplot", ",", "vdplot"}], "]"}]}]], "Input", CellChangeTimes->{3.404499901001852*^9}], Cell[BoxData[ GraphicsBox[{ {Hue[0.65], PointSize[0.05], PointBox[{{0., 0.}, {6.8, 7.4}, {-3., 9.6}, {-9.3, -6.9}, {-0.4, -7.3}, { 10.9, -7.1}, {-10.6, -17.5}, {-1., -17.5}, {10.2, -17.5}}]}, {RGBColor[0.2, 0.7, 0.7], Thickness[0.007], LineBox[{{-9.026022913256954, 2.448117839607198}, {1.263237311385459, 5.663511659807957}, {7.636606173413991, -0.1930975647588031}, { 5.192397767261253, -3.945473850260891}, {-4.683901427913404, \ -3.404306771073237}, {-9.026022913256954, 2.448117839607198}}], LineBox[{{-5.076631509558339, -12.14255108767304}, {-4.683901427913404, \ -3.404306771073237}, {5.192397767261253, -3.945473850260891}, { 5.334051797580507, -11.94892656329869}, { 4.600000000000001, -12.71176470588235}, {-5.076631509558339, \ -12.14255108767304}}]}}, AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], ImageSize->400, PlotRange->{-20, 12}, PlotRangeClipping->True]], "Output", CellChangeTimes->{3.404499902100621*^9}] }, Open ]] }, Open ]], Cell[CellGroupData[{ Cell["Compare it with the delaunay Triangulation & Convex Hull", "Section"], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"dt", "=", RowBox[{"delaunayTriangulation", "[", RowBox[{"points", ",", RowBox[{"delaunayFormat", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"edgeCoordinates", "->", " ", "True"}], ",", RowBox[{"regions", "\[Rule]", " ", "True"}], ",", RowBox[{"regionCoordinates", "\[Rule]", " ", "True"}]}], "}"}]}]}], "]"}]}]], "Input"], Cell[BoxData[ RowBox[{"{", RowBox[{ RowBox[{"edges", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"1", ",", "2"}], "}"}], ",", RowBox[{"{", RowBox[{"1", ",", "3"}], "}"}], ",", RowBox[{"{", RowBox[{"1", ",", "4"}], "}"}], ",", RowBox[{"{", RowBox[{"1", ",", "5"}], "}"}], ",", RowBox[{"{", RowBox[{"1", ",", "6"}], "}"}], ",", RowBox[{"{", RowBox[{"2", ",", "3"}], "}"}], ",", RowBox[{"{", RowBox[{"2", ",", "6"}], "}"}], ",", RowBox[{"{", RowBox[{"3", ",", "4"}], "}"}], ",", RowBox[{"{", RowBox[{"4", ",", "5"}], "}"}], ",", RowBox[{"{", RowBox[{"4", ",", "7"}], "}"}], ",", RowBox[{"{", RowBox[{"4", ",", "8"}], "}"}], ",", RowBox[{"{", RowBox[{"5", ",", "6"}], "}"}], ",", RowBox[{"{", RowBox[{"5", ",", "8"}], "}"}], ",", RowBox[{"{", RowBox[{"5", ",", "9"}], "}"}], ",", RowBox[{"{", RowBox[{"6", ",", "9"}], "}"}], ",", RowBox[{"{", RowBox[{"7", ",", "8"}], "}"}], ",", RowBox[{"{", RowBox[{"8", ",", "9"}], "}"}]}], "}"}]}], ",", RowBox[{"regions", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"2", ",", "1", ",", "6"}], "}"}], ",", RowBox[{"{", RowBox[{"1", ",", "2", ",", "3"}], "}"}], ",", RowBox[{"{", RowBox[{"1", ",", "5", ",", "6"}], "}"}], ",", RowBox[{"{", RowBox[{"5", ",", "9", ",", "6"}], "}"}], ",", RowBox[{"{", RowBox[{"4", ",", "5", ",", "1"}], "}"}], ",", RowBox[{"{", RowBox[{"4", ",", "1", ",", "3"}], "}"}], ",", RowBox[{"{", RowBox[{"5", ",", "8", ",", "9"}], "}"}], ",", RowBox[{"{", RowBox[{"8", ",", "4", ",", "7"}], "}"}], ",", RowBox[{"{", RowBox[{"4", ",", "8", ",", "5"}], "}"}]}], "}"}]}], ",", RowBox[{"edgeCoordinates", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}], ",", RowBox[{"{", RowBox[{"6.8`", ",", "7.4`"}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "3.`"}], ",", "9.6`"}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "9.3`"}], ",", RowBox[{"-", "6.9`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "0.4`"}], ",", RowBox[{"-", "7.3`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}], ",", RowBox[{"{", RowBox[{"10.9`", ",", RowBox[{"-", "7.1`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"6.8`", ",", "7.4`"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "3.`"}], ",", "9.6`"}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"6.8`", ",", "7.4`"}], "}"}], ",", RowBox[{"{", RowBox[{"10.9`", ",", RowBox[{"-", "7.1`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "3.`"}], ",", "9.6`"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "9.3`"}], ",", RowBox[{"-", "6.9`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "9.3`"}], ",", RowBox[{"-", "6.9`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "0.4`"}], ",", RowBox[{"-", "7.3`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "9.3`"}], ",", RowBox[{"-", "6.9`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "10.6`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "9.3`"}], ",", RowBox[{"-", "6.9`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "1.`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "0.4`"}], ",", RowBox[{"-", "7.3`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.9`", ",", RowBox[{"-", "7.1`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "0.4`"}], ",", RowBox[{"-", "7.3`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "1.`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "0.4`"}], ",", RowBox[{"-", "7.3`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.2`", ",", RowBox[{"-", "17.5`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"10.9`", ",", RowBox[{"-", "7.1`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.2`", ",", RowBox[{"-", "17.5`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "10.6`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "1.`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "1.`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.2`", ",", RowBox[{"-", "17.5`"}]}], "}"}]}], "}"}]}], "}"}]}], ",", RowBox[{"regionCoordinates", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"6.8`", ",", "7.4`"}], "}"}], ",", RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}], ",", RowBox[{"{", RowBox[{"10.9`", ",", RowBox[{"-", "7.1`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}], ",", RowBox[{"{", RowBox[{"6.8`", ",", "7.4`"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "3.`"}], ",", "9.6`"}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "0.4`"}], ",", RowBox[{"-", "7.3`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.9`", ",", RowBox[{"-", "7.1`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "0.4`"}], ",", RowBox[{"-", "7.3`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.2`", ",", RowBox[{"-", "17.5`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.9`", ",", RowBox[{"-", "7.1`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "9.3`"}], ",", RowBox[{"-", "6.9`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "0.4`"}], ",", RowBox[{"-", "7.3`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "9.3`"}], ",", RowBox[{"-", "6.9`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"0", ",", "0"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "3.`"}], ",", "9.6`"}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "0.4`"}], ",", RowBox[{"-", "7.3`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "1.`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}], ",", RowBox[{"{", RowBox[{"10.2`", ",", RowBox[{"-", "17.5`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "1.`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "9.3`"}], ",", RowBox[{"-", "6.9`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "10.6`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "9.3`"}], ",", RowBox[{"-", "6.9`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "1.`"}], ",", RowBox[{"-", "17.5`"}]}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"-", "0.4`"}], ",", RowBox[{"-", "7.3`"}]}], "}"}]}], "}"}]}], "}"}]}], ",", RowBox[{"statistics", "\[Rule]", RowBox[{"{", RowBox[{ "11.48742936392689`", ",", "10.679419459877021`", ",", "2.560791288223172`"}], "}"}]}]}], "}"}]], "Output", CellChangeTimes->{3.4044999061013117`*^9}] }, Open ]], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"dtplot", "=", RowBox[{"Show", "[", RowBox[{ RowBox[{"{", RowBox[{"pointsplot", ",", RowBox[{"Graphics", "[", RowBox[{"{", RowBox[{ RowBox[{"RGBColor", "[", RowBox[{".7", ",", ".2", ",", ".4"}], "]"}], ",", RowBox[{"Line", "/@", RowBox[{"(", RowBox[{"edgeCoordinates", "/.", "dt"}], ")"}]}]}], "}"}], "]"}]}], "}"}], ",", " ", RowBox[{"PlotRange", "\[Rule]", " ", RowBox[{"{", RowBox[{ RowBox[{"-", "20"}], ",", "12"}], "}"}]}], ",", RowBox[{"ImageSize", "\[Rule]", "400"}]}], "]"}]}]], "Input", CellChangeTimes->{ 3.404499910289537*^9, {3.404499958894658*^9, 3.404499966399947*^9}}], Cell[BoxData[ GraphicsBox[{ {Hue[0.65], PointSize[0.05], PointBox[{{0., 0.}, {6.8, 7.4}, {-3., 9.6}, {-9.3, -6.9}, {-0.4, -7.3}, { 10.9, -7.1}, {-10.6, -17.5}, {-1., -17.5}, {10.2, -17.5}}]}, {RGBColor[0.7, 0.2, 0.4], LineBox[{{0, 0}, {6.8, 7.4}}], LineBox[{{0, 0}, {-3., 9.6}}], LineBox[{{0, 0}, {-9.3, -6.9}}], LineBox[{{0, 0}, {-0.4, -7.3}}], LineBox[{{0, 0}, {10.9, -7.1}}], LineBox[{{6.8, 7.4}, {-3., 9.6}}], LineBox[{{6.8, 7.4}, {10.9, -7.1}}], LineBox[{{-3., 9.6}, {-9.3, -6.9}}], LineBox[{{-9.3, -6.9}, {-0.4, -7.3}}], LineBox[{{-9.3, -6.9}, {-10.6, -17.5}}], LineBox[{{-9.3, -6.9}, {-1., -17.5}}], LineBox[{{-0.4, -7.3}, {10.9, -7.1}}], LineBox[{{-0.4, -7.3}, {-1., -17.5}}], LineBox[{{-0.4, -7.3}, {10.2, -17.5}}], LineBox[{{10.9, -7.1}, {10.2, -17.5}}], LineBox[{{-10.6, -17.5}, {-1., -17.5}}], LineBox[{{-1., -17.5}, {10.2, -17.5}}]}}, AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], ImageSize->400, PlotRange->{-20, 12}, PlotRangeClipping->True]], "Output", CellChangeTimes->{3.404499911756022*^9, 3.404499967156577*^9}] }, Open ]], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"vddtplot", "=", RowBox[{"Show", "[", RowBox[{ RowBox[{"{", RowBox[{"pointsplot", ",", "vdplot", ",", "dtplot"}], "}"}], ",", RowBox[{"PlotRange", "\[Rule]", " ", RowBox[{"{", RowBox[{ RowBox[{"-", "20"}], ",", "12"}], "}"}]}], ",", RowBox[{"ImageSize", "\[Rule]", " ", "500"}]}], "]"}]}]], "Input", CellChangeTimes->{{3.404499972005012*^9, 3.404499978693706*^9}}], Cell[BoxData[ GraphicsBox[{ {Hue[0.65], PointSize[0.05], PointBox[{{0., 0.}, {6.8, 7.4}, {-3., 9.6}, {-9.3, -6.9}, {-0.4, -7.3}, { 10.9, -7.1}, {-10.6, -17.5}, {-1., -17.5}, {10.2, -17.5}}]}, {RGBColor[0.2, 0.7, 0.7], Thickness[0.007], LineBox[{{-9.026022913256954, 2.448117839607198}, {1.263237311385459, 5.663511659807957}, {7.636606173413991, -0.1930975647588031}, { 5.192397767261253, -3.945473850260891}, {-4.683901427913404, \ -3.404306771073237}, {-9.026022913256954, 2.448117839607198}}], LineBox[{{-5.076631509558339, -12.14255108767304}, {-4.683901427913404, \ -3.404306771073237}, {5.192397767261253, -3.945473850260891}, { 5.334051797580507, -11.94892656329869}, { 4.600000000000001, -12.71176470588235}, {-5.076631509558339, \ -12.14255108767304}}]}, { {Hue[0.65], PointSize[0.05], PointBox[{{0., 0.}, {6.8, 7.4}, {-3., 9.6}, {-9.3, -6.9}, {-0.4, -7.3}, { 10.9, -7.1}, {-10.6, -17.5}, {-1., -17.5}, {10.2, -17.5}}]}, {RGBColor[0.7, 0.2, 0.4], LineBox[{{0, 0}, {6.8, 7.4}}], LineBox[{{0, 0}, {-3., 9.6}}], LineBox[{{0, 0}, {-9.3, -6.9}}], LineBox[{{0, 0}, {-0.4, -7.3}}], LineBox[{{0, 0}, {10.9, -7.1}}], LineBox[{{6.8, 7.4}, {-3., 9.6}}], LineBox[{{6.8, 7.4}, {10.9, -7.1}}], LineBox[{{-3., 9.6}, {-9.3, -6.9}}], LineBox[{{-9.3, -6.9}, {-0.4, -7.3}}], LineBox[{{-9.3, -6.9}, {-10.6, -17.5}}], LineBox[{{-9.3, -6.9}, {-1., -17.5}}], LineBox[{{-0.4, -7.3}, {10.9, -7.1}}], LineBox[{{-0.4, -7.3}, {-1., -17.5}}], LineBox[{{-0.4, -7.3}, {10.2, -17.5}}], LineBox[{{10.9, -7.1}, {10.2, -17.5}}], LineBox[{{-10.6, -17.5}, {-1., -17.5}}], LineBox[{{-1., -17.5}, {10.2, -17.5}}]}}}, AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], ImageSize->500, PlotRange->{-20, 12}, PlotRangeClipping->True]], "Output", CellChangeTimes->{3.4044999790455637`*^9}] }, Open ]], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"convexHullPlot", "=", RowBox[{"Show", "[", RowBox[{ RowBox[{"{", RowBox[{"pointsplot", ",", RowBox[{"Graphics", "[", RowBox[{"{", RowBox[{ RowBox[{"RGBColor", "[", RowBox[{".3", ",", ".2", ",", ".5"}], "]"}], ",", RowBox[{"Thickness", "[", ".01", "]"}], ",", RowBox[{"Dashing", "[", RowBox[{"{", RowBox[{".01", ",", ".04"}], "}"}], "]"}], ",", RowBox[{"Line", "[", RowBox[{"vertexCoordinates", "/.", RowBox[{"convexHull", "[", "points", "]"}]}], "]"}]}], "}"}], "]"}]}], "}"}], ",", RowBox[{"ImageSize", "\[Rule]", " ", "400"}]}], "]"}]}]], "Input", CellChangeTimes->{{3.404499983886251*^9, 3.404499987859964*^9}}], Cell[BoxData[ GraphicsBox[{ {Hue[0.65], PointSize[0.05], PointBox[{{0., 0.}, {6.8, 7.4}, {-3., 9.6}, {-9.3, -6.9}, {-0.4, -7.3}, { 10.9, -7.1}, {-10.6, -17.5}, {-1., -17.5}, {10.2, -17.5}}]}, {RGBColor[0.3, 0.2, 0.5], Thickness[0.01], Dashing[{0.01, 0.04}], LineBox[{{-9.3, -6.9}, {-10.6, -17.5}, {10.2, -17.5}, {10.9, -7.1}, {6.8, 7.4}, {-3., 9.6}, {-9.3, -6.9}}]}}, AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], ImageSize->400, PlotRange->{-20, 12}, PlotRangeClipping->True]], "Output", CellChangeTimes->{3.4044999884749117`*^9}] }, Open ]], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"allplot", "=", RowBox[{"Show", "[", RowBox[{ RowBox[{"{", RowBox[{ "pointsplot", ",", "convexHullPlot", ",", "vdplot", ",", "dtplot"}], "}"}], ",", RowBox[{"PlotRange", "\[Rule]", " ", RowBox[{"{", RowBox[{ RowBox[{"-", "20"}], ",", "12"}], "}"}]}], ",", RowBox[{"ImageSize", "\[Rule]", " ", "500"}]}], "]"}]}]], "Input", CellChangeTimes->{{3.404499996942089*^9, 3.4045000021278048`*^9}}], Cell[BoxData[ GraphicsBox[{ {Hue[0.65], PointSize[0.05], PointBox[{{0., 0.}, {6.8, 7.4}, {-3., 9.6}, {-9.3, -6.9}, {-0.4, -7.3}, { 10.9, -7.1}, {-10.6, -17.5}, {-1., -17.5}, {10.2, -17.5}}]}, { {Hue[0.65], PointSize[0.05], PointBox[{{0., 0.}, {6.8, 7.4}, {-3., 9.6}, {-9.3, -6.9}, {-0.4, -7.3}, { 10.9, -7.1}, {-10.6, -17.5}, {-1., -17.5}, {10.2, -17.5}}]}, {RGBColor[0.3, 0.2, 0.5], Thickness[0.01], Dashing[{0.01, 0.04}], LineBox[{{-9.3, -6.9}, {-10.6, -17.5}, {10.2, -17.5}, {10.9, -7.1}, {6.8, 7.4}, {-3., 9.6}, {-9.3, -6.9}}]}}, {RGBColor[0.2, 0.7, 0.7], Thickness[0.007], LineBox[{{-9.026022913256954, 2.448117839607198}, {1.263237311385459, 5.663511659807957}, {7.636606173413991, -0.1930975647588031}, { 5.192397767261253, -3.945473850260891}, {-4.683901427913404, \ -3.404306771073237}, {-9.026022913256954, 2.448117839607198}}], LineBox[{{-5.076631509558339, -12.14255108767304}, {-4.683901427913404, \ -3.404306771073237}, {5.192397767261253, -3.945473850260891}, { 5.334051797580507, -11.94892656329869}, { 4.600000000000001, -12.71176470588235}, {-5.076631509558339, \ -12.14255108767304}}]}, { {Hue[0.65], PointSize[0.05], PointBox[{{0., 0.}, {6.8, 7.4}, {-3., 9.6}, {-9.3, -6.9}, {-0.4, -7.3}, { 10.9, -7.1}, {-10.6, -17.5}, {-1., -17.5}, {10.2, -17.5}}]}, {RGBColor[0.7, 0.2, 0.4], LineBox[{{0, 0}, {6.8, 7.4}}], LineBox[{{0, 0}, {-3., 9.6}}], LineBox[{{0, 0}, {-9.3, -6.9}}], LineBox[{{0, 0}, {-0.4, -7.3}}], LineBox[{{0, 0}, {10.9, -7.1}}], LineBox[{{6.8, 7.4}, {-3., 9.6}}], LineBox[{{6.8, 7.4}, {10.9, -7.1}}], LineBox[{{-3., 9.6}, {-9.3, -6.9}}], LineBox[{{-9.3, -6.9}, {-0.4, -7.3}}], LineBox[{{-9.3, -6.9}, {-10.6, -17.5}}], LineBox[{{-9.3, -6.9}, {-1., -17.5}}], LineBox[{{-0.4, -7.3}, {10.9, -7.1}}], LineBox[{{-0.4, -7.3}, {-1., -17.5}}], LineBox[{{-0.4, -7.3}, {10.2, -17.5}}], LineBox[{{10.9, -7.1}, {10.2, -17.5}}], LineBox[{{-10.6, -17.5}, {-1., -17.5}}], LineBox[{{-1., -17.5}, {10.2, -17.5}}]}}}, AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948], ImageSize->500, PlotRange->{-20, 12}, PlotRangeClipping->True]], "Output", CellChangeTimes->{3.40450000255361*^9}] }, Open ]] }, Open ]] }, Open ]] }, WindowSize->{718, 816}, WindowMargins->{{Automatic, 362}, {Automatic, 46}}, DockedCells->(FrontEndExecute[{ FrontEnd`NotebookApply[ FrontEnd`InputNotebook[], #, Placeholder]}]& ), CellLabelAutoDelete->True, Magnification->1., FrontEndVersion->"6.0 for Mac OS X x86 (32-bit) (June 19, 2007)", StyleDefinitions->"Default.nb" ] (* End of Notebook Content *) (* Internal cache information *) (*CellTagsOutline CellTagsIndex->{} *) (*CellTagsIndex CellTagsIndex->{} *) (*NotebookFileOutline Notebook[{ Cell[CellGroupData[{ Cell[590, 23, 46, 0, 76, "Title"], Cell[639, 25, 187, 6, 26, "Text"], Cell[CellGroupData[{ Cell[851, 35, 108, 2, 25, "Subsubsection"], Cell[962, 39, 1679, 25, 529, "Text"] }, Closed]], Cell[CellGroupData[{ Cell[2678, 69, 33, 0, 37, "Section"], Cell[CellGroupData[{ Cell[2736, 73, 913, 32, 43, "Input"], Cell[3652, 107, 911, 32, 43, "Output"] }, Open ]], Cell[CellGroupData[{ Cell[4600, 144, 592, 15, 43, "Input"], Cell[5195, 161, 387, 9, 262, "Output"] }, Open ]], Cell[CellGroupData[{ Cell[5619, 175, 350, 9, 43, "Input"], Cell[5972, 186, 3482, 96, 133, "Output"] }, Open ]], Cell[9469, 285, 529, 15, 58, "Input"], Cell[CellGroupData[{ Cell[10023, 304, 175, 4, 27, "Input"], Cell[10201, 310, 997, 19, 262, "Output"] }, Open ]] }, Open ]], Cell[CellGroupData[{ Cell[11247, 335, 75, 0, 67, "Section"], Cell[CellGroupData[{ Cell[11347, 339, 395, 10, 58, "Input"], Cell[11745, 351, 10029, 321, 298, "Output"] }, Open ]], Cell[CellGroupData[{ Cell[21811, 677, 739, 21, 73, "Input"], Cell[22553, 700, 1136, 23, 262, "Output"] }, Open ]], Cell[CellGroupData[{ Cell[23726, 728, 435, 11, 27, "Input"], Cell[24164, 741, 1920, 36, 323, "Output"] }, Open ]], Cell[CellGroupData[{ Cell[26121, 782, 789, 20, 88, "Input"], Cell[26913, 804, 582, 12, 262, "Output"] }, Open ]], Cell[CellGroupData[{ Cell[27532, 821, 471, 13, 43, "Input"], Cell[28006, 836, 2293, 42, 323, "Output"] }, Open ]] }, Open ]] }, Open ]] } ] *) (* End of internal cache information *)