A <- c(3000, 4000, 5000, 2000)
m <- c(100, 90, 70, 80)
M <- c(200, 150, 300, 210)
xopt_1 <- opt(n = 400, A, m)
alloc_summary(xopt_1, A, m)
xopt_2 <- opt(n = 540, A, m, M)
alloc_summary(xopt_2, A, m, M)
Run the code above in your browser using DataLab