|
[Sponsors] |
September 10, 2012, 13:45 |
|
#21 | |
Member
Tayo
Join Date: Aug 2012
Posts: 94
Rep Power: 14 |
Quote:
funkySetFields ‐field alpha1 ‐expression 1 ‐time 0 ‐keepPatches ‐condition "pow(pos().x,2) + pow(pos().y,2) < pow(0.0075,2) && pos().z <0.003" I get the following below. /*---------------------------------------------------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 2.1.1 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ Build : 2.1.1-221db2718bbb Exec : funkySetFields -field alpha1 -expression 1 -time 0 -keepPatches -condition pow(pos().x,2) + pow(pos().y,2) < pow(0.0075,2) && pos().z <0.003 Date : Sep 10 2012 Time : 11:27:43 Host : "ubuntu" PID : 3987 Case : /home/tayo/OpenFOAM/tayo-2.1.1/run/mytestCases/risingBubble/constant/polyMesh nProcs : 1 sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE). fileModificationChecking : Monitoring run-time modified files using timeStampMaster allowSystemOperations : Disallowing user-supplied system call operations // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // swakVersion: 0.2.0 - Friday the 13th (Release date: 2012-04-13) // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // Create time --> FOAM FATAL IO ERROR: cannot find file file: /home/tayo/OpenFOAM/tayo-2.1.1/run/mytestCases/risingBubble/constant/polyMesh/system/controlDict at line 0. From function regIOobject::readStream() in file db/regIOobject/regIOobjectRead.C at line 73. FOAM exiting I'm familiarizing myself with funkySetFields using a tutorial for now and even checked the examples given in swak4Foam website (where it was downloaded). As an example in the cavity case, you used the code below to set the velocity field to a "circle" around the center. Assuming I want to follow the driven-lid cavity as a basic example, do I just use this code and then follow the rest of the tutorial? I tried this and I obtained a similar error as above (this was hoping that funkySetFields has installed as I now assume). What do you think about this? funkySetFields -case cavity -field U -expression '(grad(dist())^vector(0,0,-1))*mag(pos()-vector(0.05,0.05,0))/0.05' -time 0 |
||
September 10, 2012, 15:33 |
|
#22 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
September 10, 2012, 16:31 |
|
#23 |
Member
Tayo
Join Date: Aug 2012
Posts: 94
Rep Power: 14 |
Like I said, I was following a tutorial. Here is the message I got when I ran the code from the main directory. First, I just want to make sure it's due to a swak4Foam compilation error or not.
/*---------------------------------------------------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 2.1.1 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ Build : 2.1.1-221db2718bbb Exec : funkySetFields -field alpha -expression 1 -time 0 -keepPatches -condition pow(pos().x,2) + pow(pos().y,2) < pow(0.0075,2) && pos().z <0.003 Date : Sep 10 2012 Time : 15:05:22 Host : "ubuntu" PID : 2093 Case : /home/tayo/OpenFOAM/tayo-2.1.1/run/mytestCases/risingBubble nProcs : 1 sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE). fileModificationChecking : Monitoring run-time modified files using timeStampMaster allowSystemOperations : Disallowing user-supplied system call operations // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // swakVersion: 0.2.0 - Friday the 13th (Release date: 2012-04-13) // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // Create time Create mesh for time = 0 --> FOAM FATAL ERROR: Cannot find file "points" in directory "polyMesh" in times 0 down to constant From function Time::findInstance(const fileName&, const word&, const IOobject::readOption, const word&) in file db/Time/findInstance.C at line 188. FOAM exiting Just to be sure, I also tried it on the basic driven-lid cavity tutorial. After blockMesh, I simply applied: funkySetFields -case cavity -field U -expression 'vector(0,0,0)' -time 0 and I still obtained .......... --> FOAM FATAL ERROR: funkySetFields: cannot open case directory "./cavity" FOAM exiting Similar error was obtained when the damBreak-tutorial was tried with the swak4Foam code after blockMesh was generated: funkySetFields -case damBreak -time 0 -field gamma -expression " pos().x <= 0.1461 && pos().y <= 0.292 ? 1 : 0" Error result is --> FOAM FATAL ERROR: funkySetFields: cannot open case directory "./damBreak" Following this and previous conversation, can we tell if funkySetFields is properly installed or not. And if yes, what's the procedure to properly use it for initialization. Thanks Last edited by tayo; September 10, 2012 at 17:53. |
|
September 10, 2012, 19:25 |
|
#24 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
- missing points: there is no mesh - can not open case: there is on case in the location specified
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
September 10, 2012, 19:41 |
|
#25 |
Member
Tayo
Join Date: Aug 2012
Posts: 94
Rep Power: 14 |
I don't get please kindly explain. I generated the mesh in the damBreak for example. And ofcourse, I'm working in the directory. Please explain how to use it right. Thank you
|
|
September 10, 2012, 20:09 |
|
#26 |
Member
Tayo
Join Date: Aug 2012
Posts: 94
Rep Power: 14 |
Thanks all. I think I got it working using the damBreak-tutorial now. I simply specified the location of the case (thought it would automatically detect it since I'm in the case dir) and then included -create since the gamma function was not yet created. This confirms that funkySetFields is properly installed regardless of all the warnings msgs. Special thanks to Bernhard and co for writing the swak4Foam. I now have to figure out how to properly apply it to my different cases.
tayo@ubuntu:~/OpenFOAM/tayo-2.1.1/run/mytestCases/damBreak$ funkySetFields -create -case $FOAM_RUN/mytestCases/damBreak -time 0 -field gamma -expression " pos().x <= 0.1461 && pos().y <= 0.292 ? 1 : 0" /*---------------------------------------------------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 2.1.1 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ Build : 2.1.1-221db2718bbb Exec : funkySetFields -create -case /home/tayo/OpenFOAM/tayo-2.1.1/run/mytestCases/damBreak -time 0 -field gamma -expression pos().x <= 0.1461 && pos().y <= 0.292 ? 1 : 0 Date : Sep 10 2012 Time : 18:56:29 Host : "ubuntu" PID : 3159 Case : /home/tayo/OpenFOAM/tayo-2.1.1/run/mytestCases/damBreak nProcs : 1 sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE). fileModificationChecking : Monitoring run-time modified files using timeStampMaster allowSystemOperations : Disallowing user-supplied system call operations // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // swakVersion: 0.2.0 - Friday the 13th (Release date: 2012-04-13) // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // Create time Create mesh for time = 0 Time = 0 Using command-line options Creating field gamma Putting " pos().x <= 0.1461 && pos().y <= 0.292 ? 1 : 0" into field gamma at t = "0" if condition "true" is true Setting 2268 of 2268 cells Writing to "gamma" End |
|
October 3, 2012, 13:46 |
|
#27 |
Member
Sagun Tripathi
Join Date: Aug 2012
Location: Amherst, USA
Posts: 78
Rep Power: 14 |
Hello Tayo,
I just went through the entire thread since I'm also having some difficulties in implementing swak4Foam. Here is what I have done so far: 1. Installed OpenFOAM version 2.1.1 on Linux 11.10 2. Installed bison, flex and m4 macro processor 3. Installed swak4Foam as per the instructions given on the wikiPage But whenever I try to implement funkySetFields, I get this error: command not found. What would you advise me to do? Should I uninstall everything and start from scratch all over again? I was also wondering if it is possible for you to summarize in steps how you were finally able to get swak4Foam work. Thanks and regards, Sagun |
|
October 3, 2012, 15:16 |
|
#28 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
October 3, 2012, 17:35 |
|
#29 |
Member
Tayo
Join Date: Aug 2012
Posts: 94
Rep Power: 14 |
Yep I think you should follow what Bernard advised and provide some of the error messages. I've actually installed swak4Foam on two additional computers and I had no big issue again. Also make sue that flex is installed. If you've tried all these and it doesn't still work, then I would uninstall everything and install again. It only takes a few minutes.
|
|
October 4, 2012, 05:33 |
|
#30 |
Member
Sagun Tripathi
Join Date: Aug 2012
Location: Amherst, USA
Posts: 78
Rep Power: 14 |
Hello,
Thank you so much to both of you. So this is what I get when I run wmake all in my directory of sources: root@iwpc178:/opt/openfoam211/src/swak4Foam# wmake all No 'swakConfiguration'. Python etc won't work Checking swak4Foam-version and generating file ./Allwmake: 9: [[: not found ./Allwmake: 17: [[: not found Bison is version 2.4.1 ./Allwmake: 33: cannot open 2.3: No such file ./Allwmake: 33: [[: not found OpenFOAM-version: Major 2 Minor 1 Patch 1 ./Allwmake: 67: [[: not found No change to swak4FoamParsers/foamVersion4swak.H '/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/lib/libswak4FoamParsers.so' is up to date. '/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/lib/libgroovyBC.so' is up to date. '/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/lib/libswakFunctionObjects.so' is up to date. '/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/lib/libsimpleFunctionObjects.so' is up to date. '/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/lib/libsimpleSwakFunctionObjects.so' is up to date. '/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/lib/libswakTopoSources.so' is up to date. '/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/lib/libswakSourceFields.so' is up to date. '/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/lib/libgroovyStandardBCs.so' is up to date. SWAK_PYTHON_INCLUDE not defined .... no Python-Integration make[1]: Entering directory `/opt/openfoam211/src/swak4Foam/Utilities/funkyDoCalc' make[1]: `/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/bin/funkyDoCalc' is up to date. make[1]: Leaving directory `/opt/openfoam211/src/swak4Foam/Utilities/funkyDoCalc' make[1]: Entering directory `/opt/openfoam211/src/swak4Foam/Utilities/funkySetBoundaryField' make[1]: `/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/bin/funkySetBoundaryField' is up to date. make[1]: Leaving directory `/opt/openfoam211/src/swak4Foam/Utilities/funkySetBoundaryField' make[1]: Entering directory `/opt/openfoam211/src/swak4Foam/Utilities/funkySetFields' make[1]: `/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/bin/funkySetFields' is up to date. make[1]: Leaving directory `/opt/openfoam211/src/swak4Foam/Utilities/funkySetFields' make[1]: Entering directory `/opt/openfoam211/src/swak4Foam/Utilities/replayTransientBC' make[1]: `/home/stripathi/OpenFOAM/root-2.1.1/platforms/linuxGccDPOpt/bin/replayTransientBC' is up to date. make[1]: Leaving directory `/opt/openfoam211/src/swak4Foam/Utilities/replayTransientBC' I can see there are some errors but I am unable to understand what they mean. Please help. Regards, Sagun |
|
October 4, 2012, 11:47 |
|
#31 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
Meditated on it for some hours and then it occurred to me: you're compiling swak as root, but using it as stripathi, right? The problem is that swak writes its stuff to $FOAM_USER_APPBIN where only the user who compiled it can "see" it. This is done because "non-official"-stuff does not belong in the global $FOAM_APPBIN (especially on multi-user installeations) So the recommended way to compile it is as the user who is going to use it (there is a script to afterwards copy it to directories to site-wide access it, but if you've never heard of $FOAM_SITE_APPBIN then I don't recommend using it ... the next upgrade of swak4Foam will have a lot of surprises for you)
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
October 8, 2012, 08:01 |
|
#32 |
Member
Sagun Tripathi
Join Date: Aug 2012
Location: Amherst, USA
Posts: 78
Rep Power: 14 |
OMG, yes you are right.
And it finally worked! Thanks a zillion! |
|
October 23, 2012, 11:53 |
|
#33 |
Member
Sagun Tripathi
Join Date: Aug 2012
Location: Amherst, USA
Posts: 78
Rep Power: 14 |
Hello Bernhard,
I hope you have been doing well. I eventually got groovyBC to work and simulated second order Stokes' waves for the first time yesterday. It ran perfectly fine but when I tried to do the same today, oddly enough I get this error: Courant Number mean: 0 max: 0 Interface Courant Number mean: 0 max: 0 deltaT = 0.011976048 Time = 0.011976048 swak4Foam: Allocating new repository for sampledGlobalVariables MULES: Solving for alpha1 Phase-1 volume fraction = 0.2 Min(alpha1) = 0 Max(alpha1) = 1 MULES: Solving for alpha1 Phase-1 volume fraction = 0.2 Min(alpha1) = 0 Max(alpha1) = 1 #0 Foam::error:rintStack(Foam::Ostream&) in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so" #1 Foam::sigFpe::sigHandler(int) in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so" #2 Uninterpreted: #3 Foam::PCG::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so" #4 Foam::fvMatrix<double>::solve(Foam::dictionary const&) in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libfiniteVolume.so" #5 in "/opt/openfoam211/platforms/linuxGccDPOpt/bin/interFoam" #6 __libc_start_main in "/lib/i386-linux-gnu/libc.so.6" #7 in "/opt/openfoam211/platforms/linuxGccDPOpt/bin/interFoam" Floating point exception I haven't changed anything in my case files. Hence, I don't understand why I am getting this error today. Please take a look. Thanks, Sagun |
|
October 23, 2012, 18:23 |
|
#34 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
Hold the press .... now it comes back to me .... this looks like a problem that I fixed a couple of weeks ago ... something with uninitialized memory in groovyBC/mixed. Are you working with the release that came out last week? If not then chances are good that this is fixed in this release. Quote from the README Code:
**** =groovyBC= makes =interFoam=-runs fail unpredictably Reason was an uninitialized =valueFraction= which sometimes has values that cause a floating point exception. Fixed
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
October 24, 2012, 07:40 |
|
#35 |
Member
Sagun Tripathi
Join Date: Aug 2012
Location: Amherst, USA
Posts: 78
Rep Power: 14 |
Hello Bernhard,
No I didn't alter the installation in any way. Also, Its been a while since I installed swak4Foam, so I'm pretty sure I'm not using the release that came out last week. The behaviour of groovyBC has been very erratic. Sometimes it works and sometimes it doesn't. What should I do? Thanks, Sagun |
|
October 24, 2012, 10:22 |
|
#36 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
December 2, 2012, 12:01 |
|
#37 |
Member
Sagun Tripathi
Join Date: Aug 2012
Location: Amherst, USA
Posts: 78
Rep Power: 14 |
Hello Bernhard,
I hope you are doing well. I wanted to ask you that is it possible to generate waves in 3D using groovyBC? Thanks, Sagun |
|
December 2, 2012, 17:46 |
|
#38 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
b) what do you mean with "generate waves in 3D"? groovyBC is "only" a boundary condition: if fed with the right expressions it induce waves (if the solver is right). But if you can call the "generate waves in 3D" is a philosophical question
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
December 2, 2012, 18:14 |
|
#39 |
Member
Sagun Tripathi
Join Date: Aug 2012
Location: Amherst, USA
Posts: 78
Rep Power: 14 |
Apologies for posting on this thread and for being so vague. I did not think it to be necessary to create a new thread for a question which I thought only had a 'yes/no' answer to it, but now I realize that maybe I should have done otherwise.
By 'generating waves in 3D' I meant that is it possible to generate waves at one end in a 3-dimensional tank. All the simulations that I have done so far have been in a 2-D tank which has constrained the flow only to 'over' an object and not 'around' it. Thanks, Sagun |
|
December 3, 2012, 06:18 |
|
#40 | ||
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
Quote:
Ah. And also consider the waves2foam-toolbox (which can be found on this forum and/or the Wiki)
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
|||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Pressure outlet boundary condition | rolando | OpenFOAM Running, Solving & CFD | 62 | September 18, 2017 07:45 |
DPM udf error | haghshenasfard | FLUENT | 0 | April 13, 2016 07:35 |
[OpenFOAM] Native ParaView Reader Bugs | tj22 | ParaView | 270 | January 4, 2016 12:39 |
Compiling problems with hello worldC | fw407 | OpenFOAM Installation | 21 | January 6, 2008 18:38 |
DecomposePar links against liblamso0 with OpenMPI | jens_klostermann | OpenFOAM Bugs | 11 | June 28, 2007 18:51 |