Aaron's updated version
Updated variable types to avoid warnings.
Updated variable types and a name. Changed one file read for easier adjustments.
Merge pull request #1 from houtmanr/aaron

Aaron