separate auxiliary methods from main algorithm