Redesigned calc

Recoding from scratch, the best kind of recoding.