|
[Sponsors] |
Adding forcecoeffs file to the controldict is causing pimpleDyMfoam to crash. |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
August 9, 2014, 21:01 |
Adding forcecoeffs file to the controldict is causing pimpleDyMfoam to crash.
|
#1 |
Member
Pruthvi
Join Date: Feb 2014
Posts: 41
Rep Power: 12 |
Hello all! I simulated an oscillating airfoil using pimpleDyMfoam and got some results. Later I added a forcecoeffs file and ran it again to measure forces and the solution is crashing.
I checked the log files and it seems like the forcecoeffs is altering the initial conditions of the spring. I gave anchor(0,0,0) , refattachment(0,0,0), velocity(0, 0.8, 0). In the log.pimpleDyMfoam file, it shows the initial spring length as (0, 9e-5,0) when it should actually be (0,0,0). Here is my forcecoeffs file. At the end of the controldict file I added #include "forceCoeffs" forceCoeffs1 { type forceCoeffs; // type forces; functionObjectLibs ( "libforces.so" ); outputControl timeStep; timeInterval 1; log yes; patches ( wing ); pName p; UName U; rhoName rhoInf; // Indicates incompressible log true; rhoInf 1; // Redundant for incompressible liftDir (0 0 1); dragDir (1 0 0); CofR (0 0 0); // Axle midpoint on ground pitchAxis (0 1 0); magUInf 0; lRef 0.001; // Wheelbase length Aref 0.002; // Estimated // binData // { // nBin 20; // output data into 20 bins // direction (1 0 0); // bin direction // cumulative yes; // } } I uploaded the log.pimpleDyMfoam and dynamicMeshDict files. Please help me guys. |
|
August 11, 2014, 04:38 |
|
#2 |
Senior Member
|
Did you put your include statement like this?
functions { #include "forceCoeffs" } It has to be inside the functions subdict. Regards, Tom |
|
August 11, 2014, 15:16 |
|
#3 |
Member
Pruthvi
Join Date: Feb 2014
Posts: 41
Rep Power: 12 |
Hey Tom ! Thanks for the reply. I added it in the functions subdict. Yesterday I modified my controldict file by adding the lib.openFOAM.so. I still get the error. I'm uploading the new controldict file and log file. Please take a look.
|
|
August 11, 2014, 17:56 |
|
#4 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Good evening,
I am wondering, whether it is because magUInf is set to zero, i.e. when computing the force coefficient based on the magnitude of the incident velocity, you are likely to divide by zero. Kind regards Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request. |
|
August 13, 2014, 06:42 |
|
#5 |
Member
Pruthvi
Join Date: Feb 2014
Posts: 41
Rep Power: 12 |
Hello ! I tried changing the magUInf to non-zero values and it is still crashing. The unexpected thing is that when I add the forceCoeffs file it is changing the initial conditions of the spring. The anchor is supposed to be (0,0,0) but its showing a non-zero value instead.
|
|
August 13, 2014, 06:54 |
|
#6 |
Senior Member
|
Just wondering what would happen if you run the simulation for a few (say 10) time steps with the functions section commented out and than uncomment this section. I wonder if there is something special about just the first time step that may cause this, but it looks a bit strange indeed.
Regards, Tom |
|
August 14, 2014, 22:56 |
|
#7 |
Member
Pruthvi
Join Date: Feb 2014
Posts: 41
Rep Power: 12 |
Hey I tried your suggestion and its still crashing. Could it be my bcs ? I gave a zero gradient on all four sides. There is no ambient velocity. The flatplate is plunging in still air. I added the following two lines to the fvSolutions file
PIMPLE { correctPhi yes; nOuterCorrectors 2; nCorrectors 1; nNonOrthogonalCorrectors 0; pRefCell 0; // These two were added pRefValue 0; // } Is it possible that the pRefValue shouldnt be zero ? |
|
August 15, 2014, 02:59 |
|
#8 |
Member
Pruthvi
Join Date: Feb 2014
Posts: 41
Rep Power: 12 |
I just found out that the wingMotion case is also crashing when I insert the forceCoeffs file. I would really appreciate if someone can try it and check if its a bug in pimpleDyMFoam. I was able to extract data from pimpleFoam but not from pimpleDyMFoam.
|
|
August 20, 2014, 05:19 |
|
#9 |
Senior Member
|
Hi, just did the test with the tutorial. It runs perfectly fine when magUInf is non-zero, so I cannot reproduce your error.
|
|
August 20, 2014, 12:39 |
|
#10 |
Member
Pruthvi
Join Date: Feb 2014
Posts: 41
Rep Power: 12 |
Hey Tom ! Thanks for your time. How long did you run the simulation? When I ran the test case, it went on for a while before crashing. Could you upload your log file please? If I confirm that your simulation ran fine, I will reinstall openfoam230.
|
|
August 25, 2014, 05:31 |
|
#11 |
Senior Member
|
Hi
It ran for the entire time a set in the controlDict for the case. I had to rerun the case to get the log since I deleted it last time. You can download the log here: http://we.tl/CD48eDLusI to get the log back: tar xzf log.tgz Regards, Tom |
|
October 7, 2014, 00:03 |
|
#12 |
Member
Pruthvi
Join Date: Feb 2014
Posts: 41
Rep Power: 12 |
Hello Tom! I checked your log file. Thanks a lot. I was able to run the simulations successfully if I choose 3 cores. The solution is crasing for any other number on my laptop. My laptop has 4 cores and 8 threads. I read about it online. It is called a race condition. Do you know what could be causing it?
|
|
October 10, 2014, 05:56 |
|
#13 |
Senior Member
|
I will not be able to help you with that issue I'm afraid. Sounds like a hardware/software compatibility issue, or maybe related to compiling? Really have no clue. Good luck.
Tom |
|
April 13, 2015, 02:46 |
Solved!
|
#14 |
Member
Pruthvi
Join Date: Feb 2014
Posts: 41
Rep Power: 12 |
Hello everybody!
This is a bug in OpenFOAM code and it has been resolved by commit 5179e8ea3bcb24cdb6ad0ac96764c0d562a55945 . Thanks for the help. |
|
Tags |
dynamicmesh, openfoam 2.3.0, pimpledymfoam |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[swak4Foam] funkyDoCalc with OF2.3 massflow | NiFl | OpenFOAM Community Contributions | 14 | November 25, 2020 04:30 |
[OpenFOAM.org] Compile OF 2.3 on Mac OS X .... the patch | gschaider | OpenFOAM Installation | 225 | August 25, 2015 20:43 |
Trouble compiling utilities using source-built OpenFOAM | Artur | OpenFOAM Programming & Development | 14 | October 29, 2013 11:59 |
"parabolicVelocity" in OpenFoam 2.1.0 ? | sawyer86 | OpenFOAM Running, Solving & CFD | 21 | February 7, 2012 12:44 |
error while compiling the USER Sub routine | CFD user | CFX | 3 | November 25, 2002 16:16 |