Advertisement

Engine RPM and wheel angular velocity

Started by March 24, 2016 05:16 PM
80 comments, last by adriansnetlis 8 years, 9 months ago

Yeah, OK! However, my biggest problem is where it actually gets affected by wheels. Currently the engine rotation for me is only being calculated locally. However, I want to find out how to make it assume wheel resistance forces, the clutch connection et cetera

I have got a question.

When your clutch is disengaged, you switch to gear 1 and have engine turning at around 4000 RPM. Does engine speed drop down once you engage clutch? And how would I calculate this stop? How would I realisticly split rotation between wheels(which were static) and engine(which was turning fast)?

Advertisement

Hi, I remember, this part was the most difficult for me to get it right.

The Marco Monster's tutorial is great for getting the idea.

In fact the engine-clutch-wheel rpm mayhem has 3 situations.

1. The clutch is engaged, the whole driveline turns as one assembly, as mentioned above

2. The clutch is disengaged, the engine is turning on its own and so does the rest of the driveline (or standing still in your case)

3. In between, when you start engaging the clutch this will move the engine and wheel's angular velocity to the "same" speed, this is why the engine rpm drops when the wheel starts turning.

This sounds easy, but first I'd suggest making a one-wheel car to see it in action (a simple 2d app where you see a single wheel turning, no fancy thing)

First don't bother with differentials, they just screw everyhing up :)

Also a very important thing is the inertia of each component, in all 3 of the above cases you'll need different inertias.

This is a great article for this: http://www.racer.nl/tech/effinertia.htm

For you the #3 case is interesting.

The clutch has a maximum torque that it can transmit to the gearbox, as you depress the pedal, it increases from 0 to this max value.

A simple example: your engine produces 200Nm torque, and the clutch is 90% down and it can handle,let's say 80Nm. In this case only 80Nm is going to the transmission that accelerates the wheels

You can imagine as the torques "circulate"

1. it starts from the engine

2. some of the engine torque goes to the transmission

3. the gearbox multiplies this by the gear ratio

4. through the diff it arrives to the wheel

5. the wheel start rolling, and from your tire formula you get the road resistance torque (the same that pushes the car forward)

6. this resistance torque goes back to the transmission trough the diff, and gets divided by the gear ratios

7. according to the clutch position some of it arrives to the engine and slows it down

...and repeat this in every simulation step.

I hope I gave you some idea.

Hi, I remember, this part was the most difficult for me to get it right.

The Marco Monster's tutorial is great for getting the idea.

In fact the engine-clutch-wheel rpm mayhem has 3 situations.

1. The clutch is engaged, the whole driveline turns as one assembly, as mentioned above

2. The clutch is disengaged, the engine is turning on its own and so does the rest of the driveline (or standing still in your case)

3. In between, when you start engaging the clutch this will move the engine and wheel's angular velocity to the "same" speed, this is why the engine rpm drops when the wheel starts turning.

This sounds easy, but first I'd suggest making a one-wheel car to see it in action (a simple 2d app where you see a single wheel turning, no fancy thing)

First don't bother with differentials, they just screw everyhing up :)

Also a very important thing is the inertia of each component, in all 3 of the above cases you'll need different inertias.

This is a great article for this: http://www.racer.nl/tech/effinertia.htm

For you the #3 case is interesting.

The clutch has a maximum torque that it can transmit to the gearbox, as you depress the pedal, it increases from 0 to this max value.

A simple example: your engine produces 200Nm torque, and the clutch is 90% down and it can handle,let's say 80Nm. In this case only 80Nm is going to the transmission that accelerates the wheels

You can imagine as the torques "circulate"

1. it starts from the engine

2. some of the engine torque goes to the transmission

3. the gearbox multiplies this by the gear ratio

4. through the diff it arrives to the wheel

5. the wheel start rolling, and from your tire formula you get the road resistance torque (the same that pushes the car forward)

6. this resistance torque goes back to the transmission trough the diff, and gets divided by the gear ratios

7. according to the clutch position some of it arrives to the engine and slows it down

...and repeat this in every simulation step.

I hope I gave you some idea.

Yes, you did. I'll try it:)

Hmm, what happens with angular velocities in 3rd case? Do you only adjust them by local torques and torques transferred by the clutch? I just don't see how they would sync before clutch gets 100% pressed. If they are not getting synced then at the moment of clutch being at 100% you might get sudden change in velocity on the engine or on the gearbox, depends what you choose as a "reference".
I thought about solving it as a friction problem. Generating torque that comes from the friction of the clutch, using relative angular velocity as a "scaling parameter" and exponentially raising spring force as a load on the plate.


Hi, I remember, this part was the most difficult for me to get it right.

The Marco Monster's tutorial is great for getting the idea.

In fact the engine-clutch-wheel rpm mayhem has 3 situations.

1. The clutch is engaged, the whole driveline turns as one assembly, as mentioned above
2. The clutch is disengaged, the engine is turning on its own and so does the rest of the driveline (or standing still in your case)
3. In between, when you start engaging the clutch this will move the engine and wheel's angular velocity to the "same" speed, this is why the engine rpm drops when the wheel starts turning.

This sounds easy, but first I'd suggest making a one-wheel car to see it in action (a simple 2d app where you see a single wheel turning, no fancy thing)
First don't bother with differentials, they just screw everyhing up :)

Also a very important thing is the inertia of each component, in all 3 of the above cases you'll need different inertias.
This is a great article for this: http://www.racer.nl/tech/effinertia.htm

For you the #3 case is interesting.
The clutch has a maximum torque that it can transmit to the gearbox, as you depress the pedal, it increases from 0 to this max value.

A simple example: your engine produces 200Nm torque, and the clutch is 90% down and it can handle,let's say 80Nm. In this case only 80Nm is going to the transmission that accelerates the wheels

You can imagine as the torques "circulate"
1. it starts from the engine
2. some of the engine torque goes to the transmission
3. the gearbox multiplies this by the gear ratio
4. through the diff it arrives to the wheel
5. the wheel start rolling, and from your tire formula you get the road resistance torque (the same that pushes the car forward)
6. this resistance torque goes back to the transmission trough the diff, and gets divided by the gear ratios
7. according to the clutch position some of it arrives to the engine and slows it down

...and repeat this in every simulation step.


I hope I gave you some idea.

Hmm, what happens with angular velocities in 3rd case? Do you only adjust them by local torques and torques transferred by the clutch? I just don't see how they would sync before clutch gets 100% pressed. If they are not getting synced then at the moment of clutch being at 100% you might get sudden change in velocity on the engine or on the gearbox, depends what you choose as a "reference".
I thought about solving it as a friction problem. Generating torque that comes from the friction of the clutch, using relative angular velocity as a "scaling parameter" and exponentially raising spring force as a load on the plate.

Actually they can sync when the clutch is not 100% locked. And in extreme cases it can slip when you don't even touch the pedal, but usually this doesn't happen :)

In the 3rd case when the clutch is not locked there are two possible cases. The torque is (1) limited to the amount that the clutch can transfer or (2) just apply the current clutch torque. For some mystical reason I did the second one. I just found the first one commented out in the code, don't ask why :D

for example:

the maximum clutch torque is 400Nm

the engine is producing 200Nm and the pedal is at 25%, so the current clutch torque is 100Nm in case of linear clutch.

In this case the actual torque that goes to the gearbox and accelerates the wheels is 100Nm

In an other example the pedal is not pressed and the clutch is at 100% the max torque is 400Nm

In this case I add all the 400Nm to the gearbox, even if the engine produces only 200Nm

First this seems odd, but this only happens for only one iteration and the clutch gets locked instantly and the angular velocities are fixed together.

Handling the clutch lock/unlock scenario is very important in this case. The slipage of the clutch is not related to the pedal position but the torque that goes through it.

So with little amount of throttle the clutch can handle all the torques from the engine even if the pedal is only half way down.

And as you start pressing the pedal so decreasing the clutch torque it only gets unlocked when the transferred torque exceeds it (in any direction).

Detecting lock is simple, just check if the angular velocity difference changes sign :)

simplier: when the wheel starts turning faster that the engine (after applying the torque) - or slower in case of engine braking.

The friction model also seems to be reasonable, but harder to find that "scaling parameter", and without proper damping the wheels will always over accelerate and will never sync just oscillate back and forth like a suspension without damper.

Also the clucth will never lock instantly and you'll probably have a nice lag.

I never tried this one so I'm not sure ;)

Advertisement

I start to understand some of the things, but it's still difficult for me to compile data from text. I'd be really thankful for some sort of chart or something that gives a nice overview of this topic. Huge thanks already for the help so far! ;)

I start to understand some of the things, but it's still difficult for me to compile data from text. I'd be really thankful for some sort of chart or something that gives a nice overview of this topic. Huge thanks already for the help so far! ;)


unfortunatelly some of these things are beyond math or physics. you have to learn how things work and figure out some logic that mimics the real thing. you can write accurate simulation, but many times it's just overkill and no visible difference anyway.

apart from some basic math there are no universal equations that fit all sims. this is why it's difficult, and this is why we like it :D

you may already found this site: http://www.racer.nl

lots of technical info and the source of an early version is still available.

you may also want to check out the rec.autos.simulators google group. around 2000-2003 search for [car physics]
you'll find posts from people who later made test drive unlimited, assetto corsa and such games :)

I start to understand some of the things, but it's still difficult for me to compile data from text. I'd be really thankful for some sort of chart or something that gives a nice overview of this topic. Huge thanks already for the help so far! ;)


unfortunatelly some of these things are beyond math or physics. you have to learn how things work and figure out some logic that mimics the real thing. you can write accurate simulation, but many times it's just overkill and no visible difference anyway.

apart from some basic math there are no universal equations that fit all sims. this is why it's difficult, and this is why we like it :D

you may already found this site: http://www.racer.nl

lots of technical info and the source of an early version is still available.

you may also want to check out the rec.autos.simulators google group. around 2000-2003 search for [car physics]
you'll find posts from people who later made test drive unlimited, assetto corsa and such games :)

Thank you for your reply and my apologies for late reply, was busy with coding.

Earlier yesterday I've wrote a sketch for dry friction clutch algorithm based on the "classic" model described in Simulink:

http://ch.mathworks.com/help/simulink/examples/building-a-clutch-lock-up-model.html?requestedDomain=www.mathworks.com

I've found it in couple of other places too but this one was the "cleanest" and publicly accessible.

Reformulated it a bit for a more generic case where we need to transfer torque two times over the clutch in different directions:

Tin - input torque

Tout - output torque

Fn - normal force between friction plates (controlled by clutch pedal)

muk and mus - kinetic and static coefficients of friction

Tmaxk = 2/3 * R * Fn * muk - maximum torque in kinetic friction
Tmaxs = 2/3 * R * Fn * mus - maximum torque in static friction

Iin and Iout moment of inertia on input and output side of the clutch (kg*m2)

bin and bout - damping rates on input and output side of the clutch (Nm/rad/sec)

win and wout - angular speed on input and output side of the clutch

r1 and r2 - inner and outer radii of the clutch plate friction surface

R - equivalent net radius (m)

R = ( r23 - r13 ) / ( r22 - r12 )

Clutch state [slipping]:

Tout = sign( win - wout) * Tmaxk

only the torque as a result of kinetic friction is transmitted

>> to "locked" state when:

NearlyEqual(win , wout) and |Tout| <= Tmaxs

Clutch state [locked]:
Tout = [ Iout*Tin - (Iout *bin - Iin*bout) * w ] / ( Iout + Iin)
where w=win=wout

>> to "slipping" state when:

Tout > Tmaxs

Example process:
Engine is connected to a clutch and clutch is connected directly to a wheel in the contact with the ground
1) Calculate engine RPM from angular speed of crankshaft
2) Using engine RPM and current throttle level calculate engine torque
3) Calculate delta angular speed from new engine torque and update crankshaft angular speed
4) Pass engine torque and new crankshaft speed as input to the clutch
5) Calculate clutch output torque
6) Using clutch output torque calculate delta angular speed and update wheel axle angular speed
7) Using new speed of wheel axle, process friction with the ground and get reaction torque
8) Calculate delta angular speed from reaction torque and update axle angular speed
9) Pass reaction torque and axle angular speed as input to the clutch
10) Calculate clutch output torque
11) Using clutch output torque calculate delta angular speed and update crankshaft angular speed

[return to step 1]

I've tried it yesterday and overall it works. Just need to carefully work on state changes so connected axles are not over accelerated and provide a lock mechanism for parts connected to the clutch - not only clutch itself. In first implementation clutch would lock as angular velocities match but still push to axle a single torque based on friction. Not a big deal but I prefer cleaner implementation. Just need to rewrite logic a bit.

It might look like an overkill but I'm building drive train simulation for T-26 tank. That thing has 3 clutches: main clutch on the engine and two steering clutches which work as sort of differential - meaning they deal with variable velocities of tracks. This is build for modular drive train system, still need to figure out a proper architecture and interface to be able to lock down and unlock parts of the drive train. So that locked parts have the same angular velocity and torque and aggregated moment of inertia, while taking into account possible gears in between, like in case of gear box or differential.

Thanks! This looks very promising. By the way - does different gear ratios change the inertia of the drivetrain? Also, where can I find example values for this? It'd be great if I knew where to get them for BMW M3 Coupe E92 as I currently use it for tests.

However, this seems like a very great explanation, I'll obiouvsly try out when I can:)

This topic is closed to new replies.

Advertisement