Standard Form of Modulation Equations for Internally and Externally Resonant Systems