Mobile robot tracking behavior in XY graph
1 view (last 30 days)
Show older comments
I'm trying to mimic the travel path of a robot in an XY graph on simulink and trying to enter a desired trajectory block in matlab using just XY dimensions but I'm unsure how to go about that.
I'm also trying to place obstacles on the XY graph using a simulink block with the desired obstacle location in the X and Y plane.
0 Comments
Answers (1)
Sam Chak
on 27 Aug 2022
Edited: Sam Chak
on 28 Aug 2022
Hi @T.R.O
You can try generating the Cubic Polynomial Trajectory. Check this example and see if it is good enough or suitable for your case.
Edit: To suggest using the sawtooth function to generate the triangular path for the mobile robot to track.
p = 40; % period of a triangle wave
T = 1.5*p; % 1.5 periods of a triangle wave
fs = 1000; % sample rate
t = 0:1/fs:T-1/fs;
sTr = sawtooth(2*pi/p*t, 0.5); % standard triangle wave
aTr = 10*(sTr + 1) + 2; % augmented triangle wave
plot(t, aTr)
grid on, ylim([0 25]), xlabel('x-axis'), ylabel('y-axis')
title('Desired trajectory for the Mobile Robot to follow')
3 Comments
See Also
Categories
Find more on Robotics in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

