-
Notifications
You must be signed in to change notification settings - Fork 264
Open
Labels
Description
We have at least 40 places where we have the following code:
// First loop over all dofs and find those that are in the Stokes system
// save the component (pressure and dim velocities) each belongs to.
for (unsigned int i = 0, i_stokes = 0; i_stokes < stokes_dofs_per_cell; /*increment at end of loop*/)
{
if (introspection.is_stokes_component(fe.system_to_component_index(i).first))
{
scratch.dof_component_indices[i_stokes] = fe.system_to_component_index(i).first;
++i_stokes;
}
++i;
}
This could probably be better handled by a helper function. In fact, this is something that might even be calculated once and for all (in Introspection?) so that we don't have to do it in all of these places.
Reactions are currently unavailable