Plotting a graph for time and distance where i have contant velocity
조회 수: 3 (최근 30일)
이전 댓글 표시
I am trying to plot a graph i have distance between two point that is coverd via two different path due to which i have different time to complete the path i want to show comparision of both with respect of time how shoulsd i write the code?
댓글 수: 0
답변 (1개)
jahanzaib ahmad
2019년 2월 18일
편집: jahanzaib ahmad
2019년 2월 18일
x=rand(3,2); % three points
d = pdist(x,'euclidean'); % distancecbetween those points
v=50; %veloicty
t=d/v; %time
plot(x(:,1),x(:,2),'.')
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Graph and Network Algorithms에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!