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

Accessing the first surface center near the boundary

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 31, 2020, 12:51
Default Accessing the first surface center near the boundary
  #1
New Member
 
Yujuan Luo
Join Date: Jul 2019
Posts: 21
Rep Power: 7
Yujuan is on a distinguished road
Hi all,


I know that .patchInternalField() can be used to access the first cell center near the boundary. Now I want to access the first surface center near the boundary (the surface center which is in symmetry with the boundary point regarding to the first cell center near the boundary), is there any functions like patchInternalField, or what else should I do?
Yujuan is offline   Reply With Quote

Old   August 4, 2020, 10:37
Default
  #2
New Member
 
Wenyuan Fan
Join Date: Mar 2017
Posts: 27
Rep Power: 9
Wenyuan is on a distinguished road
Hi Yujuan,

I don't think such a built-in function exists. Since "the first surface" is simply not defined in a general polyhedral framework like OpenFOAM. For instance, how do you define the first surface of a tetrahedron adjacent to a patch?

According to your description, you are dealing with some special types of cells. In this case, you need to write your own code to find that surface, which is not difficult.
Wenyuan is offline   Reply With Quote

Old   August 14, 2020, 11:31
Default
  #3
New Member
 
Yujuan Luo
Join Date: Jul 2019
Posts: 21
Rep Power: 7
Yujuan is on a distinguished road
Quote:
Originally Posted by Wenyuan View Post
Hi Yujuan,

I don't think such a built-in function exists. Since "the first surface" is simply not defined in a general polyhedral framework like OpenFOAM. For instance, how do you define the first surface of a tetrahedron adjacent to a patch?

According to your description, you are dealing with some special types of cells. In this case, you need to write your own code to find that surface, which is not difficult.



Hi Wenyuan,


Thanks a lot for your suggestions. I'll have a try.
Yujuan is offline   Reply With Quote

Old   August 14, 2020, 11:40
Default
  #4
Senior Member
 
cdegroot's Avatar
 
Chris DeGroot
Join Date: Nov 2011
Location: Canada
Posts: 414
Rep Power: 18
cdegroot is on a distinguished road
I would suggest looping through the cells returned by patchInternalField and then writing code to test each of the faces of those cells according to your criterion (which seems quite specialized to a particular application).
__________________
Chris DeGroot, PhD, PEng
CEO, Maple Key Labs
www.maplekeylabs.com
cdegroot is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
Question about adaptive timestepping Guille1811 CFX 25 November 12, 2017 18:38
Problem in setting Boundary Condition Madhatter92 CFX 12 January 12, 2016 05:39
domain imbalance for enrgy equation happy CFX 14 September 6, 2012 02:54
RPM in Wind Turbine Pankaj CFX 9 November 23, 2009 05:05
Convective Heat Transfer - Heat Exchanger Mark CFX 6 November 15, 2004 16:55


All times are GMT -4. The time now is 12:51.