Lines Matching refs:agg
113 PetscErrorCode MatCoarsenSetAdjacency(MatCoarsen agg, Mat adj) in MatCoarsenSetAdjacency() argument
116 PetscValidHeaderSpecific(agg, MAT_COARSEN_CLASSID, 1); in MatCoarsenSetAdjacency()
118 agg->graph = adj; in MatCoarsenSetAdjacency()
135 PetscErrorCode MatCoarsenSetStrictAggs(MatCoarsen agg, PetscBool str) in MatCoarsenSetStrictAggs() argument
138 PetscValidHeaderSpecific(agg, MAT_COARSEN_CLASSID, 1); in MatCoarsenSetStrictAggs()
139 agg->strict_aggs = str; in MatCoarsenSetStrictAggs()
155 PetscErrorCode MatCoarsenDestroy(MatCoarsen *agg) in MatCoarsenDestroy() argument
158 if (!*agg) PetscFunctionReturn(PETSC_SUCCESS); in MatCoarsenDestroy()
159 PetscValidHeaderSpecific(*agg, MAT_COARSEN_CLASSID, 1); in MatCoarsenDestroy()
160 if (--((PetscObject)*agg)->refct > 0) { in MatCoarsenDestroy()
161 *agg = NULL; in MatCoarsenDestroy()
165 PetscTryTypeMethod(*agg, destroy); in MatCoarsenDestroy()
166 if ((*agg)->agg_lists) PetscCall(PetscCDDestroy((*agg)->agg_lists)); in MatCoarsenDestroy()
167 …PetscCall(PetscObjectComposeFunction((PetscObject)*agg, "MatCoarsenSetMaximumIterations_C", NULL)); in MatCoarsenDestroy()
168 PetscCall(PetscObjectComposeFunction((PetscObject)*agg, "MatCoarsenSetThreshold_C", NULL)); in MatCoarsenDestroy()
169 PetscCall(PetscObjectComposeFunction((PetscObject)*agg, "MatCoarsenSetStrengthIndex_C", NULL)); in MatCoarsenDestroy()
171 PetscCall(PetscHeaderDestroy(agg)); in MatCoarsenDestroy()
227 PetscErrorCode MatCoarsenView(MatCoarsen agg, PetscViewer viewer) in MatCoarsenView() argument
232 PetscValidHeaderSpecific(agg, MAT_COARSEN_CLASSID, 1); in MatCoarsenView()
233 if (!viewer) PetscCall(PetscViewerASCIIGetStdout(PetscObjectComm((PetscObject)agg), &viewer)); in MatCoarsenView()
235 PetscCheckSameComm(agg, 1, viewer, 2); in MatCoarsenView()
238 PetscCall(PetscObjectPrintClassNamePrefixType((PetscObject)agg, viewer)); in MatCoarsenView()
239 if (agg->ops->view) { in MatCoarsenView()
241 PetscUseTypeMethod(agg, view, viewer); in MatCoarsenView()
244 …agg->strength_index_size > 0) PetscCall(PetscViewerASCIIPrintf(viewer, " Using scalar strength-of-… in MatCoarsenView()
521 MatCoarsen agg; in MatCoarsenCreate() local
527 …PetscCall(PetscHeaderCreate(agg, MAT_COARSEN_CLASSID, "MatCoarsen", "Matrix/graph coarsen", "MatCo… in MatCoarsenCreate()
528 …PetscCall(PetscObjectComposeFunction((PetscObject)agg, "MatCoarsenSetMaximumIterations_C", MatCoar… in MatCoarsenCreate()
529 …PetscCall(PetscObjectComposeFunction((PetscObject)agg, "MatCoarsenSetThreshold_C", MatCoarsenSetTh… in MatCoarsenCreate()
530 …PetscCall(PetscObjectComposeFunction((PetscObject)agg, "MatCoarsenSetStrengthIndex_C", MatCoarsenS… in MatCoarsenCreate()
531 agg->strength_index_size = 0; in MatCoarsenCreate()
532 *newcrs = agg; in MatCoarsenCreate()