Can I solve this with Matlab Optimization Toolbox?
1 view (last 30 days)
Show older comments
Dear all,
Hi, I'm new to Matlab and also to optimization problems. I need help on an optimization problem. The problem is as follows:
find x=(est_pos_1, ... est_pos_n)
minimizing the sum of squared difference between elements in matrix A and B
where:
a_ij = 1 if Euclidean distance between est_pos_i and est_pos_j is less than constant R and 0 otherwise, 0 < i, j < m + n, m is number of points with known position, n of points with unknown positions to be estimated, b_ij = 1 if Euclidean distance between actual_pos_i and actual_pos_j is less than R and 0 otherwise. Matrix B is given.
I tried solving it using Particle Swarm Optimization with poor success, i.e. the error between the estimated and actual positions is high.
5 Comments
Accepted Answer
Matt J
on 29 Mar 2013
Edited: Matt J
on 29 Mar 2013
No, you can't use the Optimization Toolbox. The solvers in the Toolbox are smooth algorithms (except for bintprog) and therefore apply to differentiable functions.
However, your matrix A, and therefore the objective function overall, is a piecewise constant, non-differentiable, function of x. The piecewise constant behavior will also mean that the objective function is flat almost everywhere, making almost every point a local minimum where the optimization can get stuck.
4 Comments
Matt J
on 29 Mar 2013
Edited: Matt J
on 29 Mar 2013
Well, I don't think there's always an easy way. Certainly optimization textbooks will always give examples of functions that are convex etc... and you build your analysis skills from that.
However, in your case, the A matrix can only take on values 0 or 1. Discrete-valued functions like that have to be piecewise constant.
More Answers (0)
See Also
Categories
Find more on Get Started with Optimization Toolbox in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!