CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Community Contributions (https://www.cfd-online.com/Forums/openfoam-community-contributions/)
-   -   [Other] Adding solvers from DensityBasedTurbo to foam-extend 3.0 (https://www.cfd-online.com/Forums/openfoam-community-contributions/151678-adding-solvers-densitybasedturbo-foam-extend-3-0-a.html)

Seroga April 15, 2015 05:23

Adding solvers from DensityBasedTurbo to foam-extend 3.0
 
Hi, everyone!

I have a problem.
I have a OpenFOAM-ext-3.0 installed.
And I want to add solvers from http://sourceforge.net/p/openfoam-ex...nicMRFDyMFoam/

What is the way I must do that?

I tried to do it like this:

Quote:

$sudo su
#source /opt/foam/foam-extend-3.0/etc/bashrc
#/opt/foam/foam-extend-3.0/applications/OF_ext_DensityBasedTurbo/src/ ./Allwmake
But in this case I get error messages like

Quote:

SlopeLimiter/BarthJespersenSlope/BarthJespersenSlope.C:30:27: fatal error: LimitedScheme.H: Нет такого файла или каталога
#include "LimitedScheme.H"
^
compilation terminated.
What should I do? Or do I do it absolutely wrong?

wyldckat April 19, 2015 14:19

Quick answer: Installation instructions are provided here: http://openfoamwiki.net/index.php/Ex...sityBasedTurbo

Seroga May 24, 2015 06:33

Thanks a lot, but that didn't work...
I got a lot of errors like could not open file after
Quote:

wmake libso $FOAM_SRC/finiteVolume
What should I do?

wyldckat May 24, 2015 09:34

Greetings Seroga,

OK, the problem is that your foam-extend 3.0 is installed as root.
As long as the source code for DensityBasedTurbo is located in your normal user account, you only need to do the following two steps as root:
Code:

cp -r timeStepping/MRF/* $FOAM_SRC/finiteVolume/cfdTools/general/MRF/
wmake libso $FOAM_SRC/finiteVolume

the remaining steps should be done as normal user.

In other words:
Code:

mkdir -p $FOAM_RUN
cd $FOAM_RUN/..
git clone git://git.code.sf.net/p/openfoam-extend/DensityBasedTurbo DensityBasedTurbo
cd DensityBasedTurbo/src

su
source /opt/foam/foam-extend-3.0/etc/bashrc
cp -r timeStepping/MRF/* $FOAM_SRC/finiteVolume/cfdTools/general/MRF/
wmake libso $FOAM_SRC/finiteVolume
exit

./Allwmake

Best regards,
Bruno

Seroga May 24, 2015 09:43

I've already tried that. But no result...

Here is the log:
Code:

root@user-System-Product-Name:/home/user/foam/user-3.0/DensityBasedTurbo/src# wmake libso $FOAM_SRC/finiteVolume
Making dependency list for source file cfdTools/general/MRF/MRFZone.C
could not open file dictionary.H for source file cfdTools/general/MRF/MRFZone.C
could not open file wordList.H for source file cfdTools/general/MRF/MRFZone.C
could not open file labelList.H for source file cfdTools/general/MRF/MRFZone.C
could not open file dimensionedScalar.H for source file cfdTools/general/MRF/MRFZone.C
could not open file dimensionedVector.H for source file cfdTools/general/MRF/MRFZone.C
could not open file fieldTypes.H for source file cfdTools/general/MRF/MRFZone.C
Making dependency list for source file cfdTools/general/MRF/MRFZones.C
could not open file objectRegistry.H for source file cfdTools/general/MRF/MRFZone.C
could not open file GeometricFields.H for source file cfdTools/general/MRF/MRFZone.C
could not open file GeoMesh.H for source file cfdTools/general/MRF/MRFZone.C
could not open file polyMesh.H for source file cfdTools/general/MRF/MRFZone.C
could not open file lduMesh.H for source file cfdTools/general/MRF/MRFZone.C
could not open file primitiveMesh.H for source file cfdTools/general/MRF/MRFZone.C
could not open file polyPatch.H for source file cfdTools/general/MRF/MRFZone.C
could not open file SubList.H for source file cfdTools/general/MRF/MRFZone.C
could not open file typeInfo.H for source file cfdTools/general/MRF/MRFZone.C
could not open file tmp.H for source file cfdTools/general/MRF/MRFZone.C
could not open file primitiveFields.H for source file cfdTools/general/MRF/MRFZone.C
could not open file SubField.H for source file cfdTools/general/MRF/MRFZone.C
could not open file autoPtr.H for source file cfdTools/general/MRF/MRFZone.C
could not open file runTimeSelectionTables.H for source file cfdTools/general/MRF/MRFZone.C
could not open file PtrList.H for source file cfdTools/general/MRF/MRFZone.C
could not open file dictionary.H for source file cfdTools/general/MRF/MRFZones.C
could not open file wordList.H for source file cfdTools/general/MRF/MRFZones.C
could not open file labelList.H for source file cfdTools/general/MRF/MRFZones.C
could not open file dimensionedScalar.H for source file cfdTools/general/MRF/MRFZones.C
could not open file dimensionedVector.H for source file cfdTools/general/MRF/MRFZones.C
could not open file fieldTypes.H for source file cfdTools/general/MRF/MRFZones.C
could not open file lduInterfacePtrsList.H for source file cfdTools/general/MRF/MRFZone.C
could not open file scalar.H for source file cfdTools/general/MRF/MRFZone.C
could not open file objectRegistry.H for source file cfdTools/general/MRF/MRFZones.C
could not open file GeometricFields.H for source file cfdTools/general/MRF/MRFZones.C
could not open file IOdictionary.H for source file cfdTools/general/MRF/MRFZone.C
could not open file GeoMesh.H for source file cfdTools/general/MRF/MRFZones.C
could not open file polyMesh.H for source file cfdTools/general/MRF/MRFZones.C
could not open file solution.H for source file cfdTools/general/MRF/MRFZone.C
could not open file lduMesh.H for source file cfdTools/general/MRF/MRFZones.C
could not open file primitiveMesh.H for source file cfdTools/general/MRF/MRFZones.C
could not open file className.H for source file cfdTools/general/MRF/MRFZone.C
could not open file DimensionedField.H for source file cfdTools/general/MRF/MRFZone.C
could not open file pointFieldsFwd.H for source file cfdTools/general/MRF/MRFZone.C
could not open file polyPatch.H for source file cfdTools/general/MRF/MRFZones.C
could not open file SubList.H for source file cfdTools/general/MRF/MRFZones.C
could not open file typeInfo.H for source file cfdTools/general/MRF/MRFZones.C
could not open file tmp.H for source file cfdTools/general/MRF/MRFZones.C
could not open file primitiveFields.H for source file cfdTools/general/MRF/MRFZones.C
could not open file SubField.H for source file cfdTools/general/MRF/MRFZones.C
could not open file autoPtr.H for source file cfdTools/general/MRF/MRFZones.C
could not open file runTimeSelectionTables.H for source file cfdTools/general/MRF/MRFZones.C
could not open file IOobject.H for source file cfdTools/general/MRF/MRFZone.C
could not open file GeometricField.H for source file cfdTools/general/MRF/MRFZone.C
could not open file PtrList.H for source file cfdTools/general/MRF/MRFZones.C
could not open file lduInterfacePtrsList.H for source file cfdTools/general/MRF/MRFZones.C
could not open file scalar.H for source file cfdTools/general/MRF/MRFZones.C
could not open file IOdictionary.H for source file cfdTools/general/MRF/MRFZones.C
could not open file solution.H for source file cfdTools/general/MRF/MRFZones.C
could not open file className.H for source file cfdTools/general/MRF/MRFZones.C
could not open file DimensionedField.H for source file cfdTools/general/MRF/MRFZones.C
could not open file pointFieldsFwd.H for source file cfdTools/general/MRF/MRFZones.C
could not open file IOobject.H for source file cfdTools/general/MRF/MRFZones.C
could not open file GeometricField.H for source file cfdTools/general/MRF/MRFZones.C
could not open file lduMatrix.H for source file cfdTools/general/MRF/MRFZone.C
could not open file dimensionedTypes.H for source file cfdTools/general/MRF/MRFZone.C
could not open file zeroField.H for source file cfdTools/general/MRF/MRFZone.C
could not open file BlockLduInterfaceField.H for source file cfdTools/general/MRF/MRFZone.C
could not open file CoeffField.H for source file cfdTools/general/MRF/MRFZone.C
could not open file lduInterfaceField.H for source file cfdTools/general/MRF/MRFZone.C
could not open file lduInterface.H for source file cfdTools/general/MRF/MRFZone.C
could not open file coupledPolyPatch.H for source file cfdTools/general/MRF/MRFZone.C
could not open file lduMatrix.H for source file cfdTools/general/MRF/MRFZones.C
could not open file dimensionedTypes.H for source file cfdTools/general/MRF/MRFZones.C
could not open file zeroField.H for source file cfdTools/general/MRF/MRFZones.C
could not open file BlockLduInterfaceField.H for source file cfdTools/general/MRF/MRFZones.C
could not open file CoeffField.H for source file cfdTools/general/MRF/MRFZones.C
could not open file lduInterfaceField.H for source file cfdTools/general/MRF/MRFZones.C
could not open file lduInterface.H for source file cfdTools/general/MRF/MRFZones.C
could not open file coupledPolyPatch.H for source file cfdTools/general/MRF/MRFZones.C
could not open file profiling.H for source file cfdTools/general/MRF/MRFZone.C
could not open file syncTools.H for source file cfdTools/general/MRF/MRFZone.C
could not open file faceSet.H for source file cfdTools/general/MRF/MRFZone.C
could not open file geometricOneField.H for source file cfdTools/general/MRF/MRFZone.C
could not open file profiling.H for source file cfdTools/general/MRF/MRFZones.C
could not open file IOPtrList.H for source file cfdTools/general/MRF/MRFZones.C
could not open file Time.H for source file cfdTools/general/MRF/MRFZones.C
could not open file parRun.H for source file cfdTools/general/MRF/MRFZones.C
could not open file primitiveFieldsFwd.H for source file cfdTools/general/MRF/MRFZones.C
could not open file Field.H for source file cfdTools/general/MRF/MRFZones.C
could not open file dimensionedType.H for source file cfdTools/general/MRF/MRFZones.C
could not open file HashTable.H for source file cfdTools/general/MRF/MRFZones.C
could not open file geometricOneField.H for source file cfdTools/general/MRF/MRFZones.C
could not open file uniformDimensionedFields.H for source file cfdTools/general/MRF/MRFZones.C
could not open file label.H for source file cfdTools/general/MRF/MRFZones.C
could not open file mathematicalConstants.H for source file cfdTools/general/MRF/MRFZones.C
could not open file OSspecific.H for source file cfdTools/general/MRF/MRFZones.C
could not open file argList.H for source file cfdTools/general/MRF/MRFZones.C
could not open file timeSelector.H for source file cfdTools/general/MRF/MRFZones.C
SOURCE=fvMesh/fvMeshGeometry.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200 -I/opt/foam/foam-extend-3.0/src/triSurface/lnInclude    -I/opt/foam/foam-extend-3.0/src/meshTools/lnInclude -IlnInclude -I. -I/opt/foam/foam-extend-3.0/src/foam/lnInclude -I/opt/foam/foam-extend-3.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/fvMeshGeometry.o
SOURCE=fvMesh/singleCellFvMesh/singleCellFvMesh.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200 -I/opt/foam/foam-extend-3.0/src/triSurface/lnInclude    -I/opt/foam/foam-extend-3.0/src/meshTools/lnInclude -IlnInclude -I. -I/opt/foam/foam-extend-3.0/src/foam/lnInclude -I/opt/foam/foam-extend-3.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/singleCellFvMesh.o
SOURCE=fvMesh/fvMesh.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200 -I/opt/foam/foam-extend-3.0/src/triSurface/lnInclude    -I/opt/foam/foam-extend-3.0/src/meshTools/lnInclude -IlnInclude -I. -I/opt/foam/foam-extend-3.0/src/foam/lnInclude -I/opt/foam/foam-extend-3.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/fvMesh.o
SOURCE=fvMesh/fvMeshSubset/fvMeshSubset.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-200 -I/opt/foam/foam-extend-3.0/src/triSurface/lnInclude    -I/opt/foam/foam-extend-3.0/src/meshTools/lnInclude -IlnInclude -I. -I/opt/foam/foam-extend-3.0/src/foam/lnInclude -I/opt/foam/foam-extend-3.0/src/OSspecific/POSIX/lnInclude  -fPIC -c $SOURCE -o Make/linux64GccDPOpt/fvMeshSubset.o
In file included from fvMesh/singleCellFvMesh/singleCellFvMesh.H:41:0,
                from fvMesh/singleCellFvMesh/singleCellFvMesh.C:26:
lnInclude/fvPatchFieldMapper.H:35:29: fatal error: primitiveFields.H: No such file or directory
compilation terminated.
In file included from fvMesh/fvMeshSubset/fvMeshSubset.H:57:0,
                from fvMesh/fvMeshSubset/fvMeshSubset.C:34:
lnInclude/fvMesh.H:50:22: fatal error: polyMesh.H: No such file or directory
compilation terminated.
In file included from fvMesh/fvMesh.C:26:0:
fvMesh/fvMesh.H:50:22: fatal error: polyMesh.H: No such file or directory
compilation terminated.
In file included from fvMesh/fvMeshGeometry.C:26:0:
fvMesh/fvMesh.H:50:22: fatal error: polyMesh.H: No such file or directory
compilation terminated.
make: *** [Make/linux64GccDPOpt/singleCellFvMesh.o] Error 1
make: *** Waiting for unfinished jobs....
make: *** [Make/linux64GccDPOpt/fvMesh.o] Error 1
make: *** [Make/linux64GccDPOpt/fvMeshGeometry.o] Error 1
make: *** [Make/linux64GccDPOpt/fvMeshSubset.o] Error 1


wyldckat May 24, 2015 10:33

Quick answer: If you installed foam-extend 3.0 from a Deb package, then try this:
Code:

su -
source /opt/foam/foam-extend-3.0/etc/bashrc
cd $FOAM_SRC
wmakeLnIncludeAll
wmake libso finiteVolume


Seroga May 24, 2015 11:39

Thanks a lot!!! That helped.
Could you please tell one more thing? Now, than I try to run transonicMRFDyMFoam it shows an error: Unknown function type patchMassFlow. That's because this function is used in controlDict added function. What's the way to handle this error?

Moreover, than I try to calculate Mach number for calculated case I get
Code:

--> FOAM FATAL ERROR:
Not Implemented
    Trying to construct an genericFvPatchField on patch inlet_0 of field h

    From function genericFvPatchField<Type>::genericFvPatchField(const fvPatch& p, const DimensionedField<Type, volMesh>& iF)
    in file fields/fvPatchFields/basic/generic/genericFvPatchField.C at line 44.

FOAM aborting

What could that be?

wyldckat May 24, 2015 16:23

Hi Seroga,

Quote:

Originally Posted by Seroga (Post 547493)
Now, than I try to run transonicMRFDyMFoam it shows an error: Unknown function type patchMassFlow. That's because this function is used in controlDict added function. What's the way to handle this error?

You need to also build/install swak4Foam.

Quote:

Originally Posted by Seroga (Post 547493)
Moreover, than I try to calculate Mach number for calculated case I get
Code:

--> FOAM FATAL ERROR:
Not Implemented
    Trying to construct an genericFvPatchField on patch inlet_0 of field h

    From function  genericFvPatchField<Type>::genericFvPatchField(const fvPatch&  p, const DimensionedField<Type, volMesh>& iF)
    in file fields/fvPatchFields/basic/generic/genericFvPatchField.C at line 44.

FOAM aborting

What could that be?

That seems very strange. I've tested in my installation of foam-extend 3.0 the tutorial "run/Axial_Rotor_MRF" from the DensityBasedTurbo toolbox.
  1. I ran the Allrun script;
  2. cancelled after transonicMRFDyMFoam ran a few seconds;
  3. and then I ran Mach.
I had no problems.

My guess is that something went wrong during the other steps in Allrun, because swak4Foam isn't installed.

Best regards,
Bruno

Seroga June 10, 2015 17:02

1 Attachment(s)
I've installed swak4Foam and everything went OK. Thanks for your help!

However, I've tried to use some other solvers from that scope like transonicMRFFSIDyMFoam and faced other problems...
The main error looks like
Quote:

Cannot find file "points" in directory "constant/polyMesh"
But I think that the problem is in blockMesh utility, because it runs first and it log contains next error
Quote:

Cannot find patch none in region region0
I've added all the log files to the message.
Could you, please, help me with this problem?

wyldckat June 12, 2015 17:18

Hi Seroga,

I've got good news and bad news:
  1. That tutorial case seems to work fine in foam-extend 3.1.
  2. I've reproduced the same error in foam-extend 3.0 and I have no idea why it doesn't work :(
Therefore, I suggest you upgrade to foam-extend 3.1.

Best regards,
Bruno


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