# PCLU

Uses a direct solver, based on LU factorization, as a preconditioner

### Options Database Keys

| -pc_lu_reuse_ordering | - Activate PCLUSetReuseOrdering()
| -pc_lu_reuse_fill | - Activates PCLUSetReuseFill()
| -pc_lu_fill <fill> | - Sets fill amount
| -pc_lu_in_place | - Activates in-place factorization
| -pc_lu_mat_ordering_type <nd,rcm,...> | - Sets ordering routine
| -pc_lu_pivot_in_blocks <true,false> | - allow pivoting within the small blocks during factorization (may increase stability of factorization.
| -pc_factor_shift_nonzero <shift> | - Sets shift amount or PETSC_DECIDE for the default
| -pc_factor_shift_positive_definite [PETSC_TRUE/PETSC_FALSE] | - Activate/Deactivate PCFactorSetShiftPd(); the value is optional with PETSC_TRUE being the default

Notes: Not all options work for all matrix formats Run with -help to see additional options for particular matrix formats or factorization algorithms

Notes: Usually this will compute an "exact" solution in one iteration and does not need a Krylov method (i.e. you can use -ksp_type preonly, or KSPSetType(ksp,KSPPREONLY) for the Krylov method

### See Also

PCCreate(), PCSetType(), PCType (for list of available types), PC,
PCILU, PCCHOLESKY, PCICC, PCLUSetReuseOrdering(), PCLUSetReuseFill(), PCGetFactoredMatrix(), PCLUSetFill(), PCLUSetUseInPlace(), PCLUSetMatOrdering(), PCFactorSetPivoting(), PCLUSetPivotingInBlocks(),PCFactorSetShiftNonzero(),PCFactorSetShiftPd()

Level:beginner
Location:src/ksp/pc/impls/factor/lu/lu.c
Index of all PC routines
Table of Contents for all manual pages
Index of all manual pages

### Examples

src/ksp/examples/tutorials/ex13.c.html
src/ksp/examples/tutorials/ex13f90.F.html