diff --git a/docs/src/manual/linear_systems.md b/docs/src/manual/linear_systems.md index 189e87aa..d40b63c2 100644 --- a/docs/src/manual/linear_systems.md +++ b/docs/src/manual/linear_systems.md @@ -97,9 +97,9 @@ Here is a list of currently supported linear solvers: | Linear solver type | `Tv` | System | `LSBackend` | Method | |:-------------------|:----:|:------:|:-------:|:-------| | [`DenseLinearSolver`](@ref) | `Real` | `NormalEquations` | `Lapack` | Cholesky -| [`SparseIndefLinearSolver`](@ref) | `Float64` | `AugmentedSystem` | `Cholmod` | LDL +| [`SparseIndefLinearSolver`](@ref) | `Float64` | `AugmentedSystem` | `Cholmod` | LDLᵀ | [`SparsePosDefLinearSolver`](@ref) | `Float64` | `NormalEquations` | `Cholmod` | Cholesky -| [`LDLFLinearSolver`](@ref) | `Real` | `AugmentedSystem` | `LDLFact` | LDL +| [`LDLFLinearSolver`](@ref) | `Real` | `AugmentedSystem` | `LDLFact` | LDLᵀ ### Default options If no option is specified, then the linear solver is chosen as follows: diff --git a/src/LinearAlgebra/LinearSolvers/LinearSolvers.jl b/src/LinearAlgebra/LinearSolvers/LinearSolvers.jl index fca89e03..d3aaffc4 100644 --- a/src/LinearAlgebra/LinearSolvers/LinearSolvers.jl +++ b/src/LinearAlgebra/LinearSolvers/LinearSolvers.jl @@ -3,8 +3,8 @@ Abstract container for solving an augmented system ``` - [-(Θ^{-1} + Rp) A'] [dx] = [ξd] - [ A Rd] [dy] = [ξp] + [-(Θ⁻¹ + Rp) Aᵀ] [dx] = [ξd] + [ A Rd] [dy] [ξp] ``` where `ξd` and `ξp` are given right-hand side. """ @@ -68,8 +68,8 @@ Update internal data, and re-compute factorization/pre-conditioner. After this call, `ls` can be used to solve the augmented system ``` - [-(Θ^{-1} + Rp) A'] [dx] = [ξd] - [ A Rd] [dy] = [ξp] + [-(Θ⁻¹ + Rp) Aᵀ] [dx] = [ξd] + [ A Rd] [dy] [ξp] ``` for given right-hand sides `ξd` and `ξp`. """ @@ -81,8 +81,8 @@ function update_linear_solver! end Solve the symmetric quasi-definite augmented system ``` - [-(Θ^{-1} + Rp) A'] [dx] = [ξd] - [ A Rd] [dy] = [ξp] + [-(Θ⁻¹ + Rp) Aᵀ] [dx] = [ξd] + [ A Rd] [dy] [ξp] ``` and over-write `dx`, `dy` with the result. @@ -118,4 +118,4 @@ AbstractLinearSolver( ::DefaultBackend, ::DefaultSystem, A::AbstractMatrix{Tv} -) where{Tv<:Real} = AbstractLinearSolver(LDLFact(), AugmentedSystem(), A) \ No newline at end of file +) where{Tv<:Real} = AbstractLinearSolver(LDLFact(), AugmentedSystem(), A) diff --git a/src/LinearAlgebra/LinearSolvers/cholmod.jl b/src/LinearAlgebra/LinearSolvers/cholmod.jl index 7318befa..b74c5c27 100644 --- a/src/LinearAlgebra/LinearSolvers/cholmod.jl +++ b/src/LinearAlgebra/LinearSolvers/cholmod.jl @@ -8,7 +8,7 @@ Use CHOLMOD backend. Options available: * `Float64` only -* Augmented system with LDL factorization +* Augmented system with LDLᵀ factorization * Normal equations with Cholesky factorization """ struct Cholmod <: LSBackend end @@ -22,7 +22,7 @@ struct Cholmod <: LSBackend end Linear solver for the 2x2 augmented system with ``A`` sparse. -Uses an LDLt factorization of the quasi-definite augmented system. +Uses an LDLᵀ factorization of the quasi-definite augmented system. """ mutable struct SparseIndefLinearSolver <: AbstractLinearSolver{Float64} m::Int # Number of rows @@ -84,7 +84,7 @@ linear_system(::SparseIndefLinearSolver) = "Augmented system" """ update_linear_solver!(ls, θ, regP, regD) -Update LDLt factorization of the augmented system. +Update LDLᵀ factorization of the augmented system. Update diagonal scaling ``\\theta``, primal-dual regularizations, and re-compute the factorization. @@ -179,16 +179,16 @@ end SparsePosDefLinearSolver Linear solver for the 2x2 augmented system -```math - [-(Θ^{-1} + Rp) A'] [dx] = [xi_d] - [ A Rd] [dy] = [xi_p] +``` + [-(Θ⁻¹ + Rp) Aᵀ] [dx] = [xi_d] + [ A Rd] [dy] [xi_p] ``` with ``A`` sparse. Uses a Cholesky factorization of the positive definite normal equations system ``` -(A*(Θ^{-1} + Rp)^{-1}*A' + Rd) dy = xi_p + A*(Θ^{-1} + Rp)^{-1}*xi_d - dx = (Θ^{-1} + Rp)^{-1} * (A' dy - xi_d) +(A * ((Θ⁻¹ + Rp)⁻¹ * Aᵀ + Rd) dy = xi_p + A * (θ⁻¹ + Rp)⁻¹ * xi_d + dx = (Θ⁻¹ + Rp)⁻¹ * (Aᵀ * dy - xi_d) ``` """ mutable struct SparsePosDefLinearSolver <: AbstractLinearSolver{Float64} @@ -307,4 +307,4 @@ function solve_augmented_system!( return nothing -end \ No newline at end of file +end diff --git a/src/LinearAlgebra/LinearSolvers/lapack.jl b/src/LinearAlgebra/LinearSolvers/lapack.jl index f6444b92..c12ac990 100644 --- a/src/LinearAlgebra/LinearSolvers/lapack.jl +++ b/src/LinearAlgebra/LinearSolvers/lapack.jl @@ -18,8 +18,8 @@ struct Lapack <: LSBackend end Linear solver for the 2x2 augmented system ``` - [-(Θ^{-1} + Rp) A'] [dx] = [xi_d] - [ A Rd] [dy] = [xi_p] + [-(Θ⁻¹ + Rp) Aᵀ] [dx] = [xi_d] + [ A Rd] [dy] [xi_p] ``` with ``A`` dense. @@ -214,4 +214,4 @@ function solve_augmented_system!( # TODO: Iterative refinement return nothing -end \ No newline at end of file +end diff --git a/src/LinearAlgebra/LinearSolvers/ldlfact.jl b/src/LinearAlgebra/LinearSolvers/ldlfact.jl index 1946028d..d699c6cb 100644 --- a/src/LinearAlgebra/LinearSolvers/ldlfact.jl +++ b/src/LinearAlgebra/LinearSolvers/ldlfact.jl @@ -9,7 +9,7 @@ Use LDLFactorizations backend. Options available: * Any numerical type `T` -* Augmented system with LDL factorization +* Augmented system with LDLᵀ factorization """ struct LDLFact <: LSBackend end @@ -22,7 +22,7 @@ struct LDLFact <: LSBackend end Linear solver for the 2x2 augmented system with ``A`` sparse. -Uses LDLFactorizations.jl to compute an LDLt factorization of the quasi-definite augmented system. +Uses LDLFactorizations.jl to compute an LDLᵀ factorization of the quasi-definite augmented system. """ mutable struct LDLFLinearSolver{Tv<:Real} <: AbstractLinearSolver{Tv} m::Int # Number of rows @@ -69,7 +69,7 @@ linear_system(::LDLFLinearSolver) = "Augmented system" """ update_linear_solver!(ls, θ, regP, regD) -Update LDLt factorization of the augmented system. +Update LDLᵀ factorization of the augmented system. Update diagonal scaling ``\\theta``, primal-dual regularizations, and re-compute the factorization. diff --git a/src/LinearAlgebra/unitBlockAngular.jl b/src/LinearAlgebra/unitBlockAngular.jl index 79b394bd..bb6a4589 100644 --- a/src/LinearAlgebra/unitBlockAngular.jl +++ b/src/LinearAlgebra/unitBlockAngular.jl @@ -367,7 +367,7 @@ end """ mul!(y, A, x) -In-place computation of `y = A*x` +In-place computation of `y = A * x` """ function mul!( y::Vector, @@ -386,9 +386,9 @@ function mul!( end """ - mul!(x, At, y) + mul!(x, Aᵀ, y) -Compute Matrix-vector product `A'*y` and overwrites the result in `x`. +Compute Matrix-vector product `Aᵀ * y` and overwrites the result in `x`. """ function mul!( x::Vector, @@ -520,7 +520,7 @@ end """ factor_normaleq(A, θ) -Compute Cholesky factorization of `A*Θ*A'`, where `Θ = Diag(θ)`. +Compute Cholesky factorization of `A*Θ*Aᵀ`, where `Θ = Diag(θ)`. """ function factor_normaleq(A::UnitBlockAngular{Tv}, θ::Vector{Tv}) where Tv<:Real @@ -556,7 +556,7 @@ end """ factor_normaleq!(F, A, θ) -In-place computation of Cholesky factorization of `A*Θ*A'`, where `Θ = Diag(θ)`. +In-place computation of Cholesky factorization of `A*Θ*Aᵀ`, where `Θ = Diag(θ)`. """ function factor_normaleq!( A::UnitBlockAngular{Tv},