diff options
author | Harpreet | 2016-08-04 15:25:44 +0530 |
---|---|---|
committer | Harpreet | 2016-08-04 15:25:44 +0530 |
commit | 9fd2976931c088dc523974afb901e96bad20f73c (patch) | |
tree | 22502de6e6988d5cd595290d11266f8432ad825b /docal.sce | |
download | FOSSEE-Optim-toolbox-development-9fd2976931c088dc523974afb901e96bad20f73c.tar.gz FOSSEE-Optim-toolbox-development-9fd2976931c088dc523974afb901e96bad20f73c.tar.bz2 FOSSEE-Optim-toolbox-development-9fd2976931c088dc523974afb901e96bad20f73c.zip |
initial add
Diffstat (limited to 'docal.sce')
-rw-r--r-- | docal.sce | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/docal.sce b/docal.sce new file mode 100644 index 0000000..0c28de0 --- /dev/null +++ b/docal.sce @@ -0,0 +1,15 @@ +ulink(); +exec builder.sce +exec loader.sce + + function y=f(x) + y=x(1)^2+x(2)^2; + endfunction + //Starting point, linear constraints and variable bounds + x0=[3 , 3]; + A=[1,1 ; 1,1/4 ; 1,-1 ; -1/4,-1 ; -1,-1 ; -1,1]; + b=[2;1;2;1;-1;2]; + Aeq=[1,1]; + beq=[2]; + //Calling Ipopt + [x,fval] =intfmincon(f, [3 3],[1 2],[],[]); |