:orphan:
# MatFDColoringGetPerturbedColumns
Returns the indices of the columns that that are currently being perturbed. 
## Synopsis
```
#include "petscmat.h" 
PetscErrorCode MatFDColoringGetPerturbedColumns(MatFDColoring coloring, PetscInt *n, const PetscInt *cols[])
```
Not Collective


## Input Parameter

- ***coloring -*** coloring context created with `MatFDColoringCreate()`



## Output Parameters

- ***n -*** the number of local columns being perturbed
- ***cols -*** the column indices, in global numbering





## Note
IF the matrix type is `MATBAIJ`, then the block column indices are returned


## Fortran Note
This routine has a different interface for Fortran
```none
     #include <petsc/finclude/petscmat.h>
          use petscmat
          PetscInt, pointer :: array(:)
          PetscErrorCode  ierr
          MatFDColoring   i
          call MatFDColoringGetPerturbedColumnsF90(i,array,ierr)
      use the entries of array ...
          call MatFDColoringRestorePerturbedColumnsF90(i,array,ierr)
```



## See Also
 `Mat`, `MatFDColoring`, `MatFDColoringCreate()`, `MatFDColoringDestroy()`, `MatFDColoringView()`, `MatFDColoringApply()`

## Level
advanced

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/matfd/fdmatrix.c.html#MatFDColoringGetPerturbedColumns">src/mat/matfd/fdmatrix.c</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/mat/matfd/fdmatrix.c)


[Index of all MatFD routines](index.md)  
[Table of Contents for all manual pages](/manualpages/index.md)  
[Index of all manual pages](/manualpages/singleindex.md)  
