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

Error while compiling using wmake of a finite volume method.

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 1, 2017, 11:27
Question Error while compiling using wmake of a finite volume method.
  #1
New Member
 
R.B.
Join Date: Aug 2017
Posts: 7
Rep Power: 9
rbabhi is on a distinguished road
Hi All,

I have downloaded a solver (SbmFoam) that was created around 2012 (exact OF version is unknown).

While compiling in the OF5, I have found several issues while compiling. The first modification I made was to include the following lines to Make/options file:

However now when I run
Code:
wmake
I get the following errors:

Code:
.......5.0/run/SbmFoam$ wmake

Making dependency list for source file SbmFoam.C
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 -O3  -DNoRepository  -ftemplate-depth-100 -I/opt/openfoam5/src/finiteVolume/lnInclude  -I/opt/openfoam5/src/meshTools/lnInclude     -IlnInclude -I.  -I/opt/openfoam5/src/OpenFOAM/lnInclude  -I/opt/openfoam5/src/OSspecific/POSIX/lnInclude   -fPIC -c SbmFoam.C -o  Make/linux64GccDPInt32Opt/SbmFoam.o
SbmFoam.C: In function ‘int main(int, char**)’:
SbmFoam.C:105:31: error: ‘nCorr’ was not declared in this scope
         for (int corr=0; corr<nCorr; corr++)
                               ^
SbmFoam.C:118:26: error: passing ‘const  Foam::fvMatrix<Foam::Vector<double> >’ as ‘this’ argument  discards qualifiers [-fpermissive]
             UEqn().relax();
                          ^
In file included from /opt/openfoam5/src/finiteVolume/lnInclude/fvMatrix.H:1061:0,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/ddtScheme.C:29,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/ddtScheme.H:342,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/fvcDdt.C:28,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/fvcDdt.H:205,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/fvc.H:44,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/fvCFD.H:8,
                 from SbmFoam.C:45:
/opt/openfoam5/src/finiteVolume/lnInclude/fvMatrix.C:674:6: note:   in  call to ‘void Foam::fvMatrix<Type>::relax() [with Type =  Foam::Vector<double>]’
 void Foam::fvMatrix<Type>::relax()
      ^
SbmFoam.C:122:44: error: passing ‘const Foam::GeometricField<double,  Foam::fvPatchField, Foam::volMesh>::Boundary’ as ‘this’ argument  discards qualifiers [-fpermissive]
             p.boundaryField().updateCoeffs();
                                            ^
In file included from /opt/openfoam5/src/OpenFOAM/lnInclude/GeometricField.C:1352:0,
                 from /opt/openfoam5/src/OpenFOAM/lnInclude/GeometricField.H:660,
                 from /opt/openfoam5/src/OpenFOAM/lnInclude/GeometricScalarField.H:38,
                 from /opt/openfoam5/src/OpenFOAM/lnInclude/GeometricFields.H:34,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/volFields.H:37,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/surfaceInterpolationScheme.C:27,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/surfaceInterpolationScheme.H:307,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/surfaceInterpolate.H:41,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/fvc.H:39,
                 from /opt/openfoam5/src/finiteVolume/lnInclude/fvCFD.H:8,
                 from SbmFoam.C:45:
/opt/openfoam5/src/OpenFOAM/lnInclude/GeometricBoundaryField.C:399:6:  note:   in call to ‘void Foam::GeometricField<Type, PatchField,  GeoMesh>::Boundary::updateCoeffs() [with Type = double; PatchField =  Foam::fvPatchField; GeoMesh = Foam::volMesh]’
 void Foam::GeometricField<Type, PatchField, GeoMesh>::Boundary::
      ^
SbmFoam.C:133:42: error: ‘nNonOrthCorr’ was not declared in this scope
             for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
                                          ^
/opt/openfoam5/wmake/rules/General/transform:25: recipe for target 'Make/linux64GccDPInt32Opt/SbmFoam.o' failed
make: *** [Make/linux64GccDPInt32Opt/SbmFoam.o] Error 1

I am new to OpenFOAM and I was wondering if anyone can guide towards the right direction to troubleshoot this issue with this code.

If it is any help, I am running Ubuntu 16.04(guest) on a VirtualBox Windows 10(host).

Many thanks.
rbabhi is offline   Reply With Quote

Reply

Tags
cfd - post, wmake error, wmake problems


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
Lattice Boltzmann method vs Finite Element Method and Finite Volume Method solemnpriest Main CFD Forum 3 August 12, 2013 12:00
Finite Volume Method cfd seeker Main CFD Forum 3 September 8, 2011 05:36
OpenFOAM15 installables are incomplete problem with paraFoam tryingof OpenFOAM Bugs 17 December 7, 2008 05:41
On the damBreak4phaseFine cases paean OpenFOAM Running, Solving & CFD 0 November 14, 2008 22:14
fluent add additional zones for the mesh file SSL FLUENT 2 January 26, 2008 12:55


All times are GMT -4. The time now is 00:09.