added function for writing .beleq files
refs #23