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

[openSmoke] libOpenSMOKE

Register Blogs Community New Posts Updated Threads Search

Like Tree133Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 8, 2012, 15:05
Default libOpenSMOKE
  #1
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
hi all,

I wanna write my masterthesis with the additional library (flamlet) for openfoam.

For 4 weeks now I try to compile the library and solver but with no results ... (many errors) ...

Do someone have ideas or experiance with that lib and compiling?
I need help


http://creckmodeling.chem.polimi.it/openfoam.html

Tobi
dongchao yang and MMC15 like this.
Tobi is offline   Reply With Quote

Old   April 8, 2012, 18:53
Default informations
  #2
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Hi,

now a few details about my system and trying s.

Using UBUNTU 10.04 64bit
I tried to compile the lib with OpenFOAM-1.7.0 (deb)

First I downloaded the libOpenSMOKE file end extracted it into $FOAM_INST_DIR (/opt/)

After that I followed the instructions in the user guide:
1. download the gsl lib
2. compile it with "./configure path="/home/shor-ty/numeric/"" and after that "make"
3. check the compilation with "make check 2>errLog" (without errors)
4. checked the folder <numeric> that all files are avaiable for compilation the libOpenSMOKE tool
5. move to the folder /opt/libOpenSMOKE/src/libraries/
6. Allwclean
7. update the Make/option files (set the path to the gsl lib)
8. Allwmake 2>errLog

Code:
+ wmake libso common
Making dependency list for source file src/OpenSMOKE_ChiDistribution.cpp
Making dependency list for source file src/OpenSMOKE_External_Functions.cpp
src/OpenSMOKE_External_Functions.cpp: In function ‘double sun_erf(double)’:
src/OpenSMOKE_External_Functions.cpp:266: warning: use of old-style cast
src/OpenSMOKE_External_Functions.cpp:267: warning: use of old-style cast
src/OpenSMOKE_External_Functions.cpp:271: warning: use of old-style cast
src/OpenSMOKE_External_Functions.cpp:272: warning: use of old-style cast
src/OpenSMOKE_External_Functions.cpp:326: warning: use of old-style cast
src/OpenSMOKE_External_Functions.cpp: In function ‘double sun_erfc(double)’:
src/OpenSMOKE_External_Functions.cpp:338: warning: use of old-style cast
src/OpenSMOKE_External_Functions.cpp:339: warning: use of old-style cast
src/OpenSMOKE_External_Functions.cpp:345: warning: use of old-style cast
src/OpenSMOKE_External_Functions.cpp:345: warning: use of old-style cast
src/OpenSMOKE_External_Functions.cpp:407: warning: use of old-style cast
+ wmake libso flamelets
Making dependency list for source file src/OpenSMOKE_PDF_NonAdiabaticFlamelet_Library.cpp
Making dependency list for source file src/OpenSMOKE_PDF_Flamelet_Library.cpp
Making dependency list for source file src/OpenSMOKE_PDF_Flamelet.cpp
+ wmake libso twoequations
Making dependency list for source file src/OpenSMOKE_SootEmpiricalModels.cpp
Making dependency list for source file src/OpenSMOKE_SootSourceTermFlamelet.cpp
Making dependency list for source file src/OpenSMOKE_SootSourceTermFlameletLibrary.cpp
Making dependency list for source file src/OpenSMOKE_SootSourceTermLibrary.cpp
+ wmake libso qmom
Making dependency list for source file src/OpenSMOKE_QMOM_EmpiricalModels.cpp
Making dependency list for source file src/OpenSMOKE_QMOM_GordonAlgorithm.cpp
+ wmake libso pdfThermo
Making dependency list for source file basicPdfThermo/basicPdfThermo.C
Making dependency list for source file basicPdfThermo/newBasicPdfThermo.C
Making dependency list for source file hPdfThermo/hPdfThermos.C
9. moving to /opt/libOpenSMOKE/src/applications/rhoSimple..Flamlet/
10. ./Allwclean
11. update the Make/option file (correct path set)
12. ./Allwmake

--> errors!!!

---------------------------------------------------------------------------------

The first time i tried it, I created the $FOAM_USER_LIBBIN and $FOAM_USER_APPBIN dir. After that I moved the libraries in the /opt/libOpenSMOKE/src/libraries/* into the APPBIN dir.

- I removed the folder <hPdfThermo (copy)> in the folder $FOAM_USER_APPBIN/hPdfThermo/ directory couse I thought that this is just a copy of the other folder.

- I removed all lnInclude folders in <common> <hPdfThermo> <twoEquations> <qmom> <flamelets>

- I moved all files stored in the "src/" subdirectory into the lib folder.
e.g.
Code:
mv src/* ../
(wanted to make clearer folders)

- I changed the Make/option files (path for $FOAM_LIBBIN and $FOAM_APPBIN etc.)

- Compiled the libraries step by step using wmake libso

- I tried to compile the solver with some errors:
Code:
createFields.H: In function 'int main(int, char*)': 
createFields.H:25: error: 'class Foam::basicPdfThermo' has no member  named 'csi'
.
.
.
After that I sent a email to Alberto and he told me that there is a bug. I have to add the following lines:
Code:
Dear Tobias, 

there is a bug in the header basicPdfThermo.H. I forgot to declare the  following virtual functions: 


    virtual volScalarField& csi(){}; 
    virtual const volScalarField& csi() const{}; 

    virtual volScalarField& csiv2(){}; 
    virtual const volScalarField& csiv2() const{}; 

    virtual volScalarField& chi_st(){}; 
    virtual const volScalarField& chi_st() const{}; 

    virtual volScalarField& H(){}; 
    virtual const volScalarField& H() const{}; 

    virtual volScalarField& as(){}; 
    virtual const volScalarField& as() const{}; 


which are then reimplemented in hPdfThermo class (which inherits  basicPdfThermo class). On my home computer I reproduced the error, but  on my laptop the compilation works fine. In any case the solution is  simple: you should add the declaration lines reported above in your  libOpenSMOKE/src/libraries/basicPdfThermo/basicPdfThermo.H file and then  recompile the library.
I tried it but it did not work. After a while I changed the lines to (remove brackets {})

Code:
    virtual volScalarField& csi(); 
    virtual const volScalarField& csi() const; 

    virtual volScalarField& csiv2(); 
    virtual const volScalarField& csiv2() const; 

    virtual volScalarField& chi_st(); 
    virtual const volScalarField& chi_st() const; 

    virtual volScalarField& H(); 
    virtual const volScalarField& H() const; 

    virtual volScalarField& as(); 
    virtual const volScalarField& as() const;
And it worked. But I still could not compile the solver.

Two day`s ago I tried it again - STEP BY STEP with the instructions (see at the top).
I make sure every file is on the right place and nothing is missing.
I could compile the libs with no error but after I compile the rhoSimple..Flamelet solver I got errors for missing files (couse i do not delete the <hPdfThermo (copy)> folder???>

Code:
could not open file OpenSMOKE_SootEmpiricalModels.h for source file rhoSimpleFoam_flamelets.C
could not open file OpenSMOKE_SootSourceTermLibrary.h for source file rhoSimpleFoam_flamelets.C
could not open file OpenSMOKE_QMOM_EmpiricalModels.h for source file rhoSimpleFoam_flamelets.C
In file included from rhoSimpleFoam_flamelets.C:34:
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:42:43: error: OpenSMOKE_SootEmpiricalModels.h: No such file or directory
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:43:45: error: OpenSMOKE_SootSourceTermLibrary.h: No such file or directory
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:44:44: error: OpenSMOKE_QMOM_EmpiricalModels.h: No such file or directory
In file included from rhoSimpleFoam_flamelets.C:34:
in the folder /opt/libOpenSMOKE/src/libraries/PdfThermo/lnInclude/
I looked for the files needed and copied all the files into the
Code:
cp qmom/src/* PdfThermo/lnInclude
The missing file error is gone now but there are new (and a lot of) errors.
Now I have those errors trying to compile the rhoSimple..flamelet solver

Code:
wmake 2>errorLog
Code:
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:365: error: ‘virtual const Foam::volScalarField& Foam::hPdfThermo<MixtureType>::csi()’ cannot be overloaded
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:136: error: with ‘virtual Foam::volScalarField& Foam::hPdfThermo<MixtureType>::csi()’
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:366: error: ‘virtual const Foam::volScalarField& Foam::hPdfThermo<MixtureType>::csi() const’ cannot be overloaded
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:142: error: with ‘virtual const Foam::volScalarField& Foam::hPdfThermo<MixtureType>::csi() const’
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:368: error: ‘virtual Foam::volScalarField& Foam::hPdfThermo<MixtureType>::csiv2()’ cannot be overloaded
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:149: error: with ‘virtual Foam::volScalarField& Foam::hPdfThermo<MixtureType>::csiv2()’
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:369: error: ‘virtual const Foam::volScalarField& Foam::hPdfThermo<MixtureType>::csiv2() const’ cannot be overloaded
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:155: error: with ‘virtual const Foam::volScalarField& Foam::hPdfThermo<MixtureType>::csiv2() const’
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:371: error: ‘virtual Foam::volScalarField& Foam::hPdfThermo<MixtureType>::chi_st()’ cannot be overloaded
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:162: error: with ‘virtual Foam::volScalarField& Foam::hPdfThermo<MixtureType>::chi_st()’
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:372: error: ‘virtual const Foam::volScalarField& Foam::hPdfThermo<MixtureType>::chi_st() const’ cannot be overloaded
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:168: error: with ‘virtual const Foam::volScalarField& Foam::hPdfThermo<MixtureType>::chi_st() const’
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:374: error: ‘virtual Foam::volScalarField& Foam::hPdfThermo<MixtureType>::H()’ cannot be overloaded
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:175: error: with ‘virtual Foam::volScalarField& Foam::hPdfThermo<MixtureType>::H()’
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:375: error: ‘virtual const Foam::volScalarField& Foam::hPdfThermo<MixtureType>::H() const’ cannot be overloaded
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:181: error: with ‘virtual const Foam::volScalarField& Foam::hPdfThermo<MixtureType>::H() const’
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:377: error: ‘virtual Foam::volScalarField& Foam::hPdfThermo<MixtureType>::as()’ cannot be overloaded
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:188: error: with ‘virtual Foam::volScalarField& Foam::hPdfThermo<MixtureType>::as()’
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:378: error: ‘virtual const Foam::volScalarField& Foam::hPdfThermo<MixtureType>::as() const’ cannot be overloaded
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:194: error: with ‘virtual const Foam::volScalarField& Foam::hPdfThermo<MixtureType>::as() const’
In file included from /opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:390,
                 from rhoSimpleFoam_flamelets.C:34:
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.C: In constructor ‘Foam::hPdfThermo<MixtureType>::hPdfThermo(const Foam::fvMesh&)’:
/opt/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.C:323: error: no matching function for call to ‘OpenSMOKE_PDF_NonAdiabaticFlamelet_Library::SetLogNormalChiDistribution()’
/opt/libOpenSMOKE/src/libraries/flamelets/lnInclude/OpenSMOKE_PDF_NonAdiabaticFlamelet_Library.hpp:53: note: candidates are: void OpenSMOKE_PDF_NonAdiabaticFlamelet_Library::SetLogNormalChiDistribution(double, int)
In file included from rhoSimpleFoam_flamelets.C:48:
createFields.H: In function ‘int main(int, char**)’:
createFields.H:25: error: invalid initialization of reference of type ‘Foam::volScalarField&’ from expression of type ‘const Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>’
/opt/openfoam170/src/finiteVolume/lnInclude/readSIMPLEControls.H:6: warning: unused variable ‘momentumPredictor’
/opt/openfoam170/src/finiteVolume/lnInclude/readSIMPLEControls.H:9: warning: unused variable ‘transonic’
/opt/libOpenSMOKE/src/libraries/common/lnInclude/OpenSMOKE_External_Functions.hpp: At global scope:
/opt/libOpenSMOKE/src/libraries/common/lnInclude/OpenSMOKE_External_Functions.hpp:197: warning: ‘Moss::gamma’ defined but not used
I hope its not too confusing and I am feeling low couse I can not compile it
I had several tries without success and I changed very often the files and settings.

And a big problem is that i dont understand the Openfoam code *thats not good*

Well,
I wrote a mail (yesterday) to the other three autors called in the documentary and hope for a recall (but I think they are all very busy).


So far,
I hope my problem is clear and someone can help me solving the problem.

Regards
Tobi

PS: The downloading file is very confusing, isn't it?
Tobi is offline   Reply With Quote

Old   April 9, 2012, 19:32
Default
  #3
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Hi Tobi,

OK, I only managed to get about 90% into this. It compiled with 1.7.x, except for "rhoSimpleFoamFlamelets_1007".
See the code here: https://github.com/wyldckat/libOpenSMOKE - instructions are (vaguely) on the front page (bottom half of the page).
I've re-engineered the code to be generic enough and it will install the libraries in your user folder. There is no need to install as root in "/opt".

You'll still have to contact the authors, because aside from the mess on that rarball they provide, the application mentioned above won't build. I don't know enough of OpenFOAM's code to hack-n-slash a fix for it
Additionally, the document they provide mentions a PISO version of their solver, but such a solver is not provided.

edit: I re-read your previous post and figure out from "basicThermo" what Alberto meant. See here the stuff he was talking about: https://github.com/wyldckat/libOpenS...4d587c66757eb1
Therefore, now everything builds on 1.7.x!! Haven't tested on the others yet.

Best regards,
Bruno
__________________

Last edited by wyldckat; April 9, 2012 at 19:51. Reason: see "edit:"
wyldckat is offline   Reply With Quote

Old   April 10, 2012, 02:06
Default
  #4
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
hi bruno,

thx for your help. I `ll try it today afternoon after I come home from work.
I ll give you a answer if it s working. tobi
Tobi is offline   Reply With Quote

Old   April 11, 2012, 19:26
Default
  #5
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Hi Tobi,

And it's up! It now also builds with 2.0.x and 2.1.x!
Instructions on the page at https://github.com/wyldckat/libOpenSMOKE have been updated to reflect the existence of the respective branches for each version of OpenFOAM.

All that is left is to figure out where is the source code for the static binaries at "utilities/exe"... according to the original documentation, it refers to these binaries only as free .

Best regards,
Bruno
__________________
wyldckat is offline   Reply With Quote

Old   April 12, 2012, 18:20
Default
  #6
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
hi,

i tested it with 1.7.1 <failed>
i tested it with 2.1.x <failed>

I can not compile the applications

Its always the same!
Code:
/home/shor-ty/OpenFOAM/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:42:43: schwerwiegender Fehler: OpenSMOKE_SootEmpiricalModels.h: Datei oder Verzeichnis nicht gefunden
Kompilierung beendet.
make[1]: *** [Make/linux64GccDPOpt/rhoSimpleFoam_flamelets.o] Fehler 1
make[1]: Das Target »/home/shor-ty/OpenFOAM/shor-ty-2.1.x/platforms/linux64GccDPOpt/bin/rhoSimpleFoamFlamelets_1007« wurde wegen Fehlern nicht aktualisiert.
make[1]: Verlasse Verzeichnis '/home/shor-ty/OpenFOAM/libOpenSMOKE/src/applications/rhoSimpleFoamFlamelets_1007'
thats not a problem if wmake don 't find the target. I copied the files into the place i looked for. . .

with no result -.-

you can compile it without any problems ?
Thats annoying!
Tobi is offline   Reply With Quote

Old   April 13, 2012, 04:04
Default
  #7
Senior Member
 
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20
bastil is on a distinguished road
Quote:
Originally Posted by Tobi View Post
Code:
/home/shor-ty/OpenFOAM/libOpenSMOKE/src/libraries/pdfThermo/lnInclude/hPdfThermo.H:42:43: schwerwiegender Fehler: OpenSMOKE_SootEmpiricalModels.h: Datei oder Verzeichnis nicht gefunden
Tobi,

you are missing OpenSMOKE_SootEmpiricalModels.h. Where is this header-file? Is it in place? Are all paths defined properly?

Kind regards

Bastian

Last edited by bastil; April 13, 2012 at 04:21.
bastil is offline   Reply With Quote

Old   April 13, 2012, 04:13
Default
  #8
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Hi Tobi,

That's very odd... I've just tried it in a another machine and it built without any problems!

If you detail the steps you've taken, I can figure out what you did wrong.

Best regards,
Bruno
__________________

Last edited by wyldckat; April 13, 2012 at 04:14. Reason: typo
wyldckat is offline   Reply With Quote

Old   April 13, 2012, 05:18
Default
  #9
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Okay...

first my local machine:

Xubuntu 11.10 64bit.
Using OpenFOAM-2.1.x on the $HOME/OpenFOAM/ folder
Using ThirdParty-2.1.x

Steps:
load gsl-1.15 and install it:

Code:
mkdir -p $HOME/OpenFOAM/gsl
cd $HOME/OpenFOAM/gsl-1.15
./configure prefix=$HOME/OpenFOAM/gsl  
make
make install
After that I have the libs needed in the $HOME/OpenFOAM/gsl folder.
Getting your updated code with git:

[code]
cd $HOME/OpenFOAM
git clone https://github.com/wyldckat/libOpenSMOKE.git
cd libOpenSMOKE
git branch -a
git checkout 2.1.x
vim Allwmake // changing the gsl direction
./Allwmake
[code]

Libs are compiled well without errors.
But why are there a folder called hPdfThermo (copy) ??
And while I compile that lib I get a message, that some files existing?!?!?

The applications give errors of missing header files. Like the

/pdfThermo/lnInclude/hPdfThermo.H

>> missing files from qmom and twoequations ? ? ?



TADAAAAAAAAAAA SOLVED!
Just remove the hPdfThermo (copy) folder!
After recompiling the libs there is no more the message "files existing lnInclude"

and I can compile the solver soot, too (exept flamelet).
But why?

I have a look into the /pdfThermo/lnInclude/ files and noticed that the entrys are different if I remove the (copy) folder!
there are no reference to that folder but if i compile it, its like a ghost wanna compile that folder!

but why?

Tobi
Tobi is offline   Reply With Quote

Old   April 13, 2012, 05:24
Default
  #10
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Mmm, OK... when I get a chance, I'll remove that folder from the git repo.

Apparently the reason why it works for me and not for you to have that "copy" folder is because wmakeLnInclude creates the links in the "lnInclude" folder... and while with me it sticks with the normal folder, for you it uses the copy version instead.

I left the copy version because it could be useful to analyse what changes occurred... but I guess it's just garbage right now.

edit: clean up complete.
__________________

Last edited by wyldckat; April 13, 2012 at 17:56. Reason: see "edit:"
wyldckat is offline   Reply With Quote

Old   April 17, 2012, 11:02
Default
  #11
Senior Member
 
Tom Fahner
Join Date: Mar 2009
Location: Breda, Netherlands
Posts: 647
Rep Power: 32
tomf will become famous soon enoughtomf will become famous soon enough
Send a message via MSN to tomf Send a message via Skype™ to tomf
Hello Bruno,

Thanks a lot for all the work, I just started playing around with it today and am quite impressed by the speed and accuracy. Just had to modify the set-up of the tutorial a bit to make it work under OF2.1.x though.

Maybe it is possible to update the 2.1.x tutorial files to the new set-up? I have attached the changed tutorial files that work with my setup for OF 2.1.x. I have split them into the different tutorial cases as far as the 0/mut files are concerned and common files for the system and constant folders.

I did not succeed in running the soot-postprocessor yet. There seems to be something wrong with the copying of the files in the Allrun script, but I do not know what exactly. It runs the KentHonnery case, but fails at the postprocessor, missing the phiN-file:

Code:
Preparing field phiN (number of soot particles per unit volume)...


--> FOAM FATAL IO ERROR: 
cannot find file

file: /home/tom/OpenFOAM/OpenFOAM-2.1.x/libOpenSMOKE/tutorials/rhoSimpleFoamPostProcessorSoot2E/KentHonnery/10000/phiN at line 0.

    From function regIOobject::readStream()
    in file db/regIOobject/regIOobjectRead.C at line 73.

FOAM exiting
Attached Files
File Type: gz Updates.tar.gz (1.8 KB, 27 views)
wyldckat, Tobi and cheng1988sjtu like this.
tomf is offline   Reply With Quote

Old   April 17, 2012, 16:37
Default
  #12
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Greetings Tom,

About "phiN", please read the section "Current Status" from my blog post: libOpenSMOKE - Making it work once again with OpenFOAM - I updated it a while ago, with stuff I had previously sent only to Tobi... because I thought he was the only person using it

I'm going to look into the changes you've made and integrate them into the v2.1.x branch. I'll edit this post and the blog post when I'm done
edit: see entry 2012-04-17 21:06 in the blog

Best regards,
Bruno

PS: Tobi, you're not alone
__________________

Last edited by wyldckat; April 17, 2012 at 17:14. Reason: see "edit:"
wyldckat is offline   Reply With Quote

Old   April 18, 2012, 04:36
Default
  #13
Senior Member
 
Tom Fahner
Join Date: Mar 2009
Location: Breda, Netherlands
Posts: 647
Rep Power: 32
tomf will become famous soon enoughtomf will become famous soon enough
Send a message via MSN to tomf Send a message via Skype™ to tomf
Hi Bruno,

Well I wish I would have found this openSMOKE library sooner, I think it would have helped me in a recent project. But for now I wanted to investigate it for future projects, whenever I have some time. The first test (tutorial) seems very promising. Probably need to dig into the code more deeply. If I can find something useful I will let it know.

Regards,
Tom
tomf is offline   Reply With Quote

Old   April 18, 2012, 17:56
Default
  #14
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Quote:
Originally Posted by tomf View Post
Hi Bruno,

Well I wish I would have found this openSMOKE library sooner, I think it would have helped me in a recent project. But for now I wanted to investigate it for future projects, whenever I have some time. The first test (tutorial) seems very promising. Probably need to dig into the code more deeply. If I can find something useful I will let it know.

Regards,
Tom

Hi I am writing a little bash tool for getting the flamelets.
I ll sent it to burno, so he can upload it.

@Tom: are you interessted in CO emmissions? And what kind of combustions do you simulate?

Tobi

I have the same problem with phi_N but what ever ... i have to get deeper into the mecahnism and all around it.

Well some informations.
The GRI_ Files are a bit different to those using CRECK. Well i am not sure why the nasa - polynomial are different ?? Any suggestions?

I am sad, that the binarys are not published!
Well ...

If the script is ready i ll upload it.

I am not alone, but i think tom is very good in C++ and OpenFOAM code!
Tobi is offline   Reply With Quote

Old   April 19, 2012, 06:23
Default
  #15
Senior Member
 
Tom Fahner
Join Date: Mar 2009
Location: Breda, Netherlands
Posts: 647
Rep Power: 32
tomf will become famous soon enoughtomf will become famous soon enough
Send a message via MSN to tomf Send a message via Skype™ to tomf
Hi Tobi,

First of all I am not necessarily good at c++ or OpenFOAM code, just a reasoanbly experienced user or OpenFOAM (a couple of years by now), so I may be able to help with getting some tutorials running and investigating stuff.

That is also how I managed to create a phiN and phiM that seem to work for the tutorial, however I have not looked into accuracy or correctness yet. They are attached to this message. They have to be put in the final result (10000) folder of the KentHonnery case and then I just ran the postprocessor for another 10000 steps by modifying the controlDict (endTime 20000), with a Msoot as in the picture.

As for my reason of looking into this specific library:

I am working on all kinds of projects that involve CFD, not only on combustion. I am therefore more generally interested in combustion simulations as a subset of CFD simulations. The recent project happened to be an industrial burner, but I want to start looking at some flames for my own interest. I soon found the current reactingFoam very slow, and learned about flamelets and lookuptables which impressed my a lot. So when this topic popped up it drew my attention, however I am not really experienced enough in chemistry to be seen as a combustion engineer. Just glad to help.

Good luck with your thesis,
Tom
Attached Images
File Type: jpg Msoot.jpg (15.6 KB, 158 views)
Attached Files
File Type: gz PostProcessorFiles.tar.gz (665 Bytes, 27 views)
tomf is offline   Reply With Quote

Old   April 19, 2012, 14:59
Default
  #16
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Hi tom,

the flamelet theory is not very simple and at least I have noone I can ask if I have questions or problems. But its very interessting... thats why I am writing my thesis in that topic ...

Is it right, that the flamelet theory is a model that - hmm how can I say it - describes flames

okay in the flamelet library are the kinetics, thermodynamics and properties from all species and reaction - is that correct?

I am a man who wanna know what he is doing. So I am also very interested into the theory of flamelets ... I read papers and stuff about flamelets but its not all clear yet. There is a other student working with ansys and flamelet model but I am not sure if he is teaching me everything correctly. I think its the right way but not exact and correct.

After reading a lot I think the following:

generate the flamelet librarys discribe the flame (maybe as an imagination its like a plane of entries in a datasheet) - if you solve your problem you get some chemical problems that you can solve direct, but its too much workload for the computer, or you look into the tables generated in the pre-processing befor. In that librarys are all the information about the chemical properties for combustion.

Example:
OpenFOAM takes one cell and needs the cemical information. Now OF refere to the look up table and get the information about the flame/chemical reaction/mixture of that cell. Some like --> cell has some properties (temperature, mixture,...) --> refere to the lookUpTables and look what entry is related to that properties - of that cell --> get the information about the chemicals and other stuff and use that for solving the next iteration(s)


Is that half-way correct?

Well its not easy to understand everything couse all captions are in english. Its okay couse I am writing and reading all the day in english

What's your case? Is it an own case or a tutorial case included by the git?

Tobi

And thx for your answer!
Tobi is offline   Reply With Quote

Old   April 19, 2012, 16:01
Default
  #17
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Tom, do you use openSMOKE with 2.1.x ?

With 1.7.x everythings work fine. But with 2.1.x I get the following error:

Code:
flameletRhoSimpleFoam: error while loading shared libraries: libgsl.so.0: cannot open shared object file: No such file or directory
maybe I did something wrong while I copied everything to other folders, but I can compile everything without errors.

hmm...


Bruno I cleared the tutorial files, and updated the header to 2.1.x
you can update your replace the old one with those but oyu have to put in the "PDF's" - its too big with that files.
Attached Files
File Type: gz rhoSimpleFoamFlamelets.tar.gz (13.0 KB, 56 views)

Last edited by Tobi; April 19, 2012 at 16:31.
Tobi is offline   Reply With Quote

Old   April 20, 2012, 06:00
Default
  #18
Senior Member
 
Tom Fahner
Join Date: Mar 2009
Location: Breda, Netherlands
Posts: 647
Rep Power: 32
tomf will become famous soon enoughtomf will become famous soon enough
Send a message via MSN to tomf Send a message via Skype™ to tomf
Well Tobi,

As I said before I am not exactly a chemical specialist, but as far as I understood it, you can consider a flamelet as a model to move from reactants to product via a typical chemical procedure, with generation/destruction of intermediate species, increments in temperature, changes in density and other thermophysical properties during this typical procedure. Now in principle you can calculate every intermediate state every time for each cell for each specie and also calculate a transport equation for each specie, but this gives you a very slow progress even in steady-state solutions. Now if there are some specific conditions the whole chemical process follows the same typical procedure, so you can relate the current combustion progress in a cell to a certain state in the chemical process. I think this is the basic explanation of the flamelet in my own words. The benefit of the look-up table is just that you do the calculation of the typical flamelet a priori and use that result during the CFD run. However I think doing a thorough literature study will give you the answers and explanations you need.

The case picture I showed was just the KentHonnery tutorial, and I am using OF 2.1.x.

Regards,
Tom
tomf is offline   Reply With Quote

Old   April 21, 2012, 08:51
Default
  #19
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Greetings to both of you!

@Tobi:
Quote:
Originally Posted by Tobi View Post
Code:
flameletRhoSimpleFoam: error while loading shared libraries: libgsl.so.0: cannot open shared object file: No such file or directory
maybe I did something wrong while I copied everything to other folders, but I can compile everything without errors.
The reason is simple: you are building your modified solver without the help of the main Allwmake in "libOpenSMOKE". Without it, you don't have the variable GSL_INST_DIR on your shell environment. If you want to be able to build independently of the helper Allwmake script, then add to your "~/.bashrc" file one of the following two lines:
Code:
export GSL_INST_DIR="$HOME/gsl"

alias gsl4smo='export GSL_INST_DIR="$HOME/gsl"'
If you choose the second one, then every time you start a new terminal and build libOpenSMOKE applications, then you'll have to run the command:
Code:
gsl4smo
Keep in mind that this will be overridden in Allwmake when it is executed, but only for the duration of its execution.

In the mean time, I'm integrating the two submissions you guys have posted here. I'll update the blog post when done.

Best regards,
Bruno
__________________
wyldckat is offline   Reply With Quote

Old   April 21, 2012, 13:59
Default
  #20
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Hi bruno,

well thx for the answer, but I already exported the variable $GSL_INST_DIR with

Code:
export GSL..="Path"
In this way I am quite familiar with Linux and I looked into your Allwmake folder
Without setting this variable I should not be able to compile the libs but I set it and can compile the libs.

Well maybe I started a new terminal without setting this variable
Don 't know. I 'll have a new try in that for now

Tobi
Tobi is offline   Reply With Quote

Reply


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
Numerical treatment of the source term in combustion equations Tobi Main CFD Forum 37 September 15, 2020 14:42
[openSmoke] flameletSmoke + new ODESolver (by Alberto Cuoci) Tobi OpenFOAM Community Contributions 1 November 21, 2017 19:24
Unsteady solver with Flamelet Model (libOpenSMOKE) francesco_capuano OpenFOAM Running, Solving & CFD 11 November 26, 2013 05:50
LibOpenSmoke, getting the species in ParaFoam Christoph_84 OpenFOAM 1 May 31, 2012 15:42


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