add title definitions and overhaul comments