|
[Sponsors] |
June 14, 2019, 12:14 |
chtMultiRegionSimpleFoam and Turbulent Flow
|
#1 |
Senior Member
Raza Javed
Join Date: Apr 2019
Location: Germany
Posts: 183
Rep Power: 7 |
Hello Everyone,
I am using chtMultiRegionSimpleFoam and my openfoam version is 4.1. My geometry consists of one fluid region and some other solid regions. And there is a laminar flow in the fluid region. But when I try to model turbulent flow, then I put k and epsilon into my boundary conditions. and then I change the turbulence properties from laminar to RAS. But when I run the solver, it gives the following error: Code:
--> FOAM FATAL IO ERROR: cannot find file file: /home/openfoam/run/final_geometry_turbulent/0/fluid/alphat at line 0. From function regIOobject::readStream() in file db/regIOobject/regIOobjectRead.C at line 72. But I take this file from one tutorial case and put it into 0 directory. and also put it into system/changeDictionaryDict for boundary conditions. My changeDictionaryDict is given below: Code:
boundary { inlet { type patch; } outlet { type patch; } } T { internalField uniform 300; boundaryField { inlet { type fixedValue; value $internalField; } outlet { type zeroGradient; value $internalField; } "fluid_to_box" { type compressible::turbulentTemperatureCoupledBaffleMixed; Tnbr T; kappaMethod fluidThermo; value uniform 300; } } } U { internalField uniform (0 0 0); boundaryField { inlet { type fixedValue; value uniform (0 0 -1e-4); } outlet { type zeroGradient; } "fluid_to_box" { type noSlip; } } } epsilon { internalField uniform 0.01; boundaryField { inlet { type fixedValue; value uniform 0.01; } outlet { type inletOutlet; inletValue uniform 0.01; } ".*" { type epsilonWallFunction; value uniform 0.01; } } } k { internalField uniform 0.1; boundaryField { inlet { type inletOutlet; inletValue uniform 0.1; } outlet { type zeroGradient; value uniform 0.1; } ".*" { type kqRWallFunction; value uniform 0.1; } } } p_rgh { internalField uniform 0; boundaryField { inlet { type zeroGradient; value uniform 0; } outlet { type fixedValue; value uniform 0; } ".*" { type fixedFluxPressure; value uniform 0; } } } p { internalField uniform 0; boundaryField { ".*" { type calculated; value uniform 0; } } } alphat { internalField uniform 0; boundaryField { inlet { type calculated; value uniform 0; } outlet { type calculated; value uniform 0; } "fluid_to_.*" { type compressible::alphatWallFunction; value uniform 0; } #includeEtc "caseDicts/setConstraintTypes" } } nut { internalField uniform 0; boundaryField { inlet { type calculated; value uniform 0; } outlet { type calculated; value uniform 0; } "fluid_to_.*" { type nutkWallFunction; value uniform 0; } #includeEtc "caseDicts/setConstraintTypes" } } // ************************************************************************* // Code:
--> FOAM FATAL ERROR: cannot be called for a calculatedFvPatchField on patch inlet of field U in file "/home/openfoam/run/final_geometry_turbulent/0/fluid/U" You are probably trying to solve for a field with a default boundary condition. From function Foam::tmp<Foam::Field<Type> > Foam::calculatedFvPatchField<Type>::gradientInternalCoeffs() const [with Type = Foam::Vector<double>] in file fields/fvPatchFields/basic/calculated/calculatedFvPatchField.C at line 187. FOAM aborting #0 Foam::error::printStack(Foam::Ostream&)*** Reading solid mesh thermophysical properties for region hot2 Adding to thermos Selecting thermodynamics package { type heSolidThermo; mixture pureMixture; transport constIso; thermo hConst; equationOfState rhoConst; specie specie; energy sensibleEnthalpy; } Adding to radiations Radiation model not active: radiationProperties not found Selecting radiationModel none Adding fvOptions Creating finite volume options from "constant/fvOptions" Selecting finite volume options model type scalarSemiImplicitSource Source: heatSource - selecting all cells - selected 939 cell(s) with volume 1.4e-06 *** Reading solid mesh thermophysical properties for region hot3 Adding to thermos Selecting thermodynamics package { type heSolidThermo; mixture pureMixture; transport constIso; thermo hConst; equationOfState rhoConst; specie specie; energy sensibleEnthalpy; } Adding to radiations Radiation model not active: radiationProperties not found Selecting radiationModel none Adding fvOptions Creating finite volume options from "constant/fvOptions" Selecting finite volume options model type scalarSemiImplicitSource Source: heatSource - selecting all cells - selected 921 cell(s) with volume 1.4e-06 Time = 0.01 Solving for fluid region fluid at ??:? #1 Foam::error::abort() at ??:? #2 Foam::calculatedFvPatchField<Foam::Vector<double> >::gradientInternalCoeffs() const at ??:? #3 Foam::fv::gaussLaplacianScheme<Foam::Vector<double>, Foam::SymmTensor<double> >::fvmLaplacianUncorrected(Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&) at ??:? #4 Foam::fv::gaussLaplacianScheme<Foam::Vector<double>, double>::fvmLaplacian(Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&) at ??:? #5 Foam::fv::laplacianScheme<Foam::Vector<double>, double>::fvmLaplacian(Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&) at ??:? #6 Foam::tmp<Foam::fvMatrix<Foam::Vector<double> > > Foam::fvm::laplacian<Foam::Vector<double>, double>(Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::word const&) at ??:? #7 Foam::tmp<Foam::fvMatrix<Foam::Vector<double> > > Foam::fvm::laplacian<Foam::Vector<double>, double>(Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&) at ??:? #8 Foam::tmp<Foam::fvMatrix<Foam::Vector<double> > > Foam::fvm::laplacian<Foam::Vector<double>, double>(Foam::tmp<Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> > const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&) at ??:? #9 Foam::linearViscousStress<Foam::RASModel<Foam::EddyDiffusivity<Foam::ThermalDiffusivity<Foam::CompressibleTurbulenceModel<Foam::fluidThermo> > > > >::divDevRhoReff(Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh>&) const at ??:? #10 ? at ??:? #11 __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6" #12 ? at ??:? Aborted (core dumped) Can someone please help me in understanding the problem here. I shall be very thankful if someone can help. Thank you Last edited by Raza Javed; June 15, 2019 at 15:14. |
|
June 17, 2019, 05:29 |
|
#2 |
Member
Join Date: Mar 2016
Posts: 73
Rep Power: 10 |
Yout nut and alphat look okay. What I noticed is, that a lot of entries for internalField are set to 0. Including pressure, nut and alphat.
Maybe your initial field is not a good start. Try using realistic initial values or patch the field with setFields. |
|
June 17, 2019, 05:37 |
|
#3 |
Senior Member
Raza Javed
Join Date: Apr 2019
Location: Germany
Posts: 183
Rep Power: 7 |
Thank you so much for your reply.
I have one more question: I try to explain my problem. I am using chtMultiRegionSimpleFoam. My Openfoam version is 4.1. I made my geometry in salome, and then imported to OpenFoam as a UNV file. I have multiple regions in my geometry, (heaters, box, and fluid). Both heaters and fluid are in the box. Now, I want to simulate the turbulent flow in the fluid region. I am using kEpsilon Model. I am trying to model incompressible flow. I put boundary conditions for alphat, k, epsilon, nut etc in system/fluid/changeDictionaryDict file. This file is shown below: Code:
boundary { inlet { type patch; } outlet { type patch; } } T { internalField uniform 300; boundaryField { inlet { type fixedValue; value $internalField; } outlet { type zeroGradient; value $internalField; } "fluid_to_box" { type zeroGradient; } } } U { internalField uniform (0 0 0); boundaryField { inlet { type fixedValue; value uniform (0 0 -1.33); } outlet { type zeroGradient; } "fluid_to_box" { type noSlip; } } } epsilon { internalField uniform 0.01; boundaryField { inlet { type fixedValue; value uniform 0.01; } outlet { type zeroGradient; //value uniform 0; } ".*" { type epsilonWallFunction; value uniform 0.01; } } } k { internalField uniform 0.1; boundaryField { inlet { type fixedValue; value uniform 0.1; } outlet { type zeroGradient; //value uniform 0; } "fluid_to_box" { type kqRWallFunction; value uniform 0.1; } } } p_rgh { internalField uniform 0; boundaryField { inlet { type zeroGradient; value uniform 0; } outlet { type fixedValue; value uniform 0; } ".*" { type fixedFluxPressure; value uniform 0; } } } p { internalField uniform 0; boundaryField { ".*" { type calculated; value uniform 0; } } } alphat { internalField uniform 0; boundaryField { inlet { type calculated;//fixedValue; value uniform 0; } outlet { type calculated; value uniform 0; } "fluid_to_box" { type alphatJayatillekeWallFunction; value uniform 0; } } } nut { internalField uniform 0; boundaryField { inlet { type calculated; value uniform 0; } outlet { type calculated; value uniform 0; } "fluid_to_box" { type nutkWallFunction; value uniform 0; } } } // ************************************************************************* // Now, I have the following doubts: 1. How and where actually we define that out flow would be incompressible? 2. As you can see in the file above, in the alphat portion, for the boundary fluid_to_box, I have put the wall function. before it was compressible written before the wall function, but I removed it because I am trying to simulate incompressible. But it gave error that: Code:
--> FOAM FATAL IO ERROR: Unknown patchField type alphatJayatillekeWallFunction for patch type mappedWall Valid patchField types are : 112 ( MarshakRadiation MarshakRadiationFixedTemperature advective atmBoundaryLayerInletEpsilon atmBoundaryLayerInletK calculated codedFixedValue codedMixed compressible::alphatJayatillekeWallFunction compressible::alphatWallFunction compressible::thermalBaffle1D<hConstSolidThermoPhysics> compressible::thermalBaffle1D<hPowerSolidThermoPhysics> compressible::turbulentHeatFluxTemperature compressible::turbulentTemperatureCoupledBaffleMixed compressible::turbulentTemperatureRadCoupledMixed convectiveHeatTransfer cyclic cyclicACMI cyclicAMI cyclicSlip directionMixed empty energyJump energyJumpAMI epsilonLowReWallFunction epsilonWallFunction externalCoupled externalCoupledTemperature externalWallHeatFluxTemperature extrapolatedCalculated fWallFunction fan fanPressure fixedEnergy fixedFluxExtrapolatedPressure fixedFluxPressure fixedGradient fixedInternalValue fixedJump fixedJumpAMI fixedMean fixedPressureCompressibleDensity fixedProfile fixedUnburntEnthalpy fixedValue freestream freestreamPressure gradientEnergy gradientUnburntEnthalpy greyDiffusiveRadiation greyDiffusiveRadiationViewFactor inletOutlet inletOutletTotalTemperature kLowReWallFunction kqRWallFunction mapped mappedField mappedFixedInternalValue mappedFixedPushedInternalValue mixed mixedEnergy mixedUnburntEnthalpy nonuniformTransformCyclic nutLowReWallFunction nutTabulatedWallFunction nutURoughWallFunction nutUSpaldingWallFunction nutUWallFunction nutkAtmRoughWallFunction nutkRoughWallFunction nutkWallFunction omegaWallFunction outletInlet outletMappedUniformInlet partialSlip phaseHydrostaticPressure plenumPressure porousBafflePressure prghPressure prghTotalHydrostaticPressure prghTotalPressure processor processorCyclic rotatingTotalPressure sliced slip symmetry symmetryPlane syringePressure timeVaryingMappedFixedValue totalFlowRateAdvectiveDiffusive totalPressure totalTemperature turbulentInlet turbulentIntensityKineticEnergyInlet turbulentMixingLengthDissipationRateInlet turbulentMixingLengthFrequencyInlet uniformDensityHydrostaticPressure uniformFixedGradient uniformFixedValue uniformInletOutlet uniformJump uniformJumpAMI uniformTotalPressure v2WallFunction variableHeightFlowRate wallHeatTransfer waveSurfacePressure waveTransmissive wedge wideBandDiffusiveRadiation zeroGradient ) 4. Can I use other boundary conditions, other than wallfunctions on this boundary fluid_to_box(mappedwall)? I tried to explain my problem, but if you need any other information, I would be happy to give. Thank you |
|
Tags |
openfoam, turbulence and laminar, turbulence modelling |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Issues on the simulation of high-speed compressible flow within turbomachinery | dowlee | OpenFOAM Running, Solving & CFD | 11 | August 6, 2021 07:40 |
Problem with divergence | TDK | FLUENT | 13 | December 14, 2018 07:00 |
About Some Concepts:Laminar flow, turbulent flow, steady flow and time-dependent flow | Jing | Main CFD Forum | 8 | October 5, 2018 18:02 |
Why can i use a laminar solver for a turbulent flow? [Heat transfer problem] | blackbow | CFX | 1 | November 22, 2016 05:42 |
Ratio of eddy viscosity to molecular viscosity : Laminar or turbulent flow? | JuPa | CFX | 7 | September 9, 2013 08:45 |