Move size to calculation to separate function calculate_size()
Add basic tests

Currently only for calculate_size. The tests also fail because of stupid floating point stuff (there's a difference of 1 from the expected value). Might as well be an error of the site I've been using for aspect ratios... (http://andrew.hedges.name/experiments/aspect_ratio/)