CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Installation

How to import a mesh from a home brewed software

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   January 30, 2008, 01:09
Default Hello all I have installed
  #1
New Member
 
Bernardo D Flores
Join Date: Mar 2009
Posts: 21
Rep Power: 17
david_flo1 is on a distinguished road
Hello all

I have installed and after struggling a while, applied the updates and compiled OpenFOAM 1.4.1 on a Edubuntu 7.1 machine. All works fine including paraFoam.

I have an application specific c++ software (Windows and VC8) made by myself to manipulate and redefine a mesh (of pyramid, hexahedral or tetrahedral (but not mixed) cells) obtained from segmented MRI data from the heart. Is a complex and large mesh.

The question is, how can I import this mesh into OpenFOAM format? I have read the whole user's manual (but chapter 8) and was thinking of reading the programmers manual next but need to reach a deadline demonstrating that I can load the mesh (PhD student here).

Basically I can create output of the data anyway is required. Currently there is a list of vertexes with unique and compacted ID and a list of polygons which relates the labels (IDs) of the vertexes that form it. There is also data that identifies a particular domain (say for example, pericardium, endocardium, atria, ventricles).

Data is a plain windows text file (.txt)

Thanks in advance for your help

Bernardo
david_flo1 is offline   Reply With Quote

Old   January 30, 2008, 01:51
Default Hello, Even if it was not f
  #2
Senior Member
 
Vincent RIVOLA
Join Date: Mar 2009
Location: France
Posts: 283
Rep Power: 18
vinz is on a distinguished road
Hello,

Even if it was not for my own software I created a while ago a converter from GridPro meshes to OpenFOAM. It might help you to look at this converter to begin your work.
You should find the files on the forum looking for GridPro in search part.
I have explained my work in the first parts of the following document:
http://www.rtech-engineering.com/VincentRIVOLA_FSI.pdf

Hope that helps!
Regards
vinz is offline   Reply With Quote

Old   January 30, 2008, 11:55
Default Hello Bernardo, Small world
  #3
New Member
 
Daniel Einstein
Join Date: Mar 2009
Posts: 22
Rep Power: 17
deinstein is on a distinguished road
Hello Bernardo,

Small world. We too are working on a heart project and we too have our own grid generation code.

The easiest thing to do is to write the OF ascii format directly. If you send me an email directly I will send you some code I wrote to do that in FORTRAN (sorry). Some of the coding is our (lame) attempt to be object oriented in FORTRAN, but I believe it is readable enough to be useful. The most important thing is to reorder the faces the OF wants them.

daniel.einstein@pnl.gov

Hope this helps
deinstein 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
Switching forum software. Import question. Peter Main CFD Forum 14 January 23, 2009 07:56
Mesh: Import to CFX DAK565656 CFX 7 November 19, 2005 20:42
import mesh in CFX Babu CFX 4 February 11, 2005 06:36
mesh import Matthias CFX 1 August 24, 2004 01:39
import mesh to CFX 4 georgian CFX 1 March 19, 2003 17:35


All times are GMT -4. The time now is 10:17.