opm-common icon indicating copy to clipboard operation
opm-common copied to clipboard

Throw for complex std::pow results in CO2::vaporPressure

Open blattms opened this issue 9 months ago • 4 comments

std::pow may throw for negative base and non-integer exponent, g++ doesn't. Here we add an explicit throw.

blattms avatar Mar 07 '25 20:03 blattms

jenkins build this please

blattms avatar Mar 07 '25 20:03 blattms

The safeguard added here is fine. I will add a fix that make sure it never is thrown. I suggest we merge that fix first.

totto82 avatar Mar 10 '25 07:03 totto82

jenkins build this please

totto82 avatar Mar 12 '25 07:03 totto82

This can be merged when the small nitpicks have been fixed.

totto82 avatar Mar 14 '25 11:03 totto82

It seems to me that the solution actually goes to zero when we approach zero from the positive side. Maybe we should just use 0 values <=0?

blattms avatar Apr 02 '25 06:04 blattms