How to integrate data points?
37 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Mahmoud
el 13 de Mzo. de 2015
Comentada: NUR AINA NAJIHA ABD MANAN
el 22 de Jun. de 2020
Hello guys, I have a set of 1220 points for acceleration vs time and I want to plot velocity vs time and displacement vs time. As you all know I should integrate acceleration in order to get the velocity, I was thinking about using the Trapezoidal rule however it will give me the total velocity but what I want is the velocity vs time (like point by point). Any idea how I can do that using Matlab? I don't want a Matlab ready function to do that. Like while or for loop are fine.
Thanks in advance
2 comentarios
Abhishek Madan
el 10 de Jun. de 2020
Hi ,
Can u please share the script which u used to solve this?
Thanks
NUR AINA NAJIHA ABD MANAN
el 22 de Jun. de 2020
yes .. please help me also, to convert accelerometer data to displacement
Respuesta aceptada
Star Strider
el 13 de Mzo. de 2015
Use the cumtrapz function.
For example:
a = acceleration_vector_from_file;
t = time_vector_from_file;
v = cumtrapz(t, a); % Velocity
c = cumtrapz(t, v); % Displacement
0 comentarios
Más respuestas (0)
Ver también
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!