Summary of the invention
Goal of the invention: the problem and shortage existing for above-mentioned prior art, the object of this invention is to provide a kind of low operand GPS localization method based on second order spreading kalman, when reaching EKF2 performance, reduce operand, be applicable to low side hardware.
Technical scheme: for achieving the above object, the technical solution used in the present invention is a kind of low operand GPS localization method based on second order spreading kalman, comprises the steps:
(1) obtain local k-1 positioning result constantly, calculate current k prior estimation state amount and prior estimate error covariance constantly:
Wherein,
for the prior estimation state amount of k receiver user constantly,
for the posteriority estimated state amount of k-1 receiver user constantly,
for the prior estimate error covariance of k receiver user constantly,
for the posteriority evaluated error covariance of k-1 receiver user constantly,
A is transition matrix:
Wherein, Δ t is the time interval between twice location; Q
kfor k process noise error constantly,
Wherein, I
3 * 3be 3 rank unit matrixs, 0
3 * 3be complete zero square formations in 3 rank;
(2) setting up observed quantity estimates
equation:
Wherein,
ρ
i=||r
i s-ru||+δ
tu+ε
ρi
represent k measured value h constantly
kin p function exist
the second derivative at place, x
j, x
lbe respectively quantity of state X
kin any two elements, p ∈ [1,2n
k],
for the position coordinates vector of satellite,
for the speed coordinate vector of satellite, ε
ρ ifor the pseudo range measurement error of satellite,
be the measuring error of pseudorange rate of change, n is number of satellites, i ∈ [1, n], e
pfor 2n
kp column vector in dimension unit matrix, n
kfor k moment number of satellites, δ
tu, δ
fube respectively clock correction and clock correction rate of change;
(3) calculate kalman gain K
k:
Wherein,
x
kfor the time of day amount of k receiver user constantly,
Represent k measured value h constantly
k?
The first order derivative at place,
represent k measured value h constantly
kin q function exist
the second derivative at place, R
kmeasuring error covariance for pseudorange and Doppler:
v wherein
krepresent to measure noise matrix, E() represent to ask covariance;
(4) calculate current k positioning result and error covariance constantly:
Wherein,
for the posteriority evaluated error covariance of k receiver user constantly, diag () is the diagonal matrix of asking matrix,
for the posteriority estimated state amount of k receiver user constantly, I is unit matrix, Z
kactual value for observed quantity;
(5) repeating said steps (1), to step (4), obtains a series of anchor points.
It should be noted that, it will be appreciated by those skilled in the art that the step (2) in the present invention: " wherein, h=... ", the h here does not add subscript k, represents generalized case, adds that subscript k is illustrated in k value constantly, other correlation parameters are in like manner.
Beneficial effect: the present invention is the method that adopts the second-order EKF algorithm of low operand to position in GPS, feature that can the dynamic change along with the change of measured value according to kalman gain in second-order EKF algorithm, can realize real-time adjustment filtering parameter, reach filtering location optimization, improved the Static and dynamic effect of location.Meanwhile, after having reduced operand, the calculated amount of calculated amount of the present invention and single order expanded Kalman filtration algorithm is similar, can in some low side devices, move, for example, can move take in the process chip that the ARM7TDMI of 80MHz dominant frequency is core.The present invention, when reaching the locating effect identical with General Second Order expanded Kalman filtration algorithm, has reduced cost.
Embodiment
Below in conjunction with the drawings and specific embodiments, further illustrate the present invention, should understand these embodiment is only not used in and limits the scope of the invention for the present invention is described, after having read the present invention, those skilled in the art all fall within the application's claims limited range to the modification of the various equivalent form of values of the present invention.
The present invention is a kind of second order spreading kalman localization method of low operand, comprises the part such as simplification, Static positioning accuracy, Kinematic Positioning effect of various computings in the demonstration, algorithm of the obtaining of data, algorithm.Its final result is, data are obtained the data of satellite and pseudorange, the Doppler that local receiver provides from GPS base band, and the calculating by this algorithm can obtain positioning result.In the demonstration of algorithm and the simplification of algorithm computing, strictly proved theoretically feasibility and the preciseness of algorithm, meanwhile, utilize the character of data and the actual requirement of engineering in algorithm, computing has been carried out simplifying and processed, it can be moved on low side hardware.The anchor point of settling accounts out through above step, when static state, positioning precision can reach 0.5m, and the test that continues 6 hours in static multipath situation, can reach precision 10m; In the time of dynamically, in weak signal situation, can accurately locate, maximum deviation is no more than 4m, and in strong multipath situation, deviation is no more than 10m, and can guarantee the continuity of route.The present invention obtains pseudorange, doppler information, the pseudorange error covariance of satellite position, speed and local receiver.Meanwhile, from algorithm, read positioning result and the positioning error covariance in a upper moment, calculate the required intermediate parameters of algorithm and kalman gain.According to the parameter obtaining and gain, calculate current time positioning result and error covariance.Repeat said process, after 1s, then resolve next time.
The quantity of state adopting in the present invention is;
X=[x,y,z,Vx,Vy,Vz,δ
tu,δ
fu]
T
Wherein, ru=[x, y, z]
tuser's coordinate vector, Vu=[Vx, Vy, Vz]
tuser's velocity vector, δ
tu, δ
fube respectively clock correction and clock correction rate of change.
The observed quantity adopting is:
Z=h(X)
Wherein,
ρ
i=||r
i s-ru||+δ
tu+ε
ρi
with
the position of this satellite and speed coordinate vector, ε
ρ ifor its pseudo range measurement error,
it is the measuring error of pseudorange rate of change.N is number of satellites, i ∈ [1, n].
Concrete steps of the present invention are as follows:
1, obtain the positioning result that carve for the moment this ground, calculate priori estimates and the prior estimate covariance of current time
Wherein, X
k,
with
be respectively time of day amount, posteriority estimated state amount and the prior estimation state amount of k receiver user constantly,
for posteriority evaluated error covariance,
for prior estimate covariance;
A is transition matrix,
Δ t is the time interval between twice location, and this place is 1s;
Q
kfor k process noise error constantly,
I
3 * 3be 3 rank unit matrixs, 0
3 * 3be complete zero square formations in 3 rank.
2, setting up observed quantity estimates
equation
Wherein,
E
pfor 2n
kp column vector in dimension unit matrix, n
kfor k moment number of satellites.
3, calculate kalman gain,
Wherein,
Represent k measured value h constantly
k?
the first order derivative at place,
Represent k measured value h constantly
kin p function exist
the second derivative at place, x
j, x
lbe respectively quantity of state X
kin any two elements,
with
meaning identical, p, q ∈ [1,2n
k];
R
kfor pseudorange and Doppler's measuring error covariance,
V
krepresent to measure noise matrix, E () represents to ask covariance.
4, calculate positioning result and the error covariance of current time,
Wherein, diag () is for asking the diagonal matrix of matrix, Z
kactual value for the observed reading of system.
5, repeat said process, will obtain a series of anchor points.
In actual motion, due to actual value X
kcannot obtain, therefore, we adopt
replace
So have
As seen from the above equation, detX
kand m
1konly relevant with clock correction rate of change with the speed of laststate receiver.Meanwhile, detX
kand m
1kit is the correction to EKF2 algorithm.The speed of receiver and clock correction rate of change calculate by Doppler shift, and in degree of accuracy, speed is more accurate than position, and therefore, the present invention adopts Doppler shift to revise with level and smooth position on the basis of EKF2 location algorithm.
In calculated amount, we adopt following method to reduce calculated amount:
(1) in EKF2 algorithm,
q
k, R
ksymmetric positive definite diagonal matrix,
be symmetric positive definite matrix, meanwhile, having many is quadratic form, sparse matrix, minimizing calculated amount that can be a large amount of when calculating;
(2) when calculating K alman Gain, need to use matrix inversion, can prove that minute mother matrix on right side in gain accounting equation is symmetric positive definite matrix, therefore utilize this character that the calculated amount of matrix inversion is reduced;
In the computing that relates to matrix A, because A is sparse matrix, so do not adopt matrix multiplication to calculate, directly in program, write out the result of each, reduce calculated amount.Meanwhile, Q
k, R
kbefore circulation, by obtaining above, do not calculate in cycling time.
Referring to Fig. 1, be depicted as gps system illustraton of model, wherein comprise: StoreFront GPS receiver 101, receiver to the pseudorange 102 of satellite, the gps satellite 103 of x time, receiver satellite 104 constantly.Main process is that gps signal, through antenna transmission, through atmospheric envelope, exists scattering, the impacts such as refraction, arrival receiver antenna.The distance that receiver is measured, not only contains the line-of-sight distance of satellite and receiver, also adds and has contained the distance that various delays cause, and becomes " pseudorange ".
Pseudorange is the basis of satnav, according to the range formula between 2, space
therefore, accurately locate need at least 4 satellites pseudorange and co-ordinates of satellite.Like this, just can adopt spreading kalman equation to calculate the coordinate of receiver.
Fig. 2 has provided GPS receiver machine system structured flowchart.Comprise radio-frequency front-end processing module, baseband signal processing module and positioning navigation module.Radio-frequency front-end processing module is by all visible gps satellite signals of antenna reception, after prefilter and prime amplifier, carry out mixing and be downconverted into intermediate-freuqncy signal with the sinusoidal wave local oscillation signal of local oscillator generation again, finally by analog to digital conversion, intermediate-freuqncy signal is transformed into the digital medium-frequency signal of discrete time.Intermediate-freuqncy signal is through catching, follow the tracks of scheduling algorithm in baseband digital signal processing module, copy the local carrier consistent with the satellite-signal receiving and local pseudo-code signal, therefrom obtain the measured values such as GPS pseudorange and carrier phase and demodulate navigation message.In baseband digital signal processing module, handle after digital medium-frequency signal, each passage is exported respectively demodulation navigation message out on the measured values such as pseudorange, Doppler shift and carrier phase of its satellite-signal of following the tracks of and signal, and information such as ephemeris parameter in these satellite measurement and navigation message are again through the processing of follow-up location navigation calculation function module, receiver finally obtains GPS positioning result, or exports various navigation informations again.
Fig. 3 has provided the software flow pattern of second order spreading kalman algorithm.First obtain the positioning result that carve for the moment this ground, calculate priori estimates and the prior estimate covariance of current time
Then set up observed quantity equation
Next calculates kalman gain K
k
Finally calculate positioning result and the error covariance of current time,
Repeat again afterwards above operation and just realized continuous location.