@@ -43,17 +43,13 @@ of random, `s` is an approximation to the eigenvalues of a system.
4343
4444``` julia
4545s = rand (n)
46-
47- # Pr applies 1 ./ s .* vec
48- Pr = LinearSolve. DiagonalPreconditioner (s)
49- # Pl applies s .* vec
5046Pl = LinearSolve. DiagonalPreconditioner (s)
5147
5248A = rand (n,n)
5349b = rand (n)
5450
5551prob = LinearProblem (A,b)
56- sol = solve (prob,IterativeSolvers_GMRES (),Pl= Pl,Pr = Pr )
52+ sol = solve (prob,IterativeSolvers_GMRES (),Pl= Pl)
5753```
5854
5955## Pre-Defined Preconditioners
@@ -63,6 +59,11 @@ preconditioners written to match the required interface.
6359
6460- ` DiagonalPreconditioner(s::Union{Number,AbstractVector}) ` : the diagonal
6561 preconditioner, defined as a diagonal matrix ` Diagonal(s) ` .
62+ - ` InvDiagonalPreconditioner(s::Union{Number,AbstractVector}) ` : the diagonal
63+ preconditioner, defined as a diagonal matrix ` Diagonal(1./s) ` .
64+ - ` ComposePreconditioner(prec1,prec2) ` : composes the preconditioners to apply
65+ ` prec1 ` before ` prec2 ` .
66+ - ` InvComposePreconditioner(prec1,prec2) ` : only god knows what this is for.
6667
6768## Preconditioner Interface
6869
@@ -73,14 +74,6 @@ following interface:
7374
7475- ` Base.eltype(::Preconditioner) `
7576- ` Base.adjoint(::Preconditioner) `
76- - ` Base.inv(::Preconditioner) ` (Optional?)
77-
78- ### Required for Right Preconditioners
79-
80- - ` Base.\(::Preconditioner,::AbstractVector) `
8177- ` LinearAlgebra.ldiv!(::AbstractVector,::Preconditioner,::AbstractVector) `
82-
83- ### Required for Left Preconditioners
84-
85- - ` Base.*(::Preconditioner,::AbstractVector) `
86- - ` LinearAlgebra.mul!(::AbstractVector,::Preconditioner,::AbstractVector) `
78+ - ` Base.inv(::Preconditioner) ` (Dear Jesus Krylov.jl, why?)
79+ - ` LinearAlgebra.mul!(::AbstractVector,::Preconditioner,::AbstractVector) ` (Required for Krylov.jl)
0 commit comments