# Velocity from acceleration

1. Oct 13, 2012

### likephysics

I am playing with accelerometer data. I am trying to plot the distance traveled.

From what I remember(highschool physics) -
V = u + a t
S= ut + 1/2 a t^2

Is U(initial velocity) always zero or is it the previous value of velocity?

2. Oct 13, 2012

### D_DaYwAlKeR

U is not always zero...

If the object starts from rest then U=0...
It depends on the time of observation ..
for example if u want to calculate the distance travellled by a body in time t=2 to t=4 having an acceleration of 3 m/s2 ...

Then u start observing the motion at time t= 2s ...then you take U as speed at time t=2 seconds which is obviously not zero ( it is v = 0 + 3 x 2 = 6m/s)...

3. Oct 13, 2012

### likephysics

When you give an example like above, I easily understand.
But when (starting from rest) you have acceleration data every millisecond, I get confused. Say, when calculating velocity at 10millisec, do you take the 9th millisec velocity as initial vel for the 10th millisec velocity?

4. Oct 13, 2012

### D_DaYwAlKeR

First of all..
we can use v = u + at only when acceleration is constant...

when u have acceleration data every second..and if it is changing then u cannot apply the equation s = ut + 1/2 at2 for a comparatively wide range of time interval like 1 second as the acceleration is changing every millisecond..

therefore, we have techniques like integration to overcome such problems in which acceleration is not constant and is changing every micro or even smaller nano seconds..

So, the answer to your question is that if the acceleration is constant between 9th millisecond and 10th millisecond...

then u can use v = u + at for that very short interval of time...and u = velocity at time 9 millisecond ....and v = vel. at time 10th millisecond .... a = given ...t = 10 - 9 = 1 millisecond...

Hope u understood..

5. Oct 14, 2012

### Naty1

think of an automobile as an example.....when you accelerate at some constant rate you increase speed from the initial value, even 0, to some higher value, right??

The change in speed for a constant acceleration for a fixed period of time is the same regardless of initial velocity [neglecting things like air friction]....
example, v =at so if you accelerate 2ft/sec/sec for 3 seconds that's an increase of 6 ft/sec....
makes no difference what the initial velocity was....whatever it was, you add 6ft/sec to it....

6. Oct 14, 2012

### rcgldr

Yes. You could use an "average" acceleration (trapezoidal rule) and velocity to do this calculation:

velocity[i+1] = velocity + 1/2 (acceleration + acceleration[i+1])
distance[i+1] = distance + 1/2 (velocity + velocity[i+1])

There are more advanced methods, but with a 1 millisecond sample period, trapezoidal rule should be reasonably close. The more advanced methods essentially do some form of curve fitting to estimate acceleration between sample periods by creating a function of acceleration versus time for each sample period.

Last edited: Oct 14, 2012
7. Oct 14, 2012

### HomogenousCow

If you can show me the raw numbers, I can find a function to fit the points, and then from there it's just kiddie integrals.