Added documentation; commented out unused stuff