Originally Posted by
Twig hi CB
good point, I need to rethink this a bit probably.
My problem is, I need to use fmincon to maximize distance between 6 points on a unit sphere in R^3. I need in some way find an expression for calculating the distance from every point to every other point?
I just thought maybe it would be easiest in some way if I were to put the different points in a matrix or something..
Also obv, I need to write a nonlinear constraint function.
I guess it would be something like:
function [c,ceq]=confun(x)
c=[] %No less than constraints
ceq=x(1).^2 + x(2).^2 + x(3).^3 - 1
end
But I need this constraint for 6 points..
thanks!