magSf: which surface?
Hello!
I'd like to know how I can access/choose the area (of only one of the 6 faces) of a internal cubical finite volume (not near a patch). I know I have to use the magSf command, but I don't know which face area (or which direction) of the finite volume it gives me. Thanking you in advance, Maxime |
Quote:
Either read the user documentation or look at the etc/cellModels to see what the face order means for any particular primitive cell shape. |
Quote:
Excuse my incomprehension but is it possible to have a code example? I don't know what you mean. How can I get the face number and how do I use it to get the face surface? Someone else has the same problem (cf. http://www.cfd-online.com/Forums/ope...tml#post266026). Can you also give me an Internet address where I can find such examples (ideally on "how to use magSf() and Sf()", and not just huge lists of commands and enormous graphs like the ones on the pages you advised me to look at on a similar post I wrote) please? I'm sure it's not hard (at least it shouldn't be), but if the user documentation was more detailed/clear it would've helped everyone better. Thank you. Maxime |
Quote:
Writing some sample code would not be difficult, but I'm unwilling to accept abuse in exchange to trying to help ... especially when you are apparently not willing to examine the existing documentation (doxygen + source code). Besides which, any sample code that I could provide would certainly not meet your exact needs anyhow and then you are back to where you started. |
I have looked through documentation and through various pieces of code that actually use magSf and I have to say that I am still uncertain how to access the values of magSf.
magSf returns a surfaceScalarField. This object has a method boundaryField() which allows to access values on each patch by boundaryField()[patchId]. Following olesen suggestion, I looked at etc/cellModels and I can clearly see cell shape definitions. The same thing seems to be described here in section 5.1.3: http://www.openfoam.com/docs/user/mesh-description.php For my purposes I am actually happy to use patch values. But out of curiosity I was wondering if you could give some additional suggestions on how to access the internal field of surface scalar field and extract the values in one direction only. I am looking at this function http://foam.sourceforge.net/doc/Doxy...ce.html#l00033 which seems to be just using magSf()[faceID]. |
All times are GMT -4. The time now is 02:21. |