CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Installation (https://www.cfd-online.com/Forums/openfoam-installation/)
-   -   [foam-extend.org] Problems on installing Foam-extend 4.0/ swak4Foam on ubuntu18.0.4 (https://www.cfd-online.com/Forums/openfoam-installation/220979-problems-installing-foam-extend-4-0-swak4foam-ubuntu18-0-4-a.html)

XJ_Wang September 29, 2019 15:43

Problems on installing Foam-extend 4.0/ swak4Foam on ubuntu18.0.4
 
1 Attachment(s)
Hi all,

I have problems on installing foam-extend 4.0. I went through the forum and followed many solutions, but it can still not work now.

I guess the installation got stuck at stage5. I also tried to install swak4Foam on my computer, which someone thought was a solution to this problem. But I also failed on installing swak4Foam

The current system I am using is Ubuntu 18.04.3 LTS.

I followed the installation guide:
https://openfoamwiki.net/index.php/I...end-4.0/Ubuntu

g++ version:
(Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0
gcc version:
(Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0

my soure file looks like:

alias of7=' source /opt/openfoam7/etc/bashrc'
alias of301='source $HOME/OpenFOAM/OpenFOAM-3.0.1/etc/bashrc '
alias fe40='source $HOME/foam/foam-extend-4.0/etc/bashrc'

I only attached the log file of stage5 because of the limitation of file size. If necessary I will upload the remaining parts.

I have spent a lot of time on installing this foam-extend. I will really appreciate it if you can help me solve this problem!

Sincerely,
Xiangjie

gschaider September 29, 2019 18:31

Quote:

Originally Posted by XJ_Wang (Post 745806)
Hi all,

I have problems on installing foam-extend 4.0. I went through the forum and followed many solutions, but it can still not work now.

I guess the installation got stuck at stage5. I also tried to install swak4Foam on my computer, which someone thought was a solution to this problem. But I also failed on installing swak4Foam

The current system I am using is Ubuntu 18.04.3 LTS.

I followed the installation guide:
https://openfoamwiki.net/index.php/I...end-4.0/Ubuntu

g++ version:
(Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0
gcc version:
(Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0

my soure file looks like:

alias of7=' source /opt/openfoam7/etc/bashrc'
alias of301='source $HOME/OpenFOAM/OpenFOAM-3.0.1/etc/bashrc '
alias fe40='source $HOME/foam/foam-extend-4.0/etc/bashrc'

I only attached the log file of stage5 because of the limitation of file size. If necessary I will upload the remaining parts.

I have spent a lot of time on installing this foam-extend. I will really appreciate it if you can help me solve this problem!

Sincerely,
Xiangjie


The remark that these are rather old versions of swak4Foam and foam-extend won't make you happy


A quick fix would be to edit Libraries/swak4FoamParsers/namedEnums/NumericAccumulationNamedEnum.C in the swak4Foam sources and replace

Code:

HUGE
with

Code:

pTraits<scalar>::min
(that is what newr versions of swak4Foam have there)

XJ_Wang September 29, 2019 20:36

1 Attachment(s)
Quote:

Originally Posted by gschaider (Post 745814)
The remark that these are rather old versions of swak4Foam and foam-extend won't make you happy


A quick fix would be to edit Libraries/swak4FoamParsers/namedEnums/NumericAccumulationNamedEnum.C in the swak4Foam sources and replace

Code:

HUGE
with

Code:

pTraits<scalar>::min
(that is what newr versions of swak4Foam have there)

Thanks for your reply.

I change the NumericAccumulationNamedEnum.C file, but there are still some mistakes.

Belowing is what I have done:
cd:Libraries/swak4FoamParsers/namedEnums
replace HUGE with 'pTraits<scalar>::min'
go into the thirdparty folder and execute 'AllMake.Stage5'


IN the log file there are still some errors about 'HUGE', I am wondering whether changing that one .C file is not enough, I should also change the header file.

CommonValueExpressionDriver.C:2060:16: error: ‘HUGE’ was not declared in this scope.


There are other errors:
'No file 'swakConfiguration'. Python etc won't work. See README for details'
Requirements for Library not satisfied. I see no sense in going on

I attached my log file.

gschaider October 1, 2019 04:48

Quote:

Originally Posted by XJ_Wang (Post 745817)
Thanks for your reply.

I change the NumericAccumulationNamedEnum.C file, but there are still some mistakes.

Belowing is what I have done:
cd:Libraries/swak4FoamParsers/namedEnums
replace HUGE with 'pTraits<scalar>::min'
go into the thirdparty folder and execute 'AllMake.Stage5'


IN the log file there are still some errors about 'HUGE', I am wondering whether changing that one .C file is not enough, I should also change the header file.

CommonValueExpressionDriver.C:2060:16: error: ‘HUGE’ was not declared in this scope.


There are other errors:
'No file 'swakConfiguration'. Python etc won't work. See README for details'
Requirements for Library not satisfied. I see no sense in going on

I attached my log file.


I only see one error and that can be fixed by replacing HUGE as well

XJ_Wang October 1, 2019 12:07

4 Attachment(s)
Quote:

Originally Posted by gschaider (Post 745945)
I only see one error and that can be fixed by replacing HUGE as well

Thank you very much!

I changed the 'HUGE' in that file, and execute 'AllMake.stage5' in the directory of ThirdParty, but more errors of 'HUGE' came up, as you can see in the attached file 'logfile'.
THen I replaced the 'HUGE' again according to the 'logfile', then some other errors about 'HUGE' came up, as you can see in the file 'logfile2'.
THen i did it again. this time it seemed good and no errors, as you can see in 'logfile3'.

I don't know how to set the environment variable according to the last sentence of the logfile3.

Code:

If you want to use swakCoded-function object or compile software based on swak set the environment variable SWAK4FOAM_SRC to /home/xiangjie/foam/foam-extend-4.0/ThirdParty/rpmBuild/BUILD/swak4Foam-0.4.0/Libraries (most people will be fine without setting that variable)
Therefore, I just left as it was. After that, I executed ./AllMake.stage6 in the ThirdParty directory. I think this is enough for installing foam-extend 4.0 on my computer.

THen i install the FSI according to the instructions in https://openfoamwiki.net/index.php/E...oam-extend-4.0

But there were many mistakes, as you can see in logfile4. Maybe I haven't install the foam-extend 4.0 correctly in my computer.

Thanks for your help! I really appreciate it!

usergt October 1, 2019 14:12

Quote:

Originally Posted by XJ_Wang (Post 745817)
go into the thirdparty folder and execute 'AllMake.Stage5'

When I execute AllMake.stage5 (small s) it traps the directory and a consecutive build after correction of the HUGE problem is not possible:

========================================
Starting ThirdParty AllMake: Stage5
========================================

The source code for swak4Foam is already present under ./rpmBuild/BUILD/swak4Foam-0.4.0
Please remove this directory if you want to refresh your installation of swak4Foam

XJ_Wang October 1, 2019 15:53

Quote:

Originally Posted by usergt (Post 745978)
When I execute AllMake.stage5 (small s) it traps the directory and a consecutive build after correction of the HUGE problem is not possible:

========================================
Starting ThirdParty AllMake: Stage5
========================================

The source code for swak4Foam is already present under ./rpmBuild/BUILD/swak4Foam-0.4.0
Please remove this directory if you want to refresh your installation of swak4Foam

Yes it says that you need to delete the folder, which means if you execute allwmake.stage5, all the new files will be generated, and the 'HUGE' problems will come up again.

I think i executed allwmake in the swak4Foam folder,
Code:

~/foam/foam-extend-4.0/ThirdParty/rpmBuild/BUILD/swak4Foam-0.4.0
.

I am sorry I just didn't say it clearly. I think I have execute allwmake.stage5 once and the others are allwmake in this directory.

Maybe I executed allwclean.stage5 first and then allwmake.stage5.

AMalaguera October 2, 2019 13:34

foam-extend for OpenFPAM V6
 
Hello community

I need to simulate problems FSI (Fluid Structure Interaction). I have OpenFoam 6.0 installed on my computer. With Ubuntu 18.04. I understand that an extended version must be installed. I have 2 questions: (1) where I get this extended version. and (2) in the case of OpenFOAM V7 it also has this extended version. I appreciate any help

Can I install foam-extend 4.0 in OpenFOAM 6?

XJ_Wang October 2, 2019 14:30

Quote:

Originally Posted by AMalaguera (Post 746057)
Hello community

I need to simulate problems FSI (Fluid Structure Interaction). I have OpenFoam 6.0 installed on my computer. With Ubuntu 18.04. I understand that an extended version must be installed. I have 2 questions: (1) where I get this extended version. and (2) in the case of OpenFOAM V7 it also has this extended version. I appreciate any help

Can I install foam-extend 4.0 in OpenFOAM 6?


As a beginner of OpenFOAM, I think FSI is based on foam-extend, not OpenFoam.

Belowing is the instruction I followed.
https://openfoamwiki.net/index.php/I...end-4.0/Ubuntu

Best wishes,
Xiangjie

AMalaguera October 2, 2019 17:41

Quote:

Originally Posted by XJ_Wang (Post 746060)
As a beginner of OpenFOAM, I think FSI is based on foam-extend, not OpenFoam.

Belowing is the instruction I followed.
https://openfoamwiki.net/index.php/I...end-4.0/Ubuntu

Best wishes,
Xiangjie

I already installed foam-extend-4.0

When run the ampFsiFoam tutorials, for example run/ampFsiFoam/3dTube/fluid$
I get the error:

"--> FOAM FATAL IO ERROR:
Essential entry 'value' missing

file: /home/angel/OpenFOAM/angel-6/FluidSolidInteraction/run/ampFsiFoam/3dTube/fluid/0/p.boundaryField.inlet from line 38 to line 40.

From function Foam::fvPatchField<Type>::fvPatchField(const Foam::fvPatch&, const Foam::DimensionedField<Type, Foam::volMesh>&, const Foam::dictionary&, bool) [with Type = double]
in file /home/ubuntu/OpenFOAM/OpenFOAM-6/src/finiteVolume/lnInclude/fvPatchField.C at line 131.

FOAM exiting

Segmentation fault (core dumped)"

I checked the log (log.blockMesh, log.setSet and log.setstoZones) files and they were executed completely. When I see paraView, that error appears

What could be the issue?

Thank you!

Angel

XJ_Wang October 3, 2019 10:49

Quote:

Originally Posted by AMalaguera (Post 746072)
I already installed foam-extend-4.0

When run the ampFsiFoam tutorials, for example run/ampFsiFoam/3dTube/fluid$
I get the error:

"--> FOAM FATAL IO ERROR:
Essential entry 'value' missing

file: /home/angel/OpenFOAM/angel-6/FluidSolidInteraction/run/ampFsiFoam/3dTube/fluid/0/p.boundaryField.inlet from line 38 to line 40.

From function Foam::fvPatchField<Type>::fvPatchField(const Foam::fvPatch&, const Foam::DimensionedField<Type, Foam::volMesh>&, const Foam::dictionary&, bool) [with Type = double]
in file /home/ubuntu/OpenFOAM/OpenFOAM-6/src/finiteVolume/lnInclude/fvPatchField.C at line 131.

FOAM exiting

Segmentation fault (core dumped)"

I checked the log (log.blockMesh, log.setSet and log.setstoZones) files and they were executed completely. When I see paraView, that error appears

What could be the issue?

Thank you!

Angel

Hi Angel,

I haven't installed foam-extend correctly on my computer, so I cannot try the fsi tutorials. Maybe your question need to be answered by others.
I am sorry that I cannot offer any help.

Xiangjie

usergt October 3, 2019 11:15

ampFsiFoam tutorial under extend-4.0
 
Quote:

Originally Posted by AMalaguera (Post 746072)
I already installed foam-extend-4.0

When run the ampFsiFoam tutorials, for example run/ampFsiFoam/3dTube/fluid$

I do not have an ampFsiFoam tutorial under extend-4.0. Please explain. Thanks!

usergt October 3, 2019 11:21

Quote:

Originally Posted by XJ_Wang (Post 745982)
Yes it says that you need to delete the folder, which means if you execute allwmake.stage5, all the new files will be generated, and the 'HUGE' problems will come up again.

I think i executed allwmake in the swak4Foam folder,
Code:

~/foam/foam-extend-4.0/ThirdParty/rpmBuild/BUILD/swak4Foam-0.4.0
.

I am sorry I just didn't say it clearly. I think I have execute allwmake.stage5 once and the others are allwmake in this directory.

Maybe I executed allwclean.stage5 first and then allwmake.stage5.

Clearly, https://openfoamwiki.net/index.php/I...end-4.0/Ubuntu is not working for swak4foam under Ubuntu 18.04. My HUGE problem has magically dissapeard after applying the patch but I do not know, if the installation is broken.

AMalaguera October 3, 2019 15:05

Quote:

Originally Posted by usergt (Post 746139)
I do not have an ampFsiFoam tutorial under extend-4.0. Please explain. Thanks!

Hello..:D

When I installed foam-extend, 3 folders were installed: FluidSolidlnteraction, run and Fsi_40.tar.gz, the latter compressed.

Within the FluidSolidlnteraction folder there are 2 folders: run and src. Within the run folder 5 solvers were installed: ampFsiFoam, fsiFoam, solidFoam, thermalStressFoam and weakFsiFoam.

Inside the ampFsiFoam solver there are 2 cases: 3dTube and axisymmetricTube. I executed the 2 cases, but I'm sure I'm not doing well. I did the same with the other solvers. The thermalStressFoam solver has only one case: flange. With this case, I opened ParaView. That's why I think that in the other cases I am doing something wrong.

Within the 3dTube case there are 2 folders: fluid and solid, in addition there are also 3 files: makeLinks, makaSerialLinks and removeSerialLinks.

I am new to OpenFoam. Could someone guide me: :eek:

Thank you

Angel

usergt October 4, 2019 07:26

Quote:

Originally Posted by AMalaguera (Post 746154)
Hello..:D

When I installed foam-extend, 3 folders were installed: FluidSolidlnteraction, run and Fsi_40.tar.gz, the latter compressed.

Within the FluidSolidlnteraction folder there are 2 folders: run and src. Within the run folder 5 solvers were installed: ampFsiFoam, fsiFoam, solidFoam, thermalStressFoam and weakFsiFoam.

Inside the ampFsiFoam solver there are 2 cases: 3dTube and axisymmetricTube. I executed the 2 cases, but I'm sure I'm not doing well. I did the same with the other solvers. The thermalStressFoam solver has only one case: flange. With this case, I opened ParaView. That's why I think that in the other cases I am doing something wrong.

Within the 3dTube case there are 2 folders: fluid and solid, in addition there are also 3 files: makeLinks, makaSerialLinks and removeSerialLinks.

I am new to OpenFoam. Could someone guide me: :eek:

Thank you

Angel

git clone git://git.code.sf.net/p/foam-extend/foam-extend-4.0 foam-extend-4.0 does not retrieve anything like "ampFsiFoam". You have to follow https://openfoamwiki.net/index.php/I...om_source_code but currently for 18.04 it seems not to be working.

usergt October 5, 2019 17:01

Just to mention that openSUSE Leap 15.0 (I had to use an old monitor becuase it does not support 4K for installation) - if one installs bison 2.7 from http://download.opensuse.org/distrib...rpm.mirrorlist - provides a flawless installation w/o the HUGE problem. OpenFOAM seems to have it w/ SUSE somehow :)

usergt October 6, 2019 12:45

Quote:

Originally Posted by usergt (Post 746286)
Just to mention that openSUSE Leap 15.0 (I had to use an old monitor becuase it does not support 4K for installation) - if one installs bison 2.7 from http://download.opensuse.org/distrib...rpm.mirrorlist - provides a flawless installation w/o the HUGE problem. OpenFOAM seems to have it w/ SUSE somehow :)

In fact openSUSE Leap 15.1 is an even better choice.

paramu September 14, 2021 13:01

issue installing swak4Foam for openFoam2012 on opensuse.
 
Hello

i am adding to this thread as it is the closest i found to my own problem, but i couldn't undesrtand how to apply the HUGE solution to my own files, in practice.

I have the admins rights on my computer.
Openfoam is installed on /usr/*, and i'm trying to figure out where i should ocpy and Allwmake the swak4Foam directory to resolve the issue it returns:


Swak version is 202x.yy.0
hg info: 06fdbe848844 (develop) tip
which: no bear in (/usr/lib/openfoam/openfoam2012/swak4Foam/privateRequirements/bin:/root/OpenFOAM/root-2012/platforms/linux64GccDPInt32Opt/bin:/usr/lib/openfoam/openfoam2012/site/2012/platforms/linux64GccDPInt32Opt/bin:/usr/lib/openfoam/openfoam2012/platforms/linux64GccDPInt32Opt/bin:/usr/lib/openfoam/openfoam2012/bin:/usr/lib/openfoam/openfoam2012/wmake:/usr/lib64/mpi/gcc/openmpi/bin:/sbin:/usr/sbin:/usr/local/sbin:/root/bin:/usr/local/bin:/usr/bin:/bin)
No 'bear' installed
Bison: /usr/lib/openfoam/openfoam2012/swak4Foam/privateRequirements/bin/bison
Flex: /usr/bin/flex
Bison at /usr/lib/openfoam/openfoam2012/swak4Foam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4)
Flex is version 2.6.4 (Minor version: 4)
OpenFOAM-version: Major 2012 Minor 0 Patch 0 (-1 == x / 0) Fork: com
No swak4FoamParsers/foamVersion4swak.H. Generated



And then:


wmake libso swak4FoamParsers
/usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:72: /usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory
make: *** No rule to make target '/usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop.
/usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:72: /usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory
make: *** No rule to make target '/usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop.
wmake error: file '/usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/sourceFiles' could not be created in /usr/lib/openfoam/openfoam2012/swak4Foam/Libraries/swak4FoamParsers
Parser library did not compile OK. No sense continuing as everything else depends on it




myflex is in the swak4FOam libraries path, but i see it is looking for it in the openfoam/bluid directory path isntead.
I've tried to put the swak4Foam as a directory above, like side by side with openfoam2012, but then it doesn't work either.


What could i try ?
Any suggestion, help, very very welcome!!! thank you so much.

paramu September 14, 2021 13:02

idem
 
sorry i forgot to specify i'm on opensuse Leap15.1

gschaider September 14, 2021 15:09

Quote:

Originally Posted by paramu (Post 812203)
Hello

i am adding to this thread as it is the closest i found to my own problem, but i couldn't undesrtand how to apply the HUGE solution to my own files, in practice.

I have the admins rights on my computer.
Openfoam is installed on /usr/*, and i'm trying to figure out where i should ocpy and Allwmake the swak4Foam directory to resolve the issue it returns:


Swak version is 202x.yy.0
hg info: 06fdbe848844 (develop) tip
which: no bear in (/usr/lib/openfoam/openfoam2012/swak4Foam/privateRequirements/bin:/root/OpenFOAM/root-2012/platforms/linux64GccDPInt32Opt/bin:/usr/lib/openfoam/openfoam2012/site/2012/platforms/linux64GccDPInt32Opt/bin:/usr/lib/openfoam/openfoam2012/platforms/linux64GccDPInt32Opt/bin:/usr/lib/openfoam/openfoam2012/bin:/usr/lib/openfoam/openfoam2012/wmake:/usr/lib64/mpi/gcc/openmpi/bin:/sbin:/usr/sbin:/usr/local/sbin:/root/bin:/usr/local/bin:/usr/bin:/bin)
No 'bear' installed
Bison: /usr/lib/openfoam/openfoam2012/swak4Foam/privateRequirements/bin/bison
Flex: /usr/bin/flex
Bison at /usr/lib/openfoam/openfoam2012/swak4Foam/privateRequirements/bin/bison is version 3.4 (Major 3 Minor 4)
Flex is version 2.6.4 (Minor version: 4)
OpenFOAM-version: Major 2012 Minor 0 Patch 0 (-1 == x / 0) Fork: com
No swak4FoamParsers/foamVersion4swak.H. Generated



And then:


wmake libso swak4FoamParsers
/usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:72: /usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory
make: *** No rule to make target '/usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop.
/usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/options:72: /usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex: No such file or directory
make: *** No rule to make target '/usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/../myflex'. Stop.
wmake error: file '/usr/lib/openfoam/openfoam2012/build/linux64GccDPInt32Opt/swak4Foam/Libraries/swak4FoamParsers/sourceFiles' could not be created in /usr/lib/openfoam/openfoam2012/swak4Foam/Libraries/swak4FoamParsers
Parser library did not compile OK. No sense continuing as everything else depends on it




myflex is in the swak4FOam libraries path, but i see it is looking for it in the openfoam/bluid directory path isntead.
I've tried to put the swak4Foam as a directory above, like side by side with openfoam2012, but then it doesn't work either.


What could i try ?
Any suggestion, help, very very welcome!!! thank you so much.


Hm. The line that is failing is

Code:

include $(OBJECTS_DIR)/../mybison
OBJECTS_DIR is set by wmake according to your Architecture/compiler and should point to something like Make/linux64Clang110DPInt32Opt in your swak4FoamParsers-directory (the .. in the path "moves" to Make where the mybison-file is)


So the problem is that OBJECTS_DIR (the directory where all the .so-files are supposed to go) is not set properly by wmake


I remember seeing this problem but I can't remember how it was fixed


How was your OF installed? Self-compiled or a binary? (I guess the second) Did you manage to compile ANY other OF software before (because the wrong OBJECTS_DIR should be a show-stopper)


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