CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   CFX (https://www.cfd-online.com/Forums/cfx/)
-   -   Water materials - pressure (https://www.cfd-online.com/Forums/cfx/217694-water-materials-pressure.html)

oliveira1820 May 21, 2019 15:08

Water materials - pressure
 
Iīm having several difficulties with the pressure calculation inside my domain filled with water.

I tried to use constant properties water and the pressure remained constant.

I tried to use water defined by the IAWPS database and the pressure reaches the maximum value of my table (200 bar) really fast, which doesnīt correspond to the real-based behaviour.

I tried to define liquid water with the correspondent NASA polymonials and the software solver crashes with the following message:

Error in subroutine CALVAR_PROP :
Error calculating Thermal Expansivity
GETVAR originally called by subroutine CAL_GVar


Can anybody help me with the material definition of water in order to get the true specific heat and density variation with temperature which will result in the true pressure?

evcelica May 21, 2019 17:09

What are you trying to solve exactly? You add heat to water in an enclosed container and want to solve for pressure?

ghorrocks May 21, 2019 17:37

Your problem is probably not in the material properties, but in the way you set the simulation up or the numerical stability it has.

For your setup, you need to think very carefully about what the flow is doing and the boundary conditions. For instance a change in temperature will lead to ta change in density, and that means fluid will enter or leave the domain. Have you got a suitable boundary to handle this flowing material?

For numerical stability, you need to check the normal things: smaller time step, double precision numerics, better initial condition, mesh quality, mesh quality and mesh quality. Mesh quality is so important it is worth repeating - everything becomes easier when you improve mesh quality.

oliveira1820 May 21, 2019 18:10

Quote:

Originally Posted by evcelica (Post 734355)
What are you trying to solve exactly? You add heat to water in an enclosed container and want to solve for pressure?


Yes, I have energy sources that go from 10 to 1000W and I want to see the relation between the energy deposited and the pressure.( It should be exponential)

oliveira1820 May 21, 2019 18:14

Quote:

Originally Posted by ghorrocks (Post 734360)
Your problem is probably not in the material properties, but in the way you set the simulation up or the numerical stability it has.

For your setup, you need to think very carefully about what the flow is doing and the boundary conditions. For instance a change in temperature will lead to ta change in density, and that means fluid will enter or leave the domain. Have you got a suitable boundary to handle this flowing material?

For numerical stability, you need to check the normal things: smaller time step, double precision numerics, better initial condition, mesh quality, mesh quality and mesh quality. Mesh quality is so important it is worth repeating - everything becomes easier when you improve mesh quality.


I'm already working with double Precision and tried to improve the mesh which proved to not influence the results.

My initial conditions are 20 degrees Celsius and atmospheric pressure.
The container is closed with walls with no slip condition as boundary conditions, there is no fluid entering or going out

ghorrocks May 21, 2019 18:53

If you are modelling a sealed cavity with liquid water then as you heat it you will get a very rapid rise in pressure, this is the expected physics. In real life the container is going to deform and the volume is going to fractionally increase, but this is enough to relieve a large amount of the pressure.

So there will be a big difference in pressure between a perfectly rigid container and a realistic container which deforms a tiny amount from the large pressure inside it. Have you taken this into account?

oliveira1820 May 21, 2019 21:09

Quote:

Originally Posted by ghorrocks (Post 734366)
If you are modelling a sealed cavity with liquid water then as you heat it you will get a very rapid rise in pressure, this is the expected physics. In real life the container is going to deform and the volume is going to fractionally increase, but this is enough to relieve a large amount of the pressure.

So there will be a big difference in pressure between a perfectly rigid container and a realistic container which deforms a tiny amount from the large pressure inside it. Have you taken this into account?

The container made of niobium is cooled with a 0,5 kg/s water flow, which in turn removes the heat excess preventing it from heating too much and deforming.

The problem is that if I use IAWPS (very accurate supposedely), the pressure goes to 200 bar ( it doesnīt go further cause my max on table is 200) and in reality it should be 10-30 bars, for the energy Iīm using and my system.

Should I account for the dofrmation of the material? And how could I do it

ghorrocks May 22, 2019 03:49

So the thermal situation is not simple - it has some undefined heat input and a coolant water system, so the temperature will be a function of all that.

And yes you should work out how much the thing deflects at the pressures you expect, as that is highly likely be a big cause of the error.

oliveira1820 May 22, 2019 15:01

Quote:

Originally Posted by ghorrocks (Post 734400)
So the thermal situation is not simple - it has some undefined heat input and a coolant water system, so the temperature will be a function of all that.

And yes you should work out how much the thing deflects at the pressures you expect, as that is highly likely be a big cause of the error.

But how' could I take the deflection into account, how do I activate it in the ANSYX CFX Pre?

ghorrocks May 22, 2019 19:01

That depends on your system, how it is reinforced, how it operates and so on.

But assuming it is pretty much just a sealed chamber - then model the chamber in FEA with the pressures you expect. You can get the deformations from this. Then see if the extra volume it gives you is enough to account for the variation you are seeing.

If the volume change is important then you need to think of a way of incorporating it into your model. A one-way FSI model would do this easily I would think.

If the volume change is not important then something else is happening. Then you have to figure out what it is and whether it is real or not.

oliveira1820 May 23, 2019 03:24

Quote:

Originally Posted by ghorrocks (Post 734512)
That depends on your system, how it is reinforced, how it operates and so on.

But assuming it is pretty much just a sealed chamber - then model the chamber in FEA with the pressures you expect. You can get the deformations from this. Then see if the extra volume it gives you is enough to account for the variation you are seeing.

If the volume change is important then you need to think of a way of incorporating it into your model. A one-way FSI model would do this easily I would think.

If the volume change is not important then something else is happening. Then you have to figure out what it is and whether it is real or not.

Just another thing that is happening on my simulation to see if you can guess the error source:

When I use the NASA polymonials to define liquid water, the specific heat and denisty vary normally, but the pressure basically satays constant (1 atm).

For the same amount of heat, when I use IAWPS to define water, the density and specific heat vary also normally, but the pressure reaches tens of bar and keeps increasing at 100 seconds of simulation.

ghorrocks May 23, 2019 07:23

That one is obvious - surely you know what is happening there.

It appears your NASA polynomials fluid is constant density. So in a sealed chamber the pressure will never change.

The IAWPS fluid have variable density, so the heating leads to a pressure change.

oliveira1820 May 23, 2019 12:45

Quote:

Originally Posted by ghorrocks (Post 734579)
That one is obvious - surely you know what is happening there.

It appears your NASA polynomials fluid is constant density. So in a sealed chamber the pressure will never change.

The IAWPS fluid have variable density, so the heating leads to a pressure change.

Sorry I didn't explained well. These last results are for the case where I define the density in function of temperature

ghorrocks May 23, 2019 18:41

Be careful here - if your fluid has density a function of temperature but not of pressure it will not behave as you expect. You should make the density a function of pressure as well.

Gert-Jan May 24, 2019 02:07

Quote:

Originally Posted by oliveira1820 (Post 734363)
Yes, I have energy sources that go from 10 to 1000W and I want to see the relation between the energy deposited and the pressure.( It should be exponential)




my 50 cents: I think you should take a step back and try to answer:

What question are you trying to answer with your CFD calculation?

If you are trying to calculate the pressure then either calculate it by hand (exponential) or take everything into account, including the FSI, like Glenn suggested. Using all the simplifications and not using FSI, your answer will not be more accurate than your hand calculation. So why all the effort?

Alternatively, rephrase your question, and simplify the physics by ignore density-pressure coupling. Something like:

- Do you want to know the local temperature and locate hot spots: use CFD with density-temperature coupling
- Do you want to investigate how long it take to heat up: use CFD with density-temperature coupling
- Do you want to investigate the flow due to buoyancy and determine local HTC: use CFD with density-temperature coupling

Regards, Gert-Jan

oliveira1820 May 24, 2019 02:14

Quote:

Originally Posted by Gert-Jan (Post 734677)
my 50 cents: I think you should take a step back and try to answer:

What question are you trying to answer with your CFD calculation?

If you are trying to calculate the pressure then either calculate it by hand (exponential) or take everything into account, including the FSI, like Glenn suggested. Using all the simplifications and not using FSI, your answer will not be more accurate than your hand calculation. So why all the effort?

Alternatively, rephrase your question, and simplify the physics by ignore density-pressure coupling. Something like:

- Do you want to know the local temperature and locate hot spots: use CFD with density-temperature coupling
- Do you want to investigate how long it take to heat up: use CFD with density-temperature coupling
- Do you want to investigate the flow due to buoyancy and determine local HTC: use CFD with density-temperature coupling

Regards, Gert-Jan

The hand calculation is a nice idea. The problem is I donīt have any idea about a formula to do it. Can you tell me or advice me where to look?

Gert-Jan May 24, 2019 02:34

I don't have it. I copied the term exponential from your query, thinking that you would have it.

Thinking it over, in a closed rigid compartment, density should not vary at all, else then the bousinesq approach. So direct density-temperature coupling won't work as well. You should take density as a constant.

You can still calculate the temperature using CFD with constant density. Take the volume average T and using an expansivity relation, determine the pressure. You need forced convection for this. So you need a mixer that helps in the heat transfer.

If you don't have a mixer, than you need free convection. Then you can include the bousinesq approach. But this is only valid over a small range of temperatures. Could be sufficient. Then again: take the volume average T and using an expansivity relation, determine the pressure.

Everything else requires density-temperature coupling with FSI.

oliveira1820 May 24, 2019 02:38

Quote:

Originally Posted by ghorrocks (Post 734653)
Be careful here - if your fluid has density a function of temperature but not of pressure it will not behave as you expect. You should make the density a function of pressure as well.

I made the density in function of pressure and the solver crashes:

DENSITY = (-0.9486* Temperature/((1) [K]) + 1292 +0.05*Pressure/((100000) [Pa]))[kg m^-3]

Do you notice anything wrong?

Gert-Jan May 24, 2019 02:51

You didn't read my post. I wrote:


"in a closed rigid compartment, density should not vary at all."


You can only use the bousinesq approach to include free convection if this is relevant.

oliveira1820 May 24, 2019 02:52

Quote:

Originally Posted by Gert-Jan (Post 734679)
I don't have it. I copied the term exponential from your query, thinking that you would have it.

Thinking it over, in a closed rigid compartment, density should not vary at all, else then the bousinesq approach. So direct density-temperature coupling won't work as well. You should take density as a constant.

You can still calculate the temperature using CFD with constant density. Take the volume average T and using an expansivity relation, determine the pressure. You need forced convection for this. So you need a mixer that helps in the heat transfer.

If you don't have a mixer, than you need free convection. Then you can include the bousinesq approach. But this is only valid over a small range of temperatures. Could be sufficient. Then again: take the volume average T and using an expansivity relation, determine the pressure.

Everything else requires density-temperature coupling with FSI.

FSI is out of question for now.

The pressure is exponential because, the chamber is cooled by water, and it raises with the energy I put in there, but at one certain value, the heat generated is higher that the heat removing capacity and the pressure raises exponentially.

Do you know a formula for calculating the pressure, with the density/temperature/thermal expansivity/heat flux removed/ that I can use (or just one of this variables)?

The purpose of the simulation is to see the temperature raising and distribution and the pressure exponentially raise with energy input(that is due to the heat remove feature), if you can think of another way to demosntrate this it will work also.


All times are GMT -4. The time now is 16:32.