Fix a nonsensical cast (double --> float --> double).