CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   Radiation and VBA using Excel (http://www.cfd-online.com/Forums/openfoam/71950-radiation-vba-using-excel.html)

kapo84 January 20, 2010 15:48

Radiation and VBA using Excel
 
I will be receiving my undergraduate degree in Mechanical Engineering this April. I am currently enrolled in a CFD class in which I am learning OpenFOAM. For the class project I would really enjoy working on the following project:

I want to model the temperature rise for cold air flowing through an air duct exposed to various ambient conditions (like an a/c hose lying on the tarmac). This would obviously include radiation. I successfully created a model in Microsoft Excel using VBA which models this temperature rise.

Can I interface the model which I created in Excel with OpenFOAM so that for every parameter adjustment a new CFD model would be created?

Also, being a beginning CFD user (although fairly strong as a programmer) will I be able to tackle the challenge of radiation??

Thank you for your help in advance,

Please feel free to ask additional questions as I may have left out key information.

elvis January 21, 2010 04:08

maybe my answer goes in the wrong direction but if you want to do "Parameter_Variation" Bernhard Gschaider wrote PyFoam that can be used for this!
Read more: http://openfoamwiki.net/index.php/Co...eter_Variation

perhaps Excel and PyFoam find together? Hope I did not tell complete rubbish as I'm not an expert on this topic ;-)

elvis

gschaider January 21, 2010 06:46

Quote:

Originally Posted by elvis (Post 243263)
maybe my answer goes in the wrong direction but if you want to do "Parameter_Variation" Bernhard Gschaider wrote PyFoam that can be used for this!
Read more: http://openfoamwiki.net/index.php/Co...eter_Variation

perhaps Excel and PyFoam find together? Hope I did not tell complete rubbish as I'm not an expert on this topic ;-)

Writing files that are readable for Excel is no problem in python. You can easily generate CommaSeparatedValues-files using the csv-module that comes with every python-installation. That module also does reading of CSV-files.
PyFoam has a wrapper-class PyFoam.Basics.CSVCollection that does a little bit of bookkeeping for writing files, but currently there is nothing for reading.

Bernhard


All times are GMT -4. The time now is 09:58.