Added tunable gain with max iters