How do i simulate the physics of a motorbike riding over a round object small then the wheel.
For a computer game.

I want the motorbike to ride over the rock and make it look realistic (doesnt have to be exact) the rider can stay fixed for now and not move.

I will use or c# but i need the mathematics first


asked 09/16/2010 09:46

jagguy's gravatar image

jagguy ♦♦

6 Answers:
Here is a skateboard of length, L, ready to hit a small round object as it moves to the right.

<------- L ----->
O                   Oo

The board has a velocity, V, to the right.

Since the little o is small, let's not worry about the fact that some of the kinetic energy has been converted into potential energy, so let's keep the velocity magnitude constant. But the direction has changed.
O                   o

If h is the height of the small o, then the angle ß formed by the back wheel to the front can be found by:
   sin ß = h/L

Now that you have ß, you have the new direction of the motorcycle moving up in the air. Then its center of gravity follows a parabola just as throwing a ball follows a parabola due to gravity.

Here are some useful equations of motion:
phoffric's gravatar image


The angle (theta) that a line through the hubs of the two wheels of the motorcycle will make with the flat ground will be given by
tan (theta) = h/L       where h is the diameter of the rock and L is the distance between the wheel hubs.
(This is a slight approximation but will be realistic enough.)
aburr's gravatar image


Here is another set of links where you can even plug in numbers to solve for the equations. This way you will be able to check your results.
Here is where your angle ß comes into play:

I looked at a motorcycle game in your other question. Remember this. Even if the rider shifts his weight, that will change the inclination of the motorcycle; but the combined center of gravity of both the motorcycle and the rider will remain in a fixed parabola. (This assumes no wind resistance, and no jet packs.)
phoffric's gravatar image


re: sin ß = h/L

If, as you said, h is fairly small, then h/L is very small. In that case a reasonable approximation is that:
    ß = h/L
Note that  ß in this formula is in radians. To convert from radians to degrees (if you need this for debugging or are just more comfortable in degrees) here is the formula:
              degrees =  ß * 180/ PI                     where PI ~= 3.14159

Given ß, then the path the Center of Mass (CM) takes at impact with the little o is:
    V = (Vx, Vy) = (V cos ß, V sin ß)

So in your motorcycle trajectory, this V is actually your initial velocity, Vo, whose direction is at angle ß.
phoffric's gravatar image


ok thanks for the replies. I will post another question about jumps and look at what is posted here.
jagguy's gravatar image


Just make something that looks good.  If you are serious about wanting it to be realistic then you might as well integrate a physics engine and do it properly, modeling shock absorbers, the cushioning of the rider's legs, etc.
NovaDenizen's gravatar image


Your answer
[hide preview]

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments


Asked: 09/16/2010 09:46

Seen: 331 times

Last updated: 09/22/2010 12:36