removing incidental function definitions caused by my misunderstanding of perl