thorough rewrite of technical development section, diagram added