Tidied up cadhumidex function code.
Just a few tweaks to spacing, naming, explicit type conversions to be
more like the way I write Python.