필터 지우기
필터 지우기

How to find the coordinates of starting, end point and peak from graph?

조회 수: 12 (최근 30일)
How to find the peak value, end point and distance between starting and end point?
x = linespace(-5,5); y = sqrt((36-x.^2)/9); figure() plot (x,y)

채택된 답변

Star Strider
Star Strider 2019년 8월 2일
Try this:
x = linspace(-5,5);
y = sqrt((36-x.^2)/9);
figure()
plot (x,y)
[onePeak,loc] = max(y) % Peak Value & Index
endPoint = y(end) % End Point Value
se_dist = max(x) - min(x) % Start To End Distance
producing:
onePeak =
1.9999
loc =
50
endPoint =
1.1055
se_dist =
10
  댓글 수: 11
parag gupta
parag gupta 2019년 8월 3일
Hey thank you so much @star :) thanksssssssss :)

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Interactive Control and Callbacks에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by