Pass in object as argument to 'calculate' function so that calculations can use the argument rather than 'this' if they choose. This also makes TypeScript type-checking more feasible.