Several fixes for algorithm. Add Travis-CI