Manually divide sub-domain for parallel computing
Hi all,
I am working with parallel computing in OpenFoam and I would like to divide my computational domain into two sub-domains at an exact position. How can I manually set up the parameters to define a position of an interface between two sub-domains instead of just using simple method that OpenFoam supported? I would not like to manually define every cell of my domain with manual method since it is impossible. Thank you. Duong |
Hello Duong,
It's some time ago since you posted this; did you manage to find a solution? I would be interested in your findings! Regards, Ralph |
You need to use a decomposeDict file in /constant.
It looks like this FoamFile { version 2.0; format ascii; class labelList; location "constant"; object decompDict; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // ( 0 0 ... // These are the mesh cells in order as defined in blocks in blockMeshDict, so for a 2D block with 10x10 cells this would have 100 entries 1 ); Then modify your decomposeDict to refernce your decomposeDict File Like this: numberOfSubdomains 8; method manual; simpleCoeffs { n ( 4 1 1); delta 0.00000001; } hierarchicalCoeffs { n ( 2 2 1 ); delta 0.001; order xyz; } scotchCoeffs { processorWeights ( 1 1 1 1 1 1 ); } manualCoeffs { dataFile "decompDict"; // Here is where your point to decompDict } distributed no; roots ( ); |
Dear Chris,
Thanks for clearing this up. Is there a way to automatically generate the file which is located in constant? I found a way to generate this file based on one of the other decomposition methods (decomposePar -cellDist) but I'm looking for a way to define the cells in another way. Cheers, Ralph |
I made the file manually. For 70 000 cells took about 5 minutes in a spread sheet.
But the split wasn't that complicated. You can check the decompose in paraview after by /processor0/paraFoam. |
For 4 million cells and often a lot of calculations it would be another story though ;)
Regards, Ralph |
Quote:
are 0 and 1 processor numbers? the row-wise order of 0's btw the brackets specifies the cell ID ? Thanks |
Yes, the numbers define the processor which is used... they are ranked on cell number in one row.
Try Quote:
Cheers! |
I guess it cannot be impossible to write a simple OF-tool that reads in cellSets or cellZones and based on those creates the decomposeDict. Then, you could control domain decomposition using the setSet utility!
|
I figured this already out ;) But anyway (on behalf of future readers); thanks for the hint!
|
Quote:
|
Ggi runs well in serial, but having problems with parallel run.
Hi Mr. Ralph,
I am trying to run dynamic-simulation of wind turbine using foam-extend ggi option. I have a mesh size of about 12 millions, and I have successfully run the case in serial for about 0.005 seconds(it took about half a day). But tried to run the case in cluster with 24 processors and I got several errors. I found out from this forum that the case has to be solved by manual decomposition method and the above hints are really useful. Quote:
Thank you. |
All times are GMT -4. The time now is 09:09. |