question about cochran.c
Dirk Hohndel
dirk at hohndel.org
Tue Oct 29 04:44:19 PDT 2019
On Tue, Oct 29, 2019 at 12:34:35PM +0100, Dirk Hohndel wrote:
> A quick grep shows me that this is the odd one out:
>
> $ grep 1\\.8 core/cochran.c
> sample->temperature.mkelvin = C_to_mkelvin((temp - 32) / 1.8);
> dc->watertemp.mkelvin = C_to_mkelvin((log[CMD_MIN_TEMP] / 32.0) - 1.8);
> dc->watertemp.mkelvin = C_to_mkelvin((log[EMC_MIN_TEMP] - 32) / 1.8);
> dc->watertemp.mkelvin = C_to_mkelvin((min_temp - 32) / 1.8);
>
> Yeah, that seems to make more sense. And ideally, all of them should do
> the division in floating point (dividing by 32.0).
Forget that last part - not enough coffee... we should not be dividing by
32 in the first place... so I think the only thing that needs to change is
the division / subtraction signs in that one line... and the grep above
was from my first naive / stupid attempt to fix this without thinking, so
in master this reads as in the line further up...
Thanks
/D
More information about the subsurface
mailing list