Put back algorithm that that was removed by accident.

Refs #9671