135bd34faSBarry Smith /* 2e1222f9fSBarry Smith Private data structure for ILU/ICC/LU/Cholesky preconditioners. 335bd34faSBarry Smith */ 435bd34faSBarry Smith #if !defined(__FACTOR_H) 535bd34faSBarry Smith #define __FACTOR_H 635bd34faSBarry Smith 72065344dSHong Zhang #include <petsc/private/pcimpl.h> 835bd34faSBarry Smith 935bd34faSBarry Smith typedef struct { 1035bd34faSBarry Smith Mat fact; /* factored matrix */ 1135bd34faSBarry Smith MatFactorInfo info; 1235bd34faSBarry Smith MatOrderingType ordering; /* matrix reordering */ 13ea799195SBarry Smith char *solvertype; 14879e8a4dSBarry Smith MatFactorType factortype; 153d1c1ea0SBarry Smith PetscReal actualfill; 163d1c1ea0SBarry Smith PetscBool inplace; /* flag indicating in-place factorization */ 173d1c1ea0SBarry Smith PetscBool reuseordering; /* reuses previous reordering computed */ 183d1c1ea0SBarry Smith PetscBool reusefill; /* reuse fill from previous LU */ 1935bd34faSBarry Smith } PC_Factor; 2035bd34faSBarry Smith 214ac6704cSBarry Smith PETSC_INTERN PetscErrorCode PCFactorInitialize(PC,MatFactorType); 225a576424SJed Brown PETSC_INTERN PetscErrorCode PCFactorGetMatrix_Factor(PC,Mat*); 236dd4cc0eSJed Brown 245a576424SJed Brown PETSC_INTERN PetscErrorCode PCFactorSetZeroPivot_Factor(PC,PetscReal); 25c7f610a1SBarry Smith PETSC_INTERN PetscErrorCode PCFactorGetZeroPivot_Factor(PC,PetscReal*); 265a576424SJed Brown PETSC_INTERN PetscErrorCode PCFactorSetShiftType_Factor(PC,MatFactorShiftType); 27c7f610a1SBarry Smith PETSC_INTERN PetscErrorCode PCFactorGetShiftType_Factor(PC,MatFactorShiftType*); 285a576424SJed Brown PETSC_INTERN PetscErrorCode PCFactorSetShiftAmount_Factor(PC,PetscReal); 29c7f610a1SBarry Smith PETSC_INTERN PetscErrorCode PCFactorGetShiftAmount_Factor(PC,PetscReal*); 305a576424SJed Brown PETSC_INTERN PetscErrorCode PCFactorSetDropTolerance_Factor(PC,PetscReal,PetscReal,PetscInt); 315a576424SJed Brown PETSC_INTERN PetscErrorCode PCFactorSetFill_Factor(PC,PetscReal); 325a576424SJed Brown PETSC_INTERN PetscErrorCode PCFactorSetMatOrderingType_Factor(PC,MatOrderingType); 332591b318SToby Isaac PETSC_INTERN PetscErrorCode PCFactorGetLevels_Factor(PC,PetscInt*); 345a576424SJed Brown PETSC_INTERN PetscErrorCode PCFactorSetLevels_Factor(PC,PetscInt); 3592e9c092SBarry Smith PETSC_INTERN PetscErrorCode PCFactorSetAllowDiagonalFill_Factor(PC,PetscBool); 3692e9c092SBarry Smith PETSC_INTERN PetscErrorCode PCFactorGetAllowDiagonalFill_Factor(PC,PetscBool*); 375a576424SJed Brown PETSC_INTERN PetscErrorCode PCFactorSetPivotInBlocks_Factor(PC,PetscBool); 38ea799195SBarry Smith PETSC_INTERN PetscErrorCode PCFactorSetMatSolverType_Factor(PC,MatSolverType); 393ca39a21SBarry Smith PETSC_INTERN PetscErrorCode PCFactorSetUpMatSolverType_Factor(PC); 40ea799195SBarry Smith PETSC_INTERN PetscErrorCode PCFactorGetMatSolverType_Factor(PC,MatSolverType*); 415a576424SJed Brown PETSC_INTERN PetscErrorCode PCFactorSetColumnPivot_Factor(PC,PetscReal); 424416b707SBarry Smith PETSC_INTERN PetscErrorCode PCSetFromOptions_Factor(PetscOptionItems *PetscOptionsObject,PC); 435a576424SJed Brown PETSC_INTERN PetscErrorCode PCView_Factor(PC,PetscViewer); 444ac6704cSBarry Smith PETSC_INTERN PetscErrorCode PCFactorSetDefaultOrdering_Factor(PC); 45*2e956fe4SStefano Zampini PETSC_INTERN PetscErrorCode PCFactorClearComposedFunctions(PC); 464ac6704cSBarry Smith 4735bd34faSBarry Smith #endif 48