# KSPChebyshevSetEigenvalues
Sets estimates for the extreme eigenvalues of the preconditioned problem. 
## Synopsis
```
#include "petscksp.h" 
PetscErrorCode KSPChebyshevSetEigenvalues(KSP ksp, PetscReal emax, PetscReal emin)
```
Logically Collective on ksp


## Input Parameters

- ***ksp -*** the Krylov space context
- ***emax, emin -*** the eigenvalue estimates



## Options Database Key

- ***-ksp_chebyshev_eigenvalues emin,emax -*** extreme eigenvalues



## Notes
Call `KSPChebyshevEstEigSet()` or use the option -ksp_chebyshev_esteig a,b,c,d to have the KSP
estimate the eigenvalues and use these estimated values automatically.

When `KSPCHEBYSHEV` is used as a smoother, one often wants to target a portion of the spectrum rather than the entire
spectrum. This function takes the range of target eigenvalues for Chebyshev, which will often slightly over-estimate
the largest eigenvalue of the actual operator (for safety) and greatly overestimate the smallest eigenvalue to
improve the smoothing properties of Chebyshev iteration on the higher frequencies in the spectrum.




## See Also
 [](chapter_ksp), `KSPCHEBYSHEV`, `KSPChebyshevEstEigSet()`,

## Level
intermediate

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ksp/ksp/impls/cheby/cheby.c.html#KSPChebyshevSetEigenvalues">src/ksp/ksp/impls/cheby/cheby.c</A>

## Implementations

<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ksp/ksp/impls/cheby/cheby.c.html#KSPChebyshevSetEigenvalues_Chebyshev">KSPChebyshevSetEigenvalues_Chebyshev in src/ksp/ksp/impls/cheby/cheby.c</A><BR>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/ksp/ksp/impls/cheby/cheby.c)


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