Rewrite for usability and less confusing variables

....