Draft: New decomposition method (multiNodeDecomp)

Open Alon Zameret requested to merge multiNodeDecomp into develop

Summary

A new decomposition method 'multiNodeDecomp' which extends the capabilities of the multi-level decomposition method found within OpenFOAM while maintaining full backwards compatibility. The multiNodeDecomp allow users control over the properties of each node within the decomposition tree, as opposed to multi-level decomposition which supports level-based modifications.

Details of new decomposition method

The multiNodeDecomp method adds the following capabilities:

  1. Support decomposition to un-even nodes by changing the number of children of each node. For example:
multiNodeCoeffs {
	method metis;
	domains (3 4);
	domains[0] (8);
}

In the example above, the mesh will be decomposed into 3 domains, where the first domain (domain[0]) will be further decomposed into 8 subdomains, while the remaining 2 domains will be decomposed into 4 subdomains only. This will result in a total of 20 subdomains. Note that the user passes a list value, which allows to have a different number of levels under different branches of the decomposition tree.

  1. Simplified interface for decomposition weights - uniform/relative weight distribution may be used to initialize the weight of each node. The user may later overwrite any of the nodes weight.
weightsInitialization relative;
weight[0][3] 2;

'Uniform' initialization will recursively set all of the nodes weights to 1, while the 'Relative' initialization sets each nodes weight to the number of leaves in its decomposition subtree. The weight of a node is then used during its parent's decomposition to control the sub-mesh size it will receive.

  1. Modify the nodes decomposition method:
method[2] {
    method scotch;
    coeffs {
        ...
    }
}

This will overwrite the method of the third subdomain of the root to use scotch and the given coefficients.

Syntax

multiNodeDecomp supports setting the decomposition properties above on a level scope (parameter[] value) or on a node scope (parameter[#nodeIndex] value). The square brackets indicate indices of the children we want to modify (0 based indexing). The user may specify ranges by using a hyphen ([0-3]) or specifying all of the children by using empty brackets ([]).

Merge request reports