Crash using DirectMappedVelocityFluxField
Dear developers, debuggers and forum readers,
When using the directMappedVelocityFlux patch to remap the U field, pisoFoam crashes when using the NEARESTFACE option. If interested, I can post the error message associated with the crash, but I've traced the origin back to the following piece of code in directMappedVelocityFluxFixedValueFvPatchField: Code:
00209 newUValues = patch().patchSlice(newUValues); Code:
00176 vectorField newUValues; Reading the similar routine used in directMappedFixedValueFvPatchField.C, I guess the variable in brackets should be allUValues and not newUValues, leading to: Code:
00209 newUValues = patch().patchSlice(allUValues); I was also wondering if a kind soul could also make good use of this discussion and explain to me what the patch().patchSlice() command does? Kind regards, Francois. |
We've finally got a proper bug reporting system :-)
Please report any OpenFOAM bugs on http://www.openfoam.com/bugs. Thanks, Mattijs |
2 Attachment(s)
This was still crashing for me;
The updated inlet velocity is written out in the wrong place in "case customDirectMappedPolyPatch::NEARESTFACE" I've attached fixed C source files. |
The mapDistributes may also need to be corrected?
|
Dear James,
I don't know which version of OpenFOAM you are using, but the issue I had has been resolved in the 1.7.x version. It's just a question of entering "git pull" in the OpenFOAM-1.7.x directory, and recompiling with ./Allwmake. I haven't yet double checked the order of writing in NEARESTFACE, but I saw that you moved the patch().patchSlice() before the mapDistribute::distribute command. I'll come back to you on that one as soon as I find the time to further investigate the problem. Kind regards, Francois. |
Hi Francois,
I was on the most recent pull of the repos, recompiled from scratch. (Check bug #0000056 on the foam bugs list); nearestFace wasn't working for me at all until I moved new*Values to before the mapDistributes, similar to the other cases... James |
Hi James,
Thank you for your reply! Good to know the problem is fixed, as I was just going to start working with the NEARESTFACE option.. ;-) Regards, Francois. |
Dear Fransje,
It seems that nearestFace still doesn't work for me. mattijs has modified this in 2010.10.15. In my U file, I use like this, inlet { type directMappedVelocityFlux; value uniform(10 0 0); setAverage false; average (10 0 0); phi phi; } Is it right? Thanks. |
Dear panda,
Yes, this is correct. By the way, if you are using the directMappedVelocityFlux type you don't need the setAverage and the related average switches since they are not used by the directMappedVelocityFluxFvPatchField class. Kind regards, Francois. |
And nearestFace should now work as well. See the following thread:
http://www.cfd-online.com/Forums/ope...tml#post283044 Kind regards, Francois. |
Quote:
Are you working now for "nearestFace" ? I think mattijs have fixed the bug for nearestPatchFace, and it is working now. But I think he didn't repair nearestFace. How about your case ? Thanks. |
Hi,
It has been a while since I looked at this, however I'm think that that the fix Mattijs implemented, worked for me? James |
All times are GMT -4. The time now is 18:50. |