[Insight-users] boundary conditions using non linear optimzers
Hartmann Philipp
p.hartmann at dkfz-heidelberg.de
Sun Jul 5 12:00:04 EDT 2009
Hello,
I am trying to fit a parametric curve into a point set using a least
squares cost function. The parametric curve has the following form:
X= a + t*b +(t-l)^2 *c
X,a,b,c are element of R^3
l is element of R
t is element of the interval [tmin, tmax]
the cost function is the sum of all squared distances of points from the
curve
Sum((min(P_i-X(t)))^2)
Parameters to optimize are: tmin, tmax, l, and the components of a,b,c
The Problem is now the boundary conditions which are desired. I need a
maximum extent of the interval [tmin,tmax]
=> abs(tmin-tmax)<=Z
And I need the conditions
Norm(b) = 1
Norm(c) = 1
Implementing the cost function is easy, but I don't know how to
implement the boundary conditions. Of course I thought about putting a
high "punishing" value into the cost function, if one condition is not
satisfied, but I hoped, there was a "cleaner" way, which allows the
optimizer to anticipate the boundaries and to step more intelligently
through the search space.
Regards,
Philipp Hartmann
More information about the Insight-users
mailing list