/// <summary>
        /// 读取到历元存储对象
        /// </summary>
        /// <param name="tables"></param>
        /// <returns></returns>
        public static MultiSiteEpochValueStorage ReadToEpochStorage(ObjectTableManager tables)
        {
            MultiSiteEpochValueStorage multiSiteStorage = new MultiSiteEpochValueStorage("无电离层双差结果");

            foreach (var table in tables)
            {
                MultiSatEpochRmsNumeralStorage multiSatStorage = multiSiteStorage.GetOrCreate(table.Name);
                var indexName = table.GetIndexColName();
                foreach (var row in table.BufferedValues)
                {
                    var epoch = (Time)row[indexName];
                    foreach (var item in row)
                    {
                        if (item.Key == indexName)
                        {
                            continue;
                        }
                        var prn = SatelliteNumber.Parse(item.Key);
                        var val = (double)item.Value;
                        multiSatStorage.GetOrCreate(epoch).Add(prn, new RmsedNumeral(val, 0));
                    }
                }
            }
            return(multiSiteStorage);
        }
        /// <summary>
        /// 计算窄巷模糊度浮点解
        /// </summary>
        /// <param name="wideIntVals"></param>
        /// <param name="funcToSolve"></param>
        /// <returns></returns>
        public MultiSatEpochRmsNumeralStorage GetNarrowLaneFcbs(MultiSatPeriodRmsNumeralStorage wideIntVals, Func <RmsedNumeral, RmsedNumeral, RmsedNumeral> funcToSolve)
        {
            MultiSatEpochRmsNumeralStorage result = new MultiSatEpochRmsNumeralStorage(this.Name + "窄巷模糊度");

            foreach (var kv in this.Data)
            {
                var time      = kv.Key;
                var resultRow = result.GetOrCreate(time);
                foreach (var row in kv.Value.KeyValues)
                {
                    var prn     = row.Key;
                    var wideInt = wideIntVals.GetValue(prn, time);

                    if (wideInt == null)
                    {
                        continue;
                    }

                    //计算窄巷模糊度
                    var resultVal = funcToSolve(row.Value, wideInt);

                    resultRow[prn] = resultVal;// new RmsedNumeral
                }
            }
            return(result);
        }
        /// <summary>
        /// 返回四舍五入小数部分
        /// </summary>
        /// <returns></returns>
        public MultiSatEpochRmsNumeralStorage GetRoundFraction()
        {
            MultiSatEpochRmsNumeralStorage result = new MultiSatEpochRmsNumeralStorage("正小数_" + this.Name);

            foreach (var kv in this.Data)
            {
                var time      = kv.Key;
                var resultRow = result.GetOrCreate(time);
                foreach (var row in kv.Value.KeyValues)
                {
                    var prn = row.Key;
                    resultRow[prn] = Geo.Utils.DoubleUtil.GetRoundFraction(row.Value);// new RmsedNumeral
                }
            }
            return(result);
        }
        /// <summary>
        /// 原始数据差分,返回新对象。
        /// </summary>
        /// <param name="basePrn"></param>
        /// <returns></returns>
        public MultiSatEpochRmsNumeralStorage GetRawDiffer(SatelliteNumber basePrn)
        {
            MultiSatEpochRmsNumeralStorage result = new MultiSatEpochRmsNumeralStorage("原始差分");

            foreach (var kv in this.Data)
            {
                if (!kv.Value.Contains(basePrn))
                {
                    continue;
                }
                var baseVals = kv.Value[basePrn];
                foreach (var row in kv.Value.KeyValues)
                {
                    var val = row.Value - baseVals;
                    result.GetOrCreate(kv.Key)[row.Key] = val;
                }
            }
            return(result);
        }
        /// <summary>
        /// 周期内加权平均
        /// </summary>
        /// <param name="minDataCount">小于此,则忽略</param>
        /// <param name="maxRmsTimes">最大运行的RMS倍数</param>
        /// <returns></returns>
        public MultiSatEpochRmsNumeralStorage GetAverage(int minDataCount, double maxRmsTimes)
        {
            MultiSatEpochRmsNumeralStorage result = new MultiSatEpochRmsNumeralStorage("平均_" + this.Name);

            foreach (var epochVals in this.Data)
            {
                var epcohResult = new BaseDictionary <SatelliteNumber, RmsedNumeral>();
                result[epochVals.Key] = epcohResult;
                foreach (var kv in epochVals.Value.Data)
                {
                    if (kv.Value.Count < minDataCount)
                    {
                        continue;
                    }

                    var ave = Geo.Utils.DoubleUtil.GetAverageInOnePeriod(kv.Value.Values.ToList(), 1, maxRmsTimes);
                    epcohResult[kv.Key] = ave;
                }
            }
            return(result);
        }