Problems with running a custom solver: "Unknown psiCombustionModel"
Hi there,
I'm quite new to CFD and OpenFOAM and have been given a thesis with uni on the simulation of Firewhirls - thankfully the work is a continuation on a previous thesis so I won't need to start from scratch - however I am having troubles running the code I have been given. In order to create a realistic model, the previous student had to create a custom solver to allow the reference frame to rotate. I have compiled the solver using wmake, however when I go to run a case I am getting the following error with the combustion model: Code:
/*---------------------------------------------------------------------------*\ Code:
/*---------------------------------------------------------------------------*\ I am using OpenFOAM 2.2.0 on ubuntu 12.04 Cheers, Alex |
Quick question: What was the OpenFOAM version that was used in the other thesis?
Because there were some substantial changes over the years and knowing the starting point would make it a lot easier to diagnose. For example: http://www.openfoam.org/version2.2.0/thermophysical.php - section "Dictionary-based Thermodynamics Selection" |
He was also using version 2.2.0!
Cheers, |
Quick answer: Then there are only a few possible reasons for this error message. Some of which I can deduce right now:
Code:
--> FOAM Warning : |
Thanks for your help Bruno - I have found a folder of his where he has the Make files for the cylindricalVelocityInlet and custom combustion models - however when I try wmake in either I get an error. Would you have an idea of what is going wrong here? (this is when attempting wmake for cylindricalVelocityInlet):
Code:
g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/home/alexei/OpenFOAM/OpenFOAM-2.2.0/src/finiteVolume/lnInclude -I/home/alexei/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude -IlnInclude -I. -I/home/alexei/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude -I/home/alexei/OpenFOAM/OpenFOAM-2.2.0/src/OSspecific/POSIX/lnInclude -fPIC -Xlinker --add-needed -Xlinker --no-as-needed Make/linux64GccDPOpt/cylindricalVelocityInletFvPatchVectorField.o -L/home/alexei/OpenFOAM/OpenFOAM-2.2.0/platforms/linux64GccDPOpt/lib \ |
Quick answer: Run:
Code:
wmake libso Didn't the original author provide instructions on how to build the provided source code? |
Ahhh thank you again - unfortunately I've been given no instructions whatsoever - just 300GB of case files and old results to sift through. Apologies for another question, but I just tried "wmake libso" and now get this:
Code:
alexei@alexei-OptiPlex-9010:~/OpenFOAM/cameron-2.2.0/applications/customcombustionModels$ wmake libso |
Hi Alex,
That is strange... did you do something between the two executions of "wmake libso"? Because the second time you run the command it should give you the exact same error message!? Try running: Code:
wclean Code:
./Allwmake Best regards, Bruno PS: Please use follow the instructions for Posting code and output with [CODE] (i.e. when writing the output in one of your posts ;)) |
Hi Bruno,
I didn't do anything between the executions of "wmake libso" - there is no Allwmake in the source code unfortunately, but I’ve tried it again with 'wclean' and get the following: Code:
alexei@alexei-OptiPlex-9010:~/OpenFOAM/cameron-2.2.0/applications/customcombustionModels$ wclean customcombustionModels is where the issues are - I've had a look and the singleStepCombustion and infinitelyFastChemistry files don't seem to be mentioned within the Make files? If this is the problem I'm not entirely sure how to fix it if you need anything else please let me know Thank you so much for your help/time https://www.dropbox.com/sh/0tldmchii...OttANOlma?dl=0 |
Hi Alex,
Well, this was interesting... I had to do some probabilistic reverse engineering to the way of thinking of the author of the thesis you inherited... this to say that I had to guess (based on the information and files you provided) that this version of the source code you have is at a point where the author was apparently experimenting the implementation of a diffusion model... but had to stop for whatever reason and didn't revert the source code to the previous point where it was previously working. The solution is as follows:
Code:
wclean Best regards, Bruno |
Thank you so much Bruno, it built successfully!
|
Bruno,
Apologies for all the questions - I've had another issue with this custom solver that you may understand Now that the libraries have been built I've run a case using the stock fireFoam solver with no problem - however trying to use the custom solver gave me the following error: Code:
alexei@alexei-OptiPlex-9010:~/OpenFOAM/alexei-2.2.0/changing_diff/whirl_0.05r_0.01in_3.0w$ rotatingCDFireFoam Code:
alexei@alexei-OptiPlex-9010:~/OpenFOAM/alexei-2.2.0/changing_diff/whirl_0.05r_0.01in_3.0w$ rotatingCDFireFoam https://www.dropbox.com/sh/0tldmchii...OttANOlma?dl=0 Kind Regards, Alexei |
Quick answer:
The case does not have a mesh, therefore I can't test things myself. Either way, my guess is that you also need to add the other library to the "libs" list in "system/controlDict": Code:
libs ( |
Bruno,
Thanks for your advice, I tried doing that and hit run on the code and it has been running for the past 3 days (over 60hrs). This morning I woke up and saw the following error - I've only posted some of it because it was quite long: Code:
7fa415096000-7fa415099000 rw-p 004a9000 08:01 41960084 /home/alexei/OpenFOAM/OpenFOAM-2.2.0/platforms/linux64GccDPOpt/lib/libreactionThermophysicalModels.so (i also uploaded those mesh files if you were interested) |
Sorry for all the questions again - but does it make sense to you that I still get an error such as this even though I've successfully compiled the library with your help earlier?
Code:
alexei@alexei-OptiPlex-9010:~/OpenFOAM/alexei-2.2.0/fixedDiff/small/whirl_0.05r_0.01in_1.125w_7e-4Diff$ rotatingCDFireFoam |
Hi Alex,
The error log for the crash is incomplete. The real reason should be disclaimed before the long list of memory addresses you posted. Try running with the following command: Code:
rotatingCDFireFoam > log.rotatingCDFireFoam 2>&1 The issue with paraFoam is because the library that ParaView loads for opening OpenFOAM cases will only load the minimum libraries it needs. If you have your own libraries in "libs", the custom libraries will depend on other libraries that aren't loaded by default. The easiest workaround is to comment the "libs" entry. Or use the following command for listing the libraries that your solver depends on: Code:
ldd $(which rotatingCDFireFoam) Going back to the first crash: without the complete error log, it's hard to deduce why it crashed. My fear is that the case files they provided you are either incorrect, or you're working with the last development snapshot. In other words: given the issue I diagnosed for a previous post, the source code was left in a point where new developments were being tested but were not completed. It's possible the thesis author provided two types of folders:
Bruno |
Bruno thanks again,
I believe you're right in that the folders i've been given were still under development - unfortunately the lecturer he was working under was not following the coding side of the project and only helping analyse results so he hasn't been much help. I've tried running another solver of a smaller case as an example for you and get the following error: Code:
*---------------------------------------------------------------------------*\ The case is attempting to simulate a non-whirling fire under constant density conditions if this helps. Kind regards, Alexei |
Hi Alexei,
I won't be able to look into the case before the weekend, but from your description and the output error message, it feels like you didn't mention some important detail: did you compile/build any other library? I ask this because the two error messages are implying that something is amiss with one or two libraries:
Bruno |
Hi Bruno,
I've decided to just re-write the re-build the custom solver's and they seem to be working much better now, however I've tried running a case in parallel and received the following output (it was going ok for a little while before this), would you be able to offer any advice on this? I've run: Code:
mpirun -np 8 dynamicDensity -parallel Code:
Courant Number mean: 7.06846e-07 max: 0.551005 Alexei |
Hi Alexei,
Quote:
My advice: baby steps. Don't try to isolate 100 problems all at once, create small test cases and isolate one problem at a time. Best regards, Bruno |
All times are GMT -4. The time now is 04:19. |