reformatted functions