Question-and-Answer Resource for the Building Energy Modeling Community
Get started with the Help page
Ask Your Question
0

Modelica: MixedAir heating/cooling load components calculation.

asked 2026-07-13 00:09:37 -0500

Jack Lee's avatar

updated 2026-07-13 00:30:08 -0500

Hi everyone,

I am trying to directly calculate the energy balance (sensible heating/cooling) for the air node in a MixedAir model to determine the exact heating/cooling load components.

To evaluate the heat balance, I considered the following key factors:

1) Internal Convective Heat Gain Rate

2) Surface Convection Rate

3) Outdoor Air Transfer Rate

4) System Air Transfer Rate

Based on this, I assumed the following balance equation:

System Air Transfer Rate = Internal Convective Heat Gain Rate + Surface Convection Rate + Outdoor Air Transfer Rate

Here is how I mapped these factors to the specific Modelica output variables in my model:

  1. Internal Convective Heat Gain Rate: roo.air.QCon_flow

  2. Surface Convection Rate: roo.air.convConExt.Q_flow + roo.air.convConExtWin.Q_flow + roo.air.convConWin.air.Q_flow + roo.air.convConBou.Q_flow

  3. Outdoor Air Transfer Rate: roo.port[2].h_outflow * roo.port[2].m_flow

  4. System Air Transfer Rate: preHea.Q_flow

I plotted the sum of the components (1 + 2 + 3) and compared it against the system air transfer rate (4) to verify the energy balance. However, the graphs do not perfectly match, and there is a noticeable discrepancy between the two.

Could anyone advise on what I might be missing? Thank you.

ps. I am attaching the .mat and csv result files. .mat file & result.xlxs

image description

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
2

answered 2026-07-14 13:17:45 -0500

In component 3, you need to use the enthalpy added by the flow into and out of the volume. Currently, it only seems to be the enthalpy inlet flow, but mass of the roo.air is presumably also leaving which must be accounted for in the balance.

edit flag offensive delete link more

Comments

Thank you for your answer! Following your advice, I added the inlet element, and the results are now a very close match.

For the inlet, I utilized souInf.ports[1].m_flow * souInf.ports[1].h_outflow. Just to be absolutely sure, I would be very grateful if you could confirm if this output variable is appropriate.

Jack Lee's avatar Jack Lee  ( 2026-07-14 23:26:06 -0500 )edit

That is probably right (without looking at your model). More general, you can simply look at the underlying energy balance of the volume, which is implemented in ConservationEquation.mo, and the variable Hb_flow is the enthalpy flow rate of all fluid ports.

Michael Wetter's avatar Michael Wetter  ( 2026-07-16 17:27:03 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2026-07-13 00:09:37 -0500

Seen: 81 times

Last updated: Jul 14