Energy partitioning for generalized product functions: the interference contribution to the energy of generalized valence bond and spin coupled wave functions.