Gearbox
automotive.gearbox
Lossless five-speed gearbox without inertia. The gear input picks the ratio: below 1.5 first gear, below 2.5 second, and so on up to fifth. Shaft a turns ratio times as fast as shaft b, and shaft b carries ratio times the torque. There is no neutral.
Ports
| Name | Domain | Direction |
|---|---|---|
gear | signal | in |
a | rotational | |
b | rotational |
Parameters
| Name | Unit | Default | Range | Description |
|---|---|---|---|---|
r1 | 1 | 3.5 | 0 to ∞ | First gear ratio |
r2 | 1 | 2.1 | 0 to ∞ | Second gear ratio |
r3 | 1 | 1.4 | 0 to ∞ | Third gear ratio |
r4 | 1 | 1 | 0 to ∞ | Fourth gear ratio |
r5 | 1 | 0.8 | 0 to ∞ | Fifth gear ratio |
Variables
| Name | Unit | Description |
|---|---|---|
ratio | 1 | Ratio of the selected gear |
Equations
ratio = if gear < 1.5 then r1 else if gear < 2.5 then r2 else if gear < 3.5 then r3 else if gear < 4.5 then r4 else r5 der(a.phi) = ratio * der(b.phi) b.tau = -ratio * a.tau