Bugfix uninitialised occ_cost variable usage

This fixes #256.
Merge pull request #257 from stonier/patch-1

Bugfix uninitialised occ_cost variable usage