rec.autos.simulators

Car Physics: Anyone?

Grant Reev

Car Physics: Anyone?

by Grant Reev » Sun, 02 Dec 2001 07:36:09

<lurk off>

just felt an urge to throw some random extras into the mix :)


>   To put it more simply, the exhaust gases are pushing on one end of the
> turbo's shaft, the intake is pushing on the other.  Usually, the exhaust gases
> are trying to speed up the turbo, while the intake gases are trying to slow it
> down.  This isn't always the case, but usually it is.

Here's a common example of when the exhaust gases are not driving the
turbo,
and neither are the intake gases. When you accelerate at full throttle,
then
lift off the gas to change gears. Suddenly the exhaust gas speed falls
away,
but there's still a full load of compressed air in the intake. Combine
that
with the backpressure wave from the intake air hitting the closed
throttle
plate and you get *** intake backpressure waves crashing into the
compressor
wheel. This isn't very healthy to the long term life of a turbo, so
there
is usually some kind of pressure relief valve on the intake just after
the turbo designed to open up when there's a large pressure differential
between the intake and the manifold pressure to let this air out and
save
your turbo. The term I'm used to for naming this device is the blow-off
valve, (BOV), and this is the source of all the weird whistle/whoosh
noises
during shifts or when letting off the throttle from the tasteless boy
racer
turbo charged honda civic with neon lights you see downtown (or my very
tasteful (no neon lights) MR2 :) ).

that would be .2 bar on the gauge. Gauges read zero at atmospheric
pressure,
and positive for greater than atmospheric pressure amounts.
They usually use units of vacuum for pressures from atmospheric down to
zero. 0.2 bar is a pathetic amount of boost :)

Remember to make sure to model lots of turbo lag! If you're modelling a
turbo and you don't get pissed off at the bad throttle response compared
to a normally aspirated engine, you're probably missing something :)
The turbo does have it's own momentum, but the major source of turbo lag
is simply the amount of space it has to pressurise in the intake
plumbing.
For instance, if you stuck an intercooler in the front grill of a mid-
engined car, you'd have about 6 miles of intake piping from the back of
the car up to the front and back to pressurise, so it would take half an
hour to boost up! Of course this is an extreme example.

Intercoolers are great in this respect, especially on a nice cool chilly
day :) However as Randy mentioned earlier, they are also extremely
important
if you're trying to run anything like .4 bar or more to prevent your
engine
from blowing up a few pistons. As the piston is compressing the air in
the
cylinder, the cylinder pressure and temperature build. At a certain
combination of both factors, the fuel can (and will!) ignite by itself.
This of course is really bad if the piston is still going up and the
resulting explosion is trying to push the piston back down. You can
avoid it by either running less boost (which is the no-fun solution),
or using an intercooler to reduces the intake charge temperature. (Or
running a richer fuel mixture - the charge won't ignite so easily if
it's
overly rich) You can also push the self ignition point further away by
using higher octane fuel. Running 87 octane gas in my MR2 at 1 bar boost
would be a guaranteed blown motor. 93-94 octane is OK. Full on racing
gas
is vastly superior than pump gas in this respect, which is why you hear
of
CART (or 80's F1) running at 40psi (2.5 bar) or more. Or those cars
Rod Millen runs at Pike's Peak at 80psi.

This is also why most turbo cars use some form of boost pressure
regulation
to prevent the boost from going over a certain limit. This is done by
bypassing excess exhaust gas around the turbo's exhaust turbine once the
desire intake pressure is reached, via a wastegate.

<lurk on>

J. Todd Wass

Car Physics: Anyone?

by J. Todd Wass » Sun, 02 Dec 2001 07:59:34

  Grant,

  WONDERFUL post!  :0)  

  Ah, ok.  I thought so, but wasn't sure...  .2 bar IS a pathetic amount of
boost :0)

  Good point, hadn't thought of the space issue.  

  Ah ha!  I knew there had to be another reason besides increasing density :-)
Hadn't thought of the temperature change from the work to the gas during
compression.

Todd Wasson
---
Performance Simulations
Drag Racing and Top Speed Prediction
Software
http://PerformanceSimulations.Com

Matthew V. Jessic

Car Physics: Anyone?

by Matthew V. Jessic » Sun, 02 Dec 2001 13:51:16


> ok, here's a trickier one then :)

> I've been thinking about upgrading my integrator from Euler to midpoint or
> RK4. Although the formulas are quite simple I'm a bit confused as to the
> implementation. If I take as an example the integration of velocity to
> produce position, then the problem is to solve

> ds(t)/dt = v(t)

> which for euler is

> s(t+dt) = s(t) + dt*v(t).

> I've been reading about using midpoint integration, and if I understand
> correctly the formula for this is

> s(t+dt) = s(t) + dt * v(t+dt/2)

> My question is, how do I evaluate v at the half time step? I do not have an
> expression for v, just a discrete set of values, so presumably I have to do
> it numerically. But wouldn't this affect the accuracy of the integrator, and
> reduce it back to 1st order? Has anybody tried implementing integrators
> other than Euler yet?

An efficient second order integrator for real time systems
that use second order systems (like your velocity and
position set above) is a combination of a
second order Adams for velocity
and a second order Moulton Corrector for position.

Here, the _prev variables are the previous value dt ago
and a is acceleration

v = v_prev + (dt/2)(3 * a - a_prev)     ' 2nd order Adams
p = p_prev + (dt/2)(v + v_prev)         ' 2nd order Moulton Corrector

Generally you can't use a corrector like that in a true
real time system using measurements because you don't have
the future measurements yet. However, in this case you can
use the Adams integrator to generate the data required
by the second integrator.

This gives you second order integration with a
cost of only one derivative evaluation each.
Note that you now have to maintain the previous value of
the derivative of velocity (a_prev)

A Runge-Kutta 4th order integrator will require 4 derivative
calculations. If you push the integration step high enough
to flirt with instability, you may find that the second
order integrator above is actually more efficient than the
Runge-Kutta even though you may have to run it at a 3 times
smaller time step. (3 derivatives in the same duration
that the RK4 would need 4 derivatives.)
I'm not considering accuracy in this case, rather the
frequency response that most efficiently gives "decent"
results without immediate instability.

- Matt

Ref: "Math Toolkit for Real-Time Programming," Jack W. Crenshaw,
CMP Books, Lawrence, Kansas, 2000. ISBN 1-929629-09-5

Ruud van Ga

Car Physics: Anyone?

by Ruud van Ga » Tue, 04 Dec 2001 20:20:21


...

Thanks for the elaborate reply, Todd!
Also thanks to Jonny, Grant and Randy (nice to see Randy still pop up
here). I now finally understand a little about turbo.
Will have to deal with all these other deadlines here though before I
can actively implement stuff, but at least my right brain can work on
that subconsciously. ;-)

To be continued in the future somewhere...

Ruud van Gaal
Free car sim  : http://www.marketgraph.nl/gallery/racer/
Pencil art    : http://www.marketgraph.nl/gallery/

Ruud van Ga

Car Physics: Anyone?

by Ruud van Ga » Tue, 04 Dec 2001 20:22:42

On Sat, 01 Dec 2001 04:51:16 GMT, "Matthew V. Jessick"



>> I've been thinking about upgrading my integrator from Euler to midpoint or
>> RK4.
...
>> ds(t)/dt = v(t)

>> which for euler is

>> s(t+dt) = s(t) + dt*v(t).

Also take note that for F=m*a type integrations, you start out with
'a', which is the 2nd derivate. So you can expand to:

s(t+dt)=s(t)+dt*v(t)+0.5*dt^2*a(t)

Which is already more stable, and nearly free. :)
And ofcourse, precalculate t^2.

Matt's combined integrator seems very interesting too, I'd try that
too if I were you (and test with big time steps to see how it's
doing).

Ruud van Gaal
Free car sim  : http://www.marketgraph.nl/gallery/racer/
Pencil art    : http://www.marketgraph.nl/gallery/

Mike Stanle

Car Physics: Anyone?

by Mike Stanle » Tue, 04 Dec 2001 22:19:27

OK, thanks to you both. I'm currently adding in code to allow me extend the
integrator (ie storing velocities and accelerations from the previous n
timesteps) after which I'll be in a position to test lots of different
integrators. My main aim is to improve on the stability of the Euler
integrator (mainly for spring forces) so I may attempt an implicit
integrator as well.

I'll post when I've done a few tests, and let you all know my conclusions.

Cheers,

Mike.



> On Sat, 01 Dec 2001 04:51:16 GMT, "Matthew V. Jessick"


> >> I've been thinking about upgrading my integrator from Euler to midpoint
or
> >> RK4.
> ...
> >> ds(t)/dt = v(t)

> >> which for euler is

> >> s(t+dt) = s(t) + dt*v(t).

> Also take note that for F=m*a type integrations, you start out with
> 'a', which is the 2nd derivate. So you can expand to:

> s(t+dt)=s(t)+dt*v(t)+0.5*dt^2*a(t)

> Which is already more stable, and nearly free. :)
> And ofcourse, precalculate t^2.

> Matt's combined integrator seems very interesting too, I'd try that
> too if I were you (and test with big time steps to see how it's
> doing).

> Ruud van Gaal
> Free car sim  : http://www.marketgraph.nl/gallery/racer/
> Pencil art    : http://www.marketgraph.nl/gallery/


rec.autos.simulators is a usenet newsgroup formed in December, 1993. As this group was always unmoderated there may be some spam or off topic articles included. Some links do point back to racesimcentral.net as we could not validate the original address. Please report any pages that you believe warrant deletion from this archive (include the link in your email). RaceSimCentral.net is in no way responsible and does not endorse any of the content herein.