Exemplo n.º 1
0
        public static TestFitPackage DieFive(double side)
        {
            //A simple test fit configuration modeled after the five side of a since die.
            //Center point is core.
            //Other four are structure.
            //TODO: Implement circulation.

            double frc = side / 6;
            double r   = side / 5;

            Curve floorProfile = RegionsFactory.RectangleWHC(side, side, Point3d.Origin);
            Curve coreCurve    = RegionsFactory.CenteredCircleRadius(r);

            List <Curve> strCurves = new List <Curve>();

            strCurves.Add(RegionsFactory.CircleCR(new Point3d(2 * frc, 2 * frc, 0), r));
            strCurves.Add(RegionsFactory.CircleCR(new Point3d(-2 * frc, 2 * frc, 0), r));
            strCurves.Add(RegionsFactory.CircleCR(new Point3d(-2 * frc, -2 * frc, 0), r));
            strCurves.Add(RegionsFactory.CircleCR(new Point3d(2 * frc, -2 * frc, 0), r));

            FloorPlanPackage FloorPlan = new FloorPlanPackage(floorProfile, coreCurve, null, strCurves, null, null);

            TestFitPackage TestFit = new TestFitPackage(FloorPlan, null);

            return(TestFit);
        }
Exemplo n.º 2
0
        public static List <Brep> CircleInSquare()
        {
            List <Brep> TestEnvironment = new List <Brep>();

            Brep testCircle = Brep.CreatePlanarBreps(RegionsFactory.CenteredCircleRadius(1), .1)[0];
            Brep testSquare = Brep.CreatePlanarBreps(RegionsFactory.RectangleWHC(5, 5, Point3d.Origin), .1)[0];

            TestEnvironment.Add(testCircle);
            TestEnvironment.Add(testSquare);

            return(TestEnvironment);
        }
Exemplo n.º 3
0
        public static List <Brep> SquareWithCircumscribedCircle()
        {
            List <Brep> TestEnvironment = new List <Brep>();

            Brep testCircle = Brep.CreatePlanarBreps(RegionsFactory.CenteredCircleRadius(Math.Sqrt(2) / 2), .01)[0];
            Brep testSquare = Brep.CreatePlanarBreps(RegionsFactory.RectangleWHC(1, 1, Point3d.Origin), .01)[0];

            TestEnvironment.Add(testSquare);
            TestEnvironment.Add(testCircle);

            return(TestEnvironment);
        }