Checked for termination safety before calls to betaReduce().
Added an outline implementation of betaReduce().