資源簡介
EKF、UKF、CKF三種濾波算法的比較,matlab編寫
代碼片段和文件信息
%?EKF?UKF?CKF?的三個算法
clear;
x=1;%?初始狀態?
x_estimate?=?0.5;%初始狀態的估計
xpre=x_estimate?;
e_x_estimate?=?x_estimate;??%EKF的初始估計
u_x_estimate?=?x_estimate;??%UKF的初始估計
c_x_estimate?=?x_estimate;??%CKF的初始估計
Q?=?10?%?過程狀態協方差?
R?=?0.01?%?測量噪聲協方差?
P?=1000;%初始估計方差
n=1;?????%%%%%?系統的維數
m=2*n;???%%%%%?CKF容積點數
w=1/m;???%%%%%%?權值
kesi=[1-1];%%%%%?CKF容積點
e_P?=?P;?%EKF方差
u_P?=?P;%UKF方差
Ppost=P;%CKF方差
tf?=?100;?%?模擬長度?
x_array?=?[x];%真實值數組
e_x_estimate_array?=?[e_x_estimate];%EKF最優估計值數組
u_x_estimate_array?=?[u_x_estimate];%UKF最優估計值數組
c_x_estimate_array?=?[c_x_estimate];%CKF最優估計值數組
u_k?=?1;?%微調參數
u_symmetry_number?=?4;?%?對稱的點的個數
u_total_number?=?2?*?u_symmetry_number?+?1;?%總的采樣點的個數
linear?=?0.5;
close?all;
for?k?=?1?:?tf?
????%?模擬系統?
%?????x?=?linear?*?x?+?(25?*?x?/?
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件???????6661??2014-07-15?16:44??EKFUKFCKkk.m
-----------?---------??----------?-----??----
?????????????????6661????????????????????1
評論
共有 條評論