A reciprocating engine, also often known as a piston engine, is typically a heat engine (although there are also pneumatic and hydraulic reciprocating engines) that uses one or more reciprocating pistons to convert pressure into a rotating motion. This article describes the common features of all types. The main types are: the internal combustion engine, used extensively in motor vehicles; the steam engine, the mainstay of the Industrial Revolution; and the niche application Stirling engine. Internal combustion engines are further classified in two ways: either a spark-ignition (SI) engine, where the spark plug initiates the combustion; or a compression-ignition (CI) engine, where the air within the cylinder is compressed, thus heating it, so that the heated air ignites fuel that is injected then or earlier.
There may be one or more pistons. Each piston is inside a cylinder, into which a gas is introduced, either already under pressure (e.g. steam engine), or heated inside the cylinder either by ignition of a fuel air mixture (internal combustion engine) or by contact with a hot heat exchanger in the cylinder (Stirling engine). The hot gases expand, pushing the piston to the bottom of the cylinder. This position is also known as the Bottom Dead Center (BDC), or where the piston forms the largest volume in the cylinder. The piston is returned to the cylinder top (Top Dead Centre) (TDC) by a flywheel, the power from other pistons connected to the same shaft or (in a double acting cylinder) by the same process acting on the other side of the piston. This is where the piston forms the smallest volume in the cylinder. In most types the expanded or "exhausted" gases are removed from the cylinder by this stroke. The exception is the Stirling engine, which repeatedly heats and cools the same sealed quantity of gas. The stroke is simply the distance between the TDC and the BDC, or the greatest distance that the piston can travel in one direction.