[ODE] Real world numbers for a Car Sim. [LONG]

Steve Baker sjbaker1 at airmail.net
Sat Oct 4 09:40:48 MST 2003


Hi!

   I'm new to this list, new to ODE - and also new to physical modelling
of motion.

Please forgive this long post - but I have a lot of questions that
have been piling up!

I have a car driving game that I'm trying to write.  I have all of the
graphics done and basic collision detection working (although not with
ODE yet) - and I'm now able to start putting some good physics into
the motion.

Since I'm not ready to plug in my own collision detection stuff, I
have ODE running the car on a flat, infinite plane.

I started with the 3 wheeled cart demo - turned it into a 4 wheel cart
and it drives around quite nicely with the parameters in the demo - but
now I want to start putting realistic data into the model.

What's giving me trouble is changing from a model with very unreal
numbers for sizes, masses and such - to a model with the exact
dimensions, weight, etc of the car I'm trying to model (A MINI
Cooper 'S').  I'm doing that because I plan to give the game away
to my buddies in the local MINI enthusuasts club - and we'll want
to do things like playing the game with different anti-sway-bar
stiffnesses to see how it changes the feel of the car.  (When you
change that parameter on a real car - it makes an AMAZING amount
of difference).

I know the weight (12,000 Newtons), the dimensions (1.7m x 1.4m x 3.6m)
and the approximate placement of the heavy parts of the car - so I
have (I think) a good estimate of the weight distribution for torque
and center of gravity.

Plugging those into the cart model results in things sinking into the
ground, wheels failing to stay attached, etc.

So I'm trying to work out the correct real-world spring stiffness and
damper coefficients.

By sitting on the hood of the car just over the front wheel - and measuring
the amount by which the car dips (1.5cm) - and knowing my weight (1,010 Newtons),
I'm estimating a spring stiffness of 67,000 Newton/meters!!  When I plug
that into the 4 wheel cart model, it simply vanishes (into orbit) on the
very first frame!

I'm guessing that my initial conditions are wrong - so I lower the car
gently onto the ground - but it's still misbehaving horribly.

What I presume I have wrong now is the damper coefficient.  I don't know
what numbers to use for that - I can't find any data online to tell me
what real world car dampers are like.  Playing with the kart model,
I seem to need the damper coefficient to be 2000 or so to make things
behave - but I have no idea whether that's physically realistic or
not.

The only way I can think to measure the damper coefficient would be to
stand on the car to squash the damper - then jump off suddenly and
measure the time the car takes to get level again....but that's
virtually impossible to do in practice.

Does anyone know (even approximately) what the damper coefficient of
a real car is?   The ones on the MINI are pretty stiff by the standards
of most american cars - but that's not much help when you need a number!

One thing that suprised me is that the ODE manual says to compute
ERP and CFM from the spring and damper parameters - and that pair of
equations includes the time between iterations of the model.  That's
a real pain because in an interactive driving game, the time constants
are variable.  That means I have to recompute ERP and CFM every time
around?  I was suprised that ODE wouldn't have me input more real-world
parameters such as the spring and damper coefficients - and compute
these peculiar ERP/CFM parameters internally....but what the hey - I
can do it.

Next, I plug in the known torque of the engine. Well - it's a curve
that depends on the RPM of the engine - but for now, I'll use the
maximum the car can produce (210 Newton meters)...but now the wheels
just spin...the car doesn't move noticably.  So I guess I need
more friction...but the model already has contact.surface.mu set
to dInfinity!   I play with the contact.surface.slip1 and slip2
numbers - but I don't know what these mean or how to measure them
in the real world.  The ODE manual doesn't even tell me what units
they are in...so it's hard to have any idea of what to set them
to.

Values of 0.001 seem to produce some forward motion - but how this
approach of typing in random numbers until it works is going to get
me to the real performance of the car is anyone's guess!   I need
to get a 0-60mph time of 6.7 seconds - but not knowing what numbers
to put in to get it.

I'm also having trouble getting the steering to stay pointing in the
right direction - so I've had to add 'power steering' - increasing
the torque of the steering 'motor' until the car will drive.  However,
the torque required is over 300 Newton meters - which suggests that
the power steering motor on the MINI has to produce more torque than
the engine!!   Surely that can't be right?

The problem is that by putting in numbers 'until it seems to work',
I have a physical model which isn't remotely as realistic as a much
simpler non-physical solution.

What I need are some 'real' numbers for these unknowns - and I don't
know how to get them.

Armed with my own MINI Cooper and a large car park, I can figure
out the amount of friction the tyres can produce using an accellerometer.
If I drive the car faster and faster in a tight circle, I can have a
friend watch the accellerometer and note the lateral accelleration
when the tyres just start to squeal (this is a lot of fun - and WILL
get you into trouble with the Mall security guys at 2:00am when the
car park is deserted!)...the answer is 0.95g - so I can work out the
real force that the tyres are able to withstand without slipping laterally.

I can also turn off the dynamic traction control on the car and
work out how fast I can accellerate in a straight line without
burning rubber and get the force at the road in the forward
direction.

I can (in principle) get these numbers for different surfaces
too...concrete, asphalt, gravel, grass.

But I don't see how to put those into the contact model to make this
work.

Help!

---------------------------- Steve Baker -------------------------
HomeEmail: <sjbaker1 at airmail.net>    WorkEmail: <sjbaker at link.com>
HomePage : http://www.sjbaker.org
Projects : http://plib.sf.net    http://tuxaqfh.sf.net
            http://tuxkart.sf.net http://prettypoly.sf.net
-----BEGIN GEEK CODE BLOCK-----
GCS d-- s:+ a+ C++++$ UL+++$ P--- L++++$ E--- W+++ N o+ K? w--- !O M-
V-- PS++ PE- Y-- PGP-- t+ 5 X R+++ tv b++ DI++ D G+ e++ h--(-) r+++ y++++
-----END GEEK CODE BLOCK-----



More information about the ODE mailing list