cleaned up. almost ready for a weak submission