CN112511694B - Running track algorithm based on satellite positioning - Google Patents
Running track algorithm based on satellite positioning Download PDFInfo
- Publication number
- CN112511694B CN112511694B CN202011249348.6A CN202011249348A CN112511694B CN 112511694 B CN112511694 B CN 112511694B CN 202011249348 A CN202011249348 A CN 202011249348A CN 112511694 B CN112511694 B CN 112511694B
- Authority
- CN
- China
- Prior art keywords
- positioning
- point
- calculating
- points
- running track
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01S—RADIO DIRECTION-FINDING; RADIO NAVIGATION; DETERMINING DISTANCE OR VELOCITY BY USE OF RADIO WAVES; LOCATING OR PRESENCE-DETECTING BY USE OF THE REFLECTION OR RERADIATION OF RADIO WAVES; ANALOGOUS ARRANGEMENTS USING OTHER WAVES
- G01S19/00—Satellite radio beacon positioning systems; Determining position, velocity or attitude using signals transmitted by such systems
- G01S19/01—Satellite radio beacon positioning systems transmitting time-stamped messages, e.g. GPS [Global Positioning System], GLONASS [Global Orbiting Navigation Satellite System] or GALILEO
- G01S19/13—Receivers
- G01S19/14—Receivers specially adapted for specific applications
- G01S19/19—Sporting applications
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01S—RADIO DIRECTION-FINDING; RADIO NAVIGATION; DETERMINING DISTANCE OR VELOCITY BY USE OF RADIO WAVES; LOCATING OR PRESENCE-DETECTING BY USE OF THE REFLECTION OR RERADIATION OF RADIO WAVES; ANALOGOUS ARRANGEMENTS USING OTHER WAVES
- G01S19/00—Satellite radio beacon positioning systems; Determining position, velocity or attitude using signals transmitted by such systems
- G01S19/38—Determining a navigation solution using signals transmitted by a satellite radio beacon positioning system
- G01S19/39—Determining a navigation solution using signals transmitted by a satellite radio beacon positioning system the satellite radio beacon positioning system transmitting time-stamped messages, e.g. GPS [Global Positioning System], GLONASS [Global Orbiting Navigation Satellite System] or GALILEO
- G01S19/393—Trajectory determination or predictive tracking, e.g. Kalman filtering
Landscapes
- Engineering & Computer Science (AREA)
- Radar, Positioning & Navigation (AREA)
- Remote Sensing (AREA)
- Computer Networks & Wireless Communication (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Position Fixing By Use Of Radio Waves (AREA)
Abstract
A running track algorithm based on satellite positioning comprises the following steps: step A, acquiring a stable positioning point through a GPS; b, calculating whether the positioning is tentative or not; c, calculating whether the positioning is just finished in pause or not; step D, calculating whether the positioning point is just recovered or not; e, calculating and filtering running positioning points; step F, calculating a filtering positioning point to realize a smooth curve; g, calculating corresponding data such as matching speed, distance and the like; and H, drawing a map. The invention leads the first point to appear at a position close to the real position, improves the accuracy of the first point and reduces the length error of the running track; the occurrence of large-scale track distortion is avoided; if there is a period of time and not fix a position, carry out a smooth calculation once more to the stable point that has obtained, change the locating point position in certain extent to the running track that APP interface demonstration observes more smoothly beautifully from the naked eye, and respectively more is close to the true value on total mileage, provides powerful technical support for guaranteeing running APP effective application.
Description
Technical Field
The invention relates to the technical field of algorithms used in positioning technology of mobile phone APP application, in particular to a running track algorithm based on satellite positioning.
Background
With the popularization of smart phones, various applications APP of the mobile phones are increasing, and sports APP is one of the applications. In order to ensure the effective application of the motion APP, the motion trajectory measuring and calculating method is widely applied to the motion APP. The existing sport APP is limited by the adopted calculation method, and in practical application of the APP, the problem that the accuracy of a sport positioning point of a user is not good when the sport APP is monitored based on satellite positioning due to the influence of the problems of bad weather of the surrounding environment, buildings, mountains and other obstacles exists. The main manifestations include the following three types: 1. the first point positioning is not accurate enough, when a user opens the APP and the GPS of the APP works, if a high-rise building or cloudy weather exists around, the positioning of the GPS has larger deviation with the actual real positioning point; 2. during running, if the GPS signal is suddenly weakened, occasional large-amplitude track distortion occurs, which may cause a large deviation in running mileage. 3. The running track generated by the APP interface has a rectangular-tooth-shaped track, so that the track is not smooth enough, if a straight line is drawn between two points according to a point given by the GPS, a broken line segment appears on the motion track due to the existence of more than two points, and the whole track looks like a rectangular-tooth-shaped multi-point graph. Above three problems that exist, because can't obtain optimization processing based on current algorithm, the orbit distortion that the APP interface was drawn (was shown) is comparatively serious, and the mileage deviation is big, has caused the restriction to the effective application of motion APP.
Disclosure of Invention
In order to overcome the defects of the prior algorithm applied to the sport APP, which is limited by the technology, as described in the background, the invention provides the method for optimizing the algorithm by adopting a first point positioning method, and the accuracy of the first point is greatly improved by testing the first point by a three-point positioning method; the stable points are obtained in the running process by setting a filtering precision threshold value and a spacing distance threshold value, so that the stability and the reasonability of the relative position of each point and the two previous points are ensured; in the algorithm, if positioning does not exist for a period of time, the stable points are automatically obtained again through the three-point positioning method, the obtained stable points are subjected to one-time smooth calculation again, the positions of the positioning points are changed within a certain range, so that the running track displayed on the APP interface is observed more smoothly from the naked eye, the running track is closer to the true value on the display of the total mileage, and the running track algorithm based on satellite positioning, which is effectively applied to running APPs, is ensured.
The technical scheme adopted by the invention for solving the technical problems is as follows:
a running track algorithm based on satellite positioning is characterized in that the calculation comprises the following steps: step A, acquiring a stable positioning point through a GPS; b, calculating whether the positioning is tentative or not; c, calculating whether the positioning is just finished in pause or not; step D, calculating whether the positioning point is just recovered or not; e, calculating and filtering running positioning points; step F, calculating a filtering positioning point to realize a smooth curve; g, calculating corresponding data such as matching speed, distance and the like; step H, drawing a map; in the step B, the step C, the step D and the step E, the filtered GPS positioning points are obtained in four steps, after the positioning points are judged, if the end points are in accordance with each other, a smoothing algorithm is introduced immediately, in the step F, the filtered positioning points are calculated to realize a smooth running track curve, and if the end points are not in accordance with each other, the step B, the step C, the step D and the step E are carried out again until the end points are in accordance with each other; the step A, acquiring stable positioning points through a GPS, and comprising the following calculation process of firstly, transmitting positioning point data; step two, calculating and judging whether the positioning point data meets the precision threshold value; step three, calculating and judging whether the positioning point data conforms to the latest interval; step four, calculating the speeds of the two points; and step five, calculating and judging whether the speed is reasonable, deleting the first point if the speed is reasonable, keeping the point two and the point three, deleting the end point if the speed is not reasonable, and finally obtaining the required stable point.
Further, in the step F, the filtered positioning points are calculated to realize a smooth running track curve, a polynomial smoothing algorithm based on the least square principle is adopted for calculation, 5 points with equal wavelength intervals in a section of spectrum are recorded as an X set and used as polynomial smoothing, and the polynomial smoothing uses the fitting value of each window to replace the coordinate value in the original window, so that each positioning point of the smooth track is obtained.
Further, in the step F, the filtering locating points are calculated to realize a smooth running track curve, polynomial smoothing is to replace Xk by using polynomial fitting values of data with wavelength points of Xk-2, Xk-1, Xk +1 and Xk +2, wherein k represents the kth point on the track point, and then sequentially move until the spectrum is traversed.
Further, in the step a, in the stable positioning point obtained by the GPS, if the step one, two, three, four, and five are completed, whether the interface of the APP needs to be updated is returned.
The invention has the beneficial effects that: according to the method, a first point positioning method optimization algorithm is adopted, and through eight steps, a test first point is calculated through a three-point positioning method, so that the first point appears at a position close to the real position, the accuracy of the first point is greatly improved, and the length error of the running track displayed on an APP interface is reduced; the stable points are obtained in the running process by setting a filtering precision threshold value and a spacing distance threshold value, so that the stability and the reasonability of the relative position of each point and the two former points are ensured, and the occurrence of large-scale track distortion is avoided; in the algorithm, if the positioning is not carried out for a period of time, the stable points are automatically obtained again through the three-point positioning method, the obtained stable points are subjected to one-time smooth calculation again, and the positions of the positioning points are changed within a certain range, so that the running track displayed on the APP interface is smoother and more attractive when observed by naked eyes, the running track is closer to a true value on the total mileage, and powerful technical support is provided for ensuring the effective application of running APP. Based on the above, so this novel application prospect that has.
Drawings
FIG. 1 is a block diagram illustration of the overall flow of the algorithm of the present invention.
FIG. 2 is a block diagram of the process of obtaining stable positioning points via GPS according to the present invention.
FIG. 3 is a schematic diagram of running track obtained by the algorithm of the present invention displayed on an APP interface.
Detailed Description
As shown in fig. 1, 2 and 3, a running track algorithm based on satellite positioning comprises the following steps: step A, acquiring a stable positioning point through a GPS; the method comprises the following specific steps of step one, entering positioning points, wherein the specific entering is positioning point (also called endpoint data) data taken from an entrance of a GPS or a base station and the like. And step two, calculating and judging whether the positioning point data meets the precision threshold value according to different positioning point types (generally comprising a satellite, a base station, WIFI and the like). Step three, calculating and judging whether the positioning point data in the step two accords with the latest interval (the distance between the two points, the unit is calculated by m); the calculation is as shown in fig. 2, L > (0.2 × t +1) (unit of L is m, t represents interval time); step four, calculating the speed of two points (the latest two positioning points); and step five, calculating and judging whether the speed is reasonable (see speed matching reasonability rules in detail), namely, checking whether the speed meets the speed adaptation limit in calculation, if so, deleting the first point (the earliest point in the three points), keeping the second point and the third point (the points appearing for the second time and the third time in the three points), and if not, deleting the last point, and finally obtaining the required stable positioning point. And in the stable positioning points acquired by the GPS, if the steps I, II, III, IV and V are completed, returning whether the APP needs to update the interface or not.
Fig. 1, 2 and 3 show a running track algorithm based on satellite positioning, step B, calculating whether the positioning is tentative. And C, calculating whether the positioning is just finished in pause or not. And D, calculating whether the positioning point is just recovered. And E, calculating and filtering running positioning points.
As shown in fig. 1, 2, and 3, a running track algorithm based on satellite positioning, step F, calculates filter positioning points to implement a smooth curve. In the calculation, a polynomial smoothing algorithm based on the least square principle is adopted, 5 points with equal wavelength intervals in a section of the spectrum of the APP track interface are marked as an X set to be used as polynomial smoothing, polynomial smoothing is to replace the kth point on the spectrum track point of the APP interface represented by Xk and k by using a polynomial fitting value of data with the wavelength points of Xk-2, Xk-1, Xk +1 and Xk +2, and then the k point is moved in sequence until the spectrum is traversed. In the calculation, assuming that the width of a filtering window (also called a filter or a convolution kernel) is n ═ 2m +1, and each measurement point x ═ m +0, -m +1, -m +2 …, m-1, m), data points in the window are fitted by a k-1 th order polynomial, and the above n equations constitute a k element linear equation set. To have a solution to the system of equations, n should be equal to or greater than k, n > k is typically chosen, and then the parameter A is determined by a least squares fit. Based on the algorithm, the fitting value of each window is finally used for replacing the coordinate value in the original window, and therefore each positioning point of the smooth track is obtained. The positioning point data enter step G, corresponding data such as pace and distance are calculated, finally, a track curve is formed through step H, a map is drawn on an APP interface, and a running motion track after smooth processing is shown in the map of the APP interface (as shown in fig. 3, the motion track is realized in the APP).
As shown in fig. 1, 2 and 3, the invention adopts an optimization algorithm of a first point positioning method, calculates a test first point by a three-point positioning method through eight steps, and enables the first point to appear at a position close to a real position, thereby greatly improving the accuracy of the first point and reducing the error of the track length; the stable points are obtained in the running process by setting a filtering precision threshold value and a spacing distance threshold value, so that the stability and the reasonability of the relative position of each point and the two former points are ensured, and the occurrence of large-scale track distortion is avoided; in the algorithm, if positioning does not exist for a period of time, the stable points are automatically obtained again through the three-point positioning method, the obtained stable points are subjected to one-time smooth calculation again, the positions of the positioning points are changed within a certain range, so that the track is more smooth and attractive when observed by naked eyes, the total mileage is closer to a true value, and powerful technical support is provided for ensuring the effective application of running APP.
In the running track algorithm based on satellite positioning according to the present invention, as shown in fig. 1, 2 and 3, the track verification logic uses the following data (function: the main point in the logic is to filter unreasonable points). : 1. running and walking reasonable speed range (10.5m/s speed of hundreds of meters in the world at present). 2. The method comprises the following steps of riding within a reasonable speed range (the average speed per hour of a looping bike race is 40 kilometers per hour; the speed per hour when the cycling bike race goes downhill exceeds 100 kilometers per hour, and can reach 70 kilometers per hour when the cycling race is timed), 3, determining a precision threshold (the size of the precision threshold is set, namely the radius value given by a GPS is set to be 20 if only a GPS positioning point needs to be reserved, and is set to be 100 if GPS and Wi-Fi positioning points need to be reserved, and base station positioning points are removed), 4, setting a speed difference threshold (between three points, namely the speed difference between the point 1 and the point 2, and the speed difference between the point 2 and the point 3 is less than 5m/s)5, and spacing point distance (0.2 m).
In the running track algorithm based on satellite positioning according to the present invention, as shown in fig. 1, 2 and 3, the average pace rationality rule data is as follows (effect: excluding the track of illogical exercise speeds). 1. According to the single-kilometer speed distribution, under any condition, the speed distribution of 1 kilometer is less than 2.0min/km, which is invalid data. 2. And according to the average speed distribution, the total distance is 3-5 kilometers, and the average speed distribution is less than 2min and 20SEC/km is invalid data. 3. And according to the average speed distribution, the total distance is 5-10 kilometers, and the average speed distribution is less than 2min and 30SEC/km is invalid data. 4. And according to the average speed distribution, the total distance is 10-21 kilometers, and the average speed distribution is less than 2min and 40SEC/km is invalid data. 5. According to the number of steps of a single kilometer, in any case, the number of steps of 1 kilometer is less than 500 steps, and the data are invalid
While there have been shown and described what are at present considered the fundamental principles and essential features of the invention and its advantages, it will be apparent to those skilled in the art that the invention is not limited to the details of the foregoing illustrative embodiments, but is capable of other specific forms without departing from the spirit or essential characteristics thereof. The present embodiments are therefore to be considered in all respects as illustrative and not restrictive, the scope of the invention being indicated by the appended claims rather than by the foregoing description, and all changes which come within the meaning and range of equivalency of the claims are therefore intended to be embraced therein.
Furthermore, it should be understood that although the present description refers to embodiments, the embodiments do not include only one independent technical solution, and such description is only for clarity, and those skilled in the art should take the description as a whole, and the technical solutions in the embodiments may be appropriately combined to form other embodiments that can be understood by those skilled in the art.
Claims (2)
1. A running track algorithm based on satellite positioning is characterized in that the calculation comprises the following steps: step A, acquiring a stable positioning point through a GPS; b, calculating whether the positioning is suspended, if so, judging the precision threshold and the minimum distance, and if not, entering the step C; step C, calculating whether the positioning is just finished in pause or not, if so, acquiring a first stable point after pause, and if not, entering the step D; d, calculating whether the positioning point is just recovered, if so, acquiring a first stable point after pause, and otherwise, entering the step E; e, calculating and filtering running positioning points; step F, calculating a filtering positioning point to realize a smooth curve; g, calculating corresponding data such as matching speed, distance and the like; step H, drawing a map; in the step B, the step C, the step D and the step E, the filtered GPS positioning points are obtained in four steps, after the positioning points are judged, if the end points are in accordance with each other, a smoothing algorithm is introduced immediately, in the step F, the filtered positioning points are calculated to realize a smooth running track curve, and if the end points are not in accordance with each other, the step B, the step C, the step D and the step E are carried out again until the end points are in accordance with each other; the step A, acquiring stable positioning points through a GPS, and comprising the following calculation process of firstly, transmitting positioning point data; step two, calculating and judging whether the positioning point data meets the precision threshold value, if so, entering step three, and if not, entering to return whether the positioning point data needs to be updated; step three, calculating and judging whether the positioning point data conforms to the minimum interval, if so, adding the point into the cache data, and judging whether the number of the introduced points is equal to three, if so, entering the step four, and if not, entering the step four, and returning if not, returning to the step three and needing updating; step four, calculating the speed between the two points; and step five, calculating and judging whether the speed is reasonable, deleting the first point if the speed is reasonable, returning whether the updating is needed, removing the last point if the speed is not reasonable, finally obtaining a needed stable point, and returning whether the updating is needed.
2. The running track algorithm based on satellite positioning as claimed in claim 1, wherein in the step F of calculating the filtering positioning points to realize a smooth running track curve, a polynomial smoothing algorithm based on the least square principle is adopted for calculation, 5 points with equal wavelength intervals in a section of the spectrum are recorded as an X set to be used as a polynomial smoothing, the polynomial smoothing is to replace Xk by using a polynomial fitting value of data with the wavelength points of Xk-2, Xk-1, Xk +1 and Xk +2, wherein k represents the kth point on the trajectory point, and then the polynomial smoothing is sequentially moved until the spectrum is traversed.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011249348.6A CN112511694B (en) | 2020-11-10 | 2020-11-10 | Running track algorithm based on satellite positioning |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011249348.6A CN112511694B (en) | 2020-11-10 | 2020-11-10 | Running track algorithm based on satellite positioning |
Publications (2)
Publication Number | Publication Date |
---|---|
CN112511694A CN112511694A (en) | 2021-03-16 |
CN112511694B true CN112511694B (en) | 2022-01-18 |
Family
ID=74957640
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011249348.6A Active CN112511694B (en) | 2020-11-10 | 2020-11-10 | Running track algorithm based on satellite positioning |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112511694B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114333233B (en) * | 2021-12-31 | 2022-11-15 | 湖南高速建设工程有限公司 | Highway constructor safety positioning management system and method |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107861132A (en) * | 2017-10-27 | 2018-03-30 | 上海斐讯数据通信技术有限公司 | A kind of GPS track optimization method and device |
CN109151708A (en) * | 2018-08-03 | 2019-01-04 | 重庆金康特智能穿戴技术研究院有限公司 | A kind of filter algorithm of the coordinate point group based on hybrid positioning method |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101907467B (en) * | 2010-08-06 | 2012-08-22 | 浙江大学 | Method and device for personal location based on motion measurement information |
JP6409297B2 (en) * | 2014-03-20 | 2018-10-24 | カシオ計算機株式会社 | Positioning device, positioning method and program |
CN105184382B (en) * | 2015-07-14 | 2018-12-28 | 成都乐动信息技术有限公司 | The optimization method and device of motion profile |
CN109031379A (en) * | 2018-08-31 | 2018-12-18 | 上海奥孛睿斯科技有限公司 | A kind of generation method and system of navigation routine map |
-
2020
- 2020-11-10 CN CN202011249348.6A patent/CN112511694B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107861132A (en) * | 2017-10-27 | 2018-03-30 | 上海斐讯数据通信技术有限公司 | A kind of GPS track optimization method and device |
CN109151708A (en) * | 2018-08-03 | 2019-01-04 | 重庆金康特智能穿戴技术研究院有限公司 | A kind of filter algorithm of the coordinate point group based on hybrid positioning method |
Also Published As
Publication number | Publication date |
---|---|
CN112511694A (en) | 2021-03-16 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107255795B (en) | Indoor mobile robot positioning method and device based on EKF/EFIR hybrid filtering | |
CN105021187B (en) | Low-power consumption outdoor positioning method | |
CN110160541A (en) | Reconstructing method and device, storage medium, the electronic device of motion profile | |
CN112511694B (en) | Running track algorithm based on satellite positioning | |
CN107466103A (en) | A kind of method of locating terminal and the network equipment | |
CN107728178B (en) | Method and device for processing motion trail | |
CN109629379B (en) | Pavement detection method based on mobile phone sensor data | |
CN115586557B (en) | Vehicle driving track deviation correcting method and device based on road network data | |
CN112179276A (en) | Overhead line sag measuring method and device | |
CN112229406A (en) | Redundancy guide full-automatic landing information fusion method and system | |
CN117251520B (en) | Method and device for identifying biodiversity key region and electronic equipment | |
CN114705180B (en) | Data correction method, device and equipment for high-precision map and storage medium | |
US10743090B2 (en) | Filtering noise values from telemetry data | |
CN104316075B (en) | The electronic device and distance measurement method calculated with distance | |
CN104981011B (en) | The acquisition of Wi-Fi hotspot data and update method based on Sequential processing | |
CN112487309B (en) | Uncertainty medical reachability calculation method based on track data | |
CN106501878A (en) | Estimate deviation method ensemble typhoon forecast method | |
CN112595330A (en) | Vehicle positioning method and device, electronic equipment and computer readable medium | |
CN106354960A (en) | Power line model obtaining method and device based on aerial images | |
CN115297435B (en) | RSSI self-adaptive ranging model matching method | |
CN112633592A (en) | Vehicle frequent-running route calculation method and system based on machine learning clustering algorithm | |
US20150087333A1 (en) | Method for correcting position information | |
CN112201041A (en) | Trunk road path flow estimation method integrating electric alarm data and sampling trajectory data | |
CN114485626B (en) | Automatic updating method for regional geomagnetic reference diagram | |
CN111047863A (en) | Road condition determining method, device, equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |