ibpsa / modelica-ibpsa

Modelica library for building and district energy systems developed within IBPSA Project 1
https://ibpsa.github.io/project1
141 stars 84 forks source link

Negative Fan Power #1621

Closed hcasperfu closed 1 year ago

hcasperfu commented 2 years ago

This issue is to add a non-negative constraint to the flow work computation flo = V̇ Δ p >= 0 in IBPSA.Fluid.Movers.BaseClasses.FlowMachineInterface in order to prevent the model from producing negative power when either the pressure rise or the flow rate is negative. An example of this situation is in the model Buildings.Examples.DualFanDualDuct.ClosedLoop (as of https://github.com/lbl-srg/modelica-buildings/commit/b65753005f56311322c675892f0fc75fc5b1d9bd). When the cold deck is dominant, the hot deck fan fanSupHot is forced to have a pressure drop instead of rise across the fan because it is overpowered by the return fan fanRet. This results in negative fan power in the model which is incorrect.

ClosedLoop

Mathadon commented 2 years ago

I do not entirely agree with this analysis. Fans can indeed be operated as turbines that generate power instead of consuming it. Not every fan may support this since it depends on the used technology but many do.

I think we have to look further at the root cause of the problem here.

mwetter commented 2 years ago

@Mathadon : If we want to have a fan also act as a turbine, more work would be needed. I don't think users expect it to work that way. For example, if a fan has an efficiency of 80%, and the shaft work is 1000 W, then PEle = PSha/eMot = 1000/0.8, e.g, it would produce more electricity than the flow work that it transmits at the shaft. Also, we would need to know what a variable frequency drive would be doing in this case. In light of this, I suggest we set negative flow work to zero.

Mathadon commented 2 years ago

@mwetter that's a good point. Okay, let's cap the flow work.

Can we add a note to the documentation that explains this 'approximation' and perhaps add a link to this issue?

hcasperfu commented 2 years ago

@Mathadon Thank you for the feedback! I have updated the documentation of FlowMachineInterface as well as the usersguide with a brief explanation and a link to this post.