Rev | Line | |
---|
[37] | 1 | % By Philip Torr 2002
|
---|
| 2 | % copyright Microsoft Corp.
|
---|
| 3 |
|
---|
| 4 | function [c,ceq] = torr_nonlcon_f2x2(f, nx1,ny1,nx2,ny2, m3)
|
---|
| 5 | %c = ... % Compute nonlinear inequalities at f.
|
---|
| 6 | %ceq = ... % Compute nonlinear equalities at f.
|
---|
| 7 |
|
---|
| 8 | %g(1) = norm(f) -1.0;
|
---|
| 9 | %g(2) = f(1) * (f(5) * f(9) - f(6) * f(8)) - f(2) * (f(4) * f(9) - f(6) * f(7)) + f(3) * (f(4) * f(8) - f(5) * f(7));
|
---|
| 10 | c = [];
|
---|
| 11 | %what norm should we use!
|
---|
| 12 | ceq(1) = sqrt(f(1)^2 + f(2)^2 + f(4)^2 + f(5)^2)- 1;
|
---|
| 13 | %ceq(1)= norm(f) -1.0;
|
---|
| 14 | ceq(2) = f(1) * (f(5) * f(9) - f(6) * f(8)) - f(2) * (f(4) * f(9) - f(6) * f(7)) + f(3) * (f(4) * f(8) - f(5) * f(7));
|
---|
Note: See
TracBrowser
for help on using the repository browser.