The martensite forms during a diffusionless transformation, in which the transformation occurs due to shear-stresses created in the crystal lattices rather than by chemical changes that occur during precipitation. The shear-stresses create many defects, or "dislocations," between the crystals, providing less-stressful areas for the carbon atoms to relocate. Upon heating, the carbon atoms first migrate to these defects, and then begin forming unstable carbides. This reduces the amount of total martensite by changing some of it to ferrite. Further heating reduces the martensite even more, transforming the unstable carbides into stable cementite.