CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

sonicFoam - pressure driven pipe: flow continuity violation and waveTransmissive BC

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 13, 2014, 09:02
Default sonicFoam - pressure driven pipe: flow continuity violation and waveTransmissive BC
  #1
New Member
 
Join Date: Sep 2012
Posts: 13
Rep Power: 15
Endel is on a distinguished road
Hello everyone,

I'm using OpenFOAM to analyse the gas flow (mass flow) behavior and arising pressure inside complex 3D structures with sonicFoam. My cases are somewhat similar to a nozzle, that goes inside a vacuum atmosphere. The inlet is always at constant pressure, so high pressure gradients are present.

While working on my cases I came across several problems like reflections at the outlet and violation of continuity when comparing the mass flow going into and out of the structure. This happens especially for cases, in which low inlet pressure is applied. I would like to share this with you and hopefully get some insight about how to solve these problems with your help in terms of Boundary Conditions and general solver behavior. Thank you in advance!

I isolated my problems as follows:

A simple straight pipe has one inlet and one outlet. One could maybe imagine the setup as a pipe, that connects a gas supply with constant pressure with an evacuated chamber. The mesh was generated using an .stl-file of a CAD drawing and snappyHexMesh, in order to mimic the procedure, that I usually undergo for more complex structures.




== 1. working Example: 80mbar Inlet Pressure ==

Applied Inletpressure: 8000Pa = 80mbar
Boundary Conditions and starting conditions see below, taken from 0/p:

Code:
	internalField   uniform 1e-4;

boundaryField
{
	"outlet.*"
	{
		type			waveTransmissive;
		field       p;
		phi         phi;
		rho         rho;
		psi         thermo:psi;
		gamma       1.4;
		fieldInf    1e-4;		
		lInf        0.5;	
		value			uniform 1e-4;
	}

	"inlet.*"
	{
		type			uniformTotalPressure;
		pressure	table
		(
		   (0 1)
		   (1e-4 8000)
		)
		
		outOfBounds clamp;
		phi         phi;
		rho         none;
		psi         thermo:psi;
		U           U;
   	        gamma       1.4;
		p0			   1e-4;
		value		   uniform 1e-4;
	}	
		
	"hull.*"	
	{
		type			zeroGradient;
	}
	
	defaultFaces
	{
	    type            empty;
	}

}

The resulting pressure stabilizes quickly inside the pipe and looks like this:

pipe_80mbar.jpg

I'm aware that the mesh could be better but it serves the purpose of this demonstration. More important: the pressure at the outlet does not come anywhere close to the desired value of 1e-4 Pa, specified as fieldInf. I made a series of simulations in which I varied the value of lInf but it didn't lower the outlet pressure. Furthermore I tried the fixedValue BC at the outlet, ending up with huge reflections and an unstable simulation. But I don't want to go into detail on this now.

For quicker analysis I wrote a matlab script based on the patchIntegrate command, that evaluates the flow through inlet and outlet. The result shows, that the flow stabilizes nicely: around 3300 mbar l/s go into the tube and out of it again.

Pipe_80mbar_fieldInf1e-4_inletflow.jpg Pipe_80mbar_fieldInf1e-4_outletflow.jpg

Conclusion: So far so good. The only thing that didn't work as I want is the pressure at the outlet. It is far too high and no where near the vacuum pressure of 1e-4 Pa specified at 0/p. Does anyone has any experience on how to achieve the desired pressure drop to 1e-4 Pa?





== 2. strange reflections: 1mbar Inlet Pressure ==

I did the exact same simulation as above, copied the mesh and everything but only changed the value of inlet pressure to 100 Pa = 1mbar:

Code:
		pressure	table
		(
		   (0 1)
		   (1e-4 100)
		)
The simulation starts normally until the pressure "hits" the outlet, where it looks as if it is reflected back into the pipe:

plotoverline_t000055.jpg plotoverline_t00024.jpg

The end pressure inside the pipe shows a reversed pressure gradient between inlet and outlet (see post above), thus causing a backwards directed flow, which is furthermore also oscillating. Note, that the pressure directly at the outlet fluctuates as can be seen by the spots that are slightly more red.

... see flow analysis and questions in the next post (I can only attach 5 pics per post) ...
Endel is offline   Reply With Quote

Old   March 13, 2014, 09:06
Default
  #2
New Member
 
Join Date: Sep 2012
Posts: 13
Rep Power: 15
Endel is on a distinguished road
… now the flow evaluation at inlet and outlet, showing a backwards directed flow and oscillations:

Pipe_1mbar_fieldInf1e-4_lInf1_inletflow.jpg Pipe_1mbar_fieldInf1e-4_lInf1_outletflow.jpg

According to the post in http://www.cfd-online.com/Forums/ope...issive-bc.html , the value for lInf might be a reason for reflections. However I did a series of simulations where I changed lInf from 0.1 to 100. The results were qualitatively the same and showed only minor differences.

As a reminder: I saw similar behavior in more complex cases with the same BC and starting conditions and only isolated the problem in this simple case.


My questions now are:
  1. Why does the simulation work fine for higher inlet pressure and not for lower inlet pressure?
  2. What could cause the backwards directed flow?
  3. Is sonicFoam at all suitable for these lower pressures as the speed that is reached for the 1mbar case is sub sonic?
  4. What other BC's could you suggest to solve this problem?


Thank you very much for your help on this, much appreciated!

Best,
Endel
Endel is offline   Reply With Quote

Old   March 18, 2014, 06:30
Default
  #3
New Member
 
Join Date: Sep 2012
Posts: 13
Rep Power: 15
Endel is on a distinguished road
Does nobody have an idea about this, why the mass flux is not conserved in this case or why the outlet suddenly has higher pressure than the inlet?

Did nobody encounter a similar problem?

Any help or discussion is helpful.

Endel
Endel is offline   Reply With Quote

Old   September 11, 2014, 17:29
Default
  #4
New Member
 
Matei Petrescu
Join Date: Jun 2013
Location: Montreal, Canada
Posts: 5
Rep Power: 13
mateiu2003k is on a distinguished road
I wish I could have helped you, but I have the same problem. Did you find the answer that you were looking for by any chance?

Matei.
mateiu2003k is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 06:03.