Merging collaborator code

Merging mine and Kori's code.