/// <summary> /// 比较 /// </summary> /// <param name="netA"></param> /// <param name="netB"></param> /// <returns></returns> public static List <NamedXyzEnu> Compare(BaseLineNet netA, BaseLineNet netB) {//提取和转换,有的方向不一致 List <NamedXyz> netBlines = new List <NamedXyz>(); foreach (var item in netB) { var line = netA.GetOrReversed(item.BaseLineName); if (line == null) { continue; } var namedXyz = new NamedXyz(line.BaseLineName.Name, line.EstimatedVector); netBlines.Add(namedXyz); } var CoordsB = netB.GetNamedXyzs(); var Compared = NamedXyz.Compare(netBlines, CoordsB); var CompareResults = new List <NamedXyzEnu>(); foreach (var localXyz in Compared) { GnssBaseLineName name = new GnssBaseLineName(localXyz.Name); var staXyz = netA.GetSiteCoord(name.RefName); if (staXyz == null) { continue; } var item = NamedXyzEnu.Get(localXyz.Name, localXyz.Value, staXyz); CompareResults.Add(item); } return(CompareResults); }
/// <summary> /// 构造函数 /// </summary> /// <param name="BaseLineNet">应该移除超限的基线</param> /// <param name="IndependentLineSelectType">选择算法</param> public BaseLineWeighter(BaseLineNet BaseLineNet, IndependentLineSelectType IndependentLineSelectType) { this.BaseLineNet = BaseLineNet; this.IndependentLineSelectType = IndependentLineSelectType; //生成所有可能的三角形,然后提取网络,计算闭合差 CurrentQualityManager = BaseLineNet.BuildTriangularClosureNets(); if (CurrentQualityManager.Count == 0) { return; } }
/// <summary> /// 闭合路径质量 /// </summary> /// <param name="ClosureNet"></param> /// <param name="GnssReveiverNominalAccuracy"></param> public QualityOfTriAngleClosureError(BaseLineNet ClosureNet, GnssReveiverNominalAccuracy GnssReveiverNominalAccuracy) : base(ClosureNet.First, ClosureNet.ClosureError, GnssReveiverNominalAccuracy) { this.BaseLineNet = ClosureNet; this.GnssReveiverNominalAccuracy = GnssReveiverNominalAccuracy; this.ClosureError = BaseLineNet.ClosureError; //计算闭合差 if (BaseLineNet.ClosureError == null) { BaseLineNet.CalculateSetAndGetClosureError(); Init(ClosureNet.First, ClosureNet.ClosureError, GnssReveiverNominalAccuracy); } }
/// <summary> /// 获取所有可能的异步环网络 /// </summary> /// <param name="timePeriods">不超过3时段</param> /// <param name="triNetName"></param> /// <returns></returns> public List <BaseLineNet> GetAsyncTriguilarNet(TriangularNetName triNetName, List <TimePeriod> timePeriods) { List <BaseLineNet> result = new List <BaseLineNet>(); if (timePeriods.Count <= 1) { return(result); } if (timePeriods.Count == 2) { var lineA = triNetName.LineA; var lineB = triNetName.LineB; var lineC = triNetName.LineC; var period1 = timePeriods[0]; var period2 = timePeriods[1]; var period1Lines = this.BaseLineManager.Get(period1); var period2Lines = this.BaseLineManager.Get(period2); //6种组合 var p1LineA = period1Lines.GetOrReversed(lineA); var p2LineA = period2Lines.GetOrReversed(lineA); var p1LineB = period1Lines.GetOrReversed(lineB); var p2LineB = period2Lines.GetOrReversed(lineB); var p1LineC = period1Lines.GetOrReversed(lineC); var p2LineC = period2Lines.GetOrReversed(lineC); BaseLineNet net1 = new BaseLineNet(new List <SiteObsBaseline>() { p1LineA, p1LineB, p2LineC }); BaseLineNet net2 = new BaseLineNet(new List <SiteObsBaseline>() { p1LineA, p2LineB, p2LineC }); BaseLineNet net3 = new BaseLineNet(new List <SiteObsBaseline>() { p1LineA, p2LineB, p1LineC }); BaseLineNet net4 = new BaseLineNet(new List <SiteObsBaseline>() { p2LineA, p1LineB, p1LineC }); BaseLineNet net5 = new BaseLineNet(new List <SiteObsBaseline>() { p2LineA, p2LineB, p1LineC }); BaseLineNet net6 = new BaseLineNet(new List <SiteObsBaseline>() { p2LineA, p1LineB, p2LineC }); var all = new List <BaseLineNet> { net1, net2, net3, net4, net5, net6 }; foreach (var item in all) { if (item.Count < 3) { continue; } result.Add(item); } return(result); } else { //3个时段 var lineA = triNetName.LineA; var lineB = triNetName.LineB; var lineC = triNetName.LineC; var period1 = timePeriods[0]; var period2 = timePeriods[1]; var period3 = timePeriods[2]; var period1Lines = this.BaseLineManager.Get(period1); var period2Lines = this.BaseLineManager.Get(period2); var period3Lines = this.BaseLineManager.Get(period3); var p1LineA = period1Lines.GetOrReversed(lineA); var p2LineA = period2Lines.GetOrReversed(lineA); var p3LineA = period3Lines.GetOrReversed(lineA); var p1LineB = period1Lines.GetOrReversed(lineB); var p2LineB = period2Lines.GetOrReversed(lineB); var p3LineB = period3Lines.GetOrReversed(lineB); var p1LineC = period1Lines.GetOrReversed(lineC); var p2LineC = period2Lines.GetOrReversed(lineC); var p3LineC = period3Lines.GetOrReversed(lineC); //6种组合 BaseLineNet net1 = new BaseLineNet(new List <SiteObsBaseline>() { p1LineA, p2LineB, p3LineC }); BaseLineNet net2 = new BaseLineNet(new List <SiteObsBaseline>() { p1LineA, p3LineB, p2LineC }); BaseLineNet net3 = new BaseLineNet(new List <SiteObsBaseline>() { p2LineA, p1LineB, p3LineC }); BaseLineNet net4 = new BaseLineNet(new List <SiteObsBaseline>() { p2LineA, p3LineB, p1LineC }); BaseLineNet net5 = new BaseLineNet(new List <SiteObsBaseline>() { p3LineA, p2LineB, p1LineC }); BaseLineNet net6 = new BaseLineNet(new List <SiteObsBaseline>() { p3LineA, p1LineB, p2LineC }); var all = new List <BaseLineNet> { net1, net2, net3, net4, net5, net6 }; foreach (var item in all) { if (item.Count < 3) { continue; } result.Add(item); } return(result); } }