A mechanistic study of the formation of slags from iron-rich coals