add comments, change names to be more consistent