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

Symbol lookup error related with a custom thermophysical model in foam-extend 4.0

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 1, 2019, 15:07
Default Symbol lookup error related with a custom thermophysical model in foam-extend 4.0
  #1
ch1
New Member
 
Christian
Join Date: Jun 2019
Posts: 14
Rep Power: 7
ch1 is on a distinguished road
Hey folks,
I followed instructions given here http://www.tfd.chalmers.se/~hani/kur...3-or-2.4.x.pdf(Part I) to compile my custom thermophysical library and link it to a solver. The difference is that I am using foam-extend 4.0. Now, I'm trying to figure out why I'm getting the following symbol lookup error
Code:
symbol lookup error: /home/of/OpenFOAM/icpaxiof/fe40/lib/linux64GccDPOpt/libbasicThermophysicalModels.so: undefined symbol: _ZN4Foam11pureMixtureINS_18kineticArTransportINS_12specieThermoINS_12hConstThermoINS_10perfectGasEEEEEEEE8typeNameE
when running the case. Using the c++filt command this error message can be converted to
Code:
Foam::pureMixture<Foam::kineticArTransport<Foam::specieThermo<Foam::hConstThermo<Foam::perfectGas> > > >::typeName
.

I uploaded the modified library here: https://www63.zippyshare.com/v/LpyM6bZf/file.html
In the attachments you can find two compilation log files of running "wmake libso" in /basic and /specie directories, respectively, and the Make/options file of the solver.

Best regards
Christian
Attached Files
File Type: gz wmake_libso_logs_and_solver_options.tar.gz (3.2 KB, 2 views)
ch1 is offline   Reply With Quote

Old   July 19, 2019, 12:34
Default
  #2
ch1
New Member
 
Christian
Join Date: Jun 2019
Posts: 14
Rep Power: 7
ch1 is on a distinguished road
Hello everyone,
finally I found the source of the error in /src/thermophysicalModels/basic/psiThermo/psiThermos.C :
Code:
#include "makeBasicPsiThermo.H"

#include "perfectGas.H"

#include "hConstThermo.H"
#include "janafThermo.H"
#include "specieThermo.H"

#include "constTransport.H"
#include "kineticArTransport.H"
#include "sutherlandTransport.H"

#include "hPsiThermo.H"
#include "pureMixture.H"


// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

namespace Foam
{

/* * * * * * * * * * * * * * * Private Static Data * * * * * * * * * * * * * */

makeBasicPsiThermo //new custom thermophysical model
(
    hPsiThermo,
    pureMixture,
    kineticArTransport,
    hConstThermo,
    perfectGas
);

makeBasicPsiThermo
(
    hPsiThermo,
    pureMixture,
    constTransport,
    hConstThermo,
    perfectGas
);
The word kineticArTransport was not defined. If you carefully follow the instructions given by http://www.tfd.chalmers.se/~hani/kur...3-or-2.4.x.pdf , you will get the same symbol look-up error in foam-extend 4.0. The problem is that the following word definition in files like constTransport.H (my copy is named kineticArTransport.H) is missing:


Code:
  //- Return the instantiated type name
        static word typeName()
        {
            return "kineticAr<" + thermo::typeName() + '>';
        }
In other OF versions like of-v1812 the definition of the word typeName exists. So there the custom thermophysical library should run without problems.

My workaround to make my custom thermophysical model run in foam-extend 4.0 was to modify the OF standard transport and thermo models like hConst,..

However, this is not very elegant and I am still curious, where and how the typeName words of the thermophysical models are defined in foam-extend 4.0.

Actually, I tried to add the above word defintion to my kineticArTransport.H, but this didn't work here, either.


Best regards
Christian
ch1 is offline   Reply With Quote

Reply


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
Symbol lookup error after upgrading to 2.1.1 ChrisA OpenFOAM Programming & Development 2 March 6, 2013 21:38
using METIS functions in fortran dokeun Main CFD Forum 7 January 29, 2013 05:06
channelFoam for a 3D pipe AlmostSurelyRob OpenFOAM 3 June 24, 2011 14:06
Convergence on anisotropic tetahedral meshes pbo OpenFOAM Running, Solving & CFD 12 December 14, 2010 12:59
[Gmsh] Import problem ARC OpenFOAM Meshing & Mesh Conversion 0 February 27, 2010 11:56


All times are GMT -4. The time now is 14:50.