added the files that Joe Thibodeau sent to calculate chunks