initial changes

make code more readable for sharing. no changes from initial submission