|
[Sponsors] |
September 17, 2013, 13:28 |
adding lift model to twoPhaseEulerFoam
|
#1 |
New Member
Join Date: Sep 2010
Location: Windsor, Ontario
Posts: 17
Rep Power: 16 |
Hi everybody,
I am trying to add new interfacial models to the twoPhaseEulerFoam solver. So, I started from lift force. I followed the drag model existing in the default solver and developed the lift model according to that. Every thing is exactly similar except the changes that I have made to implement the lift. There was no issue when I compiled the interfacialModels library by doing wmake libso. But when I do a wmake for the solver I get the following error: mytwoPhaseEulerFoam2.C.text+0x8a6b): undefined reference to `Foam::liftModel::New(Foam::dictionary const&, Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const&, Foam:haseModel const&, Foam:haseModel const&)' mytwoPhaseEulerFoam2.C.text+0x8ab9): undefined reference to `Foam::liftModel::New(Foam::dictionary const&, Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const&, Foam:haseModel const&, Foam:haseModel const&)' collect2: ld returned 1 exit status make: *** [/home/mehrdad/OpenFOAM/mehrdad-2.1.1/platforms/linux64GccDPOpt/bin/mytwoPhaseEulerFoam2] Error 1 Do you have any idea what can cause this error?! Thanks. |
|
September 17, 2013, 13:53 |
|
#2 |
Senior Member
Armin
Join Date: Feb 2011
Location: Helsinki, Finland
Posts: 156
Rep Power: 19 |
Without having your error message further checked: Did you set you linker options correctly and included:
Code:
-L$(FOAM_USER_LIBBIN) |
|
September 17, 2013, 14:13 |
|
#3 |
New Member
Join Date: Sep 2010
Location: Windsor, Ontario
Posts: 17
Rep Power: 16 |
The "files" and "options" in the interfacial Models folder are attached:
liftModels/liftModel/liftModel.C liftModels/liftModel/newLiftModel.C liftModels/Tomiyama/Tomiyama.C dragModels/dragModel/dragModel.C dragModels/dragModel/newDragModel.C dragModels/WenYu/WenYu.C LIB = $(FOAM_USER_LIBBIN)/libEulerianInterfacialModels ------------------------------------------------------------------------------------------ EXE_INC = \ -I$(LIB_SRC)/finiteVolume/lnInclude \ -I$(LIB_SRC)/meshTools/lnInclude \ -I../phaseModel/lnInclude LIB_LIBS = \ -lphaseModel |
|
September 17, 2013, 14:25 |
|
#4 |
Senior Member
Armin
Join Date: Feb 2011
Location: Helsinki, Finland
Posts: 156
Rep Power: 19 |
The options file of your solver?
|
|
September 17, 2013, 14:28 |
|
#5 |
Senior Member
Armin
Join Date: Feb 2011
Location: Helsinki, Finland
Posts: 156
Rep Power: 19 |
The options file of your solver should look something like this:
Code:
EXE_LIBS = \ -L$(FOAM_USER_LIBBIN) \ -lEulerianInterfacialModels \ -lfiniteVolume \ -lmeshTools \ -lincompressibleTransportModels \ -lphaseModel \ -lkineticTheoryModel |
|
September 17, 2013, 14:34 |
|
#6 |
New Member
Join Date: Sep 2010
Location: Windsor, Ontario
Posts: 17
Rep Power: 16 |
here is my solver's option file:
EXE_INC = \ -I$(LIB_SRC)/finiteVolume/lnInclude \ -I$(LIB_SRC)/transportModels/incompressible/lnInclude \ -IturbulenceModel \ -IinterfacialModels/lnInclude \ -IphaseModel/lnInclude \ -I$(LIB_SRC)/turbulenceModels \ -Iaveraging EXE_LIBS = \ -L$(FOAM_USER_LIBBIN) \ -lincompressibleTransportModels \ -lphaseModel \ -lEulerianInterfacialModels \ -lfiniteVolume \ -lmeshTools |
|
September 17, 2013, 15:05 |
|
#7 |
Senior Member
Armin
Join Date: Feb 2011
Location: Helsinki, Finland
Posts: 156
Rep Power: 19 |
Sorry, these were just the simple guesses... Without checking in detail what goes wrong I don't have any ideas any more.
|
|
September 17, 2013, 16:18 |
|
#8 |
Senior Member
Armin
Join Date: Feb 2011
Location: Helsinki, Finland
Posts: 156
Rep Power: 19 |
Something I just realized, you named the modified library the same as the original one.
I'm not sure if this work, at least I have never tried it to not even get into the situation of confusing them. You could try something like: Code:
LIB = $(FOAM_USER_LIBBIN)/libEulerianInterfacialModelsMod Code:
EXE_LIBS = \ -L$(FOAM_USER_LIBBIN) \ -lincompressibleTransportModels \ -lphaseModel \ -lEulerianInterfacialModelsMod \ -lfiniteVolume \ -lmeshTools |
|
September 17, 2013, 17:08 |
|
#9 |
New Member
Join Date: Sep 2010
Location: Windsor, Ontario
Posts: 17
Rep Power: 16 |
You solved my problem.
Thank you veryyyyyyyyyyyyy much. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Adding a Turbulence Model | doug | OpenFOAM Running, Solving & CFD | 11 | May 21, 2018 14:54 |
Superlinear speedup in OpenFOAM 13 | msrinath80 | OpenFOAM Running, Solving & CFD | 18 | March 3, 2015 06:36 |
Is it possible to model natural convection in a 2D horizontal model in fluent | caitoc | FLUENT | 1 | May 5, 2014 14:32 |
About the dimension of Saffman-Mei particle lift force model | haakon | OpenFOAM Programming & Development | 1 | April 22, 2013 13:27 |
Adding new term in to K eqn of K-Epsilon turbuelnce model | neeraj | OpenFOAM Running, Solving & CFD | 3 | October 11, 2012 08:18 |