Skip to main content
GameDev.net gamedev.net
🔒 Locked

Integration in Physics

Started by GaryNas Sep 12, 2006 at 10:36 AM 3 replies 950+ views
Original Post
GaryNas
GaryNas
What does the term "numerical integration" mean in terms of a physics engine? I've seen this pop up many times, and even just now on some slides from Havok. I don't remember ever using this term in my university math classes, and we were taught that integration is how to find the area under a curve... ? Thanks!
Necator
Necator
Lets say you want to calculate P(t)=P(0)+ P'(t)*dt you would usually do a simple integration over t on some interval. But this assumes that the step dt is infinitly small. In a computer simulation dt has to be approximated by some small number (since the computer only got finite precision), which means that we can only approximate the end result.

The simplest form of numerical integration is Euler integration:
dt = Tn - Tn-1
P(Tn) = P(Tn-1) + P'(Tn-1)*dt

But this will end up with different result depending on how large dt is. Smaller steps will yield better results, but take longer time or demand higher precision.

There are an article here on Gamedev about numerical integration, which could help you. It discusses euler and other methods for integrating.
http://www.gamedev.net/reference/programming/features/verlet/

It's probably describes it better than this attempt =)
smitty1276
smitty1276
Treat the integral as a summation over a finite number of tiny intervals, rather than an infinite number of infintitely small intervals. You must discretize the otherwise continuous function.
Raghar
Raghar
Quote:
Original post by GaryNas
What does the term "numerical integration" mean in terms of a physics engine?


Estimation of a future position.

You know when you have speed of "a" and accleration of "b" and you'd need to know your future position.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.