Changeset 3407 in ntrip
- Timestamp:
- Sep 2, 2011, 8:23:29 PM (14 years ago)
- Location:
- trunk/BNC
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/bncmodel.cpp
r3406 r3407 936 936 // Outlier Detection 937 937 //////////////////////////////////////////////////////////////////////////// 938 intbncModel::outlierDetection(int iPhase, const SymmetricMatrix& QQsav,939 const ColumnVector& vv, 940 QMap<QString, t_satData*>& satDataGPS, 941 QMap<QString, t_satData*>& satDataGlo, 942 QMap<QString, t_satData*>& satDataGal) { 938 QString bncModel::outlierDetection(int iPhase, const SymmetricMatrix& QQsav, 939 const ColumnVector& vv, 940 QMap<QString, t_satData*>& satDataGPS, 941 QMap<QString, t_satData*>& satDataGlo, 942 QMap<QString, t_satData*>& satDataGal) { 943 943 944 944 Tracer tracer("bncModel::outlierDetection"); … … 952 952 double maxRes; 953 953 954 int irc = 0;955 956 954 if (iPhase == 0) { 957 955 958 956 // Check GPS Code 959 957 // -------------- 960 if ( irc == 0) {958 if (prnRemoved.isEmpty()) { 961 959 findMaxRes(iPhase, vv,satDataGPS, prnCode, maxResCode, prnPhase, maxResPhase); 962 960 if (maxResCode > MAXRES_CODE_GPS) { … … 964 962 prnRemoved = prnCode; 965 963 maxRes = maxResCode; 966 irc = 1;967 964 } 968 965 } … … 970 967 // Check Galileo Code 971 968 // ------------------ 972 if ( irc == 0) {969 if (prnRemoved.isEmpty()) { 973 970 findMaxRes(iPhase, vv,satDataGal, prnCode, maxResCode, prnPhase, maxResPhase); 974 971 if (maxResCode > MAXRES_CODE_GAL) { … … 976 973 prnRemoved = prnCode; 977 974 maxRes = maxResCode; 978 irc = 1;979 975 } 980 976 } … … 985 981 // Check Glonass Phase 986 982 // ------------------- 987 if ( irc == 0) {983 if (prnRemoved.isEmpty()) { 988 984 findMaxRes(iPhase, vv,satDataGlo, prnCode, maxResCode, prnPhase, maxResPhase); 989 985 if (maxResPhase > MAXRES_PHASE_GLO) { … … 991 987 prnRemoved = prnPhase; 992 988 maxRes = maxResPhase; 993 irc = 1;994 989 } 995 990 } … … 997 992 // Check Galileo Phase 998 993 // ------------------- 999 if ( irc == 0) {994 if (prnRemoved.isEmpty()) { 1000 995 findMaxRes(iPhase, vv,satDataGal, prnCode, maxResCode, prnPhase, maxResPhase); 1001 996 if (maxResPhase > MAXRES_PHASE_GAL) { … … 1003 998 prnRemoved = prnPhase; 1004 999 maxRes = maxResPhase; 1005 irc = 1;1006 1000 } 1007 1001 } … … 1009 1003 // Check GPS Phase 1010 1004 // --------------- 1011 if ( irc == 0) {1005 if (prnRemoved.isEmpty()) { 1012 1006 findMaxRes(iPhase, vv,satDataGPS, prnCode, maxResCode, prnPhase, maxResPhase); 1013 1007 if (maxResPhase > MAXRES_PHASE_GPS) { … … 1015 1009 prnRemoved = prnPhase; 1016 1010 maxRes = maxResPhase; 1017 irc = 1;1018 1011 } 1019 1012 } 1020 1013 } 1021 1014 1022 if ( irc != 0) {1015 if (!prnRemoved.isEmpty()) { 1023 1016 _log += "Outlier " + prnRemoved.toAscii() + " " 1024 1017 + QByteArray::number(maxRes, 'f', 3) + "\n"; … … 1033 1026 } 1034 1027 1035 return irc;1028 return prnRemoved; 1036 1029 } 1037 1030 … … 1451 1444 } 1452 1445 1453 if (outlierDetection(iPhase, QQsav, vv, epoData->satDataGPS, 1454 epoData->satDataGlo, epoData->satDataGal) == 0) { 1446 QString prnRemoved = outlierDetection(iPhase, QQsav, vv, 1447 epoData->satDataGPS, 1448 epoData->satDataGlo, 1449 epoData->satDataGal); 1450 if (prnRemoved.isEmpty()) { 1455 1451 break; 1456 1452 } 1457 else { 1453 else if (prnRemoved[0] == 'G') { 1458 1454 ++numOutliers; 1459 1455 } -
trunk/BNC/bncmodel.h
r3405 r3407 109 109 void predict(int iPhase, t_epoData* epoData); 110 110 t_irc update_p(t_epoData* epoData); 111 intoutlierDetection(int iPhase, const SymmetricMatrix& QQsav,112 const ColumnVector& vv, 113 QMap<QString, t_satData*>& satDataGPS, 114 QMap<QString, t_satData*>& satDataGlo, 115 QMap<QString, t_satData*>& satDataGal); 111 QString outlierDetection(int iPhase, const SymmetricMatrix& QQsav, 112 const ColumnVector& vv, 113 QMap<QString, t_satData*>& satDataGPS, 114 QMap<QString, t_satData*>& satDataGlo, 115 QMap<QString, t_satData*>& satDataGal); 116 116 void writeNMEAstr(const QString& nmStr); 117 117
Note:
See TracChangeset
for help on using the changeset viewer.