You are missing a ) after the / in the line you indicate. Count the brackets
(1+(velocity(1,i)^2).^(3/2)
1 2 3 2 1 2 1
You need one more ) character.
I suspect you could instead use
(1+velocity(1,i)^2).^(3/2)
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!