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

No pressure drop in twoPhaseEulerFoam pipe with cyclic boundaries

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 30, 2016, 06:44
Default No pressure drop in twoPhaseEulerFoam pipe with cyclic boundaries
  #1
Senior Member
 
rdbisme's Avatar
 
Ruben Di Battista
Join Date: May 2013
Location: Paris
Posts: 137
Rep Power: 13
rdbisme is on a distinguished road
Hello,

it's been a while I've been struggling with this without understanding why I'm getting this behaviour.

I'm trying to simulate a two-phase flow with solid particles inside a liquid carrier and, even if the velocity profiles for both phases are developed, no pressure drop is achieved in the pipe.

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

3
(
    outlet
    {
        type            cyclic;
        inGroups        1(cyclic);
        nFaces          4500;
        startFace       667500;
        matchTolerance  0.0001;
        transform       unknown;
        neighbourPatch  inlet;
    }
    inlet
    {
        type            cyclic;
        inGroups        1(cyclic);
        nFaces          4500;
        startFace       672000;
        matchTolerance  0.0001;
        transform       unknown;
        neighbourPatch  outlet;
    }
    walls
    {
        type            wall;
        inGroups        1(wall);
        nFaces          6000;
        startFace       676500;
    }
)

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

momentumSource
{
    type            meanVelocityForce;
    active          yes;

    meanVelocityForceCoeffs
    {
        selectionMode   all;

        fieldNames      (U.SLN2);
        Ubar            (0 1.3 0);
    }
}

momentumSource1
{
    type            meanVelocityForce;
    active          yes;

    meanVelocityForceCoeffs
    {
        selectionMode   all;

        fieldNames      (U.LN2);
        Ubar            (0 1.3 0);
    }
}




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

phases (SLN2 LN2);

SLN2
{
    diameterModel   constant;
    constantCoeffs
    {
    d        1.3e-3;
    }
   residualAlpha    1e-6;
}

LN2
{
    diameterModel   constant;
    constantCoeffs
    {
        d               1;
    }
  
   residualAlpha    1e-6;
}

blending
{
    default
    {
        type            none;
    continuousPhase    LN2;

    }
}

sigma
(
    (SLN2 and LN2)     0
);

aspectRatio
(

);

drag
(
    (SLN2 in LN2)
    {
        type            SchillerNaumann;
        residualAlpha   1e-6;
        residualRe      1e-3;
        swarmCorrection
        {
            type        none;
        }
    }

    (LN2 in SLN2)
    {
        type            SchillerNaumann;
        residualAlpha   1e-6;
        residualRe      1e-3;
        swarmCorrection
        {
            type        none;
        }
    }


);

virtualMass
(
    (SLN2 in SLN2)
    {
        type            constantCoefficient;
        Cvm             0.5;
    }

    (LN2 in SLN2)
    {
        type            constantCoefficient;
        Cvm             0.5;
    }
);

heatTransfer
(
    (SLN2 in LN2)
    {
        type            RanzMarshall;
        residualAlpha   1e-4;
    }

    (LN2 in SLN2)
    {
        type            RanzMarshall;
        residualAlpha   1e-4;
    }
);

lift
(
);

wallLubrication
(
);

turbulentDispersion
(
);

// Minimum allowable pressure
pMin            10000;


// ************************************************************************* //

termophysicalProperties.LN2

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

thermoType
{
    type            heRhoThermo;
    mixture         pureMixture;
    transport       const;
    thermo          hConst;
    equationOfState perfectFluid;
    specie          specie;
    energy          sensibleInternalEnergy;
}

mixture
{
    specie
    {
        nMoles      1;
        molWeight   14;
    }
    equationOfState
    {
    R        3000;
    rho0        867.86;
    }
    thermodynamics
    {
        Cp          2000;
        Hf          25560;
    }
    transport
    {
        mu          294.92e-6;
        Pr          2.7975;
    }
}


// ************************************************************************* //
thermoPhysicalProperties.SLN2 (solid)

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

thermoType
{
    type            heRhoThermo;
    mixture         pureMixture;
    transport       const;
    thermo          hConst;
    equationOfState rhoConst;
    specie          specie;
    energy          sensibleInternalEnergy;
}

mixture
{
    specie
    {
        nMoles      1;
        molWeight   14;
    }
    equationOfState
    {
    rho        1026.5;
    }
    thermodynamics
    {
        Cp          1660;
        Hf          25560;
    }
    transport
    {
        mu          294.92e-6;
        Pr          2.42;
    }
}


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

dimensions      [0 0 0 0 0 0 0];

internalField   uniform 0.13;

boundaryField
{
    outlet
    {
        type            cyclic;
    }
    inlet
    {
        type            cyclic;
    }
    walls
    {
        type            zeroGradient;
    }
}


// ************************************************************************* //
Other settings summarized:
  • k-epsilon just for the liquid phase
    • epsilonWallFunction on the wall
    • zeroGradient for k on the wall
  • fixedFluxPressure on wall for p and p_rgh
  • fixedValue: 0 for velocities on walls
  • No energy equation (not solving it)
If any other details needed, ask! =)
rdbisme is offline   Reply With Quote

Old   April 8, 2016, 11:45
Default
  #2
Senior Member
 
rdbisme's Avatar
 
Ruben Di Battista
Join Date: May 2013
Location: Paris
Posts: 137
Rep Power: 13
rdbisme is on a distinguished road
I would like to answer to my own question. This is normal since using periodic BCs you do not have any pressure drop in the fields.

Using fvOptions > meanVelocityForce momentum source it prints in the output the pressure drop it's applying so that would be the pressure drop to apply to achieve the developed flow that we achieve during the cyclic bcs simulation.
rdbisme is offline   Reply With Quote

Old   December 19, 2016, 03:32
Default
  #3
New Member
 
Bryant
Join Date: Mar 2015
Posts: 7
Rep Power: 11
spf521 is on a distinguished road
Hi Ruben,
Thanks for your helpful information! I am facing a similar problem when setting a cyclic boundary using reactingTwoPhaseEulerFoam (I guess it is similar to twoPhaseEulerFoam without considering energy and phase change) of OF-4.1. I want to simulate a simple granular flow down inclined planes (2D situation), where the bottom patch is a noslip wall, the top is an atmosphere, and the left and right patch is set as "cyclic". But it is so weird that the mass of granular is decreasing continuingly just like the granular flows away through the cyclic boundaries.
Any opinion and suggestions will be helpful to me, thanks!

constant/polyMesh/boundary
Code:
(
    outlet
    {
        type            patch;
        nFaces          50;
        startFace       4900;
    }
    wall_bottom
    {
        type            wall;
        inGroups        1(wall);
        nFaces          50;
        startFace       4950;
    }
    wall_left
    {
        type            cyclic;
        inGroups        1(cyclic);
        nFaces          50;
        startFace       5000;
        matchTolerance  0.0001;
        transform       unknown;
        neighbourPatch  wall_right;
    }
    wall_right
    {
        type            cyclic;
        inGroups        1(cyclic);
        nFaces          50;
        startFace       5050;
        matchTolerance  0.0001;
        transform       unknown;
        neighbourPatch  wall_left;
    }
    frontAndBack2
    {
        type            empty;
        inGroups        1(empty);
        nFaces          5000;
        startFace       5100;
    }
)

0/p_rgh

Code:
dimensions          [1 -1 -2 0 0 0 0];
internalField       uniform 1e5;
boundaryField
{   
    outlet
    {
        type            prghTotalPressure;
        p0              $internalField;
        U               U.gas;
        phi             phi.gas;
        rho             thermo:rho.gas;
        value           $internalField;
    }
    wall_bottom
    {
        type            fixedFluxPressure;
        value           $internalField;
    }
    wall_left
    {
    type        cyclic;
    }
    wall_right
    {
    type        cyclic;
    }
    "frontAndBack.*"
    {
        type            empty;
    }
}

0/U.solids

Code:
dimensions      [0 1 -1 0 0 0 0];
internalField   uniform (0 0 0);
boundaryField
{    
    outlet
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }
    wall_bottom
    {
    type            fixedValue;
        value           uniform (0 0 0);
    }
    wall_left
    {
    type        cyclic;
    }
    wall_right
    {
    type        cyclic;
    }
    "frontAndBack.*"
    {
        type            empty;
    }
}
Attached Images
File Type: jpg t=0.0.jpg (13.3 KB, 19 views)
File Type: jpg t=0.5.jpg (13.6 KB, 15 views)
File Type: jpg t=1.0.jpg (13.6 KB, 15 views)
spf521 is offline   Reply With Quote

Old   December 23, 2016, 09:27
Default
  #4
Senior Member
 
rdbisme's Avatar
 
Ruben Di Battista
Join Date: May 2013
Location: Paris
Posts: 137
Rep Power: 13
rdbisme is on a distinguished road
Quote:
Originally Posted by spf521 View Post
Hi Ruben,
Thanks for your helpful information! I am facing a similar problem when setting a cyclic boundary using reactingTwoPhaseEulerFoam (I guess it is similar to twoPhaseEulerFoam without considering energy and phase change) of OF-4.1. I want to simulate a simple granular flow down inclined planes (2D situation), where the bottom patch is a noslip wall, the top is an atmosphere, and the left and right patch is set as "cyclic". But it is so weird that the mass of granular is decreasing continuingly just like the granular flows away through the cyclic boundaries.
Any opinion and suggestions will be helpful to me, thanks!

constant/polyMesh/boundary
Code:
(
    outlet
    {
        type            patch;
        nFaces          50;
        startFace       4900;
    }
    wall_bottom
    {
        type            wall;
        inGroups        1(wall);
        nFaces          50;
        startFace       4950;
    }
    wall_left
    {
        type            cyclic;
        inGroups        1(cyclic);
        nFaces          50;
        startFace       5000;
        matchTolerance  0.0001;
        transform       unknown;
        neighbourPatch  wall_right;
    }
    wall_right
    {
        type            cyclic;
        inGroups        1(cyclic);
        nFaces          50;
        startFace       5050;
        matchTolerance  0.0001;
        transform       unknown;
        neighbourPatch  wall_left;
    }
    frontAndBack2
    {
        type            empty;
        inGroups        1(empty);
        nFaces          5000;
        startFace       5100;
    }
)

0/p_rgh

Code:
dimensions          [1 -1 -2 0 0 0 0];
internalField       uniform 1e5;
boundaryField
{   
    outlet
    {
        type            prghTotalPressure;
        p0              $internalField;
        U               U.gas;
        phi             phi.gas;
        rho             thermo:rho.gas;
        value           $internalField;
    }
    wall_bottom
    {
        type            fixedFluxPressure;
        value           $internalField;
    }
    wall_left
    {
    type        cyclic;
    }
    wall_right
    {
    type        cyclic;
    }
    "frontAndBack.*"
    {
        type            empty;
    }
}

0/U.solids

Code:
dimensions      [0 1 -1 0 0 0 0];
internalField   uniform (0 0 0);
boundaryField
{    
    outlet
    {
        type            fixedValue;
        value           uniform (0 0 0);
    }
    wall_bottom
    {
    type            fixedValue;
        value           uniform (0 0 0);
    }
    wall_left
    {
    type        cyclic;
    }
    wall_right
    {
    type        cyclic;
    }
    "frontAndBack.*"
    {
        type            empty;
    }
}
Hey Bryant, at the end I chose to switch back to classical inlet/outlet configuration since I was having too many issues. I promised to myself to retry I again when I'll have more free time. So I'll suggest for the moment to find, if ossibile, a configuration that does not provide cyclic bcs.
rdbisme is offline   Reply With Quote

Old   December 25, 2016, 11:29
Default
  #5
New Member
 
Bryant
Join Date: Mar 2015
Posts: 7
Rep Power: 11
spf521 is on a distinguished road
Hi,Ruben, thanks for your reply. I try to follow your suggestion and use inlet/outlet configuration, while another problem occurs. Now the top and bottom patch are both noslip walls and the left patch is inlet with a constant velocity 0.2m/s, the right patch is outlet with constant pressure P. However, when the granular flow approaches to the outlet, the run crashes. I guess some BC conditions I used maybe have some problems. Looking forward to any advice, thanks!

0/p_rgh
Code:
dimensions          [1 -1 -2 0 0 0 0];
internalField       uniform 1e5;
boundaryField
{
       inlet
    {
	type               fixedFluxPressure;
        value              $internalField;
    outlet
    {
	type               prghPressure;
        p                  $internalField;
        value              $internalField;
    }
    wall
    {
        type            fixedFluxPressure;
        value           $internalField;
    }
    "frontAndBack.*"
    {
        type            empty;
    }
}

0/U.solids

Code:
dimensions      [0 1 -1 0 0 0 0];
internalField   uniform (0 0 0);
boundaryField
{    
     inlet
    {
	type            fixedValue;
        value           uniform (0.2 0 0);
    }
    outlet
    {
        type               pressureInletOutletVelocity;
        phi                 phi.solids;
        value              $internalField;
    }
    wall
    {
	type            fixedValue;
        value           uniform (0 0 0);
    }    
    "frontAndBack.*"
    {
        type            empty;
    }
}

0/alpha.solids

Code:
dimensions      [0 0 0 0 0 0 0];
internalField   uniform 0;
boundaryField
{
   inlet
    {
	type            fixedValue;
        value           uniform 0.6;
    } 
    outlet
    {
        type            zeroGradient;
    }
    wall
    {
        type            zeroGradient;
    }
    "frontAndBack.*"
    {
        type            empty;
    }
}
spf521 is offline   Reply With Quote

Reply

Tags
pipe flow, two fluid model, two phase flow, twophaseeulerfoam


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
Orifice-Pipe Problem CFXMUFFIN CFX 3 July 16, 2015 19:57
pressure drop - pipe flow C.C Main CFD Forum 6 November 19, 2012 11:02
Unsteady pressure differential between inlet and outlet of the pipe for single phase joshi20h FLUENT 0 September 26, 2012 13:41
Terrible Mistake In Fluid Dynamics History Abhi Main CFD Forum 12 July 8, 2002 10:11
Hydrostatic pressure in 2-phase flow modeling (long) DS & HB Main CFD Forum 0 January 8, 2000 16:00


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