Difference between revisions of "Contrib multiSolver/programming"

From OpenFOAMWiki
(Created page with '== Programming with multiSolver == === solverDomains === A solverDomain is an individual solver loop. It is assigned a name, and the list …')
 
(Migrated to github)
 
(8 intermediate revisions by the same user not shown)
Line 1: Line 1:
== Programming with multiSolver ==
+
This project has migrated over to '''github'''.
  
=== solverDomains ===
+
'''''[http://github.com/Marupio/multiSolver/wiki Click here for the new website.]'''''
A [[TestMarupio/glossary#solverDomain|solverDomain]] is an individual solver loop. It is assigned a name, and the list of names is static.  All [[TestMarupio/glossary#solverDomain|solverDomains]] must appear in the <tt>case/system/multiControlDict</tt> file.
+
  
=== Order of execution ===
+
http://github.com/Marupio/multiSolver/wiki
In the [[TestMarupio#simpleExample|simple example]] on the main page, all the [[TestMarupio/glossary#solverDomain|solverDomains]] execute in sequence, once per [[TestMarupio/glossary#superLoop|superLoop]].  This is not necessary: you can enclose them in conditionals; they can execute in any order; they can miss entire [[TestMarupio/glossary#superLoop|superLoops]]; however, they cannot execute more than once per [[TestMarupio/glossary#superLoop|superLoop]]. Use: <tt>multiRun++</tt> between solvers to increment the [[TestMarupio/glossary#superLoop|superLoop]] number if necessary.
+
 
+
=== runTime must go out of scope ===
+
Looking at the include files specified in the [[TestMarupio#simpleExample|simple example]] on the main page, you will notice that the entire solver loop is enclosed in its own set of braces { }, starting at <tt>#include "createTime.H"</tt>.  This is necessary because '''runTime''', the mesh, and all fields must go out of scope before '''multiSolver''' initializes another [[TestMarupio/glossary#solverDomain|solverDomain]].
+
 
+
=== Support classes ===
+
There are a few additional classes that were written to support '''multiSolver'''.  These include:
+
 
+
* <tt>tuple2List</tt> class;
+
* <tt>timeCluster</tt> class;
+
* <tt>timeClusterList</tt> class; and
+
* <tt>dummyControlDict</tt> class.
+
 
+
'''tuple2List'''<BR>
+
This is a sortable list of paired values was created.  It is sortable by first or second value, and currently can be any combination of <tt>scalar</tt> or <tt>label</tt>.
+
 
+
'''timeCluster'''<BR>
+
<tt>timeCluster</tt> is to '''multiSolver''' what <tt>instant</tt> is to '''runTime'''.  Basically an object that can catalogue all the time data within a '''multiSolver'''-enabled application.
+
 
+
'''timeClusterList'''<BR>
+
Again, similar to <tt>instantList</tt>, for '''multiSolver'''.
+
 
+
'''dummyControlDict'''<BR>
+
In order to allow ''runTimeModification'' of '''multiSolver''''s [[TestMarupio/glossary#multiDict|multiDicts]], '''multiSolver''' required an [[snip objectRegistry|objectRegistry]] that doesn't dissappear between [[TestMarupio/glossary#solverDomain|solverDomains]], when '''runTime''' goes out of scope.  Therefore it needed its own [[objectRegistry]].  Hence, <tt>multiDictRegistry_</tt> is a <tt>Time</tt> object.  <tt>Time</tt> was never intended to be a member variable, therefore its constructors do not allow initialization without a <tt>controlDict</tt>.  The object <tt>dummyControlDict</tt> was introduced as a self-initializing, minimal <tt>controlDict</tt>.  Ultimately it was necessary for global ''runTimeModification''.
+
 
+
== Implementation of multiSolver ==
+

Latest revision as of 21:46, 6 September 2013

This project has migrated over to github.

Click here for the new website.

http://github.com/Marupio/multiSolver/wiki