フィルターのクリア

How to plot a quarter of a circle

16 ビュー (過去 30 日間)
Griffin Polglaze
Griffin Polglaze 2020 年 7 月 22 日
コメント済み: KSSV 2020 年 7 月 22 日
This question is most likely too vague to answer, but I am trying to plot the geometry of a quarter circle and am not too sure where to start. To plot the quarter circle, the radius is 5 and there is a text file that has an angle range between 90 to 0 degrees where each value is decreased by 1 degree, i.e. 90, 89, 88 ... 2, 1, 0. If anyone is able to help me figure out how I should approach this problem it would be greatly appreciated.

回答 (1 件)

KSSV
KSSV 2020 年 7 月 22 日
編集済み: KSSV 2020 年 7 月 22 日
% Radius of circle
R = 1. ;
% center of cricle
C = [0. 0.] ;
% angle
th = 90:-1:0 ;
% points of cricle
xc = C(1)+R*cosd(th) ;
yc = C(2)+R*sind(th) ;
plot(xc,yc)
  2 件のコメント
Griffin Polglaze
Griffin Polglaze 2020 年 7 月 22 日
Thanks, but I need to read the text file and use the values from that to generate the plot
KSSV
KSSV 2020 年 7 月 22 日
Simple....load the data from test file using load / importdata. Use that data instead of th.

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeAnnotations についてさらに検索

タグ

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by