当前位置: 首页>>代码示例>>C#>>正文


C# LiveGeometry.TutorParser.HardCodedParserMain.GetIntersection方法代码示例

本文整理汇总了C#中LiveGeometry.TutorParser.HardCodedParserMain.GetIntersection方法的典型用法代码示例。如果您正苦于以下问题:C# LiveGeometry.TutorParser.HardCodedParserMain.GetIntersection方法的具体用法?C# LiveGeometry.TutorParser.HardCodedParserMain.GetIntersection怎么用?C# LiveGeometry.TutorParser.HardCodedParserMain.GetIntersection使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在LiveGeometry.TutorParser.HardCodedParserMain的用法示例。


在下文中一共展示了LiveGeometry.TutorParser.HardCodedParserMain.GetIntersection方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: IPage119Problem3

        public IPage119Problem3(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "I Page 119 Problem 3";

            Point a = new Point("A", 4, 0); points.Add(a);
            Point b = new Point("B", 4, 10); points.Add(b);
            Point c = new Point("C", 8, 10); points.Add(c);
            Point d = new Point("D", 0, 0); points.Add(d);
            Point o = new Point("O", 4, 5); points.Add(o);

            Segment ad = new Segment(a, d); segments.Add(ad);
            Segment bc = new Segment(b, c); segments.Add(bc);

            List<Point> pts = new List<Point>();
            pts.Add(d);
            pts.Add(o);
            pts.Add(c);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(b);
            pts.Add(o);
            pts.Add(a);
            collinear.Add(new Collinear(pts));

                        parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            given.Add(new GeometricCongruentSegments(ad, bc));
            given.Add(new Perpendicular(parser.GetIntersection(ad, new Segment(a, b))));
            given.Add(new Perpendicular(parser.GetIntersection(bc, new Segment(a, b))));

            goals.Add(new SegmentBisector(parser.GetIntersection((Segment)parser.Get(new Segment(c, d)), (Segment)parser.Get(new Segment(a, b))), (Segment)parser.Get(new Segment(c, d))));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:34,代码来源:IPage119Problem3.cs

示例2: Page296Theorem7_1_Test3

        //Demonstrates: A segment perpendicular to a radius is a tangent, tangents from point are congruent
        public Page296Theorem7_1_Test3(bool onoff, bool complete)
            : base(onoff, complete)
        {
            Point o = new Point("O", 0, 0); points.Add(o);

            //Intersection point for two tangents
            Point c = new Point("C", 0, 6.25); points.Add(c);

            //Points for two tangents
            Point a = new Point("A", 3, 4); points.Add(a);
            Point b = new Point("B", -3, 4); points.Add(b);

            //Tangent and Radii segments
            Segment ac = new Segment(a, c); segments.Add(ac);
            Segment bc = new Segment(b, c); segments.Add(bc);
            Segment oa = new Segment(o, a); segments.Add(oa);
            Segment ob = new Segment(o, b); segments.Add(ob);

            Circle circle = new Circle(o, 5.0);
            circles.Add(circle);

            parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            Intersection inter1 = parser.GetIntersection(ac, oa);
            Intersection inter2 = parser.GetIntersection(bc, ob);
            given.Add(new Strengthened(inter1, new Perpendicular(inter1)));
            given.Add(new Strengthened(inter2, new Perpendicular(inter2)));

            //CircleSegmentIntersection cInter = (CircleSegmentIntersection)parser.Get(new CircleSegmentIntersection(a, circle, ap));
            //given.Add(new Strengthened(cInter, new Tangent(cInter)));

            goals.Add(new GeometricCongruentSegments(ac, bc));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:34,代码来源:Page296Theorem7_1_Test3.cs

示例3: Page197Problem35

        public Page197Problem35(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "Page 197 Problem 35";

            Point a = new Point("A", 0, 5); points.Add(a);
            Point b = new Point("B", 3, 8); points.Add(b);
            Point c = new Point("C", 5, 0); points.Add(c);
            Point d = new Point("D", 9000, 5); points.Add(d);
            Point e = new Point("E", 0, 0); points.Add(e);
            Point f = new Point("F", 0, 30); points.Add(f);

            Segment ab = new Segment(a, b); segments.Add(ab);
            Segment ac = new Segment(a, c); segments.Add(ac);
            Segment ad = new Segment(a, d); segments.Add(ad);

            List<Point> pts = new List<Point>();
            pts.Add(e);
            pts.Add(a);
            pts.Add(f);
            collinear.Add(new Collinear(pts));

                        parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            given.Add(new GeometricCongruentAngles((Angle)parser.Get(new Angle(f, a, b)),
                                                   (Angle)parser.Get(new Angle(d, a, b))));

            goals.Add(new Strengthened(parser.GetIntersection(new Segment(a, b), new Segment(a, c)),
                                       new Perpendicular(parser.GetIntersection(new Segment(a, b), new Segment(a, c)))));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:30,代码来源:Page197Problem35.cs

示例4: Page174Theorem416_2

        // Demonstration of theorem "Median of a trapezoid is half the sum of the bases"
        /*
         *         D_______E
         *         /       \
         * L______/M________\N
         *       /           \
         *      /_____________\
         *     A               B
         */
        public Page174Theorem416_2(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "Page 174 Theorem 4-16 Part 2";

            Point a = new Point("A", 0, 0); points.Add(a);
            Point b = new Point("B", 10, 0); points.Add(b);
            Point c = new Point("C", 8, 4); points.Add(c);
            Point d = new Point("D", 2, 4); points.Add(d);

            Point l = new Point("L", -7, 2); points.Add(l);
            Point m = new Point("M", 1, 2); points.Add(m);
            Point n = new Point("N", 9, 2); points.Add(n);

            Segment ab = new Segment(a, b); segments.Add(ab);
            Segment cd = new Segment(c, d); segments.Add(cd);

            List<Point> pts = new List<Point>();
            pts.Add(a);
            pts.Add(m);
            pts.Add(d);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(b);
            pts.Add(n);
            pts.Add(c);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(l);
            pts.Add(m);
            pts.Add(n);
            collinear.Add(new Collinear(pts));

            parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            Segment ad = (Segment)parser.Get(new Segment(a, d));
            Segment bc = (Segment)parser.Get(new Segment(b, c));
            Segment ln = (Segment)parser.Get(new Segment(l, n));
            Quadrilateral quad = (Quadrilateral)parser.Get(new Quadrilateral(ad, bc, cd, ab));
            Addition sum = new Addition(ab, cd);

            //If segment MN is the median of the trapezoid, and segment LN is congruent to the sum of AB and CD, then
            //segment AD must bisect segment LN

            given.Add(new Strengthened(quad, new Trapezoid(quad)));
            given.Add(new SegmentBisector(parser.GetIntersection(ln, ad), ln));
            given.Add(new SegmentBisector(parser.GetIntersection(ln, bc), ln));
            given.Add(new GeometricSegmentEquation(ln, sum));

            goals.Add(new SegmentBisector(parser.GetIntersection(ad, ln), ad));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:62,代码来源:Page174Theorem416_2.cs

示例5: Page146Problem15

        public Page146Problem15(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "Page 146 Problem 15";

            Point t = new Point("T", 0, 0); points.Add(t);
            Point p = new Point("P", 0.5, 1.5); points.Add(p);
            Point s = new Point("S", 1, 3); points.Add(s);
            Point x = new Point("X", 3, 1); points.Add(x);
            Point q = new Point("Q", 3.5, 2.5); points.Add(q);
            Point y = new Point("Y", 4, 4); points.Add(y);
            Point o = new Point("O", 2, 2); points.Add(o);

            List<Point> pts = new List<Point>();
            pts.Add(t);
            pts.Add(o);
            pts.Add(y);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(s);
            pts.Add(o);
            pts.Add(x);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(s);
            pts.Add(p);
            pts.Add(t);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(y);
            pts.Add(q);
            pts.Add(x);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(p);
            pts.Add(o);
            pts.Add(q);
            collinear.Add(new Collinear(pts));

                        parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            given.Add(new SegmentBisector(parser.GetIntersection(new Segment(s, x), new Segment(t, y)), (Segment)parser.Get(new Segment(s, x))));
            given.Add(new SegmentBisector(parser.GetIntersection(new Segment(s, x), new Segment(t, y)), (Segment)parser.Get(new Segment(t, y))));

            InMiddle goalIm = (InMiddle)parser.Get(new InMiddle( o, new Segment(p, q)));
            goals.Add(new Strengthened(goalIm, new Midpoint(goalIm)));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:51,代码来源:Page146Problem15.cs

示例6: Page273Problem39

        public Page273Problem39(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "Page 273 Problem 39";

            Point a = new Point("A", 1, 0); points.Add(a);
            Point b = new Point("B", 0, 5); points.Add(b);
            Point c = new Point("C", 3, 3); points.Add(c);
            Point d = new Point("D", 5, 6); points.Add(d);
            Point e = new Point("E", 6, 1); points.Add(e);

            Segment ab = new Segment(a, b); segments.Add(ab);
            Segment de = new Segment(d, e); segments.Add(de);

            List<Point> pts = new List<Point>();
            pts.Add(a);
            pts.Add(c);
            pts.Add(d);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(b);
            pts.Add(c);
            pts.Add(e);
            collinear.Add(new Collinear(pts));

                        parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            given.Add(new SegmentBisector(parser.GetIntersection(new Segment(a, d), new Segment(b, e)), (Segment)parser.Get(new Segment(a, d))));
            given.Add(new GeometricParallel(ab, de));

            goals.Add(new GeometricCongruentTriangles(new Triangle(a, b, c), new Triangle(d, e, c)));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:33,代码来源:Page273Problem39.cs

示例7: Page90Problem22

        public Page90Problem22(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "Page 90 Problem 22";

            Point a = new Point("A", 0, 0); points.Add(a);
            Point b = new Point("B", 5, 0); points.Add(b);
            Point c = new Point("C", 2.5, 20); points.Add(c);
            Point d = new Point("D", 2.5, 0); points.Add(d);

            Segment ac = new Segment(a, c); segments.Add(ac);
            Segment cb = new Segment(c, b); segments.Add(cb);
            Segment cd = new Segment(c, d); segments.Add(cd);

            List<Point> pts = new List<Point>();
            pts.Add(a);
            pts.Add(d);
            pts.Add(b);
            collinear.Add(new Collinear(pts));

                        parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            given.Add(new PerpendicularBisector(parser.GetIntersection(cd, new Segment(a, b)), cd));

            goals.Add(new GeometricCongruentTriangles(new Triangle(a, c, d), new Triangle(b, c, d)));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:26,代码来源:Page90Problem22.cs

示例8: Page296Theorem7_1

        //Demonstrates: Tangents are perpendicular to radii
        public Page296Theorem7_1(bool onoff, bool complete)
            : base(onoff, complete)
        {
            Point o = new Point("O", 0, 0); points.Add(o);
            Point r = new Point("R", -3, -5); points.Add(r);
            Point s = new Point("S", 8, -5); points.Add(s);
            Point t = new Point("T", 0, -5); points.Add(t);

            Segment ot = new Segment(o, t); segments.Add(ot);

            List<Point> pnts = new List<Point>();
            pnts.Add(r);
            pnts.Add(t);
            pnts.Add(s);
            collinear.Add(new Collinear(pnts));

            Circle c = new Circle(o, 5.0);
            circles.Add(c);

            parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            Segment rs = (Segment)parser.Get(new Segment(r, s));

            CircleSegmentIntersection cInter = (CircleSegmentIntersection)parser.Get(new CircleSegmentIntersection(t, c, rs));
            given.Add(new Strengthened(cInter, new Tangent(cInter)));

            Intersection inter = parser.GetIntersection(ot, rs);
            goals.Add(new Strengthened(inter, new Perpendicular(inter)));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:30,代码来源:Page296Theorem7_1.cs

示例9: IPage119Problem5

        public IPage119Problem5(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "I Page 119 Problem 5";

            Point a = new Point("A", 0, 0);  points.Add(a);
            Point b = new Point("B", 10, 0); points.Add(b);
            Point p = new Point("P", 8, -4); points.Add(p);
            Point q = new Point("Q", 8, 4);  points.Add(q);

            Point x = new Point("X", 16, 8);    points.Add(x);
            Point y = new Point("Y", 16, 0);   points.Add(y);
            Point z = new Point("Z", 24, -12);   points.Add(z);
            Point o = new Point("O", -100, 0); points.Add(o);

            Segment bq = new Segment(b, q); segments.Add(bq);
            Segment bp = new Segment(b, p); segments.Add(bp);

            List<Point> pts = new List<Point>();
            pts.Add(o);
            pts.Add(a);
            pts.Add(b);
            pts.Add(y);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(a);
            pts.Add(q);
            pts.Add(x);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(a);
            pts.Add(p);
            pts.Add(z);
            collinear.Add(new Collinear(pts));

                        parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            given.Add(new AngleBisector((Angle)parser.Get(new Angle(q, a, p)), (Segment)parser.Get(new Segment(o, y))));
            given.Add(new Perpendicular(parser.GetIntersection(new Segment(b, p), new Segment(a, z))));
            given.Add(new Perpendicular(parser.GetIntersection(new Segment(b, q), new Segment(a, x))));

            goals.Add(new GeometricCongruentTriangles(new Triangle(a, p, b), new Triangle(a, q, b)));
            goals.Add(new GeometricCongruentSegments((Segment)parser.Get(new Segment(b, p)), (Segment)parser.Get(new Segment(b, q))));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:46,代码来源:IPage119Problem5.cs

示例10: Page174Theorem416_1

        // Simple demonstration of theorem "Median of a trapezoid is parallel to the bases"
        public Page174Theorem416_1(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "Page 174 Theorem 4-16 Part 1";

            Point a = new Point("A", 0, 0); points.Add(a);
            Point b = new Point("B", 11, 0); points.Add(b);
            Point c = new Point("C", 7, 4); points.Add(c);
            Point d = new Point("D", 2, 4); points.Add(d);
            Point m = new Point("M", 1, 2); points.Add(m);
            Point n = new Point("N", 9, 2); points.Add(n);

            Segment ab = new Segment(a, b); segments.Add(ab);
            Segment cd = new Segment(c, d); segments.Add(cd);
            Segment mn = new Segment(m, n); segments.Add(mn);

            List<Point> pts = new List<Point>();
            pts.Add(a);
            pts.Add(m);
            pts.Add(d);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(b);
            pts.Add(n);
            pts.Add(c);
            collinear.Add(new Collinear(pts));

            parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            Segment ad = (Segment)parser.Get(new Segment(a, d));
            Segment bc = (Segment)parser.Get(new Segment(b, c));
            Quadrilateral quad = (Quadrilateral)parser.Get(new Quadrilateral(ad, bc, cd, ab));
            //given.Add(new Strengthened(quad, new Trapezoid(ad, bc, cd, ab)));
            given.Add(new Parallel(ab, cd));
            given.Add(new SegmentBisector(parser.GetIntersection(mn, ad), mn));
            given.Add(new SegmentBisector(parser.GetIntersection(mn, bc), mn));

            goals.Add(new Parallel(mn, cd));
            goals.Add(new Parallel(mn, ab));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:42,代码来源:Page174Theorem416_1.cs

示例11: Page48Problem23To31

        public Page48Problem23To31(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "Page 48 Problem 23-31";

            Point a = new Point("A", 0, 5); points.Add(a);
            Point b = new Point("B", 2, 4); points.Add(b);
            Point c = new Point("C", 4, 3); points.Add(c);
            Point m = new Point("M", 3, 6); points.Add(m);

            Point x = new Point("X", -2, 1); points.Add(x);
            Point y = new Point("Y", 0, 0); points.Add(y);
            Point z = new Point("Z", 2, -1); points.Add(z);
            Point q = new Point("Q", -1, -2); points.Add(q);

            List<Point> pts = new List<Point>();
            pts.Add(a);
            pts.Add(b);
            pts.Add(c);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(x);
            pts.Add(y);
            pts.Add(z);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(q);
            pts.Add(y);
            pts.Add(b);
            pts.Add(m);
            collinear.Add(new Collinear(pts));

                        parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);
            given.Add(new Perpendicular(parser.GetIntersection(new Segment(m, q), new Segment(a, c))));
            given.Add(new GeometricParallel((Segment)parser.Get(new Segment(a, c)), (Segment)parser.Get(new Segment(x, z))));

            goals.Add(new Perpendicular(parser.GetIntersection(new Segment(m, q), new Segment(x, z))));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:40,代码来源:Page48Problem23To31.cs

示例12: Page156Problem35

        public Page156Problem35(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "Page 156 Problem 35";

            Point a = new Point("A", 9, 0); points.Add(a);
            Point b = new Point("B", 0, 3); points.Add(b);
            Point c = new Point("C", 0, 9); points.Add(c);
            Point d = new Point("D", 9, 9); points.Add(d);

            Segment ab = new Segment(a, b); segments.Add(ab);
            Segment ad = new Segment(a, d); segments.Add(ad);
            Segment bc = new Segment(b, c); segments.Add(bc);
            Segment bd = new Segment(b, d); segments.Add(bd);
            Segment cd = new Segment(c, d); segments.Add(cd);

                        parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            given.Add(new GeometricCongruentAngles((Angle)parser.Get(new Angle(a, d, b)), (Angle)parser.Get(new Angle(d, b, c))));
            given.Add(new Perpendicular(parser.GetIntersection(new Segment(a, d), new Segment(c, d))));

            goals.Add(new Strengthened(parser.GetIntersection(new Segment(b, c), new Segment(c, d)),
                      new Perpendicular(parser.GetIntersection(new Segment(b, c), new Segment(c, d)))));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:24,代码来源:Page156Problem35.cs

示例13: Page296Theorem7_1_Test2

        //Demonstrates: Tangents are perpendicular to radii
        public Page296Theorem7_1_Test2(bool onoff, bool complete)
            : base(onoff, complete)
        {
            Point o = new Point("O", 0, 0); points.Add(o);
            Point a = new Point("A", 3, 4); points.Add(a);
            Point p = new Point("P", 0, 6.25); points.Add(p);

            Segment ap = new Segment(a, p); segments.Add(ap);
            Segment ao = new Segment(a, o); segments.Add(ao);

            Circle circle = new Circle(o, 5.0);
            circles.Add(circle);

            parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            CircleSegmentIntersection cInter = (CircleSegmentIntersection)parser.Get(new CircleSegmentIntersection(a, circle, ap));
            given.Add(new Strengthened(cInter, new Tangent(cInter)));

            Intersection inter = parser.GetIntersection(ao, ap);
            goals.Add(new Strengthened(inter, new Perpendicular(inter)));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:22,代码来源:Page296Theorem7_1_Test2.cs

示例14: IPage128Problem01

        public IPage128Problem01(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "Book I Page 128 Problem 1";

            Point a = new Point("A", 2, 7); points.Add(a);
            Point b = new Point("B", 0, 0); points.Add(b);
            Point c = new Point("C", 4, 0); points.Add(c);
            Point d = new Point("D", 2, 3); points.Add(d);
            Point p = new Point("P", 2, 0); points.Add(p);

            Segment ab = new Segment(a, b); segments.Add(ab);
            Segment ac = new Segment(a, c); segments.Add(ac);
            Segment bd = new Segment(b, d); segments.Add(bd);
            Segment cd = new Segment(c, d); segments.Add(cd);

            List<Point> pts = new List<Point>();
            pts.Add(b);
            pts.Add(p);
            pts.Add(c);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(a);
            pts.Add(d);
            pts.Add(p);
            collinear.Add(new Collinear(pts));

                        parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            given.Add(new IsoscelesTriangle((Triangle)parser.Get(new Triangle(a, b, c))));
            given.Add(new IsoscelesTriangle((Triangle)parser.Get(new Triangle(d, b, c))));

            goals.Add(new GeometricCongruentTriangles(new Triangle(a, b, d), new Triangle(a, c, d)));
            goals.Add(new GeometricCongruentTriangles(new Triangle(a, b, p), new Triangle(a, c, p)));
            goals.Add(new AngleBisector((Angle)parser.Get(new Angle(b, a, c)), (Segment)parser.Get(new Segment(a, p))));
            goals.Add(new AngleBisector((Angle)parser.Get(new Angle(b, d, c)), (Segment)parser.Get(new Segment(a, p))));
            goals.Add(new PerpendicularBisector(parser.GetIntersection(new Segment(a, p), new Segment(b, c)),
                                                (Segment)parser.Get(new Segment(a, p))));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:40,代码来源:IPage128Problem01.cs

示例15: Page160Problem42

        public Page160Problem42(bool onoff, bool complete)
            : base(onoff, complete)
        {
            problemName = "Page 160 Problem 42";

            Point a = new Point("A", -3, -1); points.Add(a);
            Point b = new Point("B", 0, 0); points.Add(b);
            Point c = new Point("C", 6, 2); points.Add(c);
            Point d = new Point("D", 1, -3); points.Add(d);
            Point x = new Point("X", -5, 5); points.Add(x);
            Point y = new Point("Y", -2, 6); points.Add(y);
            Point z = new Point("Z", 1, 7); points.Add(z);
            Point q = new Point("Q", -3, 9); points.Add(q);

            List<Point> pts = new List<Point>();
            pts.Add(q);
            pts.Add(y);
            pts.Add(b);
            pts.Add(d);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(x);
            pts.Add(y);
            pts.Add(z);
            collinear.Add(new Collinear(pts));

            pts = new List<Point>();
            pts.Add(a);
            pts.Add(b);
            pts.Add(c);
            collinear.Add(new Collinear(pts));

                        parser = new LiveGeometry.TutorParser.HardCodedParserMain(points, collinear, segments, circles, onoff);

            given.Add(new GeometricParallel((Segment)parser.Get(new Segment(a, c)), (Segment)parser.Get(new Segment(x, z))));
            given.Add(new Perpendicular(parser.GetIntersection((Segment)parser.Get(new Segment(q, d)), (Segment)parser.Get(new Segment(x, z)))));

            goals.Add(new Supplementary((Angle)parser.Get(new Angle(c, b, y)), (Angle)parser.Get(new Angle(z, y, b))));
        }
开发者ID:wcatykid,项目名称:GeoShader,代码行数:40,代码来源:Page160Problem42.cs


注:本文中的LiveGeometry.TutorParser.HardCodedParserMain.GetIntersection方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。