Added progress comments, fixed a variable name.