Open Mileseee opened 3 years ago
This is correct. I added the temperature depended surface tension for completeness and neglected this term in the current implementation. This should be pointed out in the documentation.
How is the temperatureDependent model setup/selected in a case?
I want use a general polynomial for the calculation of sigma, I've tried the below in thermophysicalProperties but dont think this is correct. I'm modifying the fixed flux test case for multiRegionPhaseChangeFlow.
sigma{
type temperatureDependent;
sigma polynomial
(
(0.001 1)
(-4e-4 2)
);
};
surfaceForces
{
sigma 0.01;
surfaceTensionForceModel gradAlpha;
accelerationModel gravity;
deltaFunctionModel alphaCSF;
}
surfaceForces
{
sigma
{
type test;
sigma 0.07;
}
surfaceTensionForceModel gradAlpha;
accelerationModel gravity;
deltaFunctionModel alphaCSF;
}
outputs:
--> FOAM FATAL IO ERROR: (openfoam-2106)
Unknown surfaceTensionModel type test
Valid surfaceTensionModel types :
3(constant liquidProperties temperatureDependent)
Makes sense, but how do you prescribe the function of temperature for sigma?
sigma
{
type temperatureDependent;
sigma 0.07; %how does this translate to a function of T?
}
There is only one coefficient, and two are needed for mX+B form
sigma is a Function1:
sigma is a function of the temperature. You can specify it as polynomial:
sigma{
type temperatureDependent;
sigma polynomial
(
(0.001 1)
(-4e-4 2)
);
};
sigma{
type temperatureDependent;
sigma test; // crashes a gives options
};
details: https://www.openfoam.com/documentation/guides/latest/api/classFoam_1_1Function1.html
It doesnt seem to work with multiRegionPhaseChangeFlow, the solver crashes immediately. Below is the thermophysicalProperties file for testsuite/cht/fixedFlux.
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
phases (water air);
pMin pMin [ 1 -1 -2 0 0 0 0 ] 10000;
sigma sigma [ 1 0 -2 0 0 0 0 ] 0;
TMin TMin [ 0 0 0 1 0 0 0 ] 50;
TMax TMax [ 0 0 0 1 0 0 0 ] 500;
water
{
type pureMovingPhaseModel;
}
air
{
type pureMovingPhaseModel;
}
surfaceForces
{
sigma
{
type temperatureDependent;
sigma polynomial
(
(0.001 1)
(-4e-4 2)
);
}
surfaceTensionForceModel gradAlpha;
accelerationModel gravity;
deltaFunctionModel alphaCSF;
}
// ************************************************************************* //
The sample case depthCharge2D for compressibleInterFoam works fine with this
phases (water air);
pMin 10000;
sigma
{
type temperatureDependent;
sigma polynomial
(
(0.001 1)
(-4e-4 2)
);
}
The temperature in testsuite/cht/fixedFlux is 373 K so we get a sigma of:
sigma = 0.001*T - 4e-4*T**2 = -55
This should cause a crash in the maxCapillaryNum (negative value under the root). However, this is not implemented in compressibleInterFoam:
You can write out fields, here sigma, from the registry with volFieldValue with:
writeFields true;
Now, you can check with paraview if the values are correct
https://www.openfoam.com/documentation/guides/latest/doc/guide-fos-field-volFieldValue.html https://develop.openfoam.com/Development/openfoam/-/blob/master/tutorials/multiphase/icoReactingMultiphaseInterFoam/poolEvaporation/system/controlDict
If sigma is temperatureDependent, then there may a tangential gradient of sigma. Perhaps surfaceTensionForce() in surfaceTensionForceModel.H is lack of the tangential gradient term?