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

Using PengRobinsonGas EoS with sprayFoam

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

Like Tree17Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 14, 2019, 18:40
Default
  #21
New Member
 
Join Date: Jul 2012
Posts: 10
Rep Power: 14
mickbatti is on a distinguished road
Hi Tiziano,
I'm glad you solved it.
Can I ask you what type of modifications you applied to the class Specie?
Thanks,
Michele
mickbatti is offline   Reply With Quote

Old   March 18, 2019, 09:20
Default
  #22
New Member
 
Tiziano Maffei
Join Date: Jun 2013
Location: Milan (Italy)
Posts: 11
Rep Power: 13
tmaffei is on a distinguished road
Hi Mick,

I have used the molar fraction to evaluate the mixing properties Tc, Pc, Zc, Vc and omega instead the mass fraction.

Tiziano
tmaffei is offline   Reply With Quote

Old   May 17, 2019, 10:25
Default
  #23
New Member
 
Fanirisoa
Join Date: May 2019
Posts: 1
Rep Power: 0
Zfaniry is on a distinguished road
HI Tiziano,

Can you show me how did you use the molar fraction instead of the mass fraction please.
Zfaniry is offline   Reply With Quote

Old   June 5, 2019, 12:03
Default
  #24
New Member
 
Tiziano Maffei
Join Date: Jun 2013
Location: Milan (Italy)
Posts: 11
Rep Power: 13
tmaffei is on a distinguished road
Hi Zfaniry,

sorry for my late answer. I have added molar fraction in the member function:

template<class Specie>
inline void Foam::PengRobinsonGas<Specie>:perator+=
(
const PengRobinsonGas<Specie>& pg
)
{
scalar Y1 = this->Y();

scalar MW1 = this->W();
scalar MW2 = pg.W();

Specie:perator+=(pg);

if (mag(this->Y()) > small)
{

Y1 /= this->Y();
const scalar Y2 = pg.Y()/this->Y();
const scalar X1 = Y1*this->W()/MW1; <--- X is molar fraction
const scalar X2 = Y2 * this->W()/MW2; <--- X is molar fraction

Tc_ = Y1*Tc_ + Y2*pg.Tc_;
Vc_ = Y1*Vc_ + Y2*pg.Vc_;
Zc_ = Y1*Zc_ + Y2*pg.Zc_;
Pc_ = RR*Zc_*Tc_/Vc_;
omega_ = Y1*omega_ + Y2*pg.omega_;


Tc_ = X1*Tc_ + X2*pg.Tc_;
Vc_ = X1*Vc_ + X2*pg.Vc_;
Zc_ = X1*Zc_ + X2*pg.Zc_;
Pc_ = RR*Zc_*Tc_/Vc_;
omega_ = X1*omega_ + X2*pg.omega_;

}

}

Best regards

Tiziano
labyrinth01 likes this.
tmaffei is offline   Reply With Quote

Old   September 20, 2019, 07:58
Default
  #25
New Member
 
Manoj
Join Date: Nov 2018
Posts: 6
Rep Power: 7
Manoj Paithane is on a distinguished road
Quote:
Originally Posted by john myce View Post
By the way the method written by James works for me.
I have attached my files in case someone has an error.

Make for specie directory:

Code:
atomicWeights/atomicWeights.C
specie/specie.C
reaction/reactions/makeReactions.C
reaction/reactions/makeLangmuirHinshelwoodReactions.C

LIB = $(FOAM_USER_LIBBIN)/libspecie
Make for reactionthermo directory:

Code:
chemistryReaders/chemkinReader/chemkinReader.C
chemistryReaders/chemkinReader/chemkinLexer.L
chemistryReaders/chemistryReader/makeChemistryReaders.C

mixtures/basicMultiComponentMixture/basicMultiComponentMixture.C
mixtures/basicSpecieMixture/basicSpecieMixture.C
mixtures/basicCombustionMixture/basicCombustionMixture.C

psiReactionThermo/psiReactionThermo.C
psiReactionThermo/psiReactionThermos.C

psiuReactionThermo/psiuReactionThermo.C
psiuReactionThermo/psiuReactionThermos.C

rhoReactionThermo/rhoReactionThermo.C
rhoReactionThermo/rhoReactionThermos.C

derivedFvPatchFields/fixedUnburntEnthalpy/fixedUnburntEnthalpyFvPatchScalarField.C
derivedFvPatchFields/gradientUnburntEnthalpy/gradientUnburntEnthalpyFvPatchScalarField.C
derivedFvPatchFields/mixedUnburntEnthalpy/mixedUnburntEnthalpyFvPatchScalarField.C

functionObjects/moleFractions/moleFractionsFunctionObjects.C

LIB = $(FOAM_USER_LIBBIN)/libreactionThermophysicalModels
Code:
EXE_INC = \
    -I$(LIB_SRC)/transportModels/compressible/lnInclude \
    -I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
    -I$(WM_PROJECT_USER_DIR)/src/thermophysicalModels/specie/lnInclude \
    -I$(LIB_SRC)/thermophysicalModels/solidSpecie/lnInclude \
    -I$(LIB_SRC)/finiteVolume/lnInclude

LIB_LIBS = \
    -lcompressibleTransportModels \
    -lfluidThermophysicalModels \
    -L$(FOAM_USER_LIBBIN)/lspecie \
    -lsolidSpecie \
    -lfiniteVolume
I follow all the steps as mention by jabo and james but got error message while compiling dont know what goes wrong please help me out

following are the errors
wmakeLnIncludeAll: running wmakeLnInclude on dependent libraries:
wmakeLnInclude error: base directory /home/manoj/OpenFOAM/manoj-6/src/thermophysicalModels/specie/ does not exist
wmakeLnInclude: linking include files to ./lnInclude
Making dependency list for source file moleFractionsFunctionObjects.C
could not open file speciesTable.H for source file functionObjects/moleFractions/moleFractionsFunctionObjects.C due to No such file or directory
Making dependency list for source file mixedUnburntEnthalpyFvPatchScalarField.C
could not open file speciesTable.H for source file derivedFvPatchFields/mixedUnburntEnthalpy/mixedUnburntEnthalpyFvPatchScalarField.C due to No such file or directory
Making dependency list for source file gradientUnburntEnthalpyFvPatchScalarField.C
could not open file speciesTable.H for source file derivedFvPatchFields/gradientUnburntEnthalpy/gradientUnburntEnthalpyFvPatchScalarField.C due to No such file or directory
Making dependency list for source file fixedUnburntEnthalpyFvPatchScalarField.C
could not open file speciesTable.H for source file derivedFvPatchFields/fixedUnburntEnthalpy/fixedUnburntEnthalpyFvPatchScalarField.C due to No such file or directory
Making dependency list for source file rhoReactionThermos.C
could not open file specie.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file perfectGas.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file incompressiblePerfectGas.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file hConstThermo.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file janafThermo.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file sensibleEnthalpy.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file thermo.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file rhoConst.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file perfectFluid.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file adiabaticPerfectFluid.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file Boussinesq.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file constTransport.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file sutherlandTransport.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file thermoPhysicsTypes.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file speciesTable.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file specieElement.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file Reaction.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
could not open file ReactionList.H for source file rhoReactionThermo/rhoReactionThermos.C due to No such file or directory
Making dependency list for source file rhoReactionThermo.C
could not open file speciesTable.H for source file rhoReactionThermo/rhoReactionThermo.C due to No such file or directory
Making dependency list for source file psiuReactionThermos.C
could not open file specie.H for source file psiuReactionThermo/psiuReactionThermos.C due to No such file or directory
could not open file perfectGas.H for source file psiuReactionThermo/psiuReactionThermos.C due to No such file or directory
could not open file hConstThermo.H for source file psiuReactionThermo/psiuReactionThermos.C due to No such file or directory
could not open file janafThermo.H for source file psiuReactionThermo/psiuReactionThermos.C due to No such file or directory
could not open file thermo.H for source file psiuReactionThermo/psiuReactionThermos.C due to No such file or directory
could not open file constTransport.H for source file psiuReactionThermo/psiuReactionThermos.C due to No such file or directory
could not open file sutherlandTransport.H for source file psiuReactionThermo/psiuReactionThermos.C due to No such file or directory
could not open file absoluteEnthalpy.H for source file psiuReactionThermo/psiuReactionThermos.C due to No such file or directory
could not open file absoluteInternalEnergy.H for source file psiuReactionThermo/psiuReactionThermos.C due to No such file or directory
could not open file speciesTable.H for source file psiuReactionThermo/psiuReactionThermos.C due to No such file or directory
Making dependency list for source file psiuReactionThermo.C
could not open file speciesTable.H for source file psiuReactionThermo/psiuReactionThermo.C due to No such file or directory
Making dependency list for source file psiReactionThermos.C
could not open file specie.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file perfectGas.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file PengRobinsonGas.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file hConstThermo.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file janafThermo.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file sensibleEnthalpy.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file thermo.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file constTransport.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file sutherlandTransport.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file thermoPhysicsTypes.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file speciesTable.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file specieElement.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file Reaction.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
could not open file ReactionList.H for source file psiReactionThermo/psiReactionThermos.C due to No such file or directory
Making dependency list for source file psiReactionThermo.C
could not open file speciesTable.H for source file psiReactionThermo/psiReactionThermo.C due to No such file or directory
Making dependency list for source file basicCombustionMixture.C
could not open file speciesTable.H for source file mixtures/basicCombustionMixture/basicCombustionMixture.C due to No such file or directory
Making dependency list for source file basicSpecieMixture.C
could not open file speciesTable.H for source file mixtures/basicSpecieMixture/basicSpecieMixture.C due to No such file or directory
Making dependency list for source file basicMultiComponentMixture.C
could not open file speciesTable.H for source file mixtures/basicMultiComponentMixture/basicMultiComponentMixture.C due to No such file or directory
Making dependency list for source file makeChemistryReaders.C
could not open file thermoPhysicsTypes.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file specie.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file rhoConst.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file hConstThermo.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file hPolynomialThermo.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file hPowerThermo.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file sensibleEnthalpy.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file thermo.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file specieElement.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file Reaction.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file ReactionList.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file speciesTable.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
could not open file atomicWeights.H for source file chemistryReaders/chemistryReader/makeChemistryReaders.C due to No such file or directory
Making dependency list for source file chemkinLexer.L
could not open file ReactionList.H for source file chemistryReaders/chemkinReader/chemkinLexer.L due to No such file or directory
could not open file speciesTable.H for source file chemistryReaders/chemkinReader/chemkinLexer.L due to No such file or directory
could not open file atomicWeights.H for source file chemistryReaders/chemkinReader/chemkinLexer.L due to No such file or directory
could not open file reactionTypes.H for source file chemistryReaders/chemkinReader/chemkinLexer.L due to No such file or directory
could not open file specieElement.H for source file chemistryReaders/chemkinReader/chemkinLexer.L due to No such file or directory
could not open file Reaction.H for source file chemistryReaders/chemkinReader/chemkinLexer.L due to No such file or directory
Making dependency list for source file chemkinReader.C
could not open file atomicWeights.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file ReactionProxy.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file IrreversibleReaction.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file ReversibleReaction.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file NonEquilibriumReversibleReaction.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file ArrheniusReactionRate.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file thirdBodyArrheniusReactionRate.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file FallOffReactionRate.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file ChemicallyActivatedReactionRate.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file LindemannFallOffFunction.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file TroeFallOffFunction.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file SRIFallOffFunction.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file LandauTellerReactionRate.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file JanevReactionRate.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file powerSeriesReactionRate.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file ReactionList.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file speciesTable.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file reactionTypes.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file specieElement.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
could not open file Reaction.H for source file chemistryReaders/chemkinReader/chemkinReader.C due to No such file or directory
g++ -std=c++11 -m64 -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -Wno-attributes -O3 -DNoRepository -ftemplate-depth-100 -I/opt/openfoam6/src/transportModels/compressible/lnInclude -I/opt/openfoam6/src/thermophysicalModels/basic/lnInclude -I/home/manoj/OpenFOAM/manoj-6/src/thermophysicalModels/specie/lnInclude -I/opt/openfoam6/src/thermophysicalModels/solidSpecie/lnInclude -I/opt/openfoam6/src/finiteVolume/lnInclude -IlnInclude -I. -I/opt/openfoam6/src/OpenFOAM/lnInclude -I/opt/openfoam6/src/OSspecific/POSIX/lnInclude -fPIC -c chemistryReaders/chemkinReader/chemkinReader.C -o Make/linux64GccDPInt32Opt/chemistryReaders/chemkinReader/chemkinReader.o
In file included from chemistryReaders/chemkinReader/chemkinReader.H:39:0,
from chemistryReaders/chemkinReader/chemkinReader.C:26:
lnInclude/chemistryReader.H:39:10: fatal error: specieElement.H: No such file or directory
#include "specieElement.H"
^~~~~~~~~~~~~~~~~
compilation terminated.
/opt/openfoam6/wmake/rules/General/transform:25: recipe for target 'Make/linux64GccDPInt32Opt/chemistryReaders/chemkinReader/chemkinReader.o' failed
make: *** [Make/linux64GccDPInt32Opt/chemistryReaders/chemkinReader/chemkinReader.o] Error 1
Manoj Paithane is offline   Reply With Quote

Old   December 30, 2019, 07:53
Post
  #26
New Member
 
Manoj
Join Date: Nov 2018
Posts: 6
Rep Power: 7
Manoj Paithane is on a distinguished road
Quote:
Originally Posted by john myce View Post
By the way the method written by James works for me.
I have attached my files in case someone has an error.

Make for specie directory:

Code:
atomicWeights/atomicWeights.C
specie/specie.C
reaction/reactions/makeReactions.C
reaction/reactions/makeLangmuirHinshelwoodReactions.C

LIB = $(FOAM_USER_LIBBIN)/libspecie
Make for reactionthermo directory:

Code:
chemistryReaders/chemkinReader/chemkinReader.C
chemistryReaders/chemkinReader/chemkinLexer.L
chemistryReaders/chemistryReader/makeChemistryReaders.C

mixtures/basicMultiComponentMixture/basicMultiComponentMixture.C
mixtures/basicSpecieMixture/basicSpecieMixture.C
mixtures/basicCombustionMixture/basicCombustionMixture.C

psiReactionThermo/psiReactionThermo.C
psiReactionThermo/psiReactionThermos.C

psiuReactionThermo/psiuReactionThermo.C
psiuReactionThermo/psiuReactionThermos.C

rhoReactionThermo/rhoReactionThermo.C
rhoReactionThermo/rhoReactionThermos.C

derivedFvPatchFields/fixedUnburntEnthalpy/fixedUnburntEnthalpyFvPatchScalarField.C
derivedFvPatchFields/gradientUnburntEnthalpy/gradientUnburntEnthalpyFvPatchScalarField.C
derivedFvPatchFields/mixedUnburntEnthalpy/mixedUnburntEnthalpyFvPatchScalarField.C

functionObjects/moleFractions/moleFractionsFunctionObjects.C

LIB = $(FOAM_USER_LIBBIN)/libreactionThermophysicalModels
Code:
EXE_INC = \
    -I$(LIB_SRC)/transportModels/compressible/lnInclude \
    -I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
    -I$(WM_PROJECT_USER_DIR)/src/thermophysicalModels/specie/lnInclude \
    -I$(LIB_SRC)/thermophysicalModels/solidSpecie/lnInclude \
    -I$(LIB_SRC)/finiteVolume/lnInclude

LIB_LIBS = \
    -lcompressibleTransportModels \
    -lfluidThermophysicalModels \
    -L$(FOAM_USER_LIBBIN)/lspecie \
    -lsolidSpecie \
     -lfiniteVolume



Hi john myce,


I did whatever you told for compiling real gas equation.
but I got error as follow, I don't know about this error please provide me some solution my work is pending for so many days.


it will be very helpful if you could help me.


error:


Allwmake /home/manoj/OpenFOAM/manoj-6/src/thermophysicalModels
wmake specie
wmakeLnInclude: linking include files to ./lnInclude
g++ -std=c++11 -m64 -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -Wno-attributes -O3 -DNoRepository -ftemplate-depth-100 -IlnInclude -I. -I/opt/openfoam6/src/OpenFOAM/lnInclude -I/opt/openfoam6/src/OSspecific/POSIX/lnInclude -fPIC -c atomicWeights/atomicWeights.C -o Make/linux64GccDPInt32Opt/atomicWeights/atomicWeights.o
g++ -std=c++11 -m64 -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -Wno-attributes -O3 -DNoRepository -ftemplate-depth-100 -IlnInclude -I. -I/opt/openfoam6/src/OpenFOAM/lnInclude -I/opt/openfoam6/src/OSspecific/POSIX/lnInclude -fPIC -c specie/specie.C -o Make/linux64GccDPInt32Opt/specie/specie.o
g++ -std=c++11 -m64 -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -Wno-attributes -O3 -DNoRepository -ftemplate-depth-100 -IlnInclude -I. -I/opt/openfoam6/src/OpenFOAM/lnInclude -I/opt/openfoam6/src/OSspecific/POSIX/lnInclude -fPIC -c reaction/reactions/makeReactions.C -o Make/linux64GccDPInt32Opt/reaction/reactions/makeReactions.o
g++ -std=c++11 -m64 -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -Wno-attributes -O3 -DNoRepository -ftemplate-depth-100 -IlnInclude -I. -I/opt/openfoam6/src/OpenFOAM/lnInclude -I/opt/openfoam6/src/OSspecific/POSIX/lnInclude -fPIC -c reaction/reactions/makeLangmuirHinshelwoodReactions.C -o Make/linux64GccDPInt32Opt/reaction/reactions/makeLangmuirHinshelwoodReactions.o
g++ -std=c++11 -m64 -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -Wno-attributes -O3 -DNoRepository -ftemplate-depth-100 -IlnInclude -I. -I/opt/openfoam6/src/OpenFOAM/lnInclude -I/opt/openfoam6/src/OSspecific/POSIX/lnInclude -fPIC -shared -Xlinker --add-needed -Xlinker --no-as-needed Make/linux64GccDPInt32Opt/atomicWeights/atomicWeights.o Make/linux64GccDPInt32Opt/specie/specie.o Make/linux64GccDPInt32Opt/reaction/reactions/makeReactions.o Make/linux64GccDPInt32Opt/reaction/reactions/makeLangmuirHinshelwoodReactions.o -L/opt/openfoam6/platforms/linux64GccDPInt32Opt/lib \
-lOpenFOAM -o /home/manoj/OpenFOAM/manoj-6/platforms/linux64GccDPInt32Opt/lib/libspecie.so
wmake solidSpecie
wmake thermophysicalProperties
wmake basic
wmake reactionThermo
g++ -std=c++11 -m64 -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -Wno-attributes -O3 -DNoRepository -ftemplate-depth-100 -I/opt/openfoam6/src/transportModels/compressible/lnInclude -I/opt/openfoam6/src/thermophysicalModels/basic/lnInclude -I/home/manoj/OpenFOAM/manoj-6/src/thermophysicalModels/specie/lnInclude -I/opt/openfoam6/src/thermophysicalModels/solidSpecie/lnInclude -I/opt/openfoam6/src/finiteVolume/lnInclude -IlnInclude -I. -I/opt/openfoam6/src/OpenFOAM/lnInclude -I/opt/openfoam6/src/OSspecific/POSIX/lnInclude -fPIC -c psiReactionThermo/psiReactionThermos.C -o Make/linux64GccDPInt32Opt/psiReactionThermo/psiReactionThermos.o
psiReactionThermo/psiReactionThermos.C:69:1: error: macro "makeReactionThermo" passed 9 arguments, but takes just 8
);
^
psiReactionThermo/psiReactionThermos.C:82:1: error: macro "makeReactionThermo" passed 9 arguments, but takes just 8
);
^
psiReactionThermo/psiReactionThermos.C:95:1: error: macro "makeReactionThermo" passed 9 arguments, but takes just 8
);
^
psiReactionThermo/psiReactionThermos.C:111:1: error: macro "makeReactionThermo" passed 9 arguments, but takes just 8
);
^
psiReactionThermo/psiReactionThermos.C:124:1: error: macro "makeReactionThermo" passed 9 arguments, but takes just 8
);
^
psiReactionThermo/psiReactionThermos.C:137:1: error: macro "makeReactionThermo" passed 9 arguments, but takes just 8
);
^
psiReactionThermo/psiReactionThermos.C:153:1: error: macro "makeReactionThermo" passed 9 arguments, but takes just 8
);
^
psiReactionThermo/psiReactionThermos.C:166:1: error: macro "makeReactionThermo" passed 9 arguments, but takes just 8
);
^
psiReactionThermo/psiReactionThermos.C:179:1: error: macro "makeReactionThermo" passed 9 arguments, but takes just 8
);
^
psiReactionThermo/psiReactionThermos.C:58:1: error: ‘makeReactionThermo’ does not name a type; did you mean ‘psiReactionThermo’?
makeReactionThermo
^~~~~~~~~~~~~~~~~~
psiReactionThermo
psiReactionThermo/psiReactionThermos.C:71:1: error: ‘makeReactionThermo’ does not name a type; did you mean ‘psiReactionThermo’?
makeReactionThermo
^~~~~~~~~~~~~~~~~~
psiReactionThermo
psiReactionThermo/psiReactionThermos.C:84:1: error: ‘makeReactionThermo’ does not name a type; did you mean ‘psiReactionThermo’?
makeReactionThermo
^~~~~~~~~~~~~~~~~~
psiReactionThermo
psiReactionThermo/psiReactionThermos.C:100:1: error: ‘makeReactionThermo’ does not name a type; did you mean ‘psiReactionThermo’?
makeReactionThermo
^~~~~~~~~~~~~~~~~~
psiReactionThermo
psiReactionThermo/psiReactionThermos.C:113:1: error: ‘makeReactionThermo’ does not name a type; did you mean ‘psiReactionThermo’?
makeReactionThermo
^~~~~~~~~~~~~~~~~~
psiReactionThermo
psiReactionThermo/psiReactionThermos.C:126:1: error: ‘makeReactionThermo’ does not name a type; did you mean ‘psiReactionThermo’?
makeReactionThermo
^~~~~~~~~~~~~~~~~~
psiReactionThermo
psiReactionThermo/psiReactionThermos.C:142:1: error: ‘makeReactionThermo’ does not name a type; did you mean ‘psiReactionThermo’?
makeReactionThermo
^~~~~~~~~~~~~~~~~~
psiReactionThermo
psiReactionThermo/psiReactionThermos.C:155:1: error: ‘makeReactionThermo’ does not name a type; did you mean ‘psiReactionThermo’?
makeReactionThermo
^~~~~~~~~~~~~~~~~~
psiReactionThermo
psiReactionThermo/psiReactionThermos.C:168:1: error: ‘makeReactionThermo’ does not name a type; did you mean ‘psiReactionThermo’?
makeReactionThermo
^~~~~~~~~~~~~~~~~~
psiReactionThermo
psiReactionThermo/psiReactionThermos.C:188:5: error: ‘hePsiThermo’ is not a type
hePsiThermo,
^~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:189:5: error: ‘multiComponentMixture’ is not a type
multiComponentMixture,
^~~~~~~~~~~~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:191:2: error: expected constructor, destructor, or type conversion before ‘;’ token
);
^
psiReactionThermo/psiReactionThermos.C:197:5: error: ‘hePsiThermo’ is not a type
hePsiThermo,
^~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:198:5: error: ‘multiComponentMixture’ is not a type
multiComponentMixture,
^~~~~~~~~~~~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:200:2: error: expected constructor, destructor, or type conversion before ‘;’ token
);
^
psiReactionThermo/psiReactionThermos.C:209:5: error: ‘hePsiThermo’ is not a type
hePsiThermo,
^~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:210:5: error: ‘multiComponentMixture’ is not a type
multiComponentMixture,
^~~~~~~~~~~~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:212:2: error: expected constructor, destructor, or type conversion before ‘;’ token
);
^
psiReactionThermo/psiReactionThermos.C:218:5: error: ‘hePsiThermo’ is not a type
hePsiThermo,
^~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:219:5: error: ‘multiComponentMixture’ is not a type
multiComponentMixture,
^~~~~~~~~~~~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:221:2: error: expected constructor, destructor, or type conversion before ‘;’ token
);
^
psiReactionThermo/psiReactionThermos.C:230:5: error: ‘hePsiThermo’ is not a type
hePsiThermo,
^~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:231:5: error: ‘reactingMixture’ is not a type
reactingMixture,
^~~~~~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:233:2: error: expected constructor, destructor, or type conversion before ‘;’ token
);
^
psiReactionThermo/psiReactionThermos.C:239:5: error: ‘hePsiThermo’ is not a type
hePsiThermo,
^~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:240:5: error: ‘reactingMixture’ is not a type
reactingMixture,
^~~~~~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:242:2: error: expected constructor, destructor, or type conversion before ‘;’ token
);
^
psiReactionThermo/psiReactionThermos.C:248:5: error: ‘hePsiThermo’ is not a type
hePsiThermo,
^~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:249:5: error: ‘singleStepReactingMixture’ is not a type
singleStepReactingMixture,
^~~~~~~~~~~~~~~~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:251:2: error: expected constructor, destructor, or type conversion before ‘;’ token
);
^
psiReactionThermo/psiReactionThermos.C:257:5: error: ‘hePsiThermo’ is not a type
hePsiThermo,
^~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:258:5: error: ‘reactingMixture’ is not a type
reactingMixture,
^~~~~~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:260:2: error: expected constructor, destructor, or type conversion before ‘;’ token
);
^
psiReactionThermo/psiReactionThermos.C:268:5: error: ‘hePsiThermo’ is not a type
hePsiThermo,
^~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:269:5: error: ‘reactingMixture’ is not a type
reactingMixture,
^~~~~~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:271:2: error: expected constructor, destructor, or type conversion before ‘;’ token
);
^
psiReactionThermo/psiReactionThermos.C:277:5: error: ‘hePsiThermo’ is not a type
hePsiThermo,
^~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:278:5: error: ‘reactingMixture’ is not a type
reactingMixture,
^~~~~~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:280:2: error: expected constructor, destructor, or type conversion before ‘;’ token
);
^
psiReactionThermo/psiReactionThermos.C:286:5: error: ‘hePsiThermo’ is not a type
hePsiThermo,
^~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:287:5: error: ‘singleStepReactingMixture’ is not a type
singleStepReactingMixture,
^~~~~~~~~~~~~~~~~~~~~~~~~
psiReactionThermo/psiReactionThermos.C:289:2: error: expected constructor, destructor, or type conversion before ‘;’ token
);
^
/opt/openfoam6/wmake/rules/General/transform:25: recipe for target 'Make/linux64GccDPInt32Opt/psiReactionThermo/psiReactionThermos.o' failed
make: *** [Make/linux64GccDPInt32Opt/psiReactionThermo/psiReactionThermos.o] Error 1


Thanking you,
Manoj
Manoj Paithane is offline   Reply With Quote

Old   August 6, 2020, 06:57
Default
  #27
New Member
 
Omair
Join Date: May 2017
Posts: 9
Rep Power: 9
m.omair is on a distinguished road
Quote:
Originally Posted by john myce View Post
By the way the method written by James works for me.
I have attached my files in case someone has an error.

Make for specie directory:

Code:
atomicWeights/atomicWeights.C
specie/specie.C
reaction/reactions/makeReactions.C
reaction/reactions/makeLangmuirHinshelwoodReactions.C

LIB = $(FOAM_USER_LIBBIN)/libspecie
Make for reactionthermo directory:

Code:
chemistryReaders/chemkinReader/chemkinReader.C
chemistryReaders/chemkinReader/chemkinLexer.L
chemistryReaders/chemistryReader/makeChemistryReaders.C

mixtures/basicMultiComponentMixture/basicMultiComponentMixture.C
mixtures/basicSpecieMixture/basicSpecieMixture.C
mixtures/basicCombustionMixture/basicCombustionMixture.C

psiReactionThermo/psiReactionThermo.C
psiReactionThermo/psiReactionThermos.C

psiuReactionThermo/psiuReactionThermo.C
psiuReactionThermo/psiuReactionThermos.C

rhoReactionThermo/rhoReactionThermo.C
rhoReactionThermo/rhoReactionThermos.C

derivedFvPatchFields/fixedUnburntEnthalpy/fixedUnburntEnthalpyFvPatchScalarField.C
derivedFvPatchFields/gradientUnburntEnthalpy/gradientUnburntEnthalpyFvPatchScalarField.C
derivedFvPatchFields/mixedUnburntEnthalpy/mixedUnburntEnthalpyFvPatchScalarField.C

functionObjects/moleFractions/moleFractionsFunctionObjects.C

LIB = $(FOAM_USER_LIBBIN)/libreactionThermophysicalModels
Code:
EXE_INC = \
    -I$(LIB_SRC)/transportModels/compressible/lnInclude \
    -I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
    -I$(WM_PROJECT_USER_DIR)/src/thermophysicalModels/specie/lnInclude \
    -I$(LIB_SRC)/thermophysicalModels/solidSpecie/lnInclude \
    -I$(LIB_SRC)/finiteVolume/lnInclude

LIB_LIBS = \
    -lcompressibleTransportModels \
    -lfluidThermophysicalModels \
    -L$(FOAM_USER_LIBBIN)/lspecie \
    -lsolidSpecie \
    -lfiniteVolume
John, Why did you change the original files of openfoam. Normally its not recommended and one should create new libraries for implementation. I tried creating my own but didnt succeed in implementation.
m.omair is offline   Reply With Quote

Old   August 6, 2020, 09:44
Default
  #28
Member
 
Join Date: Sep 2018
Location: France
Posts: 62
Rep Power: 8
john myce is on a distinguished road
Quote:
Originally Posted by m.omair View Post
John, Why did you change the original files of openfoam. Normally its not recommended and one should create new libraries for implementation. I tried creating my own but didnt succeed in implementation.
Hi Omair,

I am still a beginner about coding & modify the code, but in this case I created my own libraries (specie & libreactionThermophysicalModels) with the mention "FOAM_USER_LIBBIN" to add new thermophysical properties combination to a tuned solver. And I had to source some libraries from the main code to compile properly. As far as I know, this process did not change the main code.

Cheers.
m.omair likes this.
john myce is offline   Reply With Quote

Old   August 6, 2020, 12:58
Default
  #29
New Member
 
Omair
Join Date: May 2017
Posts: 9
Rep Power: 9
m.omair is on a distinguished road
Thanks for the clarification John. I have understood. Actually as you didnt change the libraries name, so i thought you have modified the original code.
m.omair is offline   Reply With Quote

Old   October 30, 2020, 01:22
Default Implementing PR EOS - reactingFoam
  #30
New Member
 
Join Date: Jun 2011
Posts: 3
Rep Power: 15
pkundu is on a distinguished road
Hi Tiziano,
I was having the exact same error with reactingFoam and implementing PR EOS. I can compile the code but does not run beyond foamChemistryReader. Can you explain how you got rid of this error?
pkundu is offline   Reply With Quote

Old   October 30, 2020, 10:02
Default
  #31
New Member
 
Tiziano Maffei
Join Date: Jun 2013
Location: Milan (Italy)
Posts: 11
Rep Power: 13
tmaffei is on a distinguished road
Hi pkundu,

following I have reported the list of file which I have modified with the relative modifications. These file are in OpenFoam-6/src/thermophysicalModels:

1)./chemistryModel/chemistryModel/BasicChemistryModel/BasicChemistryModels.C:

//Add
makeChemistryModelType
(
StandardChemistryModel,
psiReactionThermo,
PengRobinsonGasPhysics
);

makeChemistryModelType
(
TDACChemistryModel,
psiReactionThermo,
PengRobinsonGasPhysics
);


2)./chemistryModel/chemistryModel/TDACChemistryModel/reduction/makeChemistryReductionMethods.C:
//Add
makeChemistryReductionMethods(psiReactionThermo, PengRobinsonGasPhysics);


3)./chemistryModel/chemistrySolver/chemistrySolver/makeChemistrySolvers.C:
//Add
makeChemistrySolverTypes(psiReactionThermo, PengRobinsonGasPhysics);

4)./specie/include/thermoPhysicsTypes.H:
//Add
#include "PengRobinsonGas.H"

//Add
typedef
sutherlandTransport
<
species::thermo
<
janafThermo
<
PengRobinsonGas<specie>
>,
sensibleEnthalpy
>
> PengRobinsonGasPhysics;


5)./specie/include/reactionTypes.H:
//Add
typedef Reaction<PengRobinsonGasPhysics> PengRobinsonGasReaction;

6)./specie/reaction/reactions/makeReaction.H:
//Add
#include "PengRobinsonGas.H"

7)./specie/reaction/reactions/makeReactions.C:
/Add
makeReactions(PengRobinsonGasPhysics, PengRobinsonGasReaction)

8)./reactionThermo/chemistryReaders/chemistryReader/makeChemistryReaders.C:
//Add
makeChemistryReader(PengRobinsonGasPhysics);

//Add
makeChemistryReaderType(foamChemistryReader, PengRobinsonGasPhysics);

9)./reactionThermo/psiReactionThermo/psiReactionThermos.C:
//Add
#include "PengRobinsonGas.H"

//Add
makeThermoPhysicsReactionThermos
(
psiThermo,
psiReactionThermo,
hePsiThermo,
reactingMixture,
PengRobinsonGasPhysics
);


Later, you have to recompile the folder thermophysicalModels typing "./Allwmake"

Regards

Tiziano
tmaffei is offline   Reply With Quote

Old   December 13, 2020, 02:40
Default
  #32
New Member
 
Join Date: Jun 2011
Posts: 3
Rep Power: 15
pkundu is on a distinguished road
Tiziano,
Thanks a lot for the detailed explanation, really appreciate it. I was able to compile the code. However, I get this error, shown below, after the compilation. I have tried different OF versions, but end up getting the same error after re-compiling the code. Did you make any changes to the make files?


Thanks,
Prithwish.


sprayFoam: symbol lookup error: /home/prithwish/hybridCentralFoam/OpenFOAM-v1912/platforms/linux64GccDPInt32Opt/lib/libchemistryModel.so: undefined symbol: _ZN4Foam25chemistryTabulationMethodINS_17psiReacti onThermoENS_19sutherlandTransportINS_7species6ther moINS_11janafThermoINS_15PengRobinsonGasINS_6speci eEEEEENS_16sensibleEnthalpyEEEEEE30dictionaryConst ructorTablePtr_E
pkundu is offline   Reply With Quote

Old   December 18, 2020, 16:01
Default
  #33
New Member
 
Tiziano Maffei
Join Date: Jun 2013
Location: Milan (Italy)
Posts: 11
Rep Power: 13
tmaffei is on a distinguished road
Hi Prithwish

could you share with me your case?

Tiziano
tmaffei is offline   Reply With Quote

Old   December 19, 2020, 15:39
Default
  #34
New Member
 
Join Date: Jun 2011
Posts: 3
Rep Power: 15
pkundu is on a distinguished road
I have attached the case here. However, at this point, none of the cases that use the reacting flow solvers are running.
Attached Files
File Type: gz testCase_eos.tar.gz (165.4 KB, 19 views)
pkundu is offline   Reply With Quote

Old   September 13, 2021, 11:17
Default
  #35
Member
 
UOCFD
Join Date: Oct 2020
Posts: 40
Rep Power: 6
uosilos is on a distinguished road
Quote:
Originally Posted by tmaffei View Post
Hi pkundu,

following I have reported the list of file which I have modified with the relative modifications. These file are in OpenFoam-6/src/thermophysicalModels:

1)./chemistryModel/chemistryModel/BasicChemistryModel/BasicChemistryModels.C:

//Add
makeChemistryModelType
(
StandardChemistryModel,
psiReactionThermo,
PengRobinsonGasPhysics
);

makeChemistryModelType
(
TDACChemistryModel,
psiReactionThermo,
PengRobinsonGasPhysics
);


2)./chemistryModel/chemistryModel/TDACChemistryModel/reduction/makeChemistryReductionMethods.C:
//Add
makeChemistryReductionMethods(psiReactionThermo, PengRobinsonGasPhysics);


3)./chemistryModel/chemistrySolver/chemistrySolver/makeChemistrySolvers.C:
//Add
makeChemistrySolverTypes(psiReactionThermo, PengRobinsonGasPhysics);

4)./specie/include/thermoPhysicsTypes.H:
//Add
#include "PengRobinsonGas.H"

//Add
typedef
sutherlandTransport
<
species::thermo
<
janafThermo
<
PengRobinsonGas<specie>
>,
sensibleEnthalpy
>
> PengRobinsonGasPhysics;


5)./specie/include/reactionTypes.H:
//Add
typedef Reaction<PengRobinsonGasPhysics> PengRobinsonGasReaction;

6)./specie/reaction/reactions/makeReaction.H:
//Add
#include "PengRobinsonGas.H"

7)./specie/reaction/reactions/makeReactions.C:
/Add
makeReactions(PengRobinsonGasPhysics, PengRobinsonGasReaction)

8)./reactionThermo/chemistryReaders/chemistryReader/makeChemistryReaders.C:
//Add
makeChemistryReader(PengRobinsonGasPhysics);

//Add
makeChemistryReaderType(foamChemistryReader, PengRobinsonGasPhysics);

9)./reactionThermo/psiReactionThermo/psiReactionThermos.C:
//Add
#include "PengRobinsonGas.H"

//Add
makeThermoPhysicsReactionThermos
(
psiThermo,
psiReactionThermo,
hePsiThermo,
reactingMixture,
PengRobinsonGasPhysics
);


Later, you have to recompile the folder thermophysicalModels typing "./Allwmake"

Regards

Tiziano

Hello Tiziano,


I am trying to adapt your solution to OF8 in order to use Peng-Robinson with coalChemistry solver. Some of the libraries and paths have changed since v6, so I can not follow your instructions. Any help?


Thanks in advance

Last edited by uosilos; September 14, 2021 at 11:43.
uosilos is offline   Reply With Quote

Old   April 29, 2022, 16:35
Default
  #36
New Member
 
Chris
Join Date: Nov 2021
Posts: 12
Rep Power: 4
Jury is on a distinguished road
Did you get it fixed?

Here's my error code:

Code:
wmake reactionThermo
g++ -std=c++11 -m64 -pthread -DOPENFOAM=2112 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -Wextra -Wold-style-cast -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -Wno-attributes -Wno-unknown-pragmas  -O3  -DNoRepository -ftemplate-depth-100 -I/home/d0220280/OpenFOAM/OpenFOAM-v2112/src/finiteVolume/lnInclude -I/home/d0220280/OpenFOAM/OpenFOAM-v2112/src/transportModels/compressible/lnInclude -I/home/d0220280/OpenFOAM/OpenFOAM-v2112/src/thermophysicalModels/basic/lnInclude -I/home/d0220280/OpenFOAM/OpenFOAM-v2112/src/thermophysicalModels/specie/lnInclude -I/home/d0220280/OpenFOAM/OpenFOAM-v2112/src/thermophysicalModels/solidSpecie/lnInclude -I/home/d0220280/OpenFOAM/OpenFOAM-v2112/src/thermophysicalModels/thermophysicalProperties/lnInclude -I/home/d0220280/OpenFOAM/OpenFOAM-v2112/src/functionObjects/field/lnInclude -iquote. -IlnInclude -I/home/d0220280/OpenFOAM/OpenFOAM-v2112/src/OpenFOAM/lnInclude -I/home/d0220280/OpenFOAM/OpenFOAM-v2112/src/OSspecific/POSIX/lnInclude   -fPIC -c chemistryReaders/chemistryReader/makeChemistryReaders.C -o Make/linux64GccDPInt32Opt/chemistryReaders/chemistryReader/makeChemistryReaders.o
In file included from /home/d0220280/OpenFOAM/OpenFOAM-v2112/src/OpenFOAM/lnInclude/typeInfo.H:60,
                 from /home/d0220280/OpenFOAM/OpenFOAM-v2112/src/OpenFOAM/lnInclude/IOobject.H:102,
                 from /home/d0220280/OpenFOAM/OpenFOAM-v2112/src/OpenFOAM/lnInclude/regIOobject.H:44,
                 from /home/d0220280/OpenFOAM/OpenFOAM-v2112/src/OpenFOAM/lnInclude/GeometricField.H:45,
                 from /home/d0220280/OpenFOAM/OpenFOAM-v2112/src/OpenFOAM/lnInclude/GeometricScalarField.H:40,
                 from /home/d0220280/OpenFOAM/OpenFOAM-v2112/src/OpenFOAM/lnInclude/GeometricFields.H:40,
                 from /home/d0220280/OpenFOAM/OpenFOAM-v2112/src/finiteVolume/lnInclude/volFields.H:39,
                 from /home/d0220280/OpenFOAM/OpenFOAM-v2112/src/thermophysicalModels/basic/lnInclude/basicThermo.H:49,
                 from /home/d0220280/OpenFOAM/OpenFOAM-v2112/src/thermophysicalModels/basic/lnInclude/fluidThermo.H:41,
                 from /home/d0220280/OpenFOAM/OpenFOAM-v2112/src/thermophysicalModels/basic/lnInclude/makeThermo.H:38,
                 from ./makeReactionThermo.H:32,
                 from chemistryReaders/chemistryReader/makeChemistryReaders.C:28:
chemistryReaders/chemistryReader/makeChemistryReaders.C:44:21: error: \u2018PengRobinsonGasPhysics\u2019 was not declared in this scope
 makeChemistryReader(PengRobinsonGasPhysics);
                     ^~~~~~~~~~~~~~~~~~~~~~
/home/d0220280/OpenFOAM/OpenFOAM-v2112/src/OpenFOAM/lnInclude/className.H:93:24: note: in definition of macro \u2018defineTypeNameWithName\u2019
     const ::Foam::word Type::typeName(Name)
                        ^~~~
Jury is offline   Reply With Quote

Old   July 16, 2024, 04:52
Default
  #37
New Member
 
li xuejiao
Join Date: Jul 2024
Posts: 2
Rep Power: 0
Li Xuejiao is on a distinguished road
Quote:
Originally Posted by tmaffei View Post
Hi Mick,

thanks for your answer. At the end I have found the error and now I can able to use PengRobinsonGas Eos with reactingFoam.
Furthermore, I have modified the mixing rules applied to critical pressure, temperature and so on using molar fraction instead of mass fraction. In this way my results are more similar to ones obtained with other software like fluent or unisim.

Thanks for your availability

Tiziano
Hi Tiziano,
I also encountered the same problem while using ReactingFoam and PengRobinGas Eos on the tutorial case counterFlowFlame2D. Could you please let me know if you have made any other modifications besides modifying the mixing criteria? The error I encountered is

PIMPLE: Operating solver in PISO mode

Reading thermophysical properties

Selecting thermodynamics package
{
type hePsiThermo;
mixture reactingMixture;
transport sutherland;
thermo janaf;
energy sensibleEnthalpy;
equationOfState PengRobinsonGas;
specie specie;
}

Selecting chemistryReader foamChemistryReader
#0 Foam::error:rintStack(Foam::Ostream&) at ??:?
#1 Foam::sigFpe::sigHandler(int) at ??:?
#2 ? in "/lib/x86_64-linux-gnu/libc.so.6"
#3 Foam::janafThermo<Foam::PengRobinsonGas<Foam::spec ie> > Foam:perator==<Foam::PengRobinsonGas<Foam::speci e> >(Foam::janafThermo<Foam::PengRobinsonGas<Foam::sp ecie> > const&, Foam::janafThermo<Foam::PengRobinsonGas<Foam::spec ie> > const&) at ??:?
#4 Foam::Reaction<Foam::sutherlandTransport<Foam::spe cies::thermo<Foam::janafThermo<Foam::PengRobinsonG as<Foam::specie> >, Foam::sensibleEnthalpy> > >::setThermo(Foam::HashPtrTable<Foam::sutherlandTr ansport<Foam::species::thermo<Foam::janafThermo<Fo am::PengRobinsonGas<Foam::specie> >, Foam::sensibleEnthalpy> >, Foam::word, Foam::string::hash> const&) at ??:?
#5 Foam::Reaction<Foam::sutherlandTransport<Foam::spe cies::thermo<Foam::janafThermo<Foam::PengRobinsonG as<Foam::specie> >, Foam::sensibleEnthalpy> > >::Reaction(Foam::hashedWordList const&, Foam::HashPtrTable<Foam::sutherlandTransport<Foam: :species::thermo<Foam::janafThermo<Foam::PengRobin sonGas<Foam::specie> >, Foam::sensibleEnthalpy> >, Foam::word, Foam::string::hash> const&, Foam::dictionary const&) at ??:?
#6 Foam::Reaction<Foam::sutherlandTransport<Foam::spe cies::thermo<Foam::janafThermo<Foam::PengRobinsonG as<Foam::specie> >, Foam::sensibleEnthalpy> > >::adddictionaryConstructorToTable<Foam::Reversibl eReaction<Foam::Reaction, Foam::sutherlandTransport<Foam::species::thermo<Fo am::janafThermo<Foam::PengRobinsonGas<Foam::specie > >, Foam::sensibleEnthalpy> >, Foam::thirdBodyArrheniusReactionRate> >::New(Foam::hashedWordList const&, Foam::HashPtrTable<Foam::sutherlandTransport<Foam: :species::thermo<Foam::janafThermo<Foam::PengRobin sonGas<Foam::specie> >, Foam::sensibleEnthalpy> >, Foam::word, Foam::string::hash> const&, Foam::dictionary const&) at ??:?
#7 Foam::Reaction<Foam::sutherlandTransport<Foam::spe cies::thermo<Foam::janafThermo<Foam::PengRobinsonG as<Foam::specie> >, Foam::sensibleEnthalpy> > >::New(Foam::hashedWordList const&, Foam::HashPtrTable<Foam::sutherlandTransport<Foam: :species::thermo<Foam::janafThermo<Foam::PengRobin sonGas<Foam::specie> >, Foam::sensibleEnthalpy> >, Foam::word, Foam::string::hash> const&, Foam::dictionary const&) at ??:?
#8 Foam::ReactionList<Foam::sutherlandTransport<Foam: :species::thermo<Foam::janafThermo<Foam::PengRobin sonGas<Foam::specie> >, Foam::sensibleEnthalpy> > >::readReactionDict() at ??:?
#9 Foam::foamChemistryReader<Foam::sutherlandTranspor t<Foam::species::thermo<Foam::janafThermo<Foam::Pe ngRobinsonGas<Foam::specie> >, Foam::sensibleEnthalpy> > >::foamChemistryReader(Foam::dictionary const&, Foam::hashedWordList&) at ??:?
#10 Foam::chemistryReader<Foam::sutherlandTransport<Fo am::species::thermo<Foam::janafThermo<Foam::PengRo binsonGas<Foam::specie> >, Foam::sensibleEnthalpy> > >::adddictionaryConstructorToTable<Foam::foamChemi stryReader<Foam::sutherlandTransport<Foam::species ::thermo<Foam::janafThermo<Foam::PengRobinsonGas<F oam::specie> >, Foam::sensibleEnthalpy> > > >::New(Foam::dictionary const&, Foam::hashedWordList&) at ??:?
#11 Foam::chemistryReader<Foam::sutherlandTransport<Fo am::species::thermo<Foam::janafThermo<Foam::PengRo binsonGas<Foam::specie> >, Foam::sensibleEnthalpy> > >::New(Foam::dictionary const&, Foam::hashedWordList&) at ??:?
#12 Foam::reactingMixture<Foam::sutherlandTransport<Fo am::species::thermo<Foam::janafThermo<Foam::PengRo binsonGas<Foam::specie> >, Foam::sensibleEnthalpy> > >::reactingMixture(Foam::dictionary const&, Foam::fvMesh const&, Foam::word const&) at ??:?
#13 Foam::heThermo<Foam:siReactionThermo, Foam::SpecieMixture<Foam::reactingMixture<Foam::su therlandTransport<Foam::species::thermo<Foam::jana fThermo<Foam::PengRobinsonGas<Foam::specie> >, Foam::sensibleEnthalpy> > > > >::heThermo(Foam::fvMesh const&, Foam::word const&) at ??:?
#14 Foam:siReactionThermo::addfvMeshConstructorToTab le<Foam::hePsiThermo<Foam:siReactionThermo, Foam::SpecieMixture<Foam::reactingMixture<Foam::su therlandTransport<Foam::species::thermo<Foam::jana fThermo<Foam::PengRobinsonGas<Foam::specie> >, Foam::sensibleEnthalpy> > > > > >::New(Foam::fvMesh const&, Foam::word const&) at ??:?
#15 Foam::autoPtr<Foam:siReactionThermo> Foam::basicThermo::New<Foam:siReactionThermo>(Fo am::fvMesh const&, Foam::word const&) at ??:?
#16 Foam:siReactionThermo::New(Foam::fvMesh const&, Foam::word const&) at ??:?
#17 ? in "/home/zhuoying_jin/OpenFOAM-6/platforms/linux64GccDPInt32Opt/bin/reactingFoam"
#18 ? in "/lib/x86_64-linux-gnu/libc.so.6"
#19 __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
#20 ? in "/home/zhuoying_jin/OpenFOAM-6/platforms/linux64GccDPInt32Opt/bin/reactingFoam"
Floating point exception (core dumped)
Li Xuejiao 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
Error using kOmegaSST in sprayFoam CFDUser_ OpenFOAM Running, Solving & CFD 17 November 20, 2023 16:29
SprayFOAM with manualInjection marcomacchi OpenFOAM Running, Solving & CFD 0 June 16, 2014 12:25
sprayFoam crashes lukasfischer OpenFOAM Running, Solving & CFD 3 July 14, 2013 12:08
Fluent & Barotropic EOS fivos FLUENT 0 July 11, 2013 04:32
Solid EOS adam Main CFD Forum 5 March 18, 2008 14:12


All times are GMT -4. The time now is 16:12.