失眠网,内容丰富有趣,生活中的好帮手!
失眠网 > 【目标跟踪】基于扩展卡尔曼滤波器的多机器人定位算法研究附matlab代码

【目标跟踪】基于扩展卡尔曼滤波器的多机器人定位算法研究附matlab代码

时间:2021-02-03 22:14:54

相关推荐

【目标跟踪】基于扩展卡尔曼滤波器的多机器人定位算法研究附matlab代码

✅作者简介:热爱科研的Matlab仿真开发者,修心和技术同步精进,matlab项目合作可私信。

🍎个人主页:Matlab科研工作室

🍊个人信条:格物致知。

⛄ 内容介绍

卡尔曼滤波器在移动机器人的导航与控制领域应用十分广泛,目前也正在计算机的其他领域有着广泛的应用.为了更好地理解卡尔曼滤波器的基本原理并将卡尔曼滤波更好地利用在更多领域,结合卡尔曼滤波器在机器人定位中的应用阐述卡尔曼滤波的系统模型以及卡尔曼滤波器不断预测与更新的过程,通过MATLAB软件对该方法进行仿真试验,最后给出观测结果.

⛄ 部分代码

% estimates the relative distance and orientation between...

% moving robot, and stationary robot that acts as a landmark

function movingRobot = estimateRelativePose(movingRobot,stationaryRobot)

%######################### MEASURED DISTANCES AND ANGLES ##################

% calculate measured relative distance

dx=stationaryRobot.groundTruth(end,1)-movingRobot.groundTruth(end,1);

dy=stationaryRobot.groundTruth(end,2)-movingRobot.groundTruth(end,2);

% rng('shuffle');

rho=sqrt((dx)^2+(dy)^2)+movingRobot.sigma_rho*randn(1);

% calculate measured relative angle

% rng('shuffle');

phi=normalizeAngle(normalizeAngle(normalizeAngle(atan2(dy,dx))-...

movingRobot.groundTruth(end,3))+...

normalizeAngle(movingRobot.sigma_phi*randn(1)));

% combine measured rho and phi

movingRobot.Z=[rho;phi];

%######################### ESTIMATED DISTANCES AND ANGLES ##################

% calculate estimated relative distance

dx_bar=stationaryRobot.mu(end,1)-movingRobot.mu_bar(1);

dy_bar=stationaryRobot.mu(end,2)-movingRobot.mu_bar(2);

rho_bar=sqrt((dx_bar)^2+(dy_bar)^2);

% calculate estimated relative angle

phi_bar=normalizeAngle(normalizeAngle(normalizeAngle(atan2(dy_bar,dx_bar))-...

movingRobot.mu_bar(3)));

% combine measured rho_bar and phi_bar

movingRobot.Z_bar=[rho_bar;phi_bar];

movingRobot.Z_diff=evaluateRelativePoseDifference(movingRobot.Z,movingRobot.Z_bar);

⛄ 运行结果

⛄ 参考文献

[1]马世强. 一种基于卡尔曼滤波器的多目标跟踪算法研究[J]. 电子世界, (23):3.

⛄ 完整代码

❤️部分理论引用网络文献,若有侵权联系博主删除

❤️ 关注我领取海量matlab电子书和数学建模资料

如果觉得《【目标跟踪】基于扩展卡尔曼滤波器的多机器人定位算法研究附matlab代码》对你有帮助,请点赞、收藏,并留下你的观点哦!

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。