Ejemplo n.º 1
0
        public void PieceInversion1()
        {
            var p        = Piece.Interval(3, 5).AsInterval().SetLeftClosed(true).SetRightClosed(true);
            var inverted = PieceFunctions.Invert(p);

            Assert.IsFalse(In(3, inverted));
        }
Ejemplo n.º 2
0
        public void PieceInversion2()
        {
            var p        = Piece.Interval(new ComplexNumber(1, 1), new ComplexNumber(2, 2)).AsInterval().SetLeftClosed(true, true).SetRightClosed(true, true);
            var inverted = PieceFunctions.Invert(p);

            Assert.IsTrue(In(120, inverted));
            Assert.IsTrue(In(new ComplexNumber(320, -13), inverted));
        }