constructor argList and parallel run
hi,
I have questions about the subject mentioned in the title: 1. The first part of the argList constructor is: Code:
Foam::argList::argList Now runPar is defined as Code:
void runPar(int& argc, char**& argv) Code:
bool Foam::UPstream::init(int& argc, char**& argv) //Spawns slave processes and 1. Method init(...) should spawn slave processes. Where is this happening in init()? Furthermore when looking up the .C files of class UpStream on my PC I get three different files with three different init() methods. Is the method out of the online OpenFoam library the right one? How am I suppossed to know which one will be used in the code I am analysing? 2. When talking about parallel run what is meant with master process? I have read already http://www.openfoam.org/docs/user/ru...s-parallel.php and http://www.cfd-online.com/Forums/ope...g-2-2-0-a.html If I devide the mesh into different sections and assign each section to another processor which section or processor will be the master and more important what is the meaning of being master :D ? |
If you want to figure which process is 'master', this should help
Code:
if (Pstream::master()) To my understanding this comes largely into play when talking about input/output. For example, it would be quite interesting to know which process is writing to a 'summary file', as e.g. the one in the sprayEngineFoam solver: https://github.com/OpenFOAM/OpenFOAM...startSummary.H 'OFstream logSummaryFile' is (and has to be) initialized in all processes, but in the end there will only be one file on the HDD. I haven't had time to dig through the source code, but it would be interesting to know, how OpenFOAM handles such kind of I/O operations in parallel runs. |
All times are GMT -4. The time now is 03:47. |