When a solid is heated, vacancy defect is produced in the crystal. Because on heating. some atoms or ions leave the lattice sites completely i.e., some lattice sites become vacant. As a result of this defect, the density of the substance decreases because some atoms/ ions leave the crystal completely.