Rework of abstract, added algorithm section, minor tweaks elsewhere.