modified calculate to use new internal die representation. Now write tests! Optimization to be done too
wrote tests for calculate, tests pass
Added analysis functions, tests pass. Ready for merge