# Finding the average acceleration of particles

Hi

I have created a group particles.

For my simulation, i need to able to average the acceleration of all the particles for specific period of time. Can somebody please help me?

If that is not possible, at least it should be possible to display the acceleration of a particle in blender?! right?

HG1 that looks cool!

Awesome animation HG1!
Anyway I can get velocity in numbers?

I made an new script that calcualte the average velocity of all objects.

Edit:
Oh! Iâ€™ve oversight that you wanted the acceleration.

Edit2:
I have changed the file that it display the acceleration and calculate the average acceleration of all objects.

### Attachments

VelocityColors04.blend (165 KB)AccelerationColors01.blend (171 KB)

OMG, Looking at scriptâ€¦ Thats exactly what I wantedâ€¦ !!!

But I am a blender newbieâ€¦
I created a new particle system named â€˜particleâ€™ for the plane
I pressed â€˜Pâ€™ in the 3D view and I got:
swap: 0.017 (60â€¦ frames per second)
Physics: Blah, blah
Logic: Blah, blah
And a list of other things on the top right corner of the screen

I also saw the acceleration-color animation â€” VERY COOL!

Please help on how I can see those values calculated by the script. [ I have no skills in setting up sensors and actuatorsâ€¦ ]

THANKS HG1, I am confident that the script will do just what I need!!!

While in free fall the acceleration should be constantly at 1G, but the balls shift color at the top. Turns out it is because the script converts the speed vectors to a magnitude before calculating the delta speed and because of that lose all directional info.

A fixed version is attached. Also took out time from the calculation - BGE is step based and I think itâ€™s more accurate without time but Iâ€™m not sure. Only the coloring script is fixed - the average script is untouched but have probably the same error.

This is interestingâ€¦ This is a good way to calculate damage on impact.

AccelerationColors01.blend (315 KB)

OK, if it helps, I have attached my simulation

http://hotfile.com/dl/124653766/5ab5988/Frequency_Templates.zip.html

[Sorry, File manager was not working, so I had to use hotfile]

Scenario:
The particles fall from the emitter onto a vibrating surface.
The particles contain some amount of stickiness, so they vibrate along with the surface(See frame 250+)

I need to find the average acceleration of the particles during their oscillation [while being stuck to the surface]
I donâ€™t need an average during their free fall or intial reboundâ€¦