simpler trace printing during optimization