Search: Home | Atlas | Guides | Tests | Research | Techs | Skills | Index | Recent Changes | Preferences | Login

Guides > Gearbox Design

Other languages:

Overview

Gearboxes are used in a number of the more advanced buildings, normally to add a unique cost for each construction. Each gearbox takes an input shaft rotating and converts it via a gear train into up to 3 outputs. The process of designing a gearbox is to figure out which ratios are needed and to implement those ratios in the form of positioning various sizes of connected gears on a gearbox assembly table.

Quick links

Gearbox design

Gears

There are 5 gear sizes available, measured by their number of teeth (or relative number of teeth):
Gear Size inventory item cost in metal optimization cost
3 Small Gear 2 Brass 0
4 Small Gear 2 Brass 0
5 Medium Gear 20 Iron 1
6 Medium Gear 20 Iron 1
7 Large Gear 120 Iron 5

The total optimization cost provides a basis for comparing two different gearbox designs. Spacers and small gears are constrained primarily by the shaft and gear limits, rather than by material costs.

In Tale 3, because it's more of a pain than in previous tales, Brass is 3 times as expensive as Iron, so being careful with small gears is getting more important. In any case, it's easy to optimize for units of metal rather than medium/large gears. When considering costs, also recognize that raw metal is generally worth more than the related gears, so optimize using the costs of the metal and charcoal rather than the cost of the gears. What this really means is that 5/6 and 6/5 combinations will become more important, as the 2 span permits you to reduce the number of small transfer gears that would otherwise be required.

Constraints

Up to 15 shafts may be placed in the 8x8 grid on the gearbox assembly table. Each shaft may contain up to 3 gears or spacers, and a gearbox may have no more than 30 gears in total (including spacers). There must be at least one gear on the input shaft at 1A, and a connected set of gears leading to between 1 and 3 shafts on the output row (8A-8H, at the top). The output row 8 may contain a maximum of three occupied cells, presumably to be used as outputs - no extra transfer gear locations.

Meshing

If two shafts are near each other, a gear on one shaft may mesh with a gear on the nearby shaft. This depends upon the sizes of the gears involved, and how far apart the shafts are. To mesh, gears must also be on the same layer, i.e. both being the first gears on their respective shafts, both second, or both third. If the sum of sizes of gears between a pair of shafts is greater than needed to mesh, they are too close and you must remove one. This includes spacers, which count as greater than 1 (but less than 2) for meshing purposes. For example you can not put a spacer adjacent to a 5 or 6 gear, and you can not put a spacer either adjacent or diagonal to a 7 gear.

To minimize conflicts with adjacent shafts, generally put your small gears on the bottom layer with your medium and large gears on the second or third layer.

Standard Gearbox Notation

example: 5/3 or (5/3) or 53 - a size 5 gear that meshes with a size 3 gear.
example: (5/3) * (7/4) - a size 5 gear meshing with a size 3 gear. On the same shaft as the size 3 gear is a size 7 gear, which meshes with a size 4 gear.
example: (7/4) * (5/3) - the 7 still meshes with the 4, and the 5 with the three, but this time, the 4 and the 5 share a shaft. Note that this results in the same output as the previous example - as long as all the same gears mesh, you can move it around in the chain without affecting the output speed.

This notation gives a standardised way of representing the gearbox table. To get from the factored notation to the actual rotation rate, just multiply out the fractions. For example, the (5/3) * (7/4) combination above would give (5 * 7) / (3 * 4) = 35/12 = 2.91666666 (which, as a percentage, rounds to 292%)

When designing a gearbox it's often useful to use factored notation, (6/5 * 5/3) * 5/3 = 655/533 (meaning 6x5x5 divided by 5x3x3) rather than 333%, as it's much easier to visualize the common elements when using the factored notation.

Rotation Rate in Gear Trains

Each shaft has a rotation rate, based on the 1A input shaft being 100%. In a properly designed gearbox, you can trace any output back to the input via a single chain of meshed gears between shafts. The rotation of the output is driven by the rotation of the second-last shaft, and so on back to 1A.

If the meshed gears between a pair of shafts are the same size, then both shafts rotate at the same rate. If they are not the same size, the shaft with the larger gear rotates slower. For example, suppose shaft 1A has a 3-gear (with 3 teeth), meshing with a 5-gear on shaft 2B. Every 5 rotations of shaft 1A will pass 15 teeth through where the gears mesh. Those 15 teeth are only 3 rotations of a 5-gear, so shaft 2B will rotate 3 times for every 5 rotations of 1A. That is, a rotation rate of (3/5) or 60%.

The same principle can be used many times in a row by using the 3 different layers available. A 3-gear on 1A can mesh with a 5-gear on 2B on the bottom layer, meaning that 2B rotates at 60%. Then we can put a 3-gear on the second layer of 2B, meshing with a 5-gear on the second layer of 3C (with a 1-spacer on the bottom layer). So 3C rotates at (3/5) of 2B, which is in turn (3/5) of shaft 1A. The final rotation rate of 3C is thus (3/5)*(3/5) = 36%.

Putting it Together

The need for gears to mesh, together with how they determine rotation, means that any output can be expressed as a product of a limited set of fractions. The earlier example is (3/5)*(3/5), expressing that going from 1A to 2B we mesh a 3-gear with a 5-gear (in that order), and the same from 2B to 3C. To build a gearbox with outputs in a desired range, you just need to find a sequence of fractions that multiply to give the right numbers. Much of the work has been done already, with an online tool to help e.g. silver's gearbox page. Ingenia also compiled a list of common [gearbox ratios]? that may be useful.

3/3 and 4/4 just carry a given rotation rate from shaft to shaft, and are comparatively cheap since gears of size 3 and 4 are small gears. Many designed gearboxes contain chains of gears -3-3-3 or -4-4-4 carrying a given ratio to the required output shaft.

3/5 and 5/3 are the next cheapest, since size 5 is a medium gear.

5/6 and 6/5 come next in cost order, with both 5 and 6 being medium gears.

3/6 and 6/3 are shorthand, with an implicit 5-gear in the middle since 3-gears and 6-gears cannot mesh directly. Hence this ratio costs 2 mediums and a small.

4/7 and 7/4 are much more expensive: a 7-gear is a Large gear costing 120 iron and requiring the master casting box.

More expensive still are the shorthand ratios of 3/7, 7/3, 6/7 and 7/6, all of which have an implicit 5-gear in the middle to allow the others to mesh. Finally there is 6/4 which has an implicit 5 and 7 in the middle. Fortunately these ratios are almost never needed.

The relative cost of the various gear ratios ignores the small gears and assumes that a large gear costs 5 times as much as a medium gear. A combination like (3/5*5/6) that has a shared gear will be a bit cheaper. Note that every change in speed requires a medium or large gear.

For those with Unix machines or possibly cygwin on Windows, you can use Kem's gearbox table simulator for offline design. It's actually easier to see the gearbox design on this than on the in-game gearbox table. (If you have patches for the gearbox simulator, please feel free to contact Kem or Mjr.)

Tips for Multi-output Monstrosities

With advanced marble mechanics, Raelli Ovens, Empty Hand Towers, and Fountains, you'll often need a single gearbox having multiple outputs. In theory, you can design these the same way as single-output gearboxes: work out the chain of fractions you need, and turn them into chains of shafts. In practice, there are both extra hurdles and significant savings to be found.

Gear ratio requirements are always stated as a range A250-A300, B200-B275, D223-D270, for example. Look for overlapping ratios. Look hard! In this example a 250-270 ratio would satisfy all three requirements, and you can accomplish that using a 268 gear train.

268 = 5/3 * 5/3 * 5/3 * 5/6 * 5/6 * 5/6, so the design will require at least 9 medium gears and 3 small gears.

One feasible design (in gear train order) is 5A1, 65A3, 165C3, 516C5, 35D6, 135E7, 413D8, 4C7, 43B8, 13A8 which uses only 5 small gears and 5 spacers more than the gears that are required to get the required ratio.

Why would you put a shaft on E7? It's not useful at all, since C7 is already running at 268%, just put 4D8, you'll save 2 spacers, 2 small, and 1 medium gears. -TheMazeEcho

A better way to do A250-A300, B200-B275, D223-D270 is to do: A278 B231 D231
278 is 5/3 5/3, 231 is 5/3 5/3 5/6, notice that 278 and 231 both have 5/3 5/3 as part of them.
So you can do this with only 4 mediums. It is true you must look hard for ratios but a KEY thing to do
is to find ratios for the different outputs that share subsections.
Solution with 11 shafts, 10 small, 4 medium, and 5 spacers = 30 items
A1:1,5 B2:5,3 A3:3 A4:3 A5:3 A6:3 A7:3,1,5 A8:3 C7:1,4,6 B8:1,4 D8:1,4
-Teao

Or if you want to really be elegant, and you won't have much choice as the gearboxes get more complex, you can use 5/6/5 seqences as spanners to avoid long chains of small gears.
Here's a solution with 9 shafts, 6 mediums, 7 small, 4 spacers = 26 items (verified).
Also A278 B231 D231.
5A1 35B2 16B4 35B6 135A7 416C7 13A8 4B8 4D8 = 9/15 Shafts, 17/30 Gears. - MarvL

We can squeeze this one even harder. By offseting the vertical stack or size 3 Small Gears, we can eliminate 2 spacer. Spacers don't cost you anything, but the do count against the 30 gear limit.

11/15 Shafts, 4 Medium, 10 Small, 3 Spacers for 17/30. The outputs are A278, B231, D231.

5A1 3B2 3B3 3B4 3B5 35B6 135A7 416C7 13A8 4B8 4D8 (verified)


NameCreatorDateSizeDescription
Gearbox.jpgMarvLAugust 4, 2006 5:08 am35823A250-A300, B200-B275, D223-D270 Gearbox
GearboxA278.jpgMarvLAugust 12, 2006 7:46 am51743Fewer Spacers

Home | Atlas | Guides | Tests | Research | Techs | Skills | Index | Recent Changes | Preferences | Login
You must log in to edit pages. | View other revisions
Last edited November 22, 2008 10:29 pm by Kristjan (diff)
Search: