Rolling Estonian wrote:
Most amps have a minimum air space around the amp, as long as you cut the foam out large enough to accommodate that air space you'd be ok.
Just make sure you know what you are mounting too. If you're going to go right to the metal trunk floor, be careful not to bolt/screw into anything important. Also, be sure to weather seal so your amp doesn't get wet.
My sub amp which is installed under the floor of my trunk has minimal space (maybe about 1" in front/back and about 1" on top) and I've had NO overheating problems. It also depends on the type of amp you have. A class D amp will generate less heat than A/B, so keep that in mind too.