summaryrefslogtreecommitdiff
path: root/symphonymat/symphonymat_logical1.sce
diff options
context:
space:
mode:
authorHarpreet2015-11-17 22:24:58 +0530
committerHarpreet2015-11-17 22:24:58 +0530
commitad6fd408ea41e74e56b31a5bc756639e521a20e3 (patch)
tree117dfe11397868e23e4177974ee4db6128616157 /symphonymat/symphonymat_logical1.sce
parent6a389f6a51bdd88f89706b1c32276d9e1b71ef22 (diff)
downloadOR-toolbox-test-cases-ad6fd408ea41e74e56b31a5bc756639e521a20e3.tar.gz
OR-toolbox-test-cases-ad6fd408ea41e74e56b31a5bc756639e521a20e3.tar.bz2
OR-toolbox-test-cases-ad6fd408ea41e74e56b31a5bc756639e521a20e3.zip
all the tests added
Diffstat (limited to 'symphonymat/symphonymat_logical1.sce')
-rw-r--r--symphonymat/symphonymat_logical1.sce55
1 files changed, 55 insertions, 0 deletions
diff --git a/symphonymat/symphonymat_logical1.sce b/symphonymat/symphonymat_logical1.sce
new file mode 100644
index 0000000..117b59b
--- /dev/null
+++ b/symphonymat/symphonymat_logical1.sce
@@ -0,0 +1,55 @@
+// Objective function
+c = [350*5,330*3,310*4,280*6,500,450,400,100]';
+
+// Lower Bound of variable
+lb = repmat(0,1,8);
+
+// Upper Bound of variables
+ub = [repmat(1,1,4) repmat(%inf,1,4)];
+
+// Constraint Matrix
+Aeq = [5,3,4,6,1,1,1,1;
+5*0.05,3*0.04,4*0.05,6*0.03,0.08,0.07,0.06,0.03;
+5*0.03,3*0.03,4*0.04,6*0.04,0.06,0.07,0.08,0.09;]
+
+beq = [ 25, 1.25, 1.25]
+
+intcon = [1 2 3 4];
+
+options = list("time_limit",250);
+
+// Calling Symphony
+[x,f,status,output] = symphonymat(c,intcon,[],[],Aeq,beq,lb,ub,options)
+disp("x",x,"f",f,"status",status,"output",output);
+//Output
+//setting of double parameter function executed successfully
+//Problem loaded into environment.
+//
+//Note: Time limit has been set to 250.000000.
+//
+//An optimal solution has been found.
+//
+// 0.
+//
+// Iterations: 1
+//
+// output
+//
+// 227.
+//
+// status
+//
+// 8495.
+//
+// f
+//
+// 1.
+// 1.
+// 0.
+// 1.
+// 7.25
+// 0.
+// 0.25
+// 3.5
+//
+// x