An invariant representation of the modulation equations for the sinh- and sine-Gordon wavetrains is derived. A simple derivation of the representation which makes fundamental use of squared eigenfunctions is presented. This representation is used to place the modulation equations in Riemann invariant form and to cast them in a Hamiltonian form. The multiphase sinh-Gordon study is complete, while the sine-Gordon theory for more than one phase possesses technical difficulties which are described in the text. Explicit results on real two-phase sine-Gordon waves are included.