added simple trace solving