  Let A be a commutative ring, B a commutative A-algebra and M a complex of
B-modules. We begin by constructing the square Sq_{B/A} M, which is also a
complex of B-modules. The squaring operation is a quadratic functor, and its
construction requires differential graded (DG) algebras. If there exists an
isomorphism \rho : M \iso Sq_{B/A} M then the pair (M,\rho) is called a rigid
complex over B relative to A (there are some finiteness conditions). There is
an obvious notion of rigid morphism between rigid complexes.
  We establish several properties of rigid complexes, including their
uniqueness, existence (under some extra hypothesis), and formation of pullbacks
f^{\flat}(M,\rho) (resp. f^{\sharp}(M,\rho)) along a finite (resp. essentially
smooth) ring homomorphism f^* : B \to C.
  In a subsequent paper we consider rigid dualizing complexes over commutative
rings, building on the results of the present paper. The project culminates in
a third paper, where we give a comprehensive version of Grothendieck duality
for schemes.
  The idea of rigid complexes originates in noncommutative algebraic geometry,
and is due to Van den Bergh.
