# PCFieldSplitGetSubKSP

Gets the KSP contexts for all splits

### Synopsis

    #include "petscpc.h"
    PetscErrorCode PETSCKSP_DLLEXPORT PCFieldSplitGetSubKSP(PC pc,PetscInt *n,KSP *subksp[])

Collective on KSP

### Input Parameter

pc -the preconditioner context

### Output Parameters

| n | - the number of split
| pc | - the array of KSP contexts

### Note

After PCFieldSplitGetSubKSP() the array of KSPs IS to be freed

You must call KSPSetUp() before calling PCFieldSplitGetSubKSP().

### See Also

PCFIELDSPLIT

Level:advanced
Location:src/ksp/pc/impls/fieldsplit/fieldsplit.c
Index of all PC routines
Table of Contents for all manual pages
Index of all manual pages