CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Fatal error: invalid wall function specification

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree6Likes
  • 1 Post By RobertHB
  • 1 Post By RobertHB
  • 3 Post By RobertHB
  • 1 Post By gkarlsen

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 19, 2018, 06:24
Default Fatal error: invalid wall function specification
  #1
New Member
 
Jesse Cheung
Join Date: Apr 2018
Posts: 18
Rep Power: 6
kcc49 is on a distinguished road
Hello all,

I am currently trying to run a RAS simulation based on the damBreak tutorial, it shows following text when I'm trying to run it. Is there any way to solve it? Because I have tried the same model in laminar dam break and it works well.


Code:
Selecting incompressible transport model Newtonian
Selecting incompressible transport model Newtonian
Selecting turbulence model type RAS
Selecting RAS turbulence model kEpsilon
[2] 
[2] 
[2] --> FOAM FATAL ERROR: 
[2] Invalid wall function specification
    Patch type for patch slope must be wall
    Current patch type is genericPatch

[2] 
[2] 
[2]     From function virtual void Foam::nutWallFunctionFvPatchScalarField::checkType()
[2]     in file derivedFvPatchFields/wallFunctions/nutWallFunctions/nutWallFunction/nutWallFunctionFvPatchScalarField.C[3]  at line 45.
[2] 
FOAM parallel run aborting
[2] 

[3] 
[3] --> FOAM FATAL ERROR: 
[3] Invalid wall function specification
    Patch type for patch slope must be wall
    Current patch type is genericPatch

[3] 
[3] [1] 
[1] 
[1] --> FOAM FATAL ERROR: 
[1] Invalid wall function specification
    Patch type for patch slope must be wall
    Current patch type is genericPatch

[1] 
[1] 
[1]     From function virtual void Foam::nutWallFunctionFvPatchScalarField::checkType()
[1]     in file derivedFvPatchFields/wallFunctions/nutWallFunctions/nutWallFunction/nutWallFunctionFvPatchScalarField.C at line 45.
[1] 
FOAM parallel run aborting
[1] 

[3]     From function virtual void Foam::nutWallFunctionFvPatchScalarField::checkType()
[3]     in file derivedFvPatchFields/wallFunctions/nutWallFunctions/nutWallFunction/nutWallFunctionFvPatchScalarField.C at line 45.
[3] 
FOAM parallel run aborting
[3] 
[1] #0  Foam::error::printStack(Foam::Ostream&)[3] #0  Foam::error::printStack(Foam::Ostream&)[2] #0  Foam::error::printStack(Foam::Ostream&)[0] 
[0] 
[0] --> FOAM FATAL ERROR: 
[0] Invalid wall function specification
    Patch type for patch slope must be wall
    Current patch type is genericPatch

[0] 
[0] 
[0]     From function virtual void Foam::nutWallFunctionFvPatchScalarField::checkType()
[0]     in file derivedFvPatchFields/wallFunctions/nutWallFunctions/nutWallFunction/nutWallFunctionFvPatchScalarField.C at line 45.
[0] 
FOAM parallel run aborting
[0] 
[0] #0  Foam::error::printStack(Foam::Ostream&) at ??:?
[2] #1  Foam::error::abort() at ??:?
[1] #1  Foam::error::abort() at ??:?
[3] #1  Foam::error::abort() at ??:?
[0] #1  Foam::error::abort() at ??:?
[1] #2  Foam::nutWallFunctionFvPatchScalarField::nutWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[3] #2  Foam::nutWallFunctionFvPatchScalarField::nutWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[2] #2  Foam::nutWallFunctionFvPatchScalarField::nutWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[0] #2  Foam::nutWallFunctionFvPatchScalarField::nutWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[1] #3  Foam::nutkWallFunctionFvPatchScalarField::nutkWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[2] #3  Foam::nutkWallFunctionFvPatchScalarField::nutkWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[3] #3  Foam::nutkWallFunctionFvPatchScalarField::nutkWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[0] #3  Foam::nutkWallFunctionFvPatchScalarField::nutkWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[1] #4  Foam::nutkRoughWallFunctionFvPatchScalarField::nutkRoughWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[3] #4  Foam::nutkRoughWallFunctionFvPatchScalarField::nutkRoughWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[2] #4  Foam::nutkRoughWallFunctionFvPatchScalarField::nutkRoughWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[0] #4  Foam::nutkRoughWallFunctionFvPatchScalarField::nutkRoughWallFunctionFvPatchScalarField(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[1] #5  Foam::fvPatchField<double>::adddictionaryConstructorToTable<Foam::nutkRoughWallFunctionFvPatchScalarField>::New(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[2] #5  Foam::fvPatchField<double>::adddictionaryConstructorToTable<Foam::nutkRoughWallFunctionFvPatchScalarField>::New(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[0] #5  Foam::fvPatchField<double>::adddictionaryConstructorToTable<Foam::nutkRoughWallFunctionFvPatchScalarField>::New(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[3] #5  Foam::fvPatchField<double>::adddictionaryConstructorToTable<Foam::nutkRoughWallFunctionFvPatchScalarField>::New(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[1] #6   at ??:?
[3] #6   at ??:?
[2] #6   at ??:?
[0] #6  Foam::fvPatchField<double>::New(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&)Foam::fvPatchField<double>::New(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&)Foam::fvPatchField<double>::New(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&)Foam::fvPatchField<double>::New(Foam::fvPatch const&, Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[1] #7   at ??:?
[3] #7   at ??:?
[2] #7   at ??:?
[0] #7  Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::Boundary::readField(Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&)Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::Boundary::readField(Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&)Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::Boundary::readField(Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&)Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::Boundary::readField(Foam::DimensionedField<double, Foam::volMesh> const&, Foam::dictionary const&) at ??:?
[3] #8   at ??:?
[1] #8   at ??:?
[2] #8   at ??:?
[0] #8  Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::readFields(Foam::dictionary const&)Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::readFields(Foam::dictionary const&)Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::readFields(Foam::dictionary const&)Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::readFields(Foam::dictionary const&) at ??:?
[1] #9   at ??:?
[3] #9   at ??:?
[0] #9  Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::readFields() at ??:?
[2] #9  Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::readFields()Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::readFields()Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::readFields() at ??:?
[3] #10  ? at ??:?
[1] #10  ? at ??:?
[2] #10  ? at ??:?
[0] #10  ? at turbulentTransportModels.C:?
[1] #11  Foam::eddyViscosity<Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::eddyViscosity(Foam::word const&, Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at turbulentTransportModels.C:?
[3] #11  Foam::eddyViscosity<Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::eddyViscosity(Foam::word const&, Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at turbulentTransportModels.C:?
[0] #11  Foam::eddyViscosity<Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::eddyViscosity(Foam::word const&, Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at turbulentTransportModels.C:?
[2] #11  Foam::eddyViscosity<Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::eddyViscosity(Foam::word const&, Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at ??:?
[1] #12  Foam::RASModels::kEpsilon<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::kEpsilon(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&, Foam::word const&) at ??:?
[3] #12  Foam::RASModels::kEpsilon<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::kEpsilon(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&, Foam::word const&) at ??:?
[0] #12  Foam::RASModels::kEpsilon<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::kEpsilon(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&, Foam::word const&) at ??:?
 at ??:?
[1] [2] #12  #13  Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::adddictionaryConstructorToTable<Foam::RASModels::kEpsilon<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::New(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&)Foam::RASModels::kEpsilon<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::kEpsilon(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&, Foam::word const&) at ??:?
[3] #13  Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::adddictionaryConstructorToTable<Foam::RASModels::kEpsilon<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::New(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at ??:?
[0] #13  Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::adddictionaryConstructorToTable<Foam::RASModels::kEpsilon<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::New(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at ??:?
[1] #14  Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::New(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at ??:?
[2] #13  Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::adddictionaryConstructorToTable<Foam::RASModels::kEpsilon<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::New(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at ??:?
[3] #14  Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::New(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at ??:?
[1] #15  Foam::TurbulenceModel<Foam::geometricOneField, Foam::geometricOneField, Foam::incompressibleTurbulenceModel, Foam::transportModel>::adddictionaryConstructorToTable<Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::NewTurbulenceModel(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at ??:?
[0] # at ??:?
[2] #14  14  Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::New(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&)Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> >::New(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at ??:?
[3] #15  Foam::TurbulenceModel<Foam::geometricOneField, Foam::geometricOneField, Foam::incompressibleTurbulenceModel, Foam::transportModel>::adddictionaryConstructorToTable<Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::NewTurbulenceModel(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at ??:?
[1] #16   at ??:?
[0] #15  Foam::TurbulenceModel<Foam::geometricOneField, Foam::geometricOneField, Foam::incompressibleTurbulenceModel, Foam::transportModel>::adddictionaryConstructorToTable<Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::NewTurbulenceModel(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at ??:?
[2] #15  Foam::TurbulenceModel<Foam::geometricOneField, Foam::geometricOneField, Foam::incompressibleTurbulenceModel, Foam::transportModel>::adddictionaryConstructorToTable<Foam::RASModel<Foam::IncompressibleTurbulenceModel<Foam::transportModel> > >::NewTurbulenceModel(Foam::geometricOneField const&, Foam::geometricOneField const&, Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::GeometricField<double, Foam::fvsPatchField, Foam::surfaceMesh> const&, Foam::transportModel const&, Foam::word const&) at ??:?
[3] #16  ?? at ??:?
[2] #16   at ??:?
[0] #16   at ??:?
[1] #17  ? at ??:?
[3] #17  ??? at ??:?
[2] #17   at ??:?
[1] #18  __libc_start_main at ??:?
[0] #17  ? at ??:?
[3] #18  __libc_start_main? in "/lib64/libc.so.6"
[1] #19   at ??:?
[2] #18  __libc_start_main in "/lib64/libc.so.6"
[3] #19  ? at ??:?
[0] #18  __libc_start_main? at ??:?
--------------------------------------------------------------------------
MPI_ABORT was invoked on rank 1 in communicator MPI_COMM_WORLD 
with errorcode 1.
the whole file is uploaded to google drive : https://drive.google.com/open?id=1t5...LYkrJXbRSQeAxI
kcc49 is offline   Reply With Quote

Old   April 19, 2018, 06:35
Default
  #2
Senior Member
 
Robert
Join Date: May 2015
Location: Bremen, GER
Posts: 292
Rep Power: 10
RobertHB is on a distinguished road
Quote:
Originally Posted by kcc49 View Post
Code:
[2] --> FOAM FATAL ERROR: 
[2] Invalid wall function specification
    Patch type for patch slope must be wall
    Current patch type is genericPatch
Hey Jesse, it's all right in the error log:
Line 1: FOAM FATAL ERROR: The model can't run with such a setup
Line 2: You are incorrectly trying to specify a wall function
Line 3: The patch type of patch slope required for the wall function to work: wall
Line 4: Your current patch type: genericPatch

Solution: Go into your blockMeshDict and change to patch type from genericPatch to wall.

/edit: The reason why it works in laminar but not in RAS: The laminar model doesn't require a nut field, thus not a nut wall function, and therefore it doesn't matter what the patch type is. The boundary condition of U, i'd guess fixedValue (0 0 0), can be applied to walls as well as to patches.
/e2: Blue text.
tukkuezgi likes this.
RobertHB is offline   Reply With Quote

Old   April 19, 2018, 06:41
Default
  #3
New Member
 
Jesse Cheung
Join Date: Apr 2018
Posts: 18
Rep Power: 6
kcc49 is on a distinguished road
Quote:
Originally Posted by RobertHB View Post
Hey Jesse, it's all right in the error log:
Line 1: You are incorrectly trying to specify a wall function.
Line 2: The patch type required for the wall function to work: wall
Line 3: Your current patch type: genericPatch

Solution: Go into your blockMeshDict and change to patch type from genericPatch to wall.
My blockMeshDict is shown below:
Code:
/*--------------------------------*- 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      blockMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

scale   0.146;

vertices
(
    (0 0 0)
    (2 0 0)
    (2.16438 0 0)
    (4 0 0)
    (0 0.32876 0)
    (2 0.32876 0)
    (2.16438 0.32876 0)
    (4 0.32876 0)
    (0 4 0)
    (2 4 0)
    (2.16438 4 0)
    (4 4 0)
    (0 0 0.1)
    (2 0 0.1)
    (2.16438 0 0.1)
    (4 0 0.1)
    (0 0.32876 0.1)
    (2 0.32876 0.1)
    (2.16438 0.32876 0.1)
    (4 0.32876 0.1)
    (0 4 0.1)
    (2 4 0.1)
    (2.16438 4 0.1)
    (4 4 0.1)
);

blocks
(
    hex (0 1 5 4 12 13 17 16) (23 8 1) simpleGrading (1 1 1)
    hex (2 3 7 6 14 15 19 18) (19 8 1) simpleGrading (1 1 1)
    hex (4 5 9 8 16 17 21 20) (23 42 1) simpleGrading (1 1 1)
    hex (5 6 10 9 17 18 22 21) (4 42 1) simpleGrading (1 1 1)
    hex (6 7 11 10 18 19 23 22) (19 42 1) simpleGrading (1 1 1)
);

edges
(
);

boundary
(
    leftWall
    {
        type wall;
        faces
        (
            (0 12 16 4)
            (4 16 20 8)
        );
    }
    rightWall
    {
        type wall;
        faces
        (
            (7 19 15 3)
            (11 23 19 7)
        );
    }
    lowerWall
    {
        type wall;
        faces
        (
            (0 1 13 12)
            (1 5 17 13)
            (5 6 18 17)
            (2 14 18 6)
            (2 3 15 14)
        );
    }
    atmosphere
    {
        type patch;
        faces
        (
            (8 20 21 9)
            (9 21 22 10)
            (10 22 23 11)
        );
    }
);

mergePatchPairs
(
);

// ************************************************************************* //
I cant find genericPatch in my blockMeshDict. Did I miss something?
kcc49 is offline   Reply With Quote

Old   April 19, 2018, 06:50
Default
  #4
Senior Member
 
Robert
Join Date: May 2015
Location: Bremen, GER
Posts: 292
Rep Power: 10
RobertHB is on a distinguished road
From looking at your other thread:
Your nut file needs boundary conditions for all patches defined in the blockMeshDict. In your case: leftWall, rightWall, lowerWall, atmosphere.
But in your nut file are: slope, house, wall

So try something like this:
Code:
boundaryField
{
    "(leftWall|rightWall|lowerWall)"
    {
        type            nutkWallFunction;
        value           uniform 0;
    }
    
    atmosphere
    {
        type            slip;
    }    
}
/edit: The ("text|text|text)" is used to specify multiple patches with the same BC. You could also do seperate entries for each of those.
RobertHB is offline   Reply With Quote

Old   April 19, 2018, 07:16
Default
  #5
New Member
 
Jesse Cheung
Join Date: Apr 2018
Posts: 18
Rep Power: 6
kcc49 is on a distinguished road
Quote:
Originally Posted by RobertHB View Post
From looking at your other thread:
Your nut file needs boundary conditions for all patches defined in the blockMeshDict. In your case: leftWall, rightWall, lowerWall, atmosphere.
But in your nut file are: slope, house, wall

So try something like this:
Code:
boundaryField
{
    "(leftWall|rightWall|lowerWall)"
    {
        type            nutkWallFunction;
        value           uniform 0;
    }
    
    atmosphere
    {
        type            slip;
    }    
}
/edit: The ("text|text|text)" is used to specify multiple patches with the same BC. You could also do seperate entries for each of those.
Actually, I am using wall, slope, house in my case, should I change the blockmeshdict like following :

Code:
boundary
(
    wall
    {
        type wall;
        faces
        (
            (0 12 16 4)
            (4 16 20 8)
        );
    }
    slope
    {
        type wall;
        faces
        (
            (7 19 15 3)
            (11 23 19 7)
        );
    }
    house
    {
        type wall;
        faces
        (
            (0 1 13 12)
            (1 5 17 13)
            (5 6 18 17)
            (2 14 18 6)
            (2 3 15 14)
        );
    }
    atmosphere
    {
        type patch;
        faces
        (
            (8 20 21 9)
            (9 21 22 10)
            (10 22 23 11)
        );
    }
);

mergePatchPairs
(
);

// ************************************************************************* //
kcc49 is offline   Reply With Quote

Old   April 19, 2018, 08:12
Default
  #6
New Member
 
Jesse Cheung
Join Date: Apr 2018
Posts: 18
Rep Power: 6
kcc49 is on a distinguished road
Hello Robert,

I have done some research and find out the blockmeshdict is not related to this situation as I didn't use the command blockmesh. but instead, I used ideasUnvToFoam to apply the mesh to the case, in which the mesh is generated through SALOME platform. The whole file is uploaded to google drive : https://drive.google.com/open?id=1t5...LYkrJXbRSQeAxI

Do you have any advice for given situation?

your help genuinely help a lot!

many thanks,
Jesse
kcc49 is offline   Reply With Quote

Old   April 19, 2018, 08:48
Default
  #7
Senior Member
 
Robert
Join Date: May 2015
Location: Bremen, GER
Posts: 292
Rep Power: 10
RobertHB is on a distinguished road
Note (13:52 hours): I have edited the first version of this post which was generic to match your case.

That complicates things, but i think there might be a solution. After converting your salome mesh to OpenFoam it will generate a constant/polyMesh folder. In this folder is a file called boundary.
The entry looks likes this:
Code:
    slope
    {
        type            slope;
        nFaces          960;
        startFace       247728;
    }

    house
    {
        type            house;
        nFaces          96;
        startFace       248688;
    }
OpenFoam will not recognize type slope and type house. Try changing the patch type to wall.
kcc49 likes this.
RobertHB is offline   Reply With Quote

Old   April 19, 2018, 09:22
Default
  #8
New Member
 
Jesse Cheung
Join Date: Apr 2018
Posts: 18
Rep Power: 6
kcc49 is on a distinguished road
Thanks!!!!

Finally, it works!!!!!

Thank you so much for your help I wouldn't have made it without you

I will definitely credit you in my work's acknowledgement section.
kcc49 is offline   Reply With Quote

Old   September 24, 2018, 22:32
Default Similar error - Please Help me
  #9
New Member
 
Gabriel de Souza Berestinas
Join Date: Nov 2017
Posts: 6
Rep Power: 7
gberestinas is on a distinguished road
Hello, I new Openfoam user, please could you help me with this similar error, thanks!



Create time

Create mesh for time = 0

Selecting dynamicFvMesh dynamicMotionSolverFvMesh
Selecting motion solver: solidBody
Selecting solid-body motion function rotatingMotion
Applying solid body motion to cellZone rotor

PIMPLE: max iterations = 100
field U : relTol 0, tolerance 1e-05
field p : relTol 0, tolerance 0.0001

Reading field p

Reading field U

Reading/calculating face flux field phi

AMI: Creating addressing and weights between 9914 source faces and 10224 target faces
AMI: Patch source sum(weights) min/max/average = 0.996991, 1.00625, 1.00002
AMI: Patch target sum(weights) min/max/average = 0.992911, 1.00024, 0.999997
Selecting incompressible transport model Newtonian
Selecting turbulence model type RAS
Selecting RAS turbulence model kEpsilon
[2]
[2]
[2] --> FOAM FATAL ERROR:
[2] Invalid wall function specification
Patch type for patch Side must be wall
Current patch type is patch

[2]
[2]
[2] From function virtual void Foam::nutWallFunctionFvPatchScalarField::checkType ()
[2] in file derivedFvPatchFields/wallFunctions/nutWallFunctions/nutWallFunction/nutWallFunctionFvPatchScalarField.C at line 45.
[2]
FOAM parallel run aborting
[2]
[1]
[1]
[1] --> FOAM FATAL ERROR:
[1] Invalid wall function specification
Patch type for patch Side must be wall
Current patch type is patch

[1]
[1]
[1] From function virtual void Foam::nutWallFunctionFvPatchScalarField::checkType ()
[1] in file derivedFvPatchFields/wallFunctions/nutWallFunctions/nutWallFunction/nutWallFunctionFvPatchScalarField.C at line 45.
gberestinas is offline   Reply With Quote

Old   September 25, 2018, 03:26
Default
  #10
Senior Member
 
Robert
Join Date: May 2015
Location: Bremen, GER
Posts: 292
Rep Power: 10
RobertHB is on a distinguished road
Check your blockMeshDict and change the patch type for the patch called Side to "wall".
__________________
If you liked my answer to your question, please consider leaving a "Like" in return
RobertHB is offline   Reply With Quote

Old   September 25, 2018, 09:01
Default Similar error - Please Help me
  #11
New Member
 
Gabriel de Souza Berestinas
Join Date: Nov 2017
Posts: 6
Rep Power: 7
gberestinas is on a distinguished road
In this case I don't have bockMeshDict, I've only got the Boundary file as follow:


6
(
Side
{
type patch;
nFaces 21900;
startFace 3087311;
}
Inlet
{
type patch;
nFaces 2772;
startFace 3109211;
}
Outlet
{
type patch;
nFaces 2984;
startFace 3111983;
}
AMI2
{
type cyclicAMI;
neighbourPatch AMI1;
nFaces 9914;
startFace 3114967;
}
AMI1
{
type cyclicAMI;
neighbourPatch AMI2;
nFaces 10224;
startFace 3124881;
}
propeller
{
type patch;
nFaces 39848;
startFace 3135105;
}
)


PS. I used Salome to Mesh.


Thanks
gberestinas is offline   Reply With Quote

Old   September 25, 2018, 13:42
Default
  #12
Member
 
Geir Karlsen
Join Date: Nov 2013
Location: Norway
Posts: 59
Rep Power: 12
gkarlsen is on a distinguished road
Quote:
Originally Posted by gberestinas View Post
(
Side
{
type patch;
nFaces 21900;
startFace 3087311;
}
You appear to be using a wall function for your turbulence model. Your error message tries to tell you that "Side" must be of type wall not patch if you intend to use wall functions on it.

gberestinas likes this.
gkarlsen is offline   Reply With Quote

Old   September 26, 2018, 04:01
Default
  #13
Senior Member
 
Robert
Join Date: May 2015
Location: Bremen, GER
Posts: 292
Rep Power: 10
RobertHB is on a distinguished road
Quote:
Originally Posted by gkarlsen View Post
You appear to be using a wall function for your turbulence model. Your error message tries to tell you that "Side" must be of type wall not patch if you intend to use wall functions on it.

This. Just swap patch for wall in your boundary file.
__________________
If you liked my answer to your question, please consider leaving a "Like" in return
RobertHB is offline   Reply With Quote

Old   September 26, 2018, 05:07
Thumbs up
  #14
New Member
 
Gabriel de Souza Berestinas
Join Date: Nov 2017
Posts: 6
Rep Power: 7
gberestinas is on a distinguished road
Thanks all! Change done in six boundary files, because I already had executed parallel command for six processors! Error vanished!
gberestinas is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
What's the problem with turbulence models near the wall region? Jaydi_21 Main CFD Forum 6 July 7, 2017 03:39
Radiation interface hinca CFX 15 January 26, 2014 18:11
[blockMesh] error message with modeling a cube with a hold at the center hsingtzu OpenFOAM Meshing & Mesh Conversion 2 March 14, 2012 10:56
Version 15 on Mac OS X gschaider OpenFOAM Installation 113 December 2, 2009 11:23
Wall function in adverse pressure gradients stephane baralon Main CFD Forum 11 September 2, 1999 05:05


All times are GMT -4. The time now is 20:57.