|
[Sponsors] |
April 1, 2014, 07:43 |
massflow of inlet and outlet are not equal
|
#1 |
New Member
Join Date: Mar 2014
Posts: 28
Rep Power: 12 |
Hello foamers!
In my mesh i have one inlet and one outlet, both have the same area. I set the BC as followed: -------------------------------------------------------------------------------- 0/U inlet { type flowRateInletVelocity; flowRate 0.02; value uniform (0 500 0); } outlet { type zeroGradient; } ----------------------------------------------------------------------------------------------------- 0/p inlet { type zeroGradient; } outlet { type fixedValue; value uniform 86000; } the massflows are then: MassFlows: inlet = 1.44 MassFlows: outlet = 0.880914 so they are not the same, but how can i tell the programm that the outlet massflow should be the same like the inlet massflow? Maybe somebody has an idea? |
|
April 1, 2014, 17:00 |
|
#2 |
Senior Member
Troy Snyder
Join Date: Jul 2009
Location: Akron, OH
Posts: 220
Rep Power: 19 |
Is your solver incompressible? If the solver is compressible, the mass flowrates may not be the same.
|
|
April 2, 2014, 07:07 |
|
#3 | |
New Member
Join Date: Mar 2014
Posts: 28
Rep Power: 12 |
Quote:
Yes my solver is compressible, but the massflow should be always the same because it is in kg/sec, so everything that is going in should also go out? so the massflow should be equal, but how do i can do that? |
||
April 3, 2014, 22:48 |
|
#4 |
New Member
Orry Shamash
Join Date: Apr 2014
Posts: 4
Rep Power: 12 |
mass flow rate is density*area*velocity
If this is incompressible flow, density shouldn't be a problem area isn't changing only thing changing velocity is friction if you disable viscous dissipation there should be no viscous forces and therefore no loss of flow rate |
|
April 4, 2014, 06:24 |
|
#5 |
Senior Member
Olivier
Join Date: Jun 2009
Location: France, grenoble
Posts: 272
Rep Power: 18 |
hello,
Just to add some entropy ... is you simulation transient ? by the way, you didn't tel give the solver name, neither other relevant info ... check http://www.cfd-online.com/Forums/ope...-get-help.html regards, olivier |
|
April 30, 2014, 19:22 |
|
#6 |
New Member
Join Date: Mar 2014
Posts: 28
Rep Power: 12 |
My flow is subsonic,
0/U: inlet type flowRateInletVelocity; outlet type zeroGradient; domain1 type temperatureDirectedInletVelocity; domain2 type symmetryPlane; domain3 type zeroGradient; 0/p: inlet zeroGradient; outlet type fixedValue; domain1 type zeroGradient; domain2 type symmetryPlane; domain3 type outletInlet; if i change the fixedValue of the pressure outlet i can change the outlet Massflow, but it never goes equal to the inlet massflow. Also after the calculation converged, the massflows are not equal. What should i change that is going to be equal? |
|
April 30, 2014, 19:52 |
|
#7 |
Senior Member
Troy Snyder
Join Date: Jul 2009
Location: Akron, OH
Posts: 220
Rep Power: 19 |
Regarding your initial post.
Is it possible that there may be an issue in specifying 500 in the second element of the 'value' array? What is the basis for making this 500 and not leaving as 0? Code:
Description Describes a volumetric/mass flow normal vector boundary condition by its magnitude as an integral over its area. The basis of the patch (volumetric or mass) is determined by the dimensions of the flux, phi. The current density is used to correct the velocity when applying the mass basis. Example of the boundary condition specification: \verbatim inlet { type flowRateInletVelocity; flowRate 0.2; // Volumetric/mass flow rate [m3/s or kg/s] value uniform (0 0 0); // placeholder } \endverbatim Note - The value is positive inwards - May not work correctly for transonic inlets - Strange behaviour with potentialFoam since the U equation is not solved |
|
May 1, 2014, 04:40 |
|
#8 |
New Member
Join Date: Mar 2014
Posts: 28
Rep Power: 12 |
hello tas38,
yes of course i can also write 0 instead of 500, the velocity at the inlet is just about 450m/s at the inlet. I think the velocity is calculated by the massflow at the inlet? |
|
May 1, 2014, 13:32 |
|
#9 |
New Member
Join Date: Mar 2014
Posts: 28
Rep Power: 12 |
i want to calculate the pressure with groovyBC.
type groovyBC; valueExpression "0.003/(sum(mag(Sf()))*(normal()&U))*287.058*(288.15-sqr(mag(U))/(2*1004.5))"; value uniform 90000; so that the massflow here 0.003 is the same like for the inlet, but they dont converge! |
|
July 3, 2018, 03:30 |
|
#10 |
Senior Member
Michael Alletto
Join Date: Jun 2018
Location: Bremen
Posts: 616
Rep Power: 16 |
Maybe it is a bit late. But did you solve the problem?
|
|
July 3, 2018, 10:28 |
|
#11 |
New Member
Join Date: Jun 2018
Posts: 20
Rep Power: 8 |
To the initial question: I suggest using type "inletOutlet" instead of "zeroGradient" as velocity bc for outlet.
|
|
July 3, 2018, 15:00 |
|
#12 |
Senior Member
Michael Alletto
Join Date: Jun 2018
Location: Bremen
Posts: 616
Rep Power: 16 |
I have a really simple test case. I have a 2D oscillating cylinder in a fluid at rest. The flow is laminar. The boundary conditions are: /*--------------------------------*- C++ -*----------------------------------*\
| ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: plus | | \\ / A nd | Web: www.OpenFOAM.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class volScalarField; object p; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // #include "include/initialConditions" dimensions [0 2 -2 0 0 0 0]; internalField uniform $pressure; boundaryField { #includeEtc "caseDicts/setConstraintTypes" overset { type overset; } wall { type zeroGradient; } inlet { type totalPressure; rho none; p0 uniform 0; value uniform 0; // Optional entries U U; phi phi; } outlet { type totalPressure; rho none; p0 uniform 0; value uniform 0; // Optional entries U U; phi phi; } topAndBottom { type fixedValue; value uniform 0; } } // ************************************************** *********************** // /*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: plus | | \\ / A nd | Web: www.OpenFOAM.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class volVectorField; object U; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // #include "include/initialConditions" dimensions [0 1 -1 0 0 0 0]; internalField uniform (0 0 0); boundaryField { #includeEtc "caseDicts/setConstraintTypes" overset { type overset; } walls { type movingWallVelocity; value uniform (0 0 0); } inlet { type pressureInletOutletVelocity; value uniform (0 0 0); phi phi; } outlet { type pressureInletOutletVelocity; value uniform (0 0 0); phi phi; } topAndBottom { type fixedValue; value uniform (0 0 0); } } // ************************************************** *********************** // The fvSolution dict is : /*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: plus | | \\ / A nd | Web: www.OpenFOAM.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class dictionary; object fvSolution; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // solvers { cellDisplacement { solver PCG; preconditioner DIC; tolerance 1e-06; relTol 0; maxIter 100; } p { solver PBiCGStab; preconditioner DILU; tolerance 1e-5; relTol 0.1; } pFinal { solver PBiCGStab; preconditioner DILU; tolerance 1e-6; relTol 0.; } pcorr { $pFinal; solver PCG; preconditioner DIC; tolerance 1e-7; } pcorrFinal { $pcorr; relTol 0; tolerance 1e-7; } "(U|k|epsilon)" { solver smoothSolver; smoother symGaussSeidel; tolerance 1e-6; relTol 0.01; } "(U|k|epsilon)Final" { $U; tolerance 1e-6; relTol 0; } } PIMPLE { momentumPredictor true; correctPhi true; nOuterCorrectors 25; nCorrectors 1; nNonOrthogonalCorrectors 2; massFluxInterpolation true; ddtCorr true; turbOnFinalIterOnly false; } relaxationFactors { fields { p 0.3; } equations { "(U|k|omega)" 0.7; ".*Final" 1.0; } } // ************************************************** *********************** // the solver i use is overPimpleDyMFoam. The strange thing is that when I compare inflow and outflow mass flow the absolut value is not equal. The difference is of a factor two. I have no clue what went wrong. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
mass flow of inlet and outlet is not equal | datouguaiguai | STAR-CCM+ | 2 | March 25, 2014 10:29 |
define BCs at inlet and outlet for natural ventilation simulation | jjz2013 | Main CFD Forum | 0 | January 29, 2013 16:50 |
ATTENTION! Reliability problems in CFX 5.7 | Joseph | CFX | 14 | April 20, 2010 16:45 |
boundary condition inlet equal outlet | jpinho | FLUENT | 6 | July 2, 2009 11:09 |
what the result is negatif pressure at inlet | chong chee nan | FLUENT | 0 | December 29, 2001 06:13 |