Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
| Rev 1709 | Rev 1722 |
|---|---|
| Line 84... | Line 84... |
call PetscOptionsGetInt(PETSC_NULL_CHARACTER,'-n',n,flg,ierr) |
call PetscOptionsGetInt(PETSC_NULL_CHARACTER,'-n',n,flg,ierr) |
if (rank .eq. 0) then |
if (rank .eq. 0) then |
write(*,100) n |
write(*,100) n |
endif |
endif |
100 format (/'1-D Laplacian Eigenproblem, n =',I3,' (Fortran)') |
100 format (/'1-D Laplacian Eigenproblem, n =',I4,' (Fortran)') |
! - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
! - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
! Compute the operator matrix that defines the eigensystem, Ax=kx |
! Compute the operator matrix that defines the eigensystem, Ax=kx |
! - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
! - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
| Line 163... | Line 163... |
call EPSGetDimensions(solver,nev,PETSC_NULL_INTEGER, & |
call EPSGetDimensions(solver,nev,PETSC_NULL_INTEGER, & |
PETSC_NULL_INTEGER,ierr) |
PETSC_NULL_INTEGER,ierr) |
if (rank .eq. 0) then |
if (rank .eq. 0) then |
write(*,130) nev |
write(*,130) nev |
endif |
endif |
130 format (' Number of requested eigenvalues:',I2) |
130 format (' Number of requested eigenvalues:',I4) |
call EPSGetTolerances(solver,tol,maxit,ierr) |
call EPSGetTolerances(solver,tol,maxit,ierr) |
if (rank .eq. 0) then |
if (rank .eq. 0) then |
write(*,140) tol, maxit |
write(*,140) tol, maxit |
endif |
endif |
140 format (' Stopping condition: tol=',1P,E10.4,', maxit=',I4) |
140 format (' Stopping condition: tol=',1P,E10.4,', maxit=',I4) |
| Line 179... | Line 179... |
! ** Get number of converged eigenpairs |
! ** Get number of converged eigenpairs |
call EPSGetConverged(solver,nconv,ierr) |
call EPSGetConverged(solver,nconv,ierr) |
if (rank .eq. 0) then |
if (rank .eq. 0) then |
write(*,150) nconv |
write(*,150) nconv |
endif |
endif |
150 format (' Number of converged eigenpairs:',I2/) |
150 format (' Number of converged eigenpairs:',I4/) |
! ** Display eigenvalues and relative errors |
! ** Display eigenvalues and relative errors |
if (nconv.gt.0) then |
if (nconv.gt.0) then |
if (rank .eq. 0) then |
if (rank .eq. 0) then |
write(*,*) ' k ||Ax-kx||/||kx||' |
write(*,*) ' k ||Ax-kx||/||kx||' |