Expansion chamber
On a two-stroke engine, an expansion chamber or tuned pipe is a tuned exhaust system used to enhance its power output by improving its volumetric efficiency. History

Expansion chambers were invented and successfully manufactured by Limbach, a German engineer, in 1938, to economize fuel in two stroke engines. Germany was running short of petrol, which was at that stage produced using coal and sewage transformation. An unexpected bonus was that the two stroke engines using tuned exhausts produced far more power than if running with a normal silencer. After the end of the second world war, some time passed before the concept was re-developed by East German Walter Kaaden during the Cold War. They first appeared in the west on Japanese motorcycles after East German motorcycle racer Ernst Degner defected to the west while racing for MZ in the 1961 Swedish Grand Prix. He later passed his knowledge to Japan's Suzuki. How it works 
The high pressure gas exiting the cylinder initially flows in the form of a "wavefront" as all disturbances in fluids do. The exhaust gas pushes its way into the pipe which is already occupied by gas from previous cycles, pushing that gas ahead and causing a wave front. Once the gas flow stops, the wave continues, passing the energy to the next gas down stream and so on to the end of the pipe. If this wave encounters any change in cross section or temperature it will reflect a portion of its strength in the opposite direction to its travel. For example, a strong acoustic wave encountering an increase in area will reflect a weaker acoustic wave in the opposite direction. A strong acoustic wave encountering a decrease in area will reflect a strong acoustic wave in the opposite direction. The basic principle is described in wave dynamics. An expansion chamber makes use of this phenomenon by varying its diameter (cross section) and length to cause these reflections to arrive back at the cylinder at the desired time in the cycle. There are three main parts to the expansion cycle. Blowdown
When the descending piston first exposes the exhaust port on the cylinder wall, the exhaust flows out powerfully due to its pressure (without assistance from the expansion chamber) so the diameter/area over the length of the first portion of the pipe is constant or near constant with a divergence of 0 to 2 degrees which preserves wave energy. This section of the system is called the "header pipe" (the exhaust port length is considered part of the header pipe for measurement purposes). By keeping the header pipe diameter near constant, the energy in the wave is preserved because there is no expansion needed until later in the cycle. The flow leaving the cylinder during most of the blowdown process is sonic or supersonic, and therefore no wave could travel back into the cylinder against that flow. Transfer
Once the exhaust pressure has fallen to near-atmospheric level, the piston uncovers the transfer ports. At this point energy from the expansion chamber can be used to aid the flow of fresh mixture into the cylinder. To do this, the expansion chamber is increased in diameter so that the out-going acoustic wave (created by the combustion process) creates a reflected vacuum (negative pressure) wave that returns to the cylinder. This part of the chamber is called the divergent (or diffuser) section and it diverges at 7 to 9 degrees. It may be made up of more than one diverging cone depending on requirements. The vacuum wave arrives in the cylinder during the transfer cycle and helps suck in fresh mixture from the crankcase into the cylinder, and/or prevent the suction of exhaust gases into the crankcase (due to crankcase vacuum). However, the wave may also suck fresh mixture out the exhaust port into the header of the expansion chamber. This effect is mitigated by the port-blocking wave. Port blocking
When the transfer is complete, the piston is on the compression stroke but the exhaust port is still open, an unavoidable problem with the two stroke piston port design. To help prevent the piston pushing fresh mixture out the open exhaust port the strong acoustic wave (produced by the combustion) from the expansion chamber is timed to arrive during the beginning of the compression stroke. The port blocking wave is created by reducing the diameter of the chamber. This is called the convergent section (or baffle cone). The outgoing acoustic wave hits the narrowing convergent section and reflects back a strong series of acoustic pulses to the cylinder. They arrive in time to block the exhaust port, still open during the beginning of the compression stroke and push back into the cylinder any fresh mixture drawn out into the header of the expansion chamber. The convergent section is made to converge at 16 to 25 degrees, depending on requirements. Combined with the acoustic wave there is a general rise in pressure in the chamber caused by deliberately restricting the outlet with a small tube called the stinger, which acts as a bleeder, emptying the chamber during the compression/power stroke to have it ready for the next cycle. The stinger's length and inside diameter are based on 0.59 to 0.63x the header pipe diameter and its length is equal to 12 times its diameter, depending on the results to be achieved. In a well designed tuned exhaust system, the total increase in pressure is in any case much less than the one produced by a muffler. An erroneous sizing of the stinger will lead either to poor performance (too big or too short) or to excessive heat (too small or too long) which will damage the engine. Complicating factors
The detailed operation of expansion chambers in practice is not as straightforward as the fundamental process described above. Waves traveling back up the pipe encounter the divergent section in reverse and reflect a portion of their energy back out. Temperature variations in different parts of the pipe cause reflections and changes in the local speed of sound. Sometimes these secondary wave reflections can inhibit the desired goal of more power. It is useful to keep in mind that although the waves traverse the entire expansion chamber over each cycle, the actual gases leaving the cylinder during a particular cycle do not. The gas flows and stops intermittently and the wave continues on to the end of the pipe. The hot gases leaving the port form a "slug" which fills the header pipe and remains there for the duration of that cycle. This causes a high temperature zone in the head pipe which is always filled with the most recent and hottest gas. Because this area is hotter, the speed of sound and thus the speed of the waves that travel through it are increased. During the next cycle that slug of gas will be pushed down the pipe by the next slug to occupy the next zone and so on. The volume this "slug" occupies constantly varies according to throttle position and engine speed. It is only the wave energy itself that traverses the whole pipe during a single cycle. The actual gas leaving the pipe during a particular cycle was created two or three cycles earlier. This is why exhaust gas sampling on two stroke engines is done with a special valve right in the exhaust port. The gas exiting the stinger has had too much resident time and mixing with gas from other cycles causing errors in analysis. Expansion chambers almost always have turns and curves built into them to accommodate their fit within the engine bay. Gases and waves do not behave in the same way when encountering turns. Waves travel by reflecting and spherical radiation. Turns causes a loss in the sharpness of the wave forms and therefore must be kept to a minimum to avoid unpredictable losses. Calculations used to design expansion chambers take into account only the primary wave actions. This is usually fairly close but errors can occur due to these complicating factors. See also
 Kadenacy effect
 Tuned exhaust

References

Two-stroke engine technology
Exhaust systems