public void AddReferenceStar(StarSystem sys) { ReferenceSystem refSys = new ReferenceSystem(sys, EstimatedPosition); if (NrOfRefenreceSystems== 0 || refSys.Distance > 0.0) // Exlude own position { int aznr = (int)Math.Floor((refSys.Azimuth * 180 / Math.PI + 180) / (360.0 / sections)); int altnr = (int)Math.Floor((refSys.Altitude * 180 / Math.PI) / (360.0 / sections)); sectors[aznr % sections, altnr % (sections / 2)].AddReference(refSys); } }
public void AddReferenceStar(StarSystem sys) { ReferenceSystem refSys = new ReferenceSystem(sys, EstimatedPosition); if (NrOfRefenreceSystems == 0 || refSys.Distance > 0.0) // Exlude own position { int aznr = (int)Math.Floor((refSys.Azimuth * 180 / Math.PI + 180) / (360.0 / sections)); int altnr = (int)Math.Floor((refSys.Altitude * 180 / Math.PI) / (360.0 / sections)); sectors[aznr % sections, altnr % (sections / 2)].AddReference(refSys); } }
public void AddCandidate(ReferenceSystem refSys) { candidateReferences.Add(refSys); double weight = refSys.Weight; if (weight < minWeight) { minWeight = weight; optcandidateReferences.Add(refSys); } else if (optcandidateReferences.Count < 10) { optcandidateReferences.Add(refSys); } else if (optcandidateReferences.Count < 100 && refSys.Distance < 1000 && refSys.Distance > 100) { optcandidateReferences.Add(refSys); } }
public void AddReference(ReferenceSystem refSys) { usedReferences.Add(refSys); }
public void AddReference(ReferenceSystem refSys) { usedReferences.Add(refSys); }
public void AddCandidate(ReferenceSystem refSys) { candidateReferences.Add(refSys); double weight = refSys.Weight; if (weight < minWeight) { minWeight = weight; optcandidateReferences.Add(refSys); } else if (optcandidateReferences.Count < 10) optcandidateReferences.Add(refSys); else if (optcandidateReferences.Count < 100 && refSys.Distance < 1000 && refSys.Distance > 100) optcandidateReferences.Add(refSys); }