|
[Sponsors] | |||||
|
|
|
#1 |
|
New Member
Milad
Join Date: May 2016
Location: Tehran
Posts: 3
Rep Power: 11 ![]() |
Hi dear Foamers
I am trying to run an 2 phase flow in Version 2.4 since methods are changed from 2.3 for interFoam. and I have problems with that. 1. my first problem is should I Split both outlet and inlet in to 2 face,(water and air separately)? I caught the free surface (alpha.water) correctly but for Velocity I just Need the water velocity but air have non zero velocity too. there is my U and alpha.water any ideas? thanks the first 2 codes have 2 inlets Code:
-*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.4.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
object alpha.water;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 0 0 0 0 0 0];
internalField uniform 0;
boundaryField
{
inlet-air
{
type fixedValue;
value uniform 0;
}
inlet-water
{
type fixedValue;
value uniform 1;
}
outlet
{
type zeroGradient;
}
atmosphere
{
type inletOutlet;
inletValue uniform 0;
value uniform 0;
}
walls
{
type zeroGradient;
}
rib
{
type zeroGradient;
}
front
{
type empty;
};
back
{
type empty;
};
};
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.4.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volVectorField;
object U;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //dimensions [0 1 -1 0 0 0 0];
internalField uniform (0.1 0 0);
boundaryField
{
inlet-air
{
type fixedValue;
value uniform (0 0 0);
}
inlet-water
{
type fixedValue;
value uniform (0.1 0 0);
}
outlet
{
//type zeroGradient;
type pressureInletOutletVelocity;
value uniform (0 0 0);
}
atmosphere
{
type pressureInletOutletVelocity;
value uniform (0 0 0);
}
walls
{
type fixedValue;
value uniform (0 0 0);
}
rib
{
type fixedValue;
value uniform (0 0 0);
}
front
{
type empty;
};
back
{
type empty;
};
}
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.4.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
object alpha.water;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 0 0 0 0 0 0];
internalField uniform 0;
boundaryField
{
inlet//has changed from inlet-water & inlet-air to inlet
{
type variableHeightFlowRate;
lowerBound 0.0;
upperBound 0.5;
value uniform 1;
}
outlet
{
//type inletOutlet;
//inletValue uniform 0;
type zeroGradient;
}
atmosphere
{
type inletOutlet;
inletValue uniform 0;//Like Spillway tut
value uniform 0;
}
walls
{
type zeroGradient;
}
rib
{
type zeroGradient;
}
front
{
type empty;
};
back
{
type empty;
};
};
Code:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.4.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volVectorField;
object U;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 1 -1 0 0 0 0];
internalField uniform (0.1 0 0);
boundaryField
{
inlet
{
type fixedValue;
value uniform (0.1 0 0);
}
outlet
{
type zeroGradient;
}
atmosphere
{
type pressureInletOutletVelocity;
phi phi;
value uniform (0 0 0);
}
walls
{
type fixedValue;
value uniform (0 0 0);
}
rib
{
type fixedValue;
value uniform (0 0 0);
}
front
{
type empty;
};
back
{
type empty;
};
};
// ************************************************************************* //
type variableHeightFlowRate; lowerBound 0.0; upperBound 0.9; value uniform 1; |
|
|
|
|
|
|
|
|
#2 |
|
Senior Member
Nima Samkhaniani
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,269
Blog Entries: 1
Rep Power: 26 ![]() |
whats wrong?
the air has a motion becuase there is shear stress between phases.
__________________
My Personal Website (http://nimasamkhaniani.ir/) Telegram channel (https://t.me/cfd_foam) |
|
|
|
|
|
![]() |
| Tags |
| boundary conditions, interfoam, open channel flow |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| what is swap4foam ?? | AB08 | OpenFOAM | 28 | February 2, 2016 02:22 |
| Problem in setting Boundary Condition | Madhatter92 | CFX | 12 | January 12, 2016 05:39 |
| Water subcooled boiling | Attesz | CFX | 7 | January 5, 2013 04:32 |
| Problem installing on Ubuntu 9.10 -> 'Cannot open : No such file or directory' | mfiandor | OpenFOAM Installation | 2 | January 25, 2010 10:50 |
| open channel flow boundary conditions | yan | FLUENT | 0 | July 5, 2005 00:36 |