Moved all functions to utilis.h