Algorithm and analysis for Bann and Bryson paper COGSCI 2013