<div dir="ltr">Hello PETSc Users,<br><br>I am trying to find the lowest 'n' eigenvalues of a hermitian eigenvalue problem. The size of the operator matrix (hamiltonian in my case) is dependent on the mesh spacing provided by the user (which is expected). However I have the following issue:<br><br><div>The number of eigenvalues given by the solver is not consistent with what is given as input in the EPSSetDimensions routine. For example, for a 12000x12000 matrix, the solver gives 20 correct eigenvalues if nev=20, but fails to give any eigenvalue if nev=10.<br><br>I am using the following lines of code to solve the problem:<br><br></div><div><i>call <b>EPSCreate</b>(PETSC_COMM_WORLD,eps,ierr)<br></i></div><div><i>call <b>EPSSetOperators</b>(eps,ham,PETSC_NULL_MAT,ierr)<br>call <b>EPSSetProblemType</b>(eps,EPS_HEP,ierr)<br>call <b>EPSSetWhichEigenpairs</b>(eps,EPS_SMALLEST_MAGNITUDE,ierr)<br>call <b>EPSSetDimensions</b>(eps,n_sub,n_sub*2,PETSC_DEFAULT_INTEGER,ierr)</i></div><div><i>call<b> EPSSetTolerances</b>(eps,1D-10,5000,ierr)<br>call<b> EPSSolve</b>(eps,ierr)<br></i></div><div><br>After the EPSSolve, I am calling EPSGetEigenPair and other relevant routines to get the eigenvector and eigenvalues.<br><br>Any lead as to how to solve this problem would be greatly helpful to us. Please let me know if I need to provide any further information.<br><br>Thank you for your time.<br><br>Sincerely,<br>Pranay.</div><div><br></div></div>