[petsc-users] Floating point exception

Matthew Knepley knepley at gmail.com
Sat Nov 30 15:45:55 CST 2019


On Sat, Nov 30, 2019 at 3:19 PM baikadi pranay <pranayreddy865 at gmail.com>
wrote:

> Hello PETSc users,
>
> I am currently trying to build a 1-D Schrodinger solver. I have built my
> hamiltonian matrix (of size 121 x 121) and i'm trying to find the
> eigenvalues. I have the following lines of code for the solver:
>
> *call EPSCreate(PETSC_COMM_WORLD,eps,ierr)*
>
> *call EPSSetOperators(eps,ham,S,ierr)call
> EPSSetProblemType(eps,EPS_GHEP,ierr)*
>
>
>
> *call EPSSetFromOptions(eps,ierr)call
> EPSSetDimensions(eps,10,PETSC_DEFAULT_INTEGER,PETSC_DEFAULT_INTEGER,ierr)call
> EPSSolve(eps,ierr)call EPSDestroy(eps,ierr)*
>
> At the EPSSolve line, i get the following error:
>
>
>
>
>
> *[0]PETSC ERROR: --------------------- Error Message
> --------------------------------------------------------------[0]PETSC
> ERROR: Floating point exception[0]PETSC ERROR: Vec entry at local location
> 0 is not-a-number or infinite at end of function: Parameter number
> 3[0]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html
> <http://www.mcs.anl.gov/petsc/documentation/faq.html> for trouble
> shooting.[0]PETSC ERROR: Petsc Release Version 3.11.1, Apr, 12, 2019*
>

You need to show the entire stack trace that is output here.

  Thanks,

     Matt


> I am using the options *-st_pc_factor_shift_type NONZERO
> -st_pc_factor_shift_amount 1*     ( else I end up getting the "zero pivot
> in LU factorization" error ).
>
> I outputted my matrix to matlab and confirmed that the null space is empty
> and the matrix is not singular. I am not sure why I'm getting this error.
> Could you provide me a hint as to how to solve this problem.
>
> Sincerely,
> Pranay.
>


-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20191130/d57a4cd7/attachment.html>


More information about the petsc-users mailing list