Added code to input clauses and equational constraints where appropriate