# Backlash (`backlash`)

> Free play between two shafts, such as in a gear mesh: no torque inside the gap, a stiff contact outside it.

![backlash](https://voltecx-web.nguyenvanqui291.workers.dev/docs/reference/img/backlash.svg)

[Component reference](https://voltecx-web.nguyenvanqui291.workers.dev/docs/reference/) · [繁體中文](https://voltecx-web.nguyenvanqui291.workers.dev/zh/docs/reference/mechanical/backlash/)

**Group:** Mechanical · **Kind:** `{"element":"backlash","kind":"mechanical"}`

## When to use it

Use it next to a Gear to see the impacts and the limit cycles that free play causes when the torque reverses. For a shaft without free play use Elastic Shaft.

## Pins

| Pin | Domain | Meaning |
|---|---|---|
| `a` | mechanical | Side a, usually the motor |
| `b` | mechanical | Side b, usually the load |

## Common parameters

- `gap`: Total free play between the two sides (Default: required)
- `k`: Stiffness while the two sides touch (Default: required)
- `d`: Damping while the two sides touch (Default: 0)

## Parameters

| Key | Unit | Default | Typical range | Description |
|---|---|---|---|---|
| `k` | N·m/rad | required |  | Stiffness while the two sides touch |
| `gap` | rad | required |  | Total free play between the two sides |
| `d` | N·m·s/rad | 0 |  | Damping while the two sides touch |
| `theta0` | rad | 0 |  | Twist at the start, from the middle of the free play |

_Parameter descriptions are in English in both languages._

## Model

The twist θ is the integral of ωa - ωb, starting at theta0 measured from the middle of the gap. While abs(θ) is below gap/2 no torque passes. Beyond it the flanks touch and the torque from a to b is k·(θ - gap/2) + d·(ωa - ωb) on the positive flank, and k·(θ + gap/2) + d·(ωa - ωb) on the negative one. The flank is the one of the last accepted step, so contact starts and ends up to one step late, and each flank keeps its own factorized matrix. With gap 0 it is the Elastic Shaft.

## Common mistakes

- The contact is found one step late, so a fast impact needs a small maximum step: keep it well below the contact time π·sqrt(J/k) of the lighter side.
- With contact damping d the torque can pull briefly while the flanks separate, which real teeth cannot do. Keep d small, or 0 for an elastic impact.
- gap is the total free play, both flanks together, in rad of the shaft it sits on. Put the backlash on the side whose angle the datasheet gives.

Problems rules: `pin.unconnected`, `compile.error`

## Datasheet and sources

gap is the angular backlash from the gearbox datasheet, usually in arcmin at the output: gap = arcmin·π/(180·60) rad on the output side. k is the torsional stiffness of the gearbox at that side, in N·m/rad (datasheets often give N·m/arcmin: multiply by 180·60/π).

## Example

Open the example with the command `file.openExample` and the name `demo:backlash`.

---
Generated by `cargo xtask reference` from the usage texts and parameter specs. Do not edit by hand.
