필터 지우기
필터 지우기

Integral of experimental data

조회 수: 2 (최근 30일)
Antonio
Antonio 2015년 4월 2일
편집: Roger Stafford 2015년 4월 2일
Hi, I'm tryng to solve an integral like this:
I have two data columns about variables P and V, both defined as function of an angle teta (-360<teta<360). How can I integrate this curve?

답변 (1개)

Roger Stafford
Roger Stafford 2015년 4월 2일
편집: Roger Stafford 2015년 4월 2일
Using 'g' in place of 'gamma', do this:
Q = (g*trapz(V,P)+trapz(P,V))/(g-1);
or if you want the cumulative integral, replace each 'trapz' by 'cumtrapz'.
This assumes that P and V are vectors of the same length with corresponding elements given by the same value of 'theta'.

카테고리

Help CenterFile Exchange에서 Numerical Integration and Differentiation에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by