Skip to main content
`Ctrl`+`K`

# PCGAMGSetAggressiveSquareGraph

Use graph square, \(A^T A\), for aggressive coarsening. Coarsening is slower than the alternative (MIS-2), which is faster and uses less memory

## Synopsis

    #include "petscpc.h"
    PetscErrorCode PCGAMGSetAggressiveSquareGraph(PC pc, PetscBool b)

Logically Collective

## Input Parameters

- pc - the preconditioner context

- b - default true

## Options Database Key

- -pc_gamg_aggressive_square_graph <bool,default=true> - the flag

## Notes

If `b` is `PETSC_FALSE` then MIS-k is used for aggressive coarsening, see `PCGAMGMISkSetAggressive()`

Squaring the matrix to perform the aggressive coarsening is slower and requires more memory than using MIS-k, but may result in a better preconditioner that converges faster.

## See Also

the Users Manual section on PCGAMG, the Users Manual section on PCMG, KSP: Linear System Solvers, `PCGAMG`, `PCGAMGSetThreshold()`, `PCGAMGSetAggressiveLevels()`, `PCGAMGMISkSetAggressive()`, `PCGAMGMISkSetMinDegreeOrdering()`, `PCGAMGSetLowMemoryFilter()`

## Level

intermediate

## Location

src/ksp/pc/impls/gamg/agg.c

## Examples

src/ksp/ksp/tutorials/ex56.c

## Implementations

PCGAMGSetAggressiveSquareGraph_AGG() in src/ksp/pc/impls/gamg/agg.c

Index of all PC routines
Table of Contents for all manual pages
Index of all manual pages