Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Value of t_outlet_k for circ_pump_pressure #669

Open
harrahx3 opened this issue Nov 29, 2024 · 1 comment
Open

Value of t_outlet_k for circ_pump_pressure #669

harrahx3 opened this issue Nov 29, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@harrahx3
Copy link

harrahx3 commented Nov 29, 2024

Describe the bug
In pandapipes 0.11 the attributes t_outlet_k has been added in the results parameters of the branch elements.

In the case of several pipes converging to the same junction, I understand that this attribute is useful to distinguish between the temperature at the outlet of the individual pipes, and the temperature at the junction resulting from the mixing of the fluids.

However I noticed an unexpected behavior in the case of circulation pumps, where the t_outlet_k doesn't correspond to the output temperature, but is smaller than both the feed and the return temperatures.

To Reproduce
Minimal example code:

I create a simple District Heazting system with only one circ_pump_pressure and one heat_consumer, connected with two pipes.

There is only one loop so there are never two branch elements converging towards the same junction.

import pandapipes

net = pandapipes.create_empty_network(fluid="water", name='net_pipes')

# create junctions
j0 = pandapipes.create_junction(net, pn_bar=10, tfluid_k=350)
j1 = pandapipes.create_junction(net, pn_bar=10, tfluid_k=350)
j2 = pandapipes.create_junction(net, pn_bar=10, tfluid_k=350)
j3 = pandapipes.create_junction(net, pn_bar=10, tfluid_k=350)

# create branch elements
pandapipes.create_pipe_from_parameters(net, from_junction=j0, to_junction=j1, length_km=0.1,
                                       diameter_m=0.05, u_w_per_m2k=10, text_k=273.15+15)
pandapipes.create_pipe_from_parameters(net, from_junction=j2, to_junction=j3, length_km=0.1,
                                       diameter_m=0.05, u_w_per_m2k=10, text_k=273.15+10)

pandapipes.create_circ_pump_const_pressure(net,
                                           return_junction=j3,
                                           flow_junction=j0,
                                           p_flow_bar=10,
                                           plift_bar=8,
                                           t_flow_k=333.15)

pandapipes.create_heat_consumer(net, from_junction=j1, to_junction=j2,
                                qext_w=100e3, controlled_mdot_kg_per_s=1)

pandapipes.pipeflow(net, mode='bidirectional')

print(net.res_circ_pump_pressure)

Result

net.res_circ_pump_pressure

 v_mean_m_per_s  p_from_bar  p_to_bar    t_from_k  t_to_k  t_outlet_k  \
0             NaN         2.0      10.0  306.672499  333.15  289.822499   

   mdot_from_kg_per_s  mdot_to_kg_per_s  vdot_m3_per_s  deltat_k  qext_w  
0                 1.0              -1.0       0.001003       NaN     NaN  

Expected behavior
I expect t_outlet_k being equal to the feed temperature t_to_k

Python environment (please complete the following information):

  • OS: Ubuntu 24.04
  • pandapipes version : 0.11.0
@harrahx3 harrahx3 added the bug Something isn't working label Nov 29, 2024
@dlohmeier
Copy link
Collaborator

Hi @harrahx3 , thanks for reporting this behavior. I think we still need a bit more adaption of pandapipes internals to create a logical result here. Actually, we regulate the circulation pump such that the temperature at the to node is set. This means that in cases where there are more streams into this node than just from the circulation pump, the circulation pump outlet temperature would change in such a way that the correct mixing temperature is reached. 289K is definitely not the correct value there, but t_outlet = t_to is also not always correct. I think that we need to change the behavior of the circulation pump such that the outlet temperature is set and this temperature goes into the to-node where a new mixing temperature can be observed. I believe that for this kind of behavior, we still need to adapt some equations in the system matrix construction.
@SimonRubenDrauz should we soon address this topic? I think it is related to #656 . Or would it make more sense to find a quicker solution for the circulation pumps, which could be easier as they are branch components.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants