:orphan: # PCGAMGSetNlevels Sets the maximum number of levels `PCGAMG` will use ## Synopsis ``` #include "petscpc.h" #include "petscksp.h" PetscErrorCode PCGAMGSetNlevels(PC pc, PetscInt n) ``` Not Collective ## Input Parameters - ***pc -*** the preconditioner - ***n -*** the maximum number of levels to use ## Options Database Key - ***-pc_mg_levels -*** set the maximum number of levels to allow ## Developer Note Should be called `PCGAMGSetMaximumNumberlevels()` and possible be shared with `PCMG` ## See Also `PCGAMG` ## Level intermediate ## Location src/ksp/pc/impls/gamg/gamg.c ## Implementations PCGAMGSetNlevels_GAMG in src/ksp/pc/impls/gamg/gamg.c
--- [Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/ksp/pc/impls/gamg/gamg.c) [Index of all PC routines](index.md) [Table of Contents for all manual pages](/manualpages/index.md) [Index of all manual pages](/manualpages/singleindex.md)