Arrow of a vector ( r, theta) from a point (x,y).
19 ビュー (過去 30 日間)
古いコメントを表示
Hello,
I need to show a arrow of a vector (r, theta) form a point (x,y). Is there any function to do that?
Thanks for help.
採用された回答
Star Strider
2021 年 9 月 9 日
x = rand
y = rand
r = rand
theta = 30; % Angle In Degrees
figure
quiver(x, y, r*cos(deg2rad(theta)), r*sin(deg2rad(theta)))
axis([0 2 0 2])
grid
Experiment to get different results.
.
2 件のコメント
その他の回答 (1 件)
the cyclist
2021 年 9 月 9 日
You can make an arrow on a plot using the annotation function, or you may want to use a quiver plot if you want the arrow to come from the data itself.
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Vector Fields についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!