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

adding a solver from OF 16.x to OF 4.x

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By gtarang

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 25, 2017, 16:16
Default adding a solver from OF 16.x to OF 4.x
  #1
Member
 
Anonymous
Join Date: Mar 2014
Posts: 84
Rep Power: 12
marauder is on a distinguished road
Hello guys, I'm relatively new to OpenFoam and I've a small doubt as follows,

There is steady state solver for coal combustion in ESI's OF ver 16.x which I want to add to 4.x version of OpenFoam foundation version which I generally use.

What is the easiest way possible?

Solver link - http://www.openfoam.com/documentatio...737c51864.html
marauder is offline   Reply With Quote

Old   May 26, 2017, 12:46
Default
  #2
Member
 
Tarang
Join Date: Feb 2011
Location: Delhi, India
Posts: 47
Rep Power: 15
gtarang is on a distinguished road
Well I have not checked for its alternative in OpenFOAM 4.x, but you can copy it in this way:
1. Go to the folder and in the terminal run
Code:
> foamNewApp <myApp>
2. It will create a new folder <myApp> with Make directory and <myApp>.C.
3. Copy all the contents of your app into that folder and change all the names of your app to <myApp>. Generally I add "my" to the name of the app. This helps me in keeping new files apps boundary conditions differentiated.
4. Open Make/files and verify that the <myApp>.C matches the name <myApp>.C
5. Here comes the tough part, linking the libraries. You can copy and replace the Make/options from original source to <myApp>/Make directories.
6. run wmake command in <myApp> directory from terminal
Code:
myApp> wmake
and it will compile.
If it doesn't, then perhaps it needs some more head breaking regarding the Make/options because there may be some library mismatch.
cfdsolver1 likes this.
gtarang is offline   Reply With Quote

Old   May 26, 2017, 13:11
Smile
  #3
Member
 
Anonymous
Join Date: Mar 2014
Posts: 84
Rep Power: 12
marauder is on a distinguished road
Quote:
Originally Posted by gtarang View Post
Well I have not checked for its alternative in OpenFOAM 4.x, but you can copy it in this way:
1. Go to the folder and in the terminal run
Code:
> foamNewApp <myApp>
2. It will create a new folder <myApp> with Make directory and <myApp>.C.
3. Copy all the contents of your app into that folder and change all the names of your app to <myApp>. Generally I add "my" to the name of the app. This helps me in keeping new files apps boundary conditions differentiated.
4. Open Make/files and verify that the <myApp>.C matches the name <myApp>.C
5. Here comes the tough part, linking the libraries. You can copy and replace the Make/options from original source to <myApp>/Make directories.
6. run wmake command in <myApp> directory from terminal
Code:
myApp> wmake
and it will compile.
If it doesn't, then perhaps it needs some more head breaking regarding the Make/options because there may be some library mismatch.
Thanks for the reply! Actually, after posting this I tried to create a new solver using the code I copied from other version. Turns out your prediction was right, the linkage of libraries is major headache. I'll try to do it as far as my patience goes....
marauder 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
chtMultiRegionSimpleFoam samiam1000 OpenFOAM Running, Solving & CFD 39 March 31, 2016 08:43
problem in adding instructions to the solver Gary51075607 OpenFOAM Programming & Development 2 January 13, 2015 22:26
adding strainRate in a solver Mahyar Javidi OpenFOAM Programming & Development 11 January 11, 2015 14:53
Adding additional complex source term to BuoyantBoussinesqPisoFoam solver pajofego OpenFOAM Programming & Development 2 April 9, 2013 17:00
Working directory via command line Luiz CFX 4 March 6, 2011 20:02


All times are GMT -4. The time now is 00:27.