Exemplo n.º 1
0
        public void CoordinateSystem3DTest_002()
        {
            var p = new Vector3D(53.0147, 34.5182, 20.1);

            var o  = new Vector3D(15.3106, 22.97, 0);
            var v1 = new Vector3D(10.3859, 3.3294, 30);
            var v2 = new Vector3D(2.3515, 14.101, 0);

            var cs = new CoordinateSystem3D(o, v1, v2);

            var u = p.ToUCS(cs);

            Assert.True(u.EqualsTol(1e-4, 32.3623, 12.6875, -27.3984));
            Assert.True(u.ToWCS(cs).EqualsTol(1e-4, p));

            Assert.True(p.ToUCS(cs).EqualsTol(1e-4, cs.ToUCS(p)));
            Assert.True(cs.ToWCS(u).EqualsTol(1e-4, u.ToWCS(cs)));
        }
Exemplo n.º 2
0
 public Vector3D ToUCS(CoordinateSystem3D cs)
 {
     return(cs.ToUCS(this));
 }