Evaporator heat-flow reversed in refrigerant loop model (Simscape)

25 views (last 30 days)
Hello everyone,
I’m currently modeling a refrigerant test loop in Simscape. The flow path is:
High-pressure reservoir → condenser → short pipe → valve (TXV or EXV) → short pipe → evaporator → low-pressure reservoir. All parameters are set to realistic values (pressures, diameters, temperatures, etc.).
The issue I’m facing is that the evaporator appears to be removing heat from the refrigerant instead of adding it, the temperature at port B is higher than at port A, even though the evaporator’s ambient is hotter. This causes downstream effects such as superheat decreasing when the valve closes, which is the opposite of physical behavior. Meanwhile, the condenser behaves correctly (temperature drops from port A → B as it rejects heat). Has anyone seen this before or know why the evaporator heat direction might flip in Simscape?
  5 Comments
Yifeng Tang
Yifeng Tang 41 minuter ago
I agree with Umar that you'll need to use the Two-Phase Fluids domain to model your system.
I happened to notice this Reddit post and I suppose that's from @Aiden, too? As one of the comments mentioned:
"Based on the screenshot, the model is using the thermal liquid (TL) domain. However, to model a refrigeration system, one will need to use the two-phase fluids (2P) domain. Only in the 2p domain, the pressure drop through the expansion valve will result in phase change into the mixture regime. Suggestion: rebuild a model in the 2P domain. It shouldn't take long since the model already has most of the parameters."
@Umar Feel free to copy your comments into the Answer section.
Aiden
Aiden 22 minuter ago
Yes, that's exactly right, thanks for the thoughtful breakdown! Two-Phase Fluids works well for our case.

Sign in to comment.

Accepted Answer

Umar
Umar ungefär en timme ago

Hi @Aiden,

Thanks for the update and glad my earlier comments helped you narrow this down.

What you’re seeing fits well with how the Two-Phase Fluid and Thermal Liquid libraries work:

The Two-Phase Fluid model captures phase change and saturation, so it’s expected that the outlet temperature is higher than the inlet due to superheating as the refrigerant absorbs heat and evaporates. The Thermal Liquid model, however, does *not*model phase changes or saturation. Because of that, it’s normal for the outlet temperature to be lower than the inlet, even though heat transfer direction is the same. Since it’s simulating a single-phase fluid, the temperature behaves differently compared to the two-phase refrigerant. This means superheat calculations only make sense for the Two-Phase model. Using superheat in Thermal Liquid won’t give physically meaningful results, so control signals based on that may behave unexpectedly.

I tried to open your GitHub model, but I don’t have Simulink access to inspect the .slx files directly. If you can share a simplified version — maybe just the screenshot of Simscape blocks without the configuration scripts — or a MATLAB-only representation, I’d be happy to take a closer look and help suggest how to approximate evaporator-like temperature rise in the Thermal Liquid model. This would help you validate your controller before migrating fully to the Two-Phase Fluid library.

Let me know what you think!

More Answers (0)

Categories

Find more on Two-Phase Fluid Library in Help Center and File Exchange

Tags

Products


Release

R2025b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!