CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Community Contributions

[swak4Foam] installing funkySetFields

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 10, 2010, 02:14
Default A Problem
  #21
Member
 
Mohammad Zakerzadeh
Join Date: Dec 2009
Location: Aachen, Germany
Posts: 40
Rep Power: 17
moh1367 is on a distinguished road
Dear foamers!
I have a problem when I using Funky to set a complicated fields .my profile is as below:

funkySetFields -time 0 -field alpha1 -expression 1 -condition "pos().y-1e-9-7.5e-9*exp((pow(pos().x-15e-9,10)+1)*log(1-pow((pos().x-15e-9)/7.5e-9,2)))<=0"

but I think that this module have some problem with power function. I have this error:
Putting "1" into field alpha1 at t = "0" if condition "pos().y-1e-9-7.5e-9*exp((pow(pos().x-15e-9,10)+1)*log(1-pow((pos().x-15e-9)/7.5e-9,2)))<=0" is true

#0 Foam::error:rintStack(Foam::Ostream&) in "/home/Zakerzadeh/OpenFOAM/OpenFOAM-1.6/lib/linuxGccDPOpt/libOpenFOAM.so"
#1 Foam::sigFpe::sigFpeHandler(int) in "/home/Zakerzadeh/OpenFOAM/OpenFOAM-1.6/lib/linuxGccDPOpt/libOpenFOAM.so"
#2 Uninterpreted:
#3 log in "/lib/libm.so.6"
#4 Foam::log(Foam::Field<double>&, Foam::UList<double> const&) in "/home/Zakerzadeh/OpenFOAM/OpenFOAM-1.6/lib/linuxGccDPOpt/libOpenFOAM.so"
#5 Foam::tmp<Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> > Foam::log<Foam::fvPatchField, Foam::volMesh>(Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const&) in "/home/Zakerzadeh/OpenFOAM/Zakerzadeh-1.6/applications/bin/linuxGccDPOpt/funkySetFields"
#6 .L21360 at ValueExpressionParser.C:0
#7 ValueExpressionDriver:arse(std::string const&) in "/home/Zakerzadeh/OpenFOAM/Zakerzadeh-1.6/applications/bin/linuxGccDPOpt/funkySetFields"
#8 doAnExpression(Foam::fvMesh const&, Foam::word const&, Foam::string const&, Foam::string const&, Foam::Time const&, bool, bool, bool, Foam::dimensionSet const&, bool, Foam::List<Foam::word> const&) in "/home/Zakerzadeh/OpenFOAM/Zakerzadeh-1.6/applications/bin/linuxGccDPOpt/funkySetFields"
#9 main in "/home/Zakerzadeh/OpenFOAM/Zakerzadeh-1.6/applications/bin/linuxGccDPOpt/funkySetFields"
#10 __libc_start_main in "/lib/libc.so.6"
#11 Foam::regIOobject::writeObject(Foam::IOstream::str eamFormat, Foam::IOstream::versionNumber, Foam::IOstream::compressionType) const in "/home/Zakerzadeh/OpenFOAM/Zakerzadeh-1.6/applications/bin/linuxGccDPOpt/funkySetFields"
Floating point exception

Is there anyone have any idea about it.
Sincerely
moh1367 is offline   Reply With Quote

Old   March 10, 2010, 04:44
Default
  #22
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
According to error #3 it is due to the log-function. So make sure that you are not evaluating log(r), with r<=0.

Best regards,

Niels
ngj is offline   Reply With Quote

Old   March 10, 2010, 05:05
Default
  #23
Member
 
Mohammad Zakerzadeh
Join Date: Dec 2009
Location: Aachen, Germany
Posts: 40
Rep Power: 17
moh1367 is on a distinguished road
Yes,you are right!

But when I have this problem unless I decrease the power to 2 or 1. I test an easier case with just power term . Its better to test this case . I believe that this program have some problems with power.I appreciate if you have any suggestion about it?


Sincerely
moh1367 is offline   Reply With Quote

Old   March 12, 2010, 10:13
Default
  #24
Member
 
G B
Join Date: Mar 2010
Posts: 37
Rep Power: 16
Disco_Caine is on a distinguished road
This is very embarassing! What had worked previously with OF-1.6, now is not working with OF-1.6.x. I followed my steps but now im getting this error:

Code:
position.hh: In function ‘bool ve::operator==(const ve::position&, const ve::position&)’:
position.hh:136: warning: suggest parentheses around ‘&&’ within ‘||’

ValueExpressionDriver.C: In member function ‘Foam::surfaceScalarField* ValueExpressionDriver::makeAreaField()’:
ValueExpressionDriver.C:462: error: call of overloaded ‘GeometricField(Foam::IOobject, const Foam::fvMesh&, int)’ is ambiguous
/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/src/OpenFOAM/lnInclude/GeometricField.C:421: note: candidates are: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dictionary&) [with Type = double, PatchField = Foam::fvsPatchField, GeoMesh = Foam::surfaceMesh]
/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/src/OpenFOAM/lnInclude/GeometricField.C:257: note:                 Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dimensioned<Type>&, const Foam::word&) [with Type = double, PatchField = Foam::fvsPatchField, GeoMesh = Foam::surfaceMesh]

ValueExpressionDriver.C: In member function ‘Foam::volScalarField* ValueExpressionDriver::makeVolumeField()’:
ValueExpressionDriver.C:482: error: call of overloaded ‘GeometricField(Foam::IOobject, const Foam::fvMesh&, int)’ is ambiguous
/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/src/OpenFOAM/lnInclude/GeometricField.C:421: note: candidates are: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dictionary&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/src/OpenFOAM/lnInclude/GeometricField.C:257: note:                 Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dimensioned<Type>&, const Foam::word&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]

ValueExpressionDriver.C: In member function ‘Foam::volScalarField* ValueExpressionDriver::makeDistanceField()’:
ValueExpressionDriver.C:506: error: call of overloaded ‘GeometricField(Foam::IOobject, const Foam::fvMesh&, int)’ is ambiguous

/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/src/OpenFOAM/lnInclude/GeometricField.C:421: note: candidates are: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dictionary&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]

/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/src/OpenFOAM/lnInclude/GeometricField.C:257: note:                 Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dimensioned<Type>&, const Foam::word&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]

ValueExpressionDriver.C: In member function ‘Foam::volScalarField* 

ValueExpressionDriver::makeRDistanceField(const Foam::volVectorField&)’:

ValueExpressionDriver.C:529: error: call of overloaded ‘GeometricField(Foam::IOobject, const Foam::fvMesh&, int)’ is ambiguous

/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/src/OpenFOAM/lnInclude/GeometricField.C:421: note: candidates are: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dictionary&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]

/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/src/OpenFOAM/lnInclude/GeometricField.C:257: note:                 Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dimensioned<Type>&, const Foam::word&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
make: *** [Make/linux64GccDPOpt/ValueExpressionDriver.o] Error 1
Any ideas? Thanks!
Disco_Caine is offline   Reply With Quote

Old   March 12, 2010, 13:30
Default
  #25
Member
 
G B
Join Date: Mar 2010
Posts: 37
Rep Power: 16
Disco_Caine is on a distinguished road
I do not know what i did, but it is working now. Thanks all.
Disco_Caine is offline   Reply With Quote

Old   March 15, 2010, 07:07
Default
  #26
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by moh1367 View Post
Yes,you are right!

But when I have this problem unless I decrease the power to 2 or 1. I test an easier case with just power term . Its better to test this case . I believe that this program have some problems with power.I appreciate if you have any suggestion about it?
The argument values are passed to the OF::log. One guess would be that for your expression pow(xxx,10) the xxx is too large. Use FSF to write out xxx on its own and have a look at the values.

If you really feel that there is a bug in FSF report it at
https://sourceforge.net/apps/mantisb...e_status_id=-2

Bernhard
gschaider is offline   Reply With Quote

Old   May 7, 2010, 08:00
Default
  #27
New Member
 
C.Z.
Join Date: May 2010
Posts: 4
Rep Power: 16
querdynamik is on a distinguished road
I'm trying to install funkySetFields (v1.6) on OF-1.6, but i get this error in "Allwmake" :

Quote:
....
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libfiniteVolume.so: undefined reference to `Foam::reduce(double&, Foam::sumOp<double> const&)'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libmeshTools.so: undefined reference to `Foam::triSurface::~triSurface()'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libfiniteVolume.so: undefined reference to `Foam::triSurface::~triSurface()'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libmeshTools.so: undefined reference to `Foam::triSurface::markZones(Foam::List<bool> const&, Foam::List<int>&) const'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libmeshTools.so: undefined reference to `Foam::triSurface:perator=(Foam::triSurface const&)'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libmeshTools.so: undefined reference to `Foam::triSurface::edgeOwner() const'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libmeshTools.so: undefined reference to `Foam::triSurface::triSurface()'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libmeshTools.so: undefined reference to `Foam::triSurface::triSurface(Foam::List<Foam::lab elledTri> const&, Foam::List<Foam::geometricSurfacePatch> const&, Foam::Field<Foam::Vector<double> > const&)'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libOpenFOAM.so: undefined reference to `Foam::Pstream::init(int&, char**&)'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libmeshTools.so: undefined reference to `Foam::triSurface::triSurface(Foam::triSurface const&)'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libmeshTools.so: undefined reference to `Foam::decompositionMethod::typeName'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libmeshTools.so: undefined reference to `Foam::triSurface::clearOut()'
/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt/libOpenFOAM.so: undefined reference to `Foam::Pstream::addValidParOptions(Foam::HashTable <Foam::string, Foam::word, Foam::string::hash>&)'
collect2: ld returned 1 exit status
make: *** [/home/HiWi/OpenFOAM/hiwi-1.6/applications/bin/linux64GccDPOpt/funkySetFields] error 1
Can someone help me out and tell what the problem might be?

Thanks in advance!
querdynamik is offline   Reply With Quote

Old   May 10, 2010, 06:24
Default
  #28
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by querdynamik View Post
I'm trying to install funkySetFields (v1.6) on OF-1.6, but i get this error in "Allwmake" :

Can someone help me out and tell what the problem might be?

Thanks in advance!
Something seems to be fundamentally wrong with your OF installation (there seem to be at least two libraries missing). Have you ever successfully compiled another third-party OF-utility? Could you post the stuff just before the error messages start?
gschaider is offline   Reply With Quote

Old   May 10, 2010, 18:06
Default
  #29
Member
 
Join Date: Nov 2009
Posts: 48
Rep Power: 17
farhagim is on a distinguished road
Tx man. this message is very useful for such beginner like me

Quote:
Originally Posted by Disco_Caine View Post
I have fixed my own problem, perhaps this is way too obvious for the almighty linux users, but i shall post it anyways, just in case another new guy runs into the same problem.

1) open up your terminal and make sure you are in the funkySetFields folder, (where the insertGenerated.sh is) and type this:

chmod +x insertGenerated.sh

2) then type:

./insertGenerated.sh

3) then, wmake.

And you are done with funkySetFields


P.S: sorry about the different fonts!
farhagim is offline   Reply With Quote

Old   May 17, 2010, 10:20
Default
  #30
New Member
 
C.Z.
Join Date: May 2010
Posts: 4
Rep Power: 16
querdynamik is on a distinguished road
Quote:
Originally Posted by gschaider View Post
Something seems to be fundamentally wrong with your OF installation (there seem to be at least two libraries missing). Have you ever successfully compiled another third-party OF-utility? Could you post the stuff just before the error messages start?
At first, thx for your answer and sorry for my late reply.

No, i did not even try to compile any OF-utility before. But i realised, that i was trying to install the funkySetFields-Tool from the POSTprocressing-directory. I don't know if that made any difference.
Anyway, now i tried to install it from the PREprocessing directory and got these lines :

Code:
hiwi@wmpc05:~/OpenFOAM/OpenFOAM-1.6/applications/utilities/preProcessing/FunkySetFields> ./Allwmake 
+ wmake funkySetFields
Making dependency list for source file ValueExpressionParser.C
Making dependency list for source file ValueExpressionLexer.C
Making dependency list for source file ValueExpressionDriver.C
Making dependency list for source file funkySetFields.C
SOURCE=ValueExpressionParser.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wno-strict-aliasing -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-40 -IMake/linux64GccDPOpt -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/finiteVolume/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/meshTools/lnInclude -IlnInclude -I. -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OpenFOAM/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OSspecific/POSIX/lnInclude   -fPIC -c $SOURCE -o Make/linux64GccDPOpt/ValueExpressionParser.o
In file included from location.hh:44,
                 from ValueExpressionParser.tab.hh:65,
                 from ValueExpressionParser.tab.cc:68:
position.hh: In function ‘bool ve::operator==(const ve::position&, const ve::position&)’:
position.hh:136: warning: suggest parentheses around && within ||
ValueExpressionParser.tab.cc: In member function ‘unsigned char ve::ValueExpressionParser::yytranslate_(int)’:
ValueExpressionParser.tab.cc:3207: warning: use of old-style cast
SOURCE=ValueExpressionLexer.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wno-strict-aliasing -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-40 -IMake/linux64GccDPOpt -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/finiteVolume/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/meshTools/lnInclude -IlnInclude -I. -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OpenFOAM/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OSspecific/POSIX/lnInclude   -fPIC -c $SOURCE -o Make/linux64GccDPOpt/ValueExpressionLexer.o
lex.ve.c:363: warning: use of old-style cast
lex.ve.c:433: warning: use of old-style cast
lex.ve.c:433: warning: use of old-style cast
In file included from location.hh:44,
                 from ValueExpressionParser.tab.hh:65,
                 from ValueExpressionDriver.H:14,
                 from ValueExpressionLexer.ll:3:
position.hh: In function ‘bool ve::operator==(const ve::position&, const ve::position&)’:
position.hh:136: warning: suggest parentheses around && within ||
lex.ve.c: In function ‘int velex(ve::ValueExpressionParser::semantic_type*, ve::location*, ValueExpressionDriver&)’:
lex.ve.c:8888: warning: use of old-style cast
lex.ve.c:8888: warning: use of old-style cast
lex.ve.c:8905: warning: use of old-style cast
lex.ve.c:8918: warning: use of old-style cast
lex.ve.c:9368: warning: use of old-style cast
lex.ve.c: In function ‘int yy_get_next_buffer()’:
lex.ve.c:9547: warning: use of old-style cast
lex.ve.c:9570: warning: use of old-style cast
lex.ve.c:9583: warning: use of old-style cast
lex.ve.c:9583: warning: use of old-style cast
lex.ve.c:9604: warning: use of old-style cast
lex.ve.c:9604: warning: use of old-style cast
lex.ve.c:9629: warning: use of old-style cast
lex.ve.c:9632: warning: use of old-style cast
lex.ve.c:9632: warning: use of old-style cast
lex.ve.c: In function ‘yy_state_type yy_get_previous_state()’:
lex.ve.c:9667: warning: use of old-style cast
lex.ve.c:9667: warning: use of old-style cast
lex.ve.c: In function ‘int yyinput()’:
lex.ve.c:9785: warning: use of old-style cast
lex.ve.c: In function ‘yy_buffer_state* ve_create_buffer(FILE*, int)’:
lex.ve.c:9884: warning: use of old-style cast
lex.ve.c:9893: warning: use of old-style cast
lex.ve.c: In function ‘void ve_delete_buffer(yy_buffer_state*)’:
lex.ve.c:9919: warning: use of old-style cast
lex.ve.c:9922: warning: use of old-style cast
lex.ve.c:9924: warning: use of old-style cast
lex.ve.c: In function ‘void veensure_buffer_stack()’:
lex.ve.c:10091: warning: use of old-style cast
lex.ve.c:10111: warning: use of old-style cast
lex.ve.c: In function ‘yy_buffer_state* ve_scan_buffer(char*, yy_size_t)’:
lex.ve.c:10139: warning: use of old-style cast
lex.ve.c: In function ‘yy_buffer_state* ve_scan_bytes(const char*, int)’:
lex.ve.c:10192: warning: use of old-style cast
lex.ve.c: In function ‘void yy_push_state(int)’:
lex.ve.c:10228: warning: use of old-style cast
lex.ve.c:10231: warning: use of old-style cast
lex.ve.c:10231: warning: use of old-style cast
lex.ve.c: In function ‘int yy_init_globals()’:
lex.ve.c:10398: warning: use of old-style cast
lex.ve.c:10411: warning: use of old-style cast
lex.ve.c:10412: warning: use of old-style cast
lex.ve.c: In function ‘void* vealloc(yy_size_t)’:
lex.ve.c:10478: warning: use of old-style cast
lex.ve.c: In function ‘void* verealloc(void*, yy_size_t)’:
lex.ve.c:10490: warning: use of old-style cast
lex.ve.c:10490: warning: use of old-style cast
lex.ve.c: In function ‘void vefree(void*)’:
lex.ve.c:10495: warning: use of old-style cast
lex.ve.c: At global scope:
lex.ve.c:10215: warning: ‘void yy_push_state(int)’ defined but not used
lex.ve.c:10243: warning: ‘void yy_pop_state()’ defined but not used
lex.ve.c:10255: warning: ‘int yy_top_state()’ defined but not used
SOURCE=ValueExpressionDriver.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wno-strict-aliasing -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-40 -IMake/linux64GccDPOpt -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/finiteVolume/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/meshTools/lnInclude -IlnInclude -I. -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OpenFOAM/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OSspecific/POSIX/lnInclude   -fPIC -c $SOURCE -o Make/linux64GccDPOpt/ValueExpressionDriver.o
In file included from location.hh:44,
                 from ValueExpressionParser.tab.hh:65,
                 from ValueExpressionDriver.H:14,
                 from ValueExpressionDriver.C:3:
position.hh: In function ‘bool ve::operator==(const ve::position&, const ve::position&)’:
position.hh:136: warning: suggest parentheses around && within ||
SOURCE=funkySetFields.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wno-strict-aliasing -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-40 -IMake/linux64GccDPOpt -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/finiteVolume/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/meshTools/lnInclude -IlnInclude -I. -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OpenFOAM/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OSspecific/POSIX/lnInclude   -fPIC -c $SOURCE -o Make/linux64GccDPOpt/funkySetFields.o
In file included from location.hh:44,
                 from ValueExpressionParser.tab.hh:65,
                 from ValueExpressionDriver.H:14,
                 from funkySetFields.C:41:
position.hh: In function ‘bool ve::operator==(const ve::position&, const ve::position&)’:
position.hh:136: warning: suggest parentheses around && within ||
g++ -m64 -Dlinux64 -DWM_DP -Wall -Wno-strict-aliasing -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-40 -IMake/linux64GccDPOpt -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/finiteVolume/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/meshTools/lnInclude -IlnInclude -I. -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OpenFOAM/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OSspecific/POSIX/lnInclude   -fPIC Make/linux64GccDPOpt/ValueExpressionParser.o Make/linux64GccDPOpt/ValueExpressionLexer.o Make/linux64GccDPOpt/ValueExpressionDriver.o Make/linux64GccDPOpt/funkySetFields.o -L/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt \
         -lfiniteVolume -lmeshTools -lOpenFOAM -liberty -ldl   -lm -o /home/HiWi/OpenFOAM/hiwi-1.6/applications/bin/linux64GccDPOpt/funkySetFields
/usr/bin/ld: cannot open output file /home/HiWi/OpenFOAM/hiwi-1.6/applications/bin/linux64GccDPOpt/funkySetFields: Permission denied
collect2: ld returned 1 exit status
make: *** [/home/HiWi/OpenFOAM/hiwi-1.6/applications/bin/linux64GccDPOpt/funkySetFields] Fehler 1
Looks like a completely different error to me. Hope u can help me anyway.
Thanks.

Last edited by querdynamik; May 18, 2010 at 05:52.
querdynamik is offline   Reply With Quote

Old   May 18, 2010, 06:48
Default
  #31
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by querdynamik View Post
At first, thx for your answer and sorry for my late reply.

No, i did not even try to compile any OF-utility before. But i realised, that i was trying to install the funkySetFields-Tool from the POSTprocressing-directory. I don't know if that made any difference.
No.
Quote:
Originally Posted by querdynamik View Post
Anyway, now i tried to install it from the PREprocessing directory and got these lines :

Code:
g++ -m64 -Dlinux64 -DWM_DP -Wall -Wno-strict-aliasing -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-40 -IMake/linux64GccDPOpt -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/finiteVolume/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/meshTools/lnInclude -IlnInclude -I. -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OpenFOAM/lnInclude -I/home/HiWi/OpenFOAM/OpenFOAM-1.6/src/OSspecific/POSIX/lnInclude   -fPIC Make/linux64GccDPOpt/ValueExpressionParser.o Make/linux64GccDPOpt/ValueExpressionLexer.o Make/linux64GccDPOpt/ValueExpressionDriver.o Make/linux64GccDPOpt/funkySetFields.o -L/home/HiWi/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt \
         -lfiniteVolume -lmeshTools -lOpenFOAM -liberty -ldl   -lm -o /home/HiWi/OpenFOAM/hiwi-1.6/applications/bin/linux64GccDPOpt/funkySetFields
/usr/bin/ld: cannot open output file /home/HiWi/OpenFOAM/hiwi-1.6/applications/bin/linux64GccDPOpt/funkySetFields: Permission denied
collect2: ld returned 1 exit status
make: *** [/home/HiWi/OpenFOAM/hiwi-1.6/applications/bin/linux64GccDPOpt/funkySetFields] Fehler 1
Looks like a completely different error to me. Hope u can help me anyway.
Thanks.
Compilation runs alright (forget about the warnings). Your just not allowed to write the resulting binary. That is a OS/configuration problem

Bernhard
gschaider is offline   Reply With Quote

Old   May 18, 2010, 07:56
Default
  #32
New Member
 
C.Z.
Join Date: May 2010
Posts: 4
Rep Power: 16
querdynamik is on a distinguished road
Quote:
Originally Posted by gschaider View Post

Compilation runs alright (forget about the warnings). Your just not allowed to write the resulting binary. That is a OS/configuration problem

Bernhard
Ok, got it now. Simply had to give recursive write-permissions to that directory.
Now it compiled without errors.

Thank you very much, again !
querdynamik is offline   Reply With Quote

Old   August 11, 2010, 04:18
Exclamation funkySetFields and OpenFOAM 1.7.0
  #33
New Member
 
Kelvin Loh
Join Date: Mar 2009
Posts: 25
Rep Power: 17
kel85uk is on a distinguished road
Hi all,

Tried to compile the FSF library and encountered the same error as the post previously about it being calling overloaded function. I can't figure out what's wrong... Anyone here willing to help?

Thanks.

Regards,
Kelvin

Code:
SOURCE=ValueExpressionDriver.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wno-strict-aliasing -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3  -DNoRepository -ftemplate-depth-40 -IMake/linux64GccDPOpt     -I/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/finiteVolume/lnInclude     -I/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/meshTools/lnInclude -IlnInclude -I. -I/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/OpenFOAM/lnInclude -I/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/OSspecific/POSIX/lnInclude   -fPIC -c $SOURCE -o Make/linux64GccDPOpt/ValueExpressionDriver.o
In file included from location.hh:44,
                 from ValueExpressionParser.tab.hh:65,
                 from ValueExpressionDriver.H:14,
                 from ValueExpressionDriver.C:3:
position.hh: In function ‘bool ve::operator==(const ve::position&, const ve::position&)’:
position.hh:136: warning: suggest parentheses around ‘&&’ within ‘||’
ValueExpressionDriver.C: In member function ‘Foam::surfaceScalarField* ValueExpressionDriver::makeAreaField()’:
ValueExpressionDriver.C:462: error: call of overloaded ‘GeometricField(Foam::IOobject, const Foam::fvMesh&, int)’ is ambiguous
/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/OpenFOAM/lnInclude/GeometricField.C:420: note: candidates are: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dictionary&) [with Type = double, PatchField = Foam::fvsPatchField, GeoMesh = Foam::surfaceMesh]
/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/OpenFOAM/lnInclude/GeometricField.C:256: note:                 Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dimensioned<Type>&, const Foam::word&) [with Type = double, PatchField = Foam::fvsPatchField, GeoMesh = Foam::surfaceMesh]
ValueExpressionDriver.C: In member function ‘Foam::volScalarField* ValueExpressionDriver::makeVolumeField()’:
ValueExpressionDriver.C:482: error: call of overloaded ‘GeometricField(Foam::IOobject, const Foam::fvMesh&, int)’ is ambiguous
/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/OpenFOAM/lnInclude/GeometricField.C:420: note: candidates are: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dictionary&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/OpenFOAM/lnInclude/GeometricField.C:256: note:                 Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dimensioned<Type>&, const Foam::word&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
ValueExpressionDriver.C: In member function ‘Foam::volScalarField* ValueExpressionDriver::makeDistanceField()’:
ValueExpressionDriver.C:506: error: call of overloaded ‘GeometricField(Foam::IOobject, const Foam::fvMesh&, int)’ is ambiguous
/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/OpenFOAM/lnInclude/GeometricField.C:420: note: candidates are: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dictionary&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/OpenFOAM/lnInclude/GeometricField.C:256: note:                 Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dimensioned<Type>&, const Foam::word&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
ValueExpressionDriver.C: In member function ‘Foam::volScalarField* ValueExpressionDriver::makeRDistanceField(const Foam::volVectorField&)’:
ValueExpressionDriver.C:529: error: call of overloaded ‘GeometricField(Foam::IOobject, const Foam::fvMesh&, int)’ is ambiguous
/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/OpenFOAM/lnInclude/GeometricField.C:420: note: candidates are: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dictionary&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
/home/kklloh/OpenFOAM/OpenFOAM-1.7.0/src/OpenFOAM/lnInclude/GeometricField.C:256: note:                 Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const typename GeoMesh::Mesh&, const Foam::dimensioned<Type>&, const Foam::word&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
make: *** [Make/linux64GccDPOpt/ValueExpressionDriver.o] Error 1
kel85uk is offline   Reply With Quote

Old   August 11, 2010, 05:24
Default
  #34
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by kel85uk View Post
Hi all,

Tried to compile the FSF library and encountered the same error as the post previously about it being calling overloaded function. I can't figure out what's wrong... Anyone here willing to help?

Thanks.

Regards,
Kelvin
The most interesing information required would be: version of bison and version of funkySetFields (where you got it from)
gschaider is offline   Reply With Quote

Old   August 11, 2010, 05:35
Default
  #35
New Member
 
Kelvin Loh
Join Date: Mar 2009
Posts: 25
Rep Power: 17
kel85uk is on a distinguished road
Quote:
Originally Posted by gschaider View Post
The most interesing information required would be: version of bison and version of funkySetFields (where you got it from)
Hi all,

As added information, the bison version I have is 2.4.1, flex 2.5.35, and FSF from the OpenFOAM extend project, which I got from the source file

"ICE Revision: $Id: funkySetFields.C 7567 2007-06-20 12:38:50Z bgschaid $"

Am compiling FSF in OF 1.7.0 with 64-bit Fedora Core 13 OS.

Thanks.

Regards,
Kelvin
kel85uk is offline   Reply With Quote

Old   August 11, 2010, 10:49
Default
  #36
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by kel85uk View Post
As added information, the bison version I have is 2.4.1, flex 2.5.35, and FSF from the OpenFOAM extend project, which I got from the source file
That looks alright
Quote:
Originally Posted by kel85uk View Post
"ICE Revision: $Id: funkySetFields.C 7567 2007-06-20 12:38:50Z bgschaid $"
These tags were not updated for ages so they don't mean much
Quote:
Originally Posted by kel85uk View Post
Am compiling FSF in OF 1.7.0 with 64-bit Fedora Core 13 OS.
You're using the version from the OF 1.6-Breeder are you? That compiles on my 1.7 without problems. The error message indicates a version mismatch (a constructor is called which is not present in your current OF-version)
gschaider is offline   Reply With Quote

Old   August 24, 2010, 14:09
Default
  #37
Member
 
G B
Join Date: Mar 2010
Posts: 37
Rep Power: 16
Disco_Caine is on a distinguished road
yes, i'm back with more funky set fields trouble. This time im actually getting the same error as the original poster, i.e, floating point exception. And i know what is causing it exactly, i just can't fathom why.

ill write my funkysetfields dict here, the abbreviate version:

Code:
temperature1
    {    
        field T;
        expression "52.96281*(pow(pos().z,0.262054))+273";
        condition "pos().x <= 0.0105";
        keepPatches 1;
    }
now, that works perfectly for on a mesh with z (height in my case) of 25. However, when i change this to 15, i get the error, can anyone help me why?

This is the error message

Code:
#0  Foam::error::printStack(Foam::Ostream&) in "/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libOpenFOAM.so"
#1  Foam::sigFpe::sigFpeHandler(int) in "/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libOpenFOAM.so"
#2   in "/lib/libc.so.6"
#3   in "/lib/libm.so.6"
#4  Foam::pow(Foam::Field<double>&, Foam::UList<double> const&, double const&) in "/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libOpenFOAM.so"
#5  
 in "/home/gustavo/OpenFOAM/gustavo-1.6.x/applications/bin/linux64GccDPOpt/funkySetFields"
#6  
 in "/home/gustavo/OpenFOAM/gustavo-1.6.x/applications/bin/linux64GccDPOpt/funkySetFields"
#7  
 in "/home/gustavo/OpenFOAM/gustavo-1.6.x/applications/bin/linux64GccDPOpt/funkySetFields"
#8  
 in "/home/gustavo/OpenFOAM/gustavo-1.6.x/applications/bin/linux64GccDPOpt/funkySetFields"
#9  
 in "/home/gustavo/OpenFOAM/gustavo-1.6.x/applications/bin/linux64GccDPOpt/funkySetFields"
#10  __libc_start_main in "/lib/libc.so.6"
#11  
 at /build/buildd/eglibc-2.10.1/csu/../sysdeps/x86_64/elf/start.S:116
Floating point exceptio
The function im using is perfectly defined for positive real numbers. So, anyone has any ideas as to why i get this error when i change a value in blockmeshdict?

Thanks for your time
GB
Disco_Caine is offline   Reply With Quote

Old   August 24, 2010, 19:22
Default
  #38
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by Disco_Caine View Post
yes, i'm back with more funky set fields trouble. This time im actually getting the same error as the original poster, i.e, floating point exception. And i know what is causing it exactly, i just can't fathom why.

ill write my funkysetfields dict here, the abbreviate version:

Code:
temperature1
    {    
        field T;
        expression "52.96281*(pow(pos().z,0.262054))+273";
        condition "pos().x <= 0.0105";
        keepPatches 1;
    }
now, that works perfectly for on a mesh with z (height in my case) of 25. However, when i change this to 15, i get the error, can anyone help me why?

This is the error message

Code:
#0  Foam::error::printStack(Foam::Ostream&) in "/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libOpenFOAM.so"
#1  Foam::sigFpe::sigFpeHandler(int) in "/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libOpenFOAM.so"
#2   in "/lib/libc.so.6"
#3   in "/lib/libm.so.6"
#4  Foam::pow(Foam::Field<double>&, Foam::UList<double> const&, double const&) in "/home/gustavo/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libOpenFOAM.so"
 at /build/buildd/eglibc-2.10.1/csu/../sysdeps/x86_64/elf/start.S:116
Floating point exceptio
The function im using is perfectly defined for positive real numbers. So, anyone has any ideas as to why i get this error when i change a value in blockmeshdict?

Thanks for your time
GB
What I'd suggest is replacing your expression with this simpler version
pos().z
and check whether the result is definitely bigger than 0 for your mesh

Bernhard
gschaider is offline   Reply With Quote

Old   August 25, 2010, 12:05
Default
  #39
Member
 
G B
Join Date: Mar 2010
Posts: 37
Rep Power: 16
Disco_Caine is on a distinguished road
Hello Bernhard, thanks for your reply (and sorry for taking so much time). It indeed is positive as expected. Ill try other values of z to see how the problem develops. I still find it peculiar that it woudl work with 25 and not 15.

Thanks again

UPDATE: i discovered it works on funky set fields from 18 onwards. 17 already gives floating point exception. But ill post this here for everyone to see:

http://www.wolframalpha.com/input/?i=plot+52.96281*%28z^0.262054%29+from+0+to+0.15

Why is it giving floating point exception? This must have such a simple reason.

Last edited by Disco_Caine; August 25, 2010 at 12:23. Reason: update
Disco_Caine is offline   Reply With Quote

Old   August 25, 2010, 12:49
Default
  #40
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by Disco_Caine View Post
Hello Bernhard, thanks for your reply (and sorry for taking so much time). It indeed is positive as expected. Ill try other values of z to see how the problem develops. I still find it peculiar that it woudl work with 25 and not 15.

Thanks again

UPDATE: i discovered it works on funky set fields from 18 onwards. 17 already gives floating point exception. But ill post this here for everyone to see:

http://www.wolframalpha.com/input/?i=plot+52.96281*%28z^0.262054%29+from+0+to+0.15

Why is it giving floating point exception? This must have such a simple reason.
No idea. The problem is occuring in the native pow function. So one of the value pairs offends it, To find out which there are two ways:

- modify OF-sources to print out intermediate results
- use a Debug-version of OF, a core-dump and gdb to have a look at the backtrace
- by trial and error try expressions of the form "pow(0.0345,0.262054)" to find a value that fails (start with the largest and smallest values from the previous experiment)

OK. That's three possibilities, but who's counting.

Anyway. As far as I can tell it is either a problem with pow or a problem with the expression (but you ruled that out) but not a problem of FSF per see

BTW: have you tried it with different powers? ( 0.1, 0, 1, 2 ...)
gschaider is offline   Reply With Quote

Reply

Tags
funkysetfields, installation, valueexpressionparser, wmake


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
Frequently Asked Questions about Installing OpenFOAM wyldckat OpenFOAM Installation 3 November 14, 2023 12:58
[foam-extend.org] problem when installing foam-extend-1.6 Thomas pan OpenFOAM Installation 7 September 9, 2015 22:53
Install OF 1.6.ext on Arch based distribution miro2000 OpenFOAM Installation 4 October 9, 2013 15:39
[swak4Foam] installing funkySetFields igo OpenFOAM Community Contributions 1 November 20, 2012 21:16
[swak4Foam] installing funkySetFields utility for OpenFOAM 1.4.1 ozie OpenFOAM Community Contributions 8 September 8, 2011 12:16


All times are GMT -4. The time now is 10:47.