|
[Sponsors] |
externalWallHeatFluxTemperature zeros h value if patch is out of processor |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
January 12, 2022, 16:21 |
externalWallHeatFluxTemperature zeros h value if patch is out of processor
|
#1 |
Member
Julio Pieri
Join Date: Sep 2017
Posts: 96
Rep Power: 8 |
Hi all,
I'm facing a possible bug with the externalWallHeatFluxTemperature BC in parallel, OF v2012, WSL in win10. I'll be as detailed as I can be. This is what is happening:
I investigated it a little bit further and noticed that whenever there is no patch cell on the processor, it zeros the h value. Since I have many BCs and many processors, there are a lot of zeroed h in the processor/T files. When reconstructPar takes place, it zeroes all h values on every patch in the new T file! If I resume it that way, I get floating point exception (since h is used inversed in of the thermal resistance calculation). If I manually edit the h back to non-zero values, it works. Also, if I restart the parallel simulation, it also works, as the h values are not zeroed where they are needed. More detailed example: Original BC config: Code:
BC-1 { type externalWallHeatFluxTemperature; mode coefficient; qr qr; qrRelaxation 0.001; emissivity 0.9; Ta constant 723.0; h constant 111.0; kappaMethod fluidThermo; value $internalField; } BC-2 { ... and so on processor0/anyTStep/T Code:
BC-1 (OUT OF PROCESSOR-0) { type externalWallHeatFluxTemperature; mode coefficient; kappaMethod fluidThermo; kappa none; alphaAni none; alpha none; h constant 0; Ta constant 723; emissivity 0.9; qr qr; qrRelaxation 0.005; qrPrevious nonuniform List<scalar> 0(0); refValue nonuniform List<scalar> 0(0); refGradient uniform 0; valueFraction nonuniform List<scalar> 0(0); value nonuniform List<scalar> 0(0); } processor3/anyTStep/T: Code:
BC-1 (IN PROCESSOR-3) { type externalWallHeatFluxTemperature; mode coefficient; kappaMethod fluidThermo; kappa none; alphaAni none; alpha none; h constant 111; Ta constant 723; emissivity 0.9; qr qr; qrRelaxation 0.005; qrPrevious nonuniform List<scalar> 1883(...); refValue nonuniform List<scalar> 1883(...); refGradient uniform 0; valueFraction nonuniform List<scalar> 1883(...); value nonuniform List<scalar> 1883(...); } I tried to dig into the code, and I believe this is related to the BC write() stage or something, and not with the decompose/reconstruct step. The h might be "updated, else kept as initialized" somewhere in the code. I also believe this might happen for q (flux) and Q (power) modes as well, because the way the code is written. Note that Ta is always preserved, pointing at the direction of how to solve this. The palliative solution is to run mapFields from a clean BC configuration (i.e., with all correct h entries) whenever I need to reconstruct it. This will overwrite the BCs with fresh working ones, and keep the patch values. |
|
January 13, 2022, 11:02 |
|
#2 |
Senior Member
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,685
Rep Power: 40 |
Sounds like it might be this one: https://develop.openfoam.com/Develop.../-/issues/2101
with these changes: https://develop.openfoam.com/Develop...e77bdc8f220e95 If you are using WSL, try with openfoam2112 (can be installed without collisions) |
|
January 13, 2022, 12:08 |
|
#3 |
Member
Julio Pieri
Join Date: Sep 2017
Posts: 96
Rep Power: 8 |
That's great, Mark! Thanks. I'll try that.
|
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[Other] Can't Shake Erros: patch type 'patch' not constraint type 'empty' | BrendaEM | OpenFOAM Meshing & Mesh Conversion | 12 | April 3, 2022 18:32 |
Foam-Extend 4.0 simpleFoam motorbike parallel error? | EternalSeekerX | OpenFOAM Running, Solving & CFD | 0 | May 10, 2021 04:55 |
[snappyHexMesh] Error snappyhexmesh - Multiple outside loops | avinashjagdale | OpenFOAM Meshing & Mesh Conversion | 53 | March 8, 2019 09:42 |
parallel run OpenFoam | Srinath Reddy | OpenFOAM Running, Solving & CFD | 13 | February 27, 2019 09:15 |
Possible Bug in pimpleFoam (or createPatch) (or fluent3DMeshToFoam) | cfdonline2mohsen | OpenFOAM | 3 | October 21, 2013 09:28 |