inst/code/test.rmosek.R

# Here is a small example to test that Rmosek works. If it runs
# without error, it means your Rmosek installation is working
# properly.
library(Rmosek)
lo1       <- list()
lo1$sense <- "max"
lo1$c <- c(3,1,5,1)
lo1$A <- Matrix(c(3,1,2,0,
                  2,1,3,1,
                  0,2,0,3),
	       nrow=3, byrow=TRUE, sparse=TRUE)
lo1$bc <- rbind(blc = c(30,15,-Inf),
                buc = c(30,Inf,25))
lo1$bx <- rbind(blx = c(0,0,0,0),
                bux = c(Inf,10,Inf,Inf))
r      <- mosek(lo1)

Try the mixsqp package in your browser

Any scripts or data that you put into this service are public.

mixsqp documentation built on Nov. 17, 2022, 1:09 a.m.