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

Find the common edges shared by two patches

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By deepsterblue

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 20, 2008, 15:01
Default Hi, All In my code, I want
  #1
liu
Senior Member
 
Xiaofeng Liu
Join Date: Mar 2009
Location: State College, PA, USA
Posts: 118
Rep Power: 17
liu is on a distinguished road
Hi, All

In my code, I want to find the common edges which are shared by two patches, say patch1 and patch 2.

I now I have to loop around all the edges of the patches to compare. But I am too lazy. Did anybody already do this? Or maybe someone could point me to somewhere and save me a lot time?
__________________
Xiaofeng Liu, Ph.D., P.E.,
Assistant Professor
Department of Civil and Environmental Engineering
Penn State University
223B Sackett Building
University Park, PA 16802


Web: http://water.engr.psu.edu/liu/
liu is offline   Reply With Quote

Old   October 20, 2008, 21:48
Default I can take a guess - Every
  #2
Senior Member
 
Sandeep Menon
Join Date: Mar 2009
Location: Amherst, MA
Posts: 403
Rep Power: 25
deepsterblue will become famous soon enough
I can take a guess -

Every primitivePatch edges() call provides an edge addressing list that spans between 0 and nInternalEdges, and from then on, all edges are patch boundary edges. Comparing boundary edges for patch1 and patch2 should be a much quicker way of obtaining common edges, rather than looping through all of them.

Hope this helps.
Pepanson likes this.
__________________
Sandeep Menon
University of Massachusetts Amherst
https://github.com/smenon
deepsterblue 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
free edges on patches florian Siemens 1 November 17, 2005 01:17
droplets common block Habib Siemens 1 June 25, 2005 00:07
Common blocks in VISTUR Celia Siemens 6 December 26, 2004 02:25
common blocks CMB Siemens 1 November 12, 2004 09:41
use of common RANS B.C.'s in LES? Sanjin Saric Main CFD Forum 0 March 21, 2002 06:08


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