Learn R Programming

convexjlr (version 0.8.1)

property: Get properties of optimization problem

Description

Get properties of solved optimization problem, like the status of problem (optimal, infeasible and etc.), or the optimal value of the solved optimization problem.

Usage

status(p)

optval(p)

Arguments

p

optimization problem.

Examples

Run this code
# NOT RUN {
    convex_setup()
    x <- Variable(2)
    b <- J(c(1:2))
    p <- minimize(sum((x - b) ^ 2))
    cvx_optim(p)
    status(p)
    optval(p)
# }

Run the code above in your browser using DataLab