Integration of numerical data
6 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I have a set of numerical data stored in a vector D, and a second vector of positions z, of equal length.
If i wish to calculate the integral shown in the picture, how would this be done?

0 commentaires
Réponses (2)
Star Strider
le 27 Mai 2019
For vectors of data, the best option would be the trapz (link) or the related cumtrapz functions, depending on the result you want.
1 commentaire
Abdul Basith Ashraf
le 31 Août 2020
I have not so regular data (x and y are returned from ode45).
How can I visualize the rectangles under the curve to see how good trapz is doing?
Voir également
Catégories
En savoir plus sur Numerical Integration and Differentiation dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!