|
[Sponsors] |
February 9, 2011, 07:05 |
How to import NACA 0012 Profile in Gridgen
|
#1 |
New Member
Join Date: Feb 2011
Posts: 3
Rep Power: 15 |
Hello,
I need some help with the Gridgen software. I want to import the NACA 0012 airfoil geometry in Gridgen. I have the profile points of NACA 0012 (x and y coordinates), but I am not able to import it in Gridgen. (I know we can import this kind of file in Gambit but I am not able to do it in Gridgen.) How I do import this profile in Gridgen? Does anyone have the NACA 0012 profile file which can be imported in Gridgen? Thank you very much in advance. Maple |
|
February 9, 2011, 09:09 |
Use the Gridgen Segment file format
|
#2 |
Senior Member
Rick Matus
Join Date: Mar 2009
Location: Fort Worth, Texas, USA
Posts: 116
Rep Power: 17 |
Maple:
You can import the airfoil coordinates in Gridgen segment file format. You can import the segment file as either grid or database. Go the Input/Output menu and choose either Database Import or Grid Pts import. If you choose Grid Pts Import, then choose Curves on the next menu. Select your segment file in the file browser and you are all set. The following piece of pseudo-code describes the format the data found in a segment file should take: c.....nmax is the number of segments c.....ni(n) is the number of points on segment n c.....imax is the number of points integer nmax integer ni(nmax) real x(imax), y(imax), z(imax) do n = 1, nmax write(1,*) ni(n) do i = 1, ni(n) write(1,*) x(i,n), y(i,n), z(i,n) end do end do Hope this helps, Rick |
|
February 14, 2011, 13:22 |
|
#4 |
Senior Member
Join Date: Nov 2009
Posts: 411
Rep Power: 20 |
You can try to use the procedure described at this link:
http://www.pointwise.com/glyph/airfoilGen/ This will do the job for you. However if you want to be able to import any kind of curve defined by points the Fortran snippet suggested by Rmatus is the way to go, you can easily convert the code to any programming language you are more familiar. Do |
|
February 14, 2011, 13:23 |
Not necessary, but illustrative
|
#5 |
Senior Member
Rick Matus
Join Date: Mar 2009
Location: Fort Worth, Texas, USA
Posts: 116
Rep Power: 17 |
Far:
You are correct about the pseudo-code. It is not necessary to write code to make a segment file. But the pseudo-code listing is a concise way to show the file format. Hope this helps, Rick |
|
February 14, 2011, 13:31 |
|
#6 |
Senior Member
|
simple way is to write the coordinates in x, y and z (make it zero for two dimensional cases) and one at the top of files with total no of coordinates. e.g.
3 1.0 0.0 0.0 2.0 2.0 0.0 2.5 2.5 0.0 for 4 coordinates write 4 1.0 0.0 0.0 2.0 2.0 0.0 2.5 2.5 0.0 3.0 3.5 0.0 hope this helps |
|
February 14, 2011, 13:34 |
|
#8 |
Senior Member
Join Date: Nov 2009
Posts: 411
Rep Power: 20 |
@Far
You mean to write the file by hand ? Do |
|
February 27, 2011, 22:01 |
|
#10 | |
New Member
Md. Sayeemuzzaman
Join Date: Apr 2010
Posts: 9
Rep Power: 16 |
Quote:
and can i import this file to the gridgen? |
||
February 28, 2011, 10:15 |
Default extension for a segment file is .dat
|
#11 |
Senior Member
Rick Matus
Join Date: Mar 2009
Location: Fort Worth, Texas, USA
Posts: 116
Rep Power: 17 |
The default extension for the segment file is .dat, but you can make it whatever you want and Gridgen and Pointwise will both still read it.
Use File, Import, Grid to import it into Pointwise. Hope this helps, Rick |
|
May 7, 2013, 12:33 |
|
#12 |
Member
Johannes Ringborn
Join Date: Nov 2012
Posts: 40
Rep Power: 14 |
Sorry to bring up this thread again.
I always get the error message: "Could not read file" file when selecting →Input/Output →Grid →PTs Import →Curves and choosing the attached file. Any help would be much appreciated |
|
May 7, 2013, 12:59 |
601 is a lot of control points for a connector
|
#13 |
Senior Member
Rick Matus
Join Date: Mar 2009
Location: Fort Worth, Texas, USA
Posts: 116
Rep Power: 17 |
Johannes:
The file imported just fine in Pointwise (see attachment). In Gridgen, I think you may be running into a limit on the number of control points allowed on a connector. You can work around this by first importing it as a database curve (I/O, Database Import, filename, Type Segment), and then using Create Connectors on DB entities to make a connector with that shape. Hope this helps, Rick |
|
May 7, 2013, 13:26 |
|
#14 | |
Member
Johannes Ringborn
Join Date: Nov 2012
Posts: 40
Rep Power: 14 |
Quote:
Your suggested approach works fine Inserting an Akima spline connector takes pretty long though but at least I do not have to import each point manually I tried now a simple case (Far's example from above): 3 1.0 0.0 0.0 2.0 2.0 0.0 2.5 2.5 0.0 And this one did neither get imported (via grid points)?! Pretty strange... |
||
May 7, 2013, 13:36 |
|
#15 | |
Senior Member
Rick Matus
Join Date: Mar 2009
Location: Fort Worth, Texas, USA
Posts: 116
Rep Power: 17 |
Quote:
|
||
May 7, 2013, 13:40 |
|
#16 | |
Member
Johannes Ringborn
Join Date: Nov 2012
Posts: 40
Rep Power: 14 |
Quote:
Could not read file. -Hit any key to continue- ...(see attached image). |
||
May 7, 2013, 13:43 |
Try this file.
|
#17 |
Senior Member
Rick Matus
Join Date: Mar 2009
Location: Fort Worth, Texas, USA
Posts: 116
Rep Power: 17 |
Here is the file I was able to import. Give it a try and see if you still get an error.
Thanks, Rick |
|
May 7, 2013, 14:01 |
|
#18 | |
Member
Johannes Ringborn
Join Date: Nov 2012
Posts: 40
Rep Power: 14 |
Quote:
Actually there is an error in a local manual I used for the import. It is written, that there has to be an empty line at the end of the file. But actually the import does not work with this empty line. Anyway Rick, thank you very much and your effort helped me a lot! Maybe somebody in the future won't have as much problems as me because of this thread. Have a nice evening! |
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Errors running allwmake in OpenFOAM141dev with WM_COMPILE_OPTION%3ddebug | unoder | OpenFOAM Installation | 11 | January 30, 2008 21:30 |
Incomplete NACA 0012 profile | Rif | Main CFD Forum | 1 | January 10, 2008 03:45 |
Problems with flat plate and NACA 0012 Lift/Force | Harly | FLUENT | 0 | June 18, 2007 11:02 |
NACA 0012 simulation results | Luis | FLUENT | 3 | February 15, 2006 12:42 |
bladegen & NACA profile | ichgut | CFX | 1 | August 9, 2004 10:31 |