Streamlined compute_estimate based on richierocks's suggestion in #168. Added tests.