From 33bdd144438436b759bc8d0b0beba715f0e39e5d Mon Sep 17 00:00:00 2001 From: Harpreet Date: Thu, 10 Sep 2015 12:37:16 +0530 Subject: output added --- macros/symphony_call.sci | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'macros/symphony_call.sci') diff --git a/macros/symphony_call.sci b/macros/symphony_call.sci index 843ad6a..ea5f34f 100644 --- a/macros/symphony_call.sci +++ b/macros/symphony_call.sci @@ -9,7 +9,7 @@ // are also available at // http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt -function [xopt,fopt,iter] = symphony_call(nbVar,nbCon,objCoef,isInt,LB,UB,conMatrix,conLB,conUB,objSense,options) +function [xopt,fopt,status,output] = symphony_call(nbVar,nbCon,objCoef,isInt,LB,UB,conMatrix,conLB,conUB,objSense,options) //Opening Symphony environment sym_open(); @@ -32,17 +32,21 @@ function [xopt,fopt,iter] = symphony_call(nbVar,nbCon,objCoef,isInt,LB,UB,conMat xopt = []; fopt = []; status = []; - iter = []; + output = []; if (~op) then xopt = sym_getVarSoln(); + // Symphony gives a row matrix converting it to column matrix + xopt = xopt'; + fopt = sym_getObjVal(); - iter = sym_getIterCount(); end status = sym_getStatus(); + + output = struct("Iterations" , []); + + output.Iterations = sym_getIterCount(); - //Closing Symphony Environment - sym_close(); endfunction -- cgit