Rigor mortis - muscles uses up ATP energy in the body (due to anaerobic respiration) and leads to lactic acid being produced (this increases acidity of body and leads to stiffening after death)...
Algor mortis - the corpse reaches the ambient room temperature. This is followed by putrification