Ejemplo n.º 1
0
        public override AdjustResultMatrix Run(AdjustObsMatrix input)
        {
            var result = ConditionalAdjuster.Run(input);



            throw new NotImplementedException();
        }
Ejemplo n.º 2
0
        /// <summary>
        /// 条件平差法解算固定解,将固定解当成虚拟观测量,对原浮点解进行约束,条件平差。
        /// </summary>
        /// <param name="coeffOfParam">系数阵,条件方程构造</param>
        /// <param name="totalFloat">原浮点解</param>
        /// <param name="fixedObs">已经固定的参数,固定解当成虚拟观测量</param>
        /// <returns></returns>
        public static WeightedVector SolveAmbiFixedResultByConditionAdjust(WeightedVector totalFloat, Vector fixedObs, IMatrix coeffOfParam)
        {
            //以下算法已经验证等价!!2018.09.02, czs, hmx
            bool           isSong       = false;
            WeightedVector NewEstimated = null;

            if (isSong)
            {
                #region 求固定解 宋力杰方法
                IMatrix X_old         = totalFloat;
                IMatrix QX_old        = totalFloat.InverseWeight;
                IMatrix coeffOfParamT = coeffOfParam.Transposition;

                IMatrix W = coeffOfParam.Multiply(X_old).Minus(new VectorMatrix(fixedObs));

                IMatrix tmp = coeffOfParam.Multiply(QX_old).Multiply(coeffOfParamT);

                IMatrix Nadd = (QX_old.Multiply(coeffOfParamT)).Multiply(tmp.GetInverse());

                IMatrix X_new = X_old.Minus(Nadd.Multiply(W));

                IMatrix tmp2   = Nadd.Multiply(coeffOfParam);
                IMatrix QX_new = QX_old.Minus(tmp2.Multiply(QX_old));

                NewEstimated = new WeightedVector(X_new, QX_new)
                {
                    ParamNames = coeffOfParam.ColNames
                };
                #endregion
            }
            else
            {
                //条件平差
                AdjustObsMatrix obsMatrix = new AdjustObsMatrix();
                obsMatrix.SetCoefficient(coeffOfParam).SetObservation(totalFloat).SetFreeVector(fixedObs);
                ConditionalAdjuster adjuster = new ConditionalAdjuster();
                var resultMatrix             = adjuster.Run(obsMatrix);

                NewEstimated = resultMatrix.CorrectedObs;
            }

            return(NewEstimated);
        }
Ejemplo n.º 3
0
 /// <summary>
 /// 手动矩阵生成器
 /// </summary>
 public ParamFixedAdjuster()
 {
     ConditionalAdjuster = new ConditionalAdjuster();
 }