CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM

FvPatchScalarField access operator

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 7, 2008, 10:43
Default operator Hi! I have fvPa
  #1
Senior Member
 
Maka Mohu
Join Date: Mar 2009
Posts: 305
Rep Power: 18
maka is on a distinguished road
operator[]

Hi!

I have fvPatchScalarField& vsfp
I want to print the values and the coordinates of all face centers that belong to vsfp. I found operator like [] in the documentation but I do not know how to use it. Any idea how to do that? Thanks.

Best regards,
Maka.
maka is offline   Reply With Quote

Old   May 7, 2008, 11:02
Default Try: const vectorField& ctr
  #2
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,907
Rep Power: 33
hjasak will become famous soon enough
Try:

const vectorField& ctrs = vsfp.patch().Cf();

Enjoy,

Hrv
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   July 1, 2008, 09:31
Default face order in patches. I no
  #3
Senior Member
 
Maka Mohu
Join Date: Mar 2009
Posts: 305
Rep Power: 18
maka is on a distinguished road
face order in patches.

I noticed that if the patch is normal to z, the values of the scalar on the patch is ordered:
x1 y z1
x1 y z2
...
x2 y z1
x2 y z2

Is there a general rule of ordering such face value. I want to use this to average patch value over specified direction. Thanks.

Best regards,
Maka.
maka is offline   Reply With Quote

Old   July 1, 2008, 09:32
Default correction: I noticed .. norm
  #4
Senior Member
 
Maka Mohu
Join Date: Mar 2009
Posts: 305
Rep Power: 18
maka is on a distinguished road
correction:
I noticed .. normal to Y.
maka is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Ouput Variable Operator selim CFX 1 October 24, 2007 12:15
Question about fvmlaplacian operator cosimobianchini OpenFOAM Running, Solving & CFD 0 February 1, 2007 14:40
Operator Splitting. Maria. Main CFD Forum 5 September 17, 2005 23:10
Operator precedence hemph OpenFOAM 1 September 13, 2005 13:40
a math operator in UDF lichun Dong FLUENT 7 June 18, 2005 23:04


All times are GMT -4. The time now is 00:53.