How to calculate the area of specific path under the curve?

1 visualización (últimos 30 días)
Salah Alfiky
Salah Alfiky el 22 de En. de 2022
Respondida: Louis Alexander el 22 de En. de 2022
Area wanted to calculate
this is the area i want to calculate
the code i used
>> i=[0:0.5:3.5];
>> l=18*sqrt(i);
>> plot (i,l)
>> grid on
>>

Respuestas (2)

KSSV
KSSV el 22 de En. de 2022
Read about trapz.
  2 comentarios
Louis Alexander
Louis Alexander el 22 de En. de 2022
like this:
i=[0:0.5:3.5];
l=18*sqrt(i);
plot (i,l)
grid on
Q = cumtrapz(l,i)
Q = trapz(l,i)

Iniciar sesión para comentar.


Louis Alexander
Louis Alexander el 22 de En. de 2022
if your curve can be expressed as a function, you can choose
integralintegral2 or integral3

Categorías

Más información sobre Numerical Integration and Differentiation en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by