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

Find the common edges shared by two patches

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

Reply
 
LinkBack Thread Tools 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: 8
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: 386
Rep Power: 15
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.
__________________
Sandeep Menon
University of Massachusetts Amherst
https://github.com/smenon
deepsterblue is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
free edges on patches florian CD-adapco 1 November 17, 2005 02:17
droplets common block Habib CD-adapco 1 June 25, 2005 00:07
Common blocks in VISTUR Celia CD-adapco 6 December 26, 2004 03:25
common blocks CMB CD-adapco 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 11:32.