線形計画法モデルを解決するための素敵な R パッケージを探しています。私はデフォルトで十分満足していますが、シャドウと割引価格lpSolve::lp
を取得する方法はありません。これらと、完全性制約が必要です。
サンプルモデル:
A = rbind(
c(0.5, 0.2, 0.2),
c( -1, 1, 0),
c( 0, 1, -1),
c( -1, -1, -1),
c( -1, 0, 0),
c( 0, -1, 0),
c( 0, 0, -1)
)
b = c(5, 0, 0, -13, 0, 0, 0)
c_ = c(8.4, 6, 9.2)
(signs = c('=', rep('<=', 6)))
res = lpSolve::lp('min', c_, A, signs, b, all.int = TRUE)
# Objective function
res
# Variables
res$solution
# Shadow prices???
# Reduced prices???