|
[Sponsors] |
June 21, 2007, 16:34 |
I'm trying to implement a new
|
#1 |
Member
Doug Hunsaker
Join Date: Mar 2009
Location: Logan, UT
Posts: 63
Rep Power: 17 |
I'm trying to implement a new turbulence model. I've read through many of the other posts about implementing the k-omega model from the wiki into 1.3:
http://www.cfd-online.com/OpenFOAM_D...tml?1168380100 In 1.4, this model comes built-in, so I'd like to jump straight to implementing my own model. I've created a directory user/src/turbulenceModels/incompressible into which I copied the following directories from the OF/src/turbulenceModels/incompressible folder: laminar, lnInclude, Make, turbulenceModel, and wallFunctions. I then added my own directory called myKEpsilon which is basically a copy of the original kEpsilon src files renamed (just to learn how to link this turbulence model into the code). I then changed the Make/files file to: turbulenceModel/turbulenceModel.C turbulenceModel/newTurbulenceModel.C laminar/laminar.C myKEpsilon/myKEpsilon.C wallFunctions/nutWallFunction/nutWallFunction/nutWallFunctionFvPatchScalarField. C wallFunctions/nutWallFunction/nutStandardWallFunction/nutStandardWallFunctionFvP atchScalarField.C wallFunctions/nutWallFunction/nutStandardRoughWallFunction/nutStandardRoughWallF unctionFvPatchScalarField.C LIB = $(FOAM_USER_LIBBIN)/libincompressibleTurbulenceModels Then I tried to compile by using the ./Allwmake in the user/src/turbulenceModels directory and got the following error: doug@dell:~/OpenFOAM/doug-1.4/src/turbulenceModels> ./Allwmake Making dependency list for source file myKEpsilon/myKEpsilon.C SOURCE=myKEpsilon/myKEpsilon.C ; g++ -m32 -Dlinux -DDP -Wall -Wno-strict-aliasing -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-40 -I/home/doug/OpenFOAM/OpenFOAM-1.4/src/finiteVolume/lnInclude -I/home/doug/OpenFOAM/OpenFOAM-1.4/src/meshTools/lnInclude -I/home/doug/OpenFOAM/OpenFOAM-1.4/src/transportModels -IlnInclude -I. -I/home/doug/OpenFOAM/OpenFOAM-1.4/src/OpenFOAM/lnInclude -fPIC -pthread -c $SOURCE -o Make/linuxGcc4DPOpt/myKEpsilon.o myKEpsilon/myKEpsilon.C: In constructor 'Foam::turbulenceModels::myKEpsilon::myKEpsilon(co nst Foam::volVectorField&, const Foam::surfaceScalarField&, Foam::transportModel&)': myKEpsilon/myKEpsilon.C:52: error: 'Foam::IOobject' is an ambiguous base of 'Foam::fvMesh' myKEpsilon/myKEpsilon.C: In member function 'virtual bool Foam::turbulenceModels::myKEpsilon::read()': myKEpsilon/myKEpsilon.C:97: error: 'turublenceModel' has not been declared myKEpsilon/myKEpsilon.C: In member function 'virtual void Foam::turbulenceModels::myKEpsilon::correct()': myKEpsilon/myKEpsilon.C:135: error: 'sp' is not a member of 'Foam::fvm' myKEpsilon/myKEpsilon.C:153: error: 'class Foam::volScalarField' has no member named 'k_' make: *** [Make/linuxGcc4DPOpt/myKEpsilon.o] Error 1 Any ideas? It seems to me that implementing a new turbulence model should be quite common, and therefore well documented somewhere. However, I haven't found much help on the wiki or the discussion board. Any guidance to better documentation would also be appreciated. Thanks. -doug |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
turbulence model | elkan | FLUENT | 3 | June 13, 2007 03:42 |
V2F turbulence model | Luke | CFX | 2 | May 19, 2007 07:38 |
changing model constants in k-e turbulence model | Sunil | CFX | 3 | October 3, 2006 12:12 |
HELP! TURBULENCE k-e OR k-omega TURBULENCE MODEL? | Mirek Kabacinski | FLUENT | 5 | August 24, 2003 22:31 |
adding turbulence models to CFX | Steve Collie | CFX | 0 | January 30, 2001 16:32 |