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

OpenFoam Compiler

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 17, 2016, 06:52
Default OpenFoam Compiler
  #1
New Member
 
toboto
Join Date: Jun 2016
Posts: 20
Rep Power: 9
toboto is on a distinguished road
Dear All,

I've just started my journey with OpenFOAM 3 months ago. I've used the standard solvers to run some cases with some success. Now I am trying to learn how to develop new solvers or modify old ones. I've background about C++ but I think it isn't enough to proceed with OF development. So, I decided to follow an OpenFoam development dedicated course. I found course by Chalmers "OpenSource CFD for industry – high-level development" is a good start (with other courses available online).

My problem now is that while learning I need to apply the small examples given in the course. e.g: info << T.xy() << endl;

For general C++ I was using any compile or IDE to do that but obviously this will not work because "info" isn't a standard C++ object.

I tried to include the corresponding .h files and include foam namespace in my code but this lead me to errors asking for another .h files.

Is there any way to overcome this problem?

Best regards.
toboto is offline   Reply With Quote

Old   June 17, 2016, 12:13
Default
  #2
Senior Member
 
David Gaden
Join Date: Apr 2009
Location: Winnipeg, Canada
Posts: 437
Rep Power: 22
marupio is on a distinguished road
I think it would be best if you work within a working OpenFOAM environment. You can create your own folder outside of the OpenFOAM source code... but the Make/files and Make/options needs to reference OpenFOAM-related stuff. You might create your own lib and bin output folders (i.e. where you tell it to put the compiled output at the bottom of Make/files).

I personally just use a text editor, and then OpenFOAM's built-in wmake for compiling.

I've heard some people have success using Eclipse for development.
__________________
~~~
Follow me on twitter @DavidGaden
marupio is offline   Reply With Quote

Reply


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
How to contribute to the community of OpenFOAM users and to the OpenFOAM technology wyldckat OpenFOAM 17 November 10, 2017 15:54
OpenFOAM v3.0.1 Training, London, Houston, Berlin, Jan-Mar 2016 cfd.direct OpenFOAM Announcements from Other Sources 0 January 5, 2016 03:18
Error compiling OpenFoam 1.6.x with intel compiler icc mak_04 OpenFOAM Installation 5 October 28, 2011 07:06
CFX11 + Fortran compiler ? Mohan CFX 20 March 30, 2011 18:56
Cross-compiling OpenFOAM 1.7.0 on Linux for Windows 32 and 64bits with Mingw-w64 wyldckat OpenFOAM Announcements from Other Sources 3 September 8, 2010 06:25


All times are GMT -4. The time now is 03:59.