Calculate the velocity for each time increment using displacement and time using a for loop?

10 views (last 30 days)
Mithushan Kanthasamy
Mithushan Kanthasamy on 20 Jan 2022
Answered: KSSV on 20 Jan 2022
displacement = [3.01, 3.02, 3.03, 3.04, 3.05,3.06]
time = [1, 1.01, 1.02, 1.03, 1.04,1.05]

Answers (1)

KSSV
KSSV on 20 Jan 2022
velocity = gradient(displacement)./gradient(time)

Community Treasure Hunt

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

Start Hunting!