optimize trimming using subsimplex