I'm trying to simulate a Fan Filter Unit, when trying to model the HEPA filter at the output, I'm trying to impose the condition that for a small area, the outward velocity component builds up a pressure difference.
For example if the outflow velocity is 1m/s, the pressure on the inside surface of the filter is locally 10Pa; if the outflow is 2m/s, pressure inside is 20Pa.
This is different from the "type fanPressure" condition which sums the total flow rate, so I'm trying to use fixedCodedValue type condition.
the 0/p file contains this outlet patch:
Code:
out_hepaface
{
type codedFixedValue;
value $internalField;
name test;
code
#{
scalarField& pField = *this;
const vectorField& UFace = patch().lookupPatchField<volVectorField, vector>("U");
const vectorField& np = patch().nf();
int prop_coef = 1;
forAll(pField, faceI) {
pField[faceI] = prop_coef*UFace[faceI] & np[faceI];
}
#};
}
The 0/U file contains :
Code:
out_hepaface
{
type pressureInletOutletVelocity;
value $internalField;
inletValue $internalField;
}
The solver is simpleFoam, and with deltaT = 0.001, it still makes sigFpe errors.
I've been learning OpenFOAM for only about 2 weeks so if you could kindly explain in detail if anything doesn't make sense.