CFD Online Logo CFD Online URL
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Find the common edges shared by two patches

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

Like Tree1Likes
  • 1 Post By deepsterblue

LinkBack Thread Tools Search this Thread Display Modes
Old   October 20, 2008, 16:01
Default Hi, All In my code, I want
Senior Member
Xiaofeng Liu
Join Date: Mar 2009
Location: State College, PA, USA
Posts: 118
Rep Power: 16
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

liu is offline   Reply With Quote

Old   October 20, 2008, 22:48
Default I can take a guess - Every
Senior Member
Sandeep Menon
Join Date: Mar 2009
Location: Amherst, MA
Posts: 403
Rep Power: 24
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
deepsterblue is offline   Reply With Quote


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
free edges on patches florian Siemens 1 November 17, 2005 02:17
droplets common block Habib Siemens 1 June 25, 2005 01:07
Common blocks in VISTUR Celia Siemens 6 December 26, 2004 03:25
common blocks CMB Siemens 1 November 12, 2004 10:41
use of common RANS B.C.'s in LES? Sanjin Saric Main CFD Forum 0 March 21, 2002 07:08

All times are GMT -4. The time now is 21:35.