main functions renamed