Thermal spikes from stopped muons and density effects in muon-catalyzed fusion