Grid calculator