Beispiel #1
0
        /// <summary>
        /// 计算A,B,C等参数
        /// </summary>
        /// <param name="sinA0">sinA0</param>
        /// <param name="ABC">ABC数组</param>
        /// <param name="alpha">alpha</param>
        /// <param name="beta">beta</param>
        private void CalABC_AlphaBeta(double sinA0, double[] ABC, ref double alpha, ref double beta, ref double gama)
        {
            double cos2_A0 = 1 - sinA0 * sinA0;
            double k_2 = 0;
            double e2 = Ell.e2, b = Ell.b;
            double e1 = Ell.e1;

            k_2 = GeoPro.Getk_2(e2, cos2_A0);
            GeoPro.GetABC(b, k_2, ABC);
            alpha = GeoPro.GetAlpha(e1, cos2_A0);
            beta  = GeoPro.GetBeta(e1, cos2_A0);
            gama  = GeoPro.GetGama(e1, cos2_A0);
        }
Beispiel #2
0
        /// <summary>
        /// 趋近法算角度
        /// </summary>
        /// <param name="dL">初始经度差</param>
        /// <param name="cosu2">cosu2</param>
        /// <param name="cosu1">cosu1</param>
        /// <param name="ab">ab参数数组</param>
        /// <param name="lamda">lamda经度差估计值</param>
        /// <param name="A1">A1坐标方位角</param>
        /// <param name="del">del</param>
        /// <param name="cos2_A0">cos2_A0</param>
        /// <param name="x">x</param>
        private void CalA1_Lamda(double dL, double u2, double u1, double [] ab, ref double lamda, ref double A1,
                                 ref double del, ref double cos2_A0)
        {
            double deltat = 0, delta = 0;
            double cos_del = 0, sin_del = 0;
            double e1 = Ell.e1;
            double alpha = 0, beta = 0, gama = 0;
            double sinA0;
            double p = 0;
            double q = 0;

            lamda = dL;
            do
            {
                deltat = delta;
                p      = Math.Cos(u2) * Math.Sin(lamda);
                q      = ab[2] - ab[3] * Math.Cos(lamda);
                A1     = Math.Abs(Math.Atan(p / q));
                A1     = GeoPro.InvJudgeA1A2(p, q, A1);

                sin_del = p * Math.Sin(A1) + q * Math.Cos(A1);
                cos_del = ab[0] + ab[1] * Math.Cos(lamda);
                del     = Math.Atan(sin_del / cos_del);
                del     = GeoPro.InvJudgedel(del, cos_del);

                sinA0 = Math.Cos(u1) * Math.Sin(A1);
                double del1 = Math.Atan(Math.Tan(u1) / Math.Cos(A1));
                cos2_A0 = 1 - sinA0 * sinA0;

                alpha = GeoPro.GetAlpha(e1, cos2_A0);
                beta  = GeoPro.GetBeta(e1, cos2_A0);
                gama  = GeoPro.GetGama(e1, cos2_A0);

                delta = (alpha * del + (beta) * Math.Cos(2 * del1 + del) * Math.Sin(del)
                         + gama * Math.Sin(2 * del) * Math.Cos(4 * del1 + 2 * del)) * sinA0;
                lamda = dL + delta;
            } while (Math.Abs(delta - deltat) * 206265 > 0.00001);
        }