cleaned up defineExpression