  We study Casimir forces on the partition in a closed box (piston) with
perfect metallic boundary conditions. Related closed geometries have generated
interest as candidates for a repulsive force. By using an optical path
expansion we solve exactly the case of a piston with a rectangular cross
section, and find that the force always attracts the partition to the nearest
base. For arbitrary cross sections, we can use an expansion for the density of
states to compute the force in the limit of small height to width ratios. The
corrections to the force between parallel plates are found to have interesting
dependence on the shape of the cross section. Finally, for temperatures in the
range of experimental interest we compute finite temperature corrections to the
force (again assuming perfect boundaries).
