[petsc-users] General query, default preconditioner

Ghosh, Swarnava sghosh2012 at gatech.edu
Tue Sep 16 13:10:56 CDT 2014


Hello,

  I just had a general query if PETSC has something like a "default preconditioner" when preconditioner type is not set and equations are solved using KSPSolve and GMRES method.
  Specifically, I am using the following lines of code:

  KSPCreate(PETSC_COMM_WORLD,&pOfdft->ksp);  
  KSPSetType(pOfdft->ksp, KSPGMRES);
  KSPSetOperators(pOfdft->ksp,A,A,SAME_NONZERO_PATTERN);
  KSPSetTolerances(pOfdft->ksp,KSPTOL,PETSC_DEFAULT,PETSC_DEFAULT,PETSC_DEFAULT);
  KSPSetFromOptions(pOfdft->ksp);
  KSPSetUp(pOfdft->ksp); 

Regards,
Swarnava

-- 


More information about the petsc-users mailing list