CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Programming & Development

mesh/geometry programming

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

Reply
 
LinkBack Thread Tools Display Modes
Old   October 25, 2009, 13:55
Default mesh/geometry programming
  #1
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 259
Blog Entries: 5
Rep Power: 11
tomislav_maric is on a distinguished road
Hello everyone,

I will be doing some geometrical calculations in OpenFOAM and I would like to develop on the existing objects. face.mag() is a nice example. How can I instantiate a face in my application? Face constructors take labelList for an argument, and it is not clear how the labels of this labelList are connected to the list of points. Any advice?
tomislav_maric is offline   Reply With Quote

Old   October 26, 2009, 03:53
Default
  #2
Senior Member
 
Kathrin Kissling
Join Date: Mar 2009
Location: Besigheim, Germany
Posts: 134
Rep Power: 8
kathrin_kissling is on a distinguished road
Hi Tomislav,

what I found is this

It refences the order of the lables of points in one face (I think so)
// Basic rule: we assume that the sequence of labels in each list
// will be circular in the same order (but not necessarily in the
// same direction or from the same starting point).

It can be found in src/OpenFOAM/meshes/meshShapes/face/face.C
Deep down in the static member function there is on function which
compares two faces. And there is this rule. It starts at line 306.
There might be more useful routines for your project

Best regards!

Kathrin
kathrin_kissling is offline   Reply With Quote

Old   October 26, 2009, 05:20
Default
  #3
Senior Member
 
Tomislav Maric
Join Date: Mar 2009
Location: Darmstadt, Germany
Posts: 259
Blog Entries: 5
Rep Power: 11
tomislav_maric is on a distinguished road
hi kathrin,

thanks for your answer. by the way, I'm in Munich, alive and well and I'll be coming to the Stammtisch in Stuttgart. Regarding your question:

1. of course it's the list of labels, and right now I don't need the face comparison

2. my problem was: what list of points are these labels from?

There seems to be a global pointList, and the labels are actually positions in that list. This is kind of a problem, because I don't want a global list of points in the registry, I want to create my own face when ever I want. That means that I will have my own point list and I need to make the face recognize the labels from that list. I'm digging through it right now.
tomislav_maric 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
A book for a beginner wanting to learn programming frank Main CFD Forum 9 May 12, 2014 23:15
OpenFoam programming prapanj OpenFOAM 10 March 18, 2010 08:23
Programming for CFD atmcfd Main CFD Forum 7 September 9, 2009 01:48
Programming in OpenFOAM vinu OpenFOAM 2 July 11, 2009 10:16
new CFD Programming Forum Thinker Main CFD Forum 14 November 19, 2002 17:03


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