I run multiphaseInterfoam, and I have trouble with the inlet being non-constant (I want it to be constant.)
Here are my alpha-files\
/--------------------------------- C++ -----------------------------------\
FoamFile { version 2.0; format ascii; class volScalarField; location "0"; object alpha.air; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 0 0 0 0 0 0];
internalField uniform 0;
boundaryField { //- Set patchGroups for constraint patches #includeEtc "caseDicts/setConstraintTypes"
inlet { type alphaContactAngle; thetaProperties ( ( freshWater air ) 90 0 0 0 ( saltWater air ) 90 0 0 0 ( freshWater saltWater ) 90 0 0 0 ); value uniform 0; } outlet { type alphaContactAngle; thetaProperties ( ( freshWater air ) 90 0 0 0 ( saltWater air ) 90 0 0 0 ( freshWater saltWater ) 90 0 0 0 ); value uniform 0; } atmosphere { type inletOutlet; inletValue uniform 1; value uniform 1; } barge { type alphaContactAngle; thetaProperties ( ( freshWater air ) 90 0 0 0 ( saltWater air ) 90 0 0 0 ( freshWater saltWater ) 90 0 0 0 ); value uniform 0; } }
alpha.freshwater:
/--------------------------------- C++ -----------------------------------\
FoamFile { version 2.0; format ascii; class volScalarField; location "0"; object alpha.freshWater; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 0 0 0 0 0 0];
internalField uniform 0;
boundaryField { //- Set patchGroups for constraint patches #includeEtc "caseDicts/setConstraintTypes"
inlet { type fixedValue; value $internalField; } outlet { type variableHeightFlowRate; lowerBound 0; upperBound 1; value $internalField; } atmosphere { type inletOutlet; inletValue $internalField; value $internalField; } barge { type zeroGradient; } }
alpha.saltWater
FoamFile { version 2.0; format ascii; class volScalarField; location "0"; object alpha.saltWater; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 0 0 0 0 0 0];
internalField uniform 0;
boundaryField { //- Set patchGroups for constraint patches #includeEtc "caseDicts/setConstraintTypes"
inlet { type fixedValue; value $internalField; } outlet { type variableHeightFlowRate; lowerBound 0; upperBound 1; value $internalField; } atmosphere { type inletOutlet; inletValue $internalField; value $internalField; } barge { type zeroGradient; } }
// ************************************************************************* //
alphas
/--------------------------------- C++ -----------------------------------\
FoamFile { version 2.0; format ascii; class volScalarField; location "0"; object alphas; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 0 0 0 0 0 0];
internalField uniform 0;
boundaryField { //- Set patchGroups for constraint patches #includeEtc "caseDicts/setConstraintTypes"
inlet { type fixedValue; value $internalField; } outlet { type variableHeightFlowRate; lowerBound 0; upperBound 1; value $internalField; } atmosphere { type inletOutlet; inletValue $internalField; value $internalField; } barge { type zeroGradient; } }
// ************************************************************************* //
The above gives the following, wanted, distribtion of fluids for timestep 1
However, after several time the above changes, also at the inlet:
I really don't understand the contactAngle functino used in alpha.air above. I have tried with the following alpha.air
/--------------------------------- C++ -----------------------------------\
FoamFile { version 2.0; format ascii; class volScalarField; location "0"; object alpha.air; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dimensions [0 0 0 0 0 0 0];
internalField uniform 0;
boundaryField { //- Set patchGroups for constraint patches #includeEtc "caseDicts/setConstraintTypes"
inlet { type fixedValue; value $internalField; } outlet { type variableHeightFlowRate; lowerBound 0; upperBound 1; value $internalField; } atmosphere { type inletOutlet; inletValue $internalField; value $internalField; } barge { type zeroGradient; } }
// ************************************************************************* //
With the alpha.air above I get a long error message that includes stuff that is interpreted as internet links so that I am not allowed to pulblish them here. The error message can be seen on this link to the CDF-online forum, where I have also have asked this question.
Does anybvody know how to modify the above files to make the distribution of alpha's at the inlet constant?