Shortest previous burst

Added the shortest previous burst algorithms and tested them to make sure the results were right