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

potentialFoam not working properly

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 8, 2014, 08:47
Default potentialFoam not working properly
  #1
New Member
 
X
Join Date: Oct 2014
Posts: 4
Rep Power: 11
GAlava is on a distinguished road
Hi there!

I am running potentialFoam to initially solve the airflow over a cube, but I am not getting a reasonable velocity field. It runs, but it seems that it has done nothing by the results. The flow is not developed at all.
I also would like to ask if potentialFoam can run several iterations (I want 10 in this case) as any oher solver and write the correspondent output folders (1, 2, 3, ...), since it seems that it is not the case.

I attach my controlDict file

CONTROLDICT
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.3.0                                 |
|   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "system";
    object      controlDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

application     potentialFoam;

startFrom       startTime;

startTime       0;

stopAt          endTime;

endTime         10;

deltaT          1;

writeControl    timeStep;

writeInterval   1;

purgeWrite      0;

writeFormat     ascii;

writePrecision  6;

writeCompression off;

timeFormat      general;

timePrecision   6;

runTimeModifiable true;


// ************************************************************************* //
I upload an image of the Velocity field after running potentialFoam

Thank you.
Attached Images
File Type: jpg Vfield.jpg (17.1 KB, 58 views)
GAlava is offline   Reply With Quote

Old   October 8, 2014, 09:38
Default
  #2
Senior Member
 
Alexey Matveichev
Join Date: Aug 2011
Location: Nancy, France
Posts: 1,930
Rep Power: 38
alexeym has a spectacular aura aboutalexeym has a spectacular aura about
Send a message via Skype™ to alexeym
Hi,

it'll be much easier for everybody if you attach case files to the message. Otherwise there will be lots of standard questions:

1. What are your BCs?
2. What are your ICs?
3. Can you show your fvSchemes and fvSolution?

Concerning you question about " ... run several iterations ... ". No, if you take a look at source code of potentialFoam, it's supposed to run just one iteration.
alexeym is offline   Reply With Quote

Old   October 8, 2014, 12:12
Default
  #3
New Member
 
X
Join Date: Oct 2014
Posts: 4
Rep Power: 11
GAlava is on a distinguished road
Thanks for your rapid response, These are the schemes and the 0/U file. I am using a typical inlet-outles, wall for the floor and the surface of the cube and symmetry for the wrap of the domain configuration.

fvSolution

Code:
*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.3.0                                 |
|   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "system";
    object      fvSolution;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

solvers
{
    p
    {
        solver          GAMG;
        tolerance       1e-07;
        relTol          0.08;
        smoother        GaussSeidel;
        nPreSweeps      0;
        nPostSweeps     2;
        cacheAgglomeration true;
        nCellsInCoarsestLevel 10;
        agglomerator    faceAreaPair;
        mergeLevels     1;
        maxIter            100;
    }

    U
    {
        solver          smoothSolver;
        smoother        symGaussSeidel;
        tolerance       1e-07;
        relTol          0.1;
    }
}

potentialFlow
{
    nNonOrthogonalCorrectors 8;
}

relaxationFactors
{
    fields
    {
        p               0.3;
    }
    equations
    {
        U               0.7;
    }
}
fvSchemes

Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.3.0                                 |
|   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "system";
    object      fvSchemes;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

ddtSchemes
{
    default         steadyState;
}

gradSchemes
{
    default         leastSquares;
}

divSchemes
{
    default         none;
}

laplacianSchemes
{
    default         Gauss linear corrected;
}

interpolationSchemes
{
    default         linear;
}

snGradSchemes
{
    default         corrected;
}

fluxRequired
{
    default         no;
    p               ;
}


// ************************************************************************* //
BC

Code:
/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.3.0                                 |
|   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       volVectorField;
    location    "0";
    object      U;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [0 1 -1 0 0 0 0];

internalField  uniform (0 0 0);

boundaryField
{
    OUTLET
    {
        type            uniformFixedValue;
        uniformValue    constant (5 0 0);
    }
    INLET
    {
        type            uniformFixedValue;
        uniformValue    constant (5 0 0);
    }
    
// GROUND, WALL and DENSITY are physical walls    

    GROUND
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }
    WALL
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }
    DENSITY
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }
    
    
    SYM_RIGHT
    {
        type            symmetryPlane;
    }
    SYM_UP
    {
        type            symmetryPlane;
    }
    SYM_LEFT
    {
        type            symmetryPlane;
    }
}


// ************************************************************************* //
GAlava is offline   Reply With Quote

Old   October 8, 2014, 12:47
Default
  #4
Senior Member
 
Alexey Matveichev
Join Date: Aug 2011
Location: Nancy, France
Posts: 1,930
Rep Power: 38
alexeym has a spectacular aura aboutalexeym has a spectacular aura about
Send a message via Skype™ to alexeym
Hi,

well, in general the following BCs are imposed (btw you've forgotten pressure boundary conditions):

inlet: U - fixed value, p - zero gradient
outlet: U - zero gradient, p - fixed value

Also I'm not quite sure in two things:

1. Necessity for this potentialFoam run.
2. Symmetry of the flow.
alexeym is offline   Reply With Quote

Old   October 8, 2014, 13:41
Default
  #5
New Member
 
X
Join Date: Oct 2014
Posts: 4
Rep Power: 11
GAlava is on a distinguished road
I use the symmetryPlane as a numerical trick to impose a non-viscous wall (the normal to the fake wall component of the velocity is null end the gradient is null)

Are you suggesting that the imposed BC can be the problem? Which BC do you suggest? It is a very simple incompressible flow entering a tunnel, for examle.

Thanks.
GAlava is offline   Reply With Quote

Old   October 8, 2014, 14:16
Default
  #6
Senior Member
 
Alexey Matveichev
Join Date: Aug 2011
Location: Nancy, France
Posts: 1,930
Rep Power: 38
alexeym has a spectacular aura aboutalexeym has a spectacular aura about
Send a message via Skype™ to alexeym
Another possibility is that you've messed up the direction of the velocity. As your screenshot lacks coordinate axes, maybe (5 0 0) is directed into the wall and not along the tunnel

If you'd like to simulate incompressible flow in the tunnel, I'd suggest you to use pimpleFoam (if you're interested in transient state) or simpleFoam (if you need steady state). Use fixed value BC for velocity at the inlet, zero gradient BC for velocity at the outlet; and vice-a-versa for pressure: zero gradient at the inlet, fixed value at the outlet.

Quote:
I use the symmetryPlane as a numerical trick to impose a non-viscous wall (the normal to the fake wall component of the velocity is null end the gradient is null)
Do you mean slip BC?
alexeym is offline   Reply With Quote

Old   October 8, 2014, 15:29
Default
  #7
New Member
 
X
Join Date: Oct 2014
Posts: 4
Rep Power: 11
GAlava is on a distinguished road
Yep, slip BC was what I meant.

Thank you vey much alexeym, great help!
GAlava is offline   Reply With Quote

Old   March 9, 2021, 12:34
Default
  #8
Member
 
Bushra Rasheed
Join Date: Dec 2020
Posts: 97
Rep Power: 5
B_R_Khan is on a distinguished road
Hi!

I know this thread was posted long time ago but were you able to run potentialFoam over a cube? I have been trying to do the same but get no results. It gives no errors but there are no pressure and velocity fields solved by it. I'm using slip boundary condition on cube walls.
B_R_Khan is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Initialization with potentialFoam Sune OpenFOAM Running, Solving & CFD 6 March 2, 2016 13:18
what "If" condition means in rebound brbbhatti OpenFOAM Programming & Development 0 August 12, 2014 10:18
potentialFoam error achyutan OpenFOAM Running, Solving & CFD 0 July 8, 2013 09:21
Flapping wing rotation in Fluent 3D not working properly davesmith_01 FLUENT 1 February 13, 2011 22:35
Sample utility not working properly titio OpenFOAM 2 June 9, 2010 11:45


All times are GMT -4. The time now is 04:48.