Esempio n. 1
0
        public void Espg_1_3_2_1_Test()
        {
            var projection = new Krovak(
                new GeographicCoordinate(0.863937979, 0.741764932),
                1.370083463,
                0.528627762,
                0.9999,
                Vector2.Zero,
                new SpheroidEquatorialInvF(6377397.155, 299.15281)
            );
            var input = new GeographicCoordinate(0.876312568, 0.294084);
            var expected = new Point2(1050538.63, 568991.00);

            var result = projection.TransformValue(input);

            Assert.AreEqual(expected.X, result.X, 0.007);
            Assert.AreEqual(expected.Y, result.Y, 0.1);
        }
Esempio n. 2
0
        public void Espg_1_3_2_1_InverseTest()
        {
            var projection = new Krovak(
                new GeographicCoordinate(0.863937979, 0.741764932),
                1.370083463,
                0.528627762,
                0.9999,
                Vector2.Zero,
                new SpheroidEquatorialInvF(6377397.155, 299.15281)
                );
            var expected = new GeographicCoordinate(0.876312568, 0.294084);
            var input    = new Point2(1050538.63, 568991.00);

            var result = projection.GetInverse().TransformValue(input);

            Assert.AreEqual(expected.Latitude, result.Latitude, 0.0000000008);
            Assert.AreEqual(expected.Longitude, result.Longitude, 0.000001);
        }
Esempio n. 3
0
 public Inverse(Krovak core)
     : base(core)
 {
     Contract.Requires(core != null);
 }
Esempio n. 4
0
 public KrovakNorth(Krovak core)
 {
     if (null == core) throw new ArgumentNullException("core");
     Contract.EndContractBlock();
     Core = core;
 }