nuget server logo nuget api documents
↑

API Docs / Microsoft.VisualBasic.Math.Core / InteriorPointSolver

InteriorPointSolver

Full name Microsoft.VisualBasic.Math.LinearAlgebra.LinearProgramming.IPMCrossover.InteriorPointSolver Assembly Microsoft.VisualBasic.Math.Core Members 10

01 Syntax

Microsoft.VisualBasic.Math.LinearAlgebra.LinearProgramming.IPMCrossover.InteriorPointSolver

02 Methods

NameOverloadsSummary
.ctor 2 通用构造:矩阵抽象 + 可选上界
UpdateUpperSlack 1 w = u − x(带数值下限,避免除零)
Complementarity 1 平均互补间隙 μ = (xᵀs + wᵀz) / (n + n_finite)
ComplementarityAt 1 沿方向走 α 之后的平均互补间隙(Mehrotra σ 用)
MaxStepX 1 原始步长上界:0 ≤ x + αΔx ≤ u(双侧)
MaxStepDual 1 对偶步长上界:s + αΔs ≥ 0,z + αΔz ≥ 0
MehrotraStart 1 Mehrotra 起始点 无上界(x ≥ 0):沿用已验证的 Mehrotra(1992) 启发式——最小范数 x̂/ŝ + 偏移平衡。 有上界(0 ≤ x ≤ u):改为 1) 取盒子中心 x⁰ = u/2(无上界变量取 1), 2) 用同一因子做最小范数修正 x⁰ ← x⁰ − Aᵀ(AAᵀ)⁻¹(Ax⁰ − b),使 A·x⁰ =…
Solve 1 主入口

03 Fields

NameOverloadsSummary
u 1 上界(+∞ = 无上界)

04 Members

method .ctor overload 2 #
#ctor(Double[0:,0:], Double(), Double(), Double, Int32, List(Of String))

向后兼容构造:稠密矩阵 + 无上界(x ≥ 0)

method .ctor #
#ctor(ILpMatrix, Double(), Double(), Double(), Double, Int32, List(Of String))

通用构造:矩阵抽象 + 可选上界

Parameters
NameTypeDescription
uILpMatrix

上界数组(长度 = 列数);Nothing 或元素为 +∞ 表示该变量无上界

method UpdateUpperSlack #
UpdateUpperSlack(Double(), Double())

w = u − x(带数值下限,避免除零)

method Complementarity #
Complementarity(Double(), Double(), Double(), Double())

平均互补间隙 μ = (xᵀs + wᵀz) / (n + n_finite)

method ComplementarityAt #
ComplementarityAt(Double(), Double(), Double(), Double(), Double(), Double(), Double(), Double)

沿方向走 α 之后的平均互补间隙(Mehrotra σ 用)

method MaxStepX #
MaxStepX(Double(), Double())

原始步长上界:0 ≤ x + αΔx ≤ u(双侧)

method MaxStepDual #
MaxStepDual(Double(), Double(), Double(), Double())

对偶步长上界:s + αΔs ≥ 0,z + αΔz ≥ 0

method MehrotraStart #
MehrotraStart(Double(), Double(), Double(), Double())

Mehrotra 起始点

无上界(x ≥ 0):沿用已验证的 Mehrotra(1992) 启发式——最小范数 x̂/ŝ + 偏移平衡。 有上界(0 ≤ x ≤ u):改为 1) 取盒子中心 x⁰ = u/2(无上界变量取 1), 2) 用同一因子做最小范数修正 x⁰ ← x⁰ − Aᵀ(AAᵀ)⁻¹(Ax⁰ − b),使 A·x⁰ = b, 3) 夹回 [1%·u, 99%·u] 严格内部, 4) 对偶按 d = c − Aᵀŷ 的正/负部分拆分:s = max(d,0)+λ、z = max(−d,0)+λ (保证 s − z = d,即初始对偶残差为 0,且 s,z ≥ λ > 0)。 说明:不能把无上界的"平衡偏移"直接套用到有界情形——w·z 项会让 δ 爆炸, 把 x 整体推到界上(实测会让原始残差发散)。

method Solve #
Solve

主入口

field u #
u

上界(+∞ = 无上界)