Hi all
I have two vectors of data. They are the same length. I want to multiply them and integrate over a distance. How can I do this in MATLAB?
I saw many people asking the same question and no answer. Does it mean it cannot be done in MATLAB?!

 Réponse acceptée

KSSV
KSSV le 29 Nov 2016

0 votes

doc trapz.

3 commentaires

omnia
omnia le 29 Nov 2016
let me explain my purpose in a better way. I have a matrix 'p' of 300*300 drawn over x and y. So I have 2D plot of p. I want to integrate this p over x and y and then plot the resultant 300*300 matrix.
Trapz gives only one value!
omnia
omnia le 29 Nov 2016
Never mind. You are right. I got my value now
KSSV
KSSV le 29 Nov 2016
cool....you got it..

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

Question posée :

le 29 Nov 2016

Commenté :

le 29 Nov 2016

Community Treasure Hunt

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

Start Hunting!

Translated by