Inital commit of reading band gaps and of the sort function