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

Multiple Internal Heat Exchangers for Storage Tank - Modelica

asked 2019-03-20 06:39:55 -0600

akey's avatar

updated 2019-03-21 09:22:34 -0600

I have a case where I have multiple internal heat exchangers inside the same tank. This is to take a hot feed from generators such as heat pumps and solar collectors, while providing heat for both space heating and hot water. To achieve this I am connecting the stratified enhanced internal hex models of the LBNL Buildings Library in series. Please see the attached image as an example. Is this the best approach to achieve this? If not, what are the shortfalls and is there an alternative? The issue I can see is that the heat exchangers will only be present in each tank. For example, in a hypothetical scenario, where the heat exchanger enters the top of the top tank, and leaves the bottom of the bottom tank then this approach would not be suitable. In such a situation how could the existing model be modified to have multiple heat exchangers at different heights? At the moment it appears the only parameter that dictates the position of the heat exchanger is the number of heat exchanger elements in each of the tank volumes. It would be useful to be able to specify the tank volumes where the heat exchanger is present. image description

Edit - Following the recommendation of Michael Wetter, I added a second heat exchanger to the Storage.StratifiedEnhancedInternalHex to take into account buoyancy and conduction. here is a screenshot with the additional HEX. image description I then added parameters for the top and bottom height of the exchanger. Here is the additional script needed to run the component:

parameter Modelica.SIunits.Height hHex2_a
    "Height of portHex_a of the second heat exchanger, measured from tank bottom";
parameter Modelica.SIunits.Height hHex2_b
    "Height of portHex_b of the second heat exchanger, measured from tank bottom";
final parameter Integer segHex2_a = nSeg-integer(hHex2_a/segHeight)
    "Tank segment in which port a1 of the heat exchanger 2 is located in"
final parameter Integer segHex2_b = nSeg-integer(hHex2_b/segHeight)
    "Tank segment in which port b1 of the heat exchanger 2 is located in"
final parameter Modelica.SIunits.Length dHHex2 = abs(hHex2_a-hHex2_b)
    "Vertical distance between the heat exchanger 2 inlet and outlet";
final parameter Integer nSegHex2Tan=
    if segHex2_a > segHex2_b then segHex2_a-segHex2_b + 1 else segHex2_b-segHex2_a + 1
    "Number of tank segments the heat exchanger resides in";
final parameter Integer nSegHex2 = nSegHex2Tan*hexSegMult
"Number of heat exchanger segments";

for j in 0:nSegHexTan-1 loop
    for i in 1:hexSegMult loop
      connect(indTanHex1.port[j*hexSegMult+i], heaPorVol[segHex2_a + (if hHex2_a > hHex2_b then j else -j)])
end for;
  end for;
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2019-03-20 23:45:06 -0600

If you open the model you see that the only connection between the heat exchanger and the volume is through the heat port of the volume. I therefore think you should be able to change Storage.StratifiedEnhancedInternalHex to have more than one instance of the heat exchanger indTanHex.

The arrangement that you show does not represent the right physics as it does not allow buoyancy from tan1 to tan or heat conduction between the fluids of these two tanks.

edit flag offensive delete link more


Thanks Michael. I noticed this but I was unsure of the connection equation:

equation for j in 0:nSegHexTan-1 loop for i in 1:hexSegMult loop connect(indTanHex.port[j*hexSegMult+i], heaPorVol[segHex_a + (if hHex_a > hHex_b then j else -j)]); end for; end for;

My understanding is that it iterates through the segments but I wasn't sure if it knows the height of the tank segment in relation to the HEX. i.e is it possible to have the top HEX in contact with the top 4 segments and the bottom HEX in contact with the bottom 4 segments of the tank using this equation?

akey's avatar akey  ( 2019-03-21 05:35:01 -0600 )edit

Ok problem solved. I was able to add two internal heat exchangers to the tank and then just set parameters for separate top and bottom heights for each of the exchangers. Apart from the height of the exchangers, all other properties remained the same i.e. HEX diameter, nsegments, capacitance etc, so this simplifed the adjustment. I calculated the necessary position parameters for the 2nd HEX in the script. I have checked the results and they make sense. I will add a screen shot of the final set up and the additional parameters to my original question incase it is useful to someone else.

akey's avatar akey  ( 2019-03-21 09:14:34 -0600 )edit

Your Answer

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

Add Answer

Training Workshops

Question Tools

1 follower


Asked: 2019-03-20 06:39:55 -0600

Seen: 498 times

Last updated: Mar 21 '19