Dear All,
I want to integrate the x, y. I use trapz(x,y). It gives me 1000. X-range id 0 to 4.45. But how to integrate with upper limit and lower limit i.e. 2 to 3. How to do it ? x is the first column and y is the 2nd column of the attached excel sheet.

댓글 수: 2

Torsten
Torsten 2019년 3월 12일
x ranges from 0.3 to 4.4. How do you want to integrate from 100 to 500 ? Or do you mean the row number ?
Manish Kumar
Manish Kumar 2019년 3월 12일
i have edited the question.

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

 채택된 답변

Torsten
Torsten 2019년 3월 12일

0 개 추천

idx = x>=2 && x<=3;
xp = x(idx);
yp = y(idx);
value = trapz(xp,yp)

댓글 수: 3

Manish Kumar
Manish Kumar 2019년 3월 12일
Error is coming. I am attching the scrrenshot
Torsten
Torsten 2019년 3월 12일
idx = (x>=2 & x<=3);
Manish Kumar
Manish Kumar 2019년 3월 12일
Thank you sir

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

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Programming에 대해 자세히 알아보기

질문:

2019년 3월 12일

댓글:

2019년 3월 12일

Community Treasure Hunt

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

Start Hunting!

Translated by