Updated expression implementation

- Compiled all of the expression terms into a single buffer for better
  memory efficiency

- Indexed all the clauses by the vars they use to make it easier to
  process only the clauses that will be affected by an assignment,
  rather than walk the whole expression every time.
Dead code removal