Martin Sandve Alnæs wrote:
> On 12/4/06, Garth N. Wells <g.n.wells@xxxxxxxxxx> wrote:
>> Anders Logg wrote:
>>> On Mon, Dec 04, 2006 at 02:14:51PM +0100, Garth N. Wells wrote:
>>>> Could we add something to FFC to describe where the various
degrees of
>>>> freedom live (on vertices, edges, internal)?
>>>>
>>>> Garth
>>> Yes we could, but I'd rather not. Why do we need it? I'd prefer if
>>> DOLFIN did not know anything about dofs, other than how to reorder
>>> them.
>>>
>> Not sure that it's this simple if you want to assemble some terms
>> block-wise. Also, for parallel assembly we might need to know where
dofs
>> lie. I'm still thinking about this so I can't be concrete in what's
>> needed just yet.
>
> I've just done some work on parallell assembly for PyCC, using the UFC
> interface. This is basically how I make the node partition:
>
> // fill index_set with all global dofs used by elements in the local
> grid partition
> std::set<int> index_set;
>
> // iterate over all mesh cells in local mesh partition
> pycc::UfcCellIterator *iter = mesh_iter_fac.create_cell_iterator();
> for(; !iter->end(); iter->next())
> {
> const ufc::cell & ufc_cell = iter->get_cell();
>
> // get loc2glob from nm
> ufc_node_map.tabulate_nodes(rows, ufc_mesh, ufc_cell);
>
> // insert loc2glob entries into index_set
> for(int i=0; i<row_size; i++)
> {
> index_set.insert(rows[i]);
> }
> }
> delete iter;
>
>
I see that this generates a set of degrees of freedom for a given
process for a given cell partitioning, but where do you renumber? Do you
renumber somewhere so that nodes 0 to m-1 are on processs 1, m to 2m-1
on process 2, etc?
Garth