diff --git a/src/utils/matlab/vtl/kf_prototype.m b/src/utils/matlab/vtl/kf_prototype.m index 806c2139b..6367f121c 100644 --- a/src/utils/matlab/vtl/kf_prototype.m +++ b/src/utils/matlab/vtl/kf_prototype.m @@ -28,36 +28,7 @@ kf_yerr = zeros(2*sat_number, 1); % kf_xerr = zeros(8, 1); kf_S = zeros(2*sat_number, 2*sat_number); % kf_P_y innovation covariance matrix -%% State error Covariance Matrix Q (PVT) -kf_Q = [ 100 0 0 0 0 0 0 0 - 0 100 0 0 0 0 0 0 - 0 0 100 0 0 0 0 0 - 0 0 0 10 0 0 0 0 - 0 0 0 0 10 0 0 0 - 0 0 0 0 0 10 0 0 - 0 0 0 0 0 0 500 0 - 0 0 0 0 0 0 0 1500];%careful, values for V and T could not be adecuate. -%% - -% % Measurement error Covariance Matrix R assembling -% for chan=1:5 %neccesary quantities -% % It is diagonal 2*NSatellite x 2*NSatellite (NSat psudorange error;NSat pseudo range rate error) -% kf_R(chan, chan) = 40.0; %TODO: fill with real values. -% kf_R(chan+sat_number, chan+sat_number) = 10.0; -% end - -kf_R=[ 3 0 0 0 0 0 0 0 0 0 - 0 3 0 0 0 0 0 0 0 0 - 0 0 3 0 0 0 0 0 0 0 - 0 0 0 3 0 0 0 0 0 0 - 0 0 0 0 3 0 0 0 0 0 - 0 0 0 0 0 30 0 0 0 0 - 0 0 0 0 0 0 30 0 0 0 - 0 0 0 0 0 0 0 30 0 0 - 0 0 0 0 0 0 0 0 30 0 - 0 0 0 0 0 0 0 0 0 30]; - -% pre-allocate for speed +%% pre-allocate for speed d = zeros(sat_number, 1); rho_pri = zeros(sat_number, 1); rhoDot_pri = zeros(sat_number, 1); @@ -73,7 +44,21 @@ sat_dopp_hz_filt=zeros(sat_number,length(navSolution.RX_time)); %% ################## Kalman Tracking ###################################### % receiver solution from rtklib_solver for t=2:length(navSolution.RX_time) - + + %% State error Covariance Matrix Q (PVT) and R (MEASUREMENTS) + if (t