|
[Sponsors] |
Script for an airfoil polar plots computation |
![]() |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
![]() |
![]() |
#1 |
Senior Member
maddalena
Join Date: Mar 2009
Posts: 436
Rep Power: 23 ![]() |
Hello everybody,
With a fixed mesh, I would like to calculate aerodynamic coefficient at different angles of attack for an airfoil, i.e. obtain the cl-alpha and cd-alpha curves. Is there anyone that has a written script for this purpose? If not, could you suggest me how to write it? I know the real basis of writing script, but I still miss how to write math operations and editing files for doing something like velocity projections on the coordinate axis. Any help? Cheers, maddalena |
|
![]() |
![]() |
![]() |
![]() |
#2 |
Senior Member
Kevin Smith
Join Date: Mar 2009
Posts: 104
Rep Power: 17 ![]() |
PyFoam is used routinely for this type of parameter variation. http://openfoamwiki.net/index.php/Co...eter_Variation
|
|
![]() |
![]() |
![]() |
![]() |
#3 | |
Senior Member
maddalena
Join Date: Mar 2009
Posts: 436
Rep Power: 23 ![]() |
Quote:
![]() |
||
![]() |
![]() |
![]() |
![]() |
#4 |
Senior Member
Kevin Smith
Join Date: Mar 2009
Posts: 104
Rep Power: 17 ![]() |
PyFoam is a python library that can be used in python scripts. The examples on that page can be copied into a script and run from the command line.
|
|
![]() |
![]() |
![]() |
![]() |
#5 | |
Senior Member
maddalena
Join Date: Mar 2009
Posts: 436
Rep Power: 23 ![]() |
Quote:
Do you know if there are some kind of documentations that explain the programming basis? I mean: open, reading and writing files, operations, things like that. I am trying to understand what the example files do, but all the variables are called with the same name, thus I cannot understand if they are "keywords" or what... In addition, what are the functions already implemented in python? For example, is there any function that works like sol.changeBoundary("inlet", ...) but for the controlDict file? Where can I find these kind of information? Thaknk for your time and support, mad |
||
![]() |
![]() |
![]() |
![]() |
#6 |
Senior Member
Kevin Smith
Join Date: Mar 2009
Posts: 104
Rep Power: 17 ![]() |
I'm not sure there is any further documentation other than that wiki page. It sounds painful, but I would suggest just looking through the pyfoam code to figure out what functions are available and how it works..
Yes, you can modify any openfoam dictionary with pyfoam I believe - http://openfoamwiki.net/index.php/Co...ions_for_walls . I've used similar code to this to modify other dictionaries. |
|
![]() |
![]() |
![]() |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Polar airfoil of the Naca 0015 | Titasse | FLUENT | 10 | June 27, 2010 10:39 |
Airfoil computation | shan | FLUENT | 1 | April 10, 2008 08:50 |
HELP ( 3D airfoil computation) | shan | FLUENT | 0 | April 3, 2008 09:59 |
Need for help for 3D airfoil computation | D.T. | Main CFD Forum | 0 | May 6, 2003 13:04 |
Steady solutions in Airfoil Computation? | Tyler Sherk | Main CFD Forum | 4 | August 12, 2002 12:08 |