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

list of commands in openfoam

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By Jerryfan

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 25, 2016, 10:20
Default list of commands in openfoam
  #1
Senior Member
 
A. Min
Join Date: Mar 2015
Posts: 308
Rep Power: 12
alimea is on a distinguished road
Hi guys

1- I want to know about "commands in openfoam:. e.g. I don't know what "Info" command do? or "mesh" ,...
Could you please introduce me a page which tells me the performance of every command?

2- I want to know about step by step of solvers. For example in the buoyantBoussinesqSimpleFoam, I couldn't get the trend of solving! where can I get my answer?

Thanks a lot
alimea is offline   Reply With Quote

Old   July 25, 2016, 11:28
Default
  #2
Member
 
Jerry
Join Date: Oct 2013
Location: Salt Lake City, UT, USA
Posts: 52
Rep Power: 13
Jerryfan is on a distinguished road
Hi alimea,


First of all, I don't think those mentioned in your questions are called commands in OpenFOAM. They are actually variables from programming's perspective in my opinion. Semantically, they are no difference with normal c++ variable
Quote:
int myfoamvar
. Back to your question, Info is a new output stream defined in OpenFOAM. Principally, it just like the c++ standard output cout. The reason why OpenFOAM defines this is that the stream operator << has to be overloaded so that it can handle the output of variables defined in OF. For example, the output of a vector, a list, a Field.... The same reason also applies to the stream operator >>.

As for mesh, of most of the solvers, mesh is a fvMesh variable, see the definition below:
Quote:
fvMesh mesh
(
IOobject
(
fvMesh::defaultRegion,
runTime.timeName(),
runTime,
IOobject::MUST_READ
)
);
Semantically, it's no difference than
Quote:
myfvMesh mesh(...)
if we have a myfvMesh class we defined ourselves in c++. fvMesh class defined in OF for handling discretization using finite volume method. For this general information, you can find in the class description of each class in the source file. If you really want to know everything in detail, I think you somehow need to dig into the source code. You can always get some scattered information for what you are looking for just by google. But I strongly suggest you to study the source code. It tells everything though not in a straightforward way. To be honest, I am also very new to OF. I just started March this year. But I found it's really interesting sometimes to dig out something out of the source code.
I don't know too much about the solver you mentioned in question 2 now. I think it's better to post another sperate post specifically for seeking explanations of this solver. I believe lots of Foamers know and use this solver.
LogiDF likes this.
Jerryfan is offline   Reply With Quote

Old   July 25, 2016, 12:25
Default
  #3
Senior Member
 
Mahdi Hosseinali
Join Date: Apr 2009
Location: NB, Canada
Posts: 273
Rep Power: 18
anishtain4 is on a distinguished road
if you want to understand what they mean and how they are related first of all read
OpenFOAM programmer's guide, or even user guide before that. You are going to need a good basic understanding of c++ or having a hard time figuring out things.
A good place to start is to take a look at $FOAM_APP/test and go through them step by step while consulting Doxygen documentations.
anishtain4 is offline   Reply With Quote

Old   July 25, 2016, 21:20
Default
  #4
Member
 
Jerry
Join Date: Oct 2013
Location: Salt Lake City, UT, USA
Posts: 52
Rep Power: 13
Jerryfan is on a distinguished road
Hi Alimea,


Agree with anishtain4. The examples in the test folder are very good sources for learning OF. If you want, you can even debug with examples. This way you will know the details step by step.
Jerryfan is offline   Reply With Quote

Old   July 26, 2016, 04:02
Default
  #5
Senior Member
 
A. Min
Join Date: Mar 2015
Posts: 308
Rep Power: 12
alimea is on a distinguished road
Thanks my friends
I have done some examples in O.F., but they didn't have any changing in code such as in solvers! so I don't have any experience about that. [/LEFT][/RIGHT]
alimea is offline   Reply With Quote

Old   July 26, 2016, 11:29
Default
  #6
Member
 
Jerry
Join Date: Oct 2013
Location: Salt Lake City, UT, USA
Posts: 52
Rep Power: 13
Jerryfan is on a distinguished road
Hi alimea,


I started with the solvers in the basic directory. Those are the most fundamental solvers in O.F. Usually, it's much easier to start off. Try to modify starting from this point.
Jerryfan is offline   Reply With Quote

Reply

Tags
command editor, openfoam, solver


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
Getting Started with OpenFOAM wyldckat OpenFOAM 26 June 21, 2024 07:54
OpenFOAM Training: Programming CFD Course 12-13 and 19-20 April 2016 cfd.direct OpenFOAM Announcements from Other Sources 0 January 14, 2016 11:19
OpenFOAM v3.0.1 Training, London, Houston, Berlin, Jan-Mar 2016 cfd.direct OpenFOAM Announcements from Other Sources 0 January 5, 2016 04:18
OpenFOAM Training, London, Chicago, Munich, Sep-Oct 2015 cfd.direct OpenFOAM Announcements from Other Sources 2 August 31, 2015 14:36
Modified OpenFOAM Forum Structure and New Mailing-List pete Site News & Announcements 0 June 29, 2009 06:56


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