refactored functions in main
different modes can now be called from command line instead of needing recompilation
removed unused code
added option for printing maximum resident set size between each part of in-file BWT
refactored steps 2/7 and 3/8