turbulentDFMInlet crashed using inhomogenous turbulence input - stan_lw, February 04, 2021 #251
Replies: 10 comments
-
stan, I am not sure if I have the correct set of your files, but the ones I've got from Frank appear to have one missing file: constant/inflowProperties (not saying that this is the only issue. Might be in our code, too) I suggest changing 0/U to include:
and add the attached file to constant/. That file was generated using the SimCenter TInF tool. The CFD Expert in WE-UQ uses the same engine and should generate the same input file. Please let me know if that got you any further. I am available to zoom Friday afternoon or most days next week. ~Peter
|
Beta Was this translation helpful? Give feedback.
-
Thank you for your suggestion. From Section 2.3 in the documentation (https://nheri-simcenter.github.io/TinF-Documentation/theory/turbulent_inflow.html#specification-of-the-statistics-of-the-target-turbulence), there are three methods to specify the statistics: Direct specification, Specification via interpolation, and Specification via prescribed functions. If I understood correctly, the “inflowProperties” file is only needed for the “Specification via prescribed functions method”. I am trying to use “Specification via interpolation” method which reads the tabulated data in constant/boundaryData/inlet. So I think the “inflowProperties” file is actually not needed? Anyway I have try running with your suggestion. I added the downloaded file constant/inflowProperties, and modified 0/U inlet boundary as suggested. However, it still crashed at the first time step.
|
Beta Was this translation helpful? Give feedback.
-
Would you mind connecting with me via zoom or share a recording showing all your settings so I can reproduce the issue? This looks like a bug in the OpenFOAM module and will require some debugging on our end. Having precisely your settings makes tracking and testing easier. Thanks
|
Beta Was this translation helpful? Give feedback.
-
Sure we can discuss over Zoom, I will send you the updated case file with inflowProperties if you want to try whether you can reproduce the bug.
|
Beta Was this translation helpful? Give feedback.
-
Did you get a chance to discuss with Peter, over Zoom? Would you like me to help you setup a meeting? Thanks
|
Beta Was this translation helpful? Give feedback.
-
Hi Ajay,
|
Beta Was this translation helpful? Give feedback.
-
The issue appears to be that directional parameters in InflowProperties must be provided or the code runs into numeric exceptions (1/0 or 0/0). Workaround: TODO:
|
Beta Was this translation helpful? Give feedback.
-
To update on this issue, Jay suggests turning off “calculateU, calculateL and calculateR” by setting them to false. I tried that, but this does not work. In fact, the original tutorial case (which crashed) does not have these lines so by default they are false. If we turned them on (i.e, set them to true), then the simulation works because instead of looking for the tables in /constant/boundaryData/inlet, the simulation looks for /constant/inflowProperties file and skip reading the tables. I run a few tests to provide a clearer description of the issue:
From above tests, the simulation works if it reads the file /constant/inflowProperties to obtain U, R, and L (“Specification via prescribed functions” method in the Documentation), but crashed if it reads the tables in /constant/boundaryData/inlet (“Specification via interpolation” method in the Documentation). So the issue lies with the tabulated data in the tables. Jay mentioned that the sigma tensor needs to be positive definite, I will play around with the values in the R table to check whether this is the root cause.
|
Beta Was this translation helpful? Give feedback.
-
To update, I did another test with an R table having all positive-definite R matrix. In fact, the original R table in the tutorial already have all rows being positive definite, excepts the four rows at the top and bottom of the domains, which have zeros for all values. I changed the values of R11, R22 and R33 to 1e-9 (a very small number but sufficient to make the R matrix positive definite) and rerun, but the simulation still crashed without starting.
|
Beta Was this translation helpful? Give feedback.
-
I am writing to you as a follow-up on our discussion during today's programmer meeting. Peter & myself ran Jay's and your examples locally on my Ubuntu VM today morning. Below is a detailed description of all the steps we followed, just in case. For this, we used OpenFOAM7. I downloaded the TinF from SimCenter Github (https://github.com/NHERI-SimCenter/TurbulenceInflowTool). I used the "wmake" command using the files in the folder openFOAM_code / openFOAM7 / turbulentInflow to compile the libraries. We compared with Jay's examples provided in the folder tutorials / inhomogeneousTurbulence / DFM / channel395. For the solver here, he has used pimpleFoam. We used both pimpleFoam and pisoFoam and both seem to work and restart. We see that you have renamed the solver as TinFFoam but I hope the linking is correctly done. Another thing that we noticed was that some items (like Ufinal / kfinal etc.) were missing from the system / fvSolutions dictionary. These were in the original Jay's files but were removed. I am guessing that this was probably unintentional. If we run the files, we get an error message from OpenFOAM that these are missing. So once we added them back, the case started running. We used the procedure outlined by Jay (given below in the attached email) to test the restart operation. We ran four cases where each had a time increment of 0.2: (c) Case02a: Start time was 0s and end time was 2s. Since there is a random generator being employed, there is a small difference between the results of Case12 and Case02a. In order to confirm this, we ran the case again (Case02b). I have emailed the link for you to download all four cases. We think that the restart function itself is working correctly. Could you please check again?
|
Beta Was this translation helpful? Give feedback.
-
I am trying to run a test case with turbulentDFMInlet using tabulated boundary data for U, R, L. Since the inhomogenousTurbulence case in the tutorial uses tabulated boundary data, I started with that case. This tutorial case uses turbulentATSMInlet, and I encounter no issue with that. However, when I modified it to run with turbulentDFMInlet, it crashed after the first time step. Below are the three changes I made to the original tutorial case file:
The case file is too large to be uploaded here. I will send it over email. The zipped case file also contains the run.log file and the error message when it crashed. Thank you!
Beta Was this translation helpful? Give feedback.
All reactions