I am building a large DAE-based vapor‑compression refrigeration loop in Julia using DifferentialEquations.jl and CoolProp for thermodynamic properties, and I am running into repeated CoolProp crashes during DAE initialization and Newton iterations. Although the physical solution is valid, the DAE solver temporarily explores nonphysical trial states (negative pressures, NaNs, or extreme enthalpies), which causes CoolProp property calls such as “(P,H)” or saturation queries “(P,Q)” to fail. I have been adding local “effective” projections using isfinite checks, pressure floors, and enthalpy bounds to keep property evaluations in a valid domain, but the challenge is ensuring these guards are applied consistently everywhere without overwriting the DAE state variables or breaking solver convergence. I’m looking for best practices or established patterns for making CoolProp calls DAE‑safe in Julia while preserving correct physics and solver robustness.
1 Like