CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (http://www.cfd-online.com/Forums/openfoam-solving/)
-   -   unsteady ramp inlet condition (http://www.cfd-online.com/Forums/openfoam-solving/108163-unsteady-ramp-inlet-condition.html)

pepe.aero October 16, 2012 06:12

unsteady ramp inlet condition
 
Hi all,

i'm trying to assign unsteady inlet boundary condition (ramp-shaped UX profile) working on a multiphase problem.
In OF 2.1.1 I can do it using the uniformFixedValue type by this way in the 0/U file:

inlet
{
type uniformFixedValue;
uniformValue csvFile;
csvFileCoeffs
{
fileName "$FOAM_CASE/u_ramp.txt"
outOfBounds clamp;
hasHeaderLine true;
refColumn 0;
componentColumns (1 2 3);
}
}


where the u_ramp.txt is something like the following:

Time,Ux,Uy,Uz
0.00, 0.0, 0.0, 0.0
0.01, 0.0, 0.0, 0.0
0.02, -0.066363, 0.0, 0.0
0.03, -0.132726, 0.0, 0.0
0.04, -0.199089, 0.0, 0.0
0.05, -0.265452, 0.0, 0.0
0.06, -0.331815, 0.0, 0.0
0.07, -0.398178, 0.0, 0.0
0.08, -0.464541, 0.0, 0.0
0.09, -0.530904, 0.0, 0.0
0.10, -0.597267, 0.0, 0.0
0.11, -0.663630, 0.0, 0.0
0.12, -0.730000, 0.0, 0.0
0.13, -0.730000, 0.0, 0.0
0.14, -0.730000, 0.0, 0.0
0.15, -0.730000, 0.0, 0.0


The problem is: Paraview reports this error trying to visualize results:

ERROR: In /home/utkarsh/Kitware/superbuild/paraview/src/paraview/VTK/IO/vtkOpenFOAMReader.cxx, line 6535
vtkOpenFOAMReaderPrivate (0x298a3d0): Wrong list type for uniform field

Is not all. In the variable list available to be visualized I can't find U for inlet boundary, and I find U (of cell) just for internalMesh, while the interpolated one does not appear.

In my idea this is not a post-processing problem, but my doubt is if I setup the unsteady boundary condition properly.
Has anyone experiences with a ramp inlet in OpenFOAM?

Thanks for your support,

Kind regards,

Andrea

michielm October 16, 2012 08:08

I have noticed that ParaView doesn't always understand the uniformFixedValue boundary condition if I load the files from vtk of with a .foam file.

However, if I use paraFoam it works well, because apparently there is some conversion that fixes the problem. Have you used paraFoam to open your dataset?!

pepe.aero October 16, 2012 09:23

Hi Michiel,

thanks a lot for your reply. I was used to use the paraview command instead of paraFoam. You're right, using paraFoam the problem is fixed. Good.

A second issue is: OpenFOAM shows me some convergence problems using the unsteady boundary condition. I'm using a ramp at inlet to grow up gradually the velocity in order to assign a smooth velocity profile and reach convergence in less iterations.
But the result at the moment is that I reach no convergence by this way. So, do I have to change something in the numerical parameters (fvSchemes, fvSolutions) in order to suit unsteady BCs?

Thanks again for your help!

Regards,

Andrea

michielm October 16, 2012 10:42

Hi Andrea,
To be able to answer that I need to know more about the case you are trying to model.
What are you modelling and what are the boundary conditions you are applying?!

pepe.aero October 16, 2012 15:45

1 Attachment(s)
Hi,

sure I give you all details.
I'm working on naval application of a hull in a multiphase flow. The problem can be referred to the wigley-hull tutorial, but I'm trying to improve different features, such as an unsteady ramp inlet boundary condition.
The hull is in a 3D rectangular domain and I've attached files regarding numerical parameters and all boundary conditions.
Notice that the initial position of free surface (alpha1 is mass fraction) is set with command setFields just before the start of the computation.

I really appreciate your support!

Kind regards,

Andrea

michielm October 18, 2012 05:05

Hi Andrea,
I can't really find a clear reason for the case not to converge.

Do you have convergences issues in the inner or the outer loop of your iterations?

shildenbrand August 7, 2013 03:33

Hi all,

I have the same problem as in post #1 in this thread.

My configuration: OF 2.2.1 and Paraview 4.0.1

Since I could not compile the PV3 readers for ParaView 4 I use the PV builtin-reader - which works well, except for the case with a Boundary condition "uniformFixedValue".
That's why using paraFoam makes no difference in my case.


Any ideas how to fix this problem?


Stefan

pajot August 25, 2013 11:43

Hi Stefan:

Quote:

Originally Posted by shildenbrand (Post 444283)
Hi all,

I have the same problem as in post #1 in this thread.

My configuration: OF 2.2.1 and Paraview 4.0.1

Since I could not compile the PV3 readers for ParaView 4 I use the PV builtin-reader - which works well, except for the case with a Boundary condition "uniformFixedValue".
That's why using paraFoam makes no difference in my case.


Any ideas how to fix this problem?


Stefan

Unfortunately, I come not with a solution but to report that I have the same issue, and I'm running OF 2.2.1 and Paraview 3.98.0. It makes no difference that I am running paraFoam (if I just paraview, it can't read the OF results anyway).

Are you running a multiprocessor simulation?

shildenbrand August 26, 2013 05:03

Quote:

Originally Posted by pajot (Post 447938)

Are you running a multiprocessor simulation?

Hi Stephen,

yes I run a multiprocessor simulation, but the error is coming up no matter if I read in the decomposed or the reconstructed case.

hrvig October 22, 2013 00:57

Did you manage to solve this?

shildenbrand October 22, 2013 04:23

Quote:

Originally Posted by hrvig (Post 458194)
Did you manage to solve this?

No - I am sorry. No news.


All times are GMT -4. The time now is 07:13.