Finding curvature of a route, set by coordinates
1 次查看(过去 30 天)
显示 更早的评论
I have a spreadsheet containing data about a vehicle's location in terms of longitude and latitude. I have converted this into a cartesian plot using the latlon2local function, which turns out fine and is below:
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/615790/image.png)
The spreadsheet is attached.
My question is, how do I get some sort of plot of the radii of curvature of the turns around that route? I want to find how 'steep' the turns are, and preferably what angle the turn goes through. The spreadsheet also contains angular data (it's column 6), but I find it tedious to match every turn manually with the angle (as I have lots of datasets like this one).
Please let me know if you need any clarification.
The code to make the plot above is laid out below:
A = readmatrix("20181026075227_947BE7249B00.csv");
figure(2)
%column 3 is longitude, column 4 is latitude
%normalise coordinates wrt the first points
[xEast, yNorth] = latlon2local(A(:, 4), A(:, 3), 0, [A(1, 4), A(1, 3), 0]);
plot(xEast, yNorth)
xlabel('X (m)')
ylabel('Y (m)')
title('Route')
grid on;
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Axis Labels 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!