Esempio n. 1
0
        public void TestEquals()
        {
            Matrix22F m1 = new Matrix22F(columnMajor, MatrixOrder.ColumnMajor);
            Matrix22F m2 = new Matrix22F(columnMajor, MatrixOrder.ColumnMajor);

            Assert.IsTrue(m1.Equals(m1));
            Assert.IsTrue(m1.Equals(m2));
            for (int i = 0; i < 4; i++)
            {
                m2     = new Matrix22F(columnMajor, MatrixOrder.ColumnMajor);
                m2[i] += 0.1f;
                Assert.IsFalse(m1.Equals(m2));
            }

            Assert.IsFalse(m1.Equals(m1.ToString()));
        }
Esempio n. 2
0
        public void TestToString()
        {
            Matrix22F m = new Matrix22F(columnMajor, MatrixOrder.ColumnMajor);

            Assert.IsFalse(String.IsNullOrEmpty(m.ToString()));
        }
Esempio n. 3
0
 public void TestToString()
 {
     Matrix22F m = new Matrix22F(columnMajor, MatrixOrder.ColumnMajor);
       Assert.IsFalse(String.IsNullOrEmpty(m.ToString()));
 }
Esempio n. 4
0
        public void TestEquals()
        {
            Matrix22F m1 = new Matrix22F(columnMajor, MatrixOrder.ColumnMajor);
              Matrix22F m2 = new Matrix22F(columnMajor, MatrixOrder.ColumnMajor);
              Assert.IsTrue(m1.Equals(m1));
              Assert.IsTrue(m1.Equals(m2));
              for (int i = 0; i < 4; i++)
              {
            m2 = new Matrix22F(columnMajor, MatrixOrder.ColumnMajor);
            m2[i] += 0.1f;
            Assert.IsFalse(m1.Equals(m2));
              }

              Assert.IsFalse(m1.Equals(m1.ToString()));
        }