A muffler (North America) or silencer (outside North America) is a device for reducing the amount of noise emitted by a machine such as an internal combustion engine. The first was invented by Hiram Percy Maxim to silence firearms. When used on internal combustion engines, the engine exhaust blows out through the muffler.
Mufflers are typically installed along the exhaust pipe of the engine. They usually contain a series of baffles to absorb sound, although the majority of the noise reduction is not through absorption but through destructive interference in the muffler itself. The muffler accomplishes this with a resonating chamber, which is specifically designed such that opposite sound waves are likely to collide, canceling each other out.
Catalytic converters also often have a muffling effect.
While the goal is to absorb energy that would otherwise be released as sound into the environment, mufflers do force engines to work somewhat harder pushing exhaust gas through them. Therefore, it is a common engine tuning practice to replace stock mufflers with versions that require less energy to force the gas through (usually described as lowering the "back pressure"). Such accessory mufflers can often increase an engine's power, but usually at the cost of less effective noise suppression.