added scaling to source version of heat merge