So, I wanted to be able to give some input into Metis in the way of element weights. By default libMesh just weights each element with it's number of nodes. What I added gives you the ability to attach an ErrorVector * that is then used to weight the partitioning. This is working well for my purposes.
Why an ErrorVector? Because I thought that having some of the statistics capabilities of ErrorVector might be useful to someone doing partition weighting (things like cut_above, variance, mean, etc.). I am already using some of those capabilities in my own code.
I'm attaching a diff that makes these changes just to MetisPartitioner. I wanted to see if you guys are ok with this change.... or if I should actually make some changes to the base Partitioner class to allow this. I honestly don't know what the right thing to do is. I would hate to have someone attach weights only to have them ignored by something like the LinearPartitioner or SFCPartitioner.
What do you think?
Derek
|