5.0

5.0 | 1 rating Rate this file 16 Downloads (last 30 days) File Size: 31 KB File ID: #27711
image thumbnail

Euclidian projection on ellipsoid and conic

by

 

24 May 2010 (Updated )

Projecting a point on ellipsoid or conic in n-dimensional space

| Watch this File

File Information
Description

Find the projection of point P in R^n on the ellipsoid

E = { x = x0 + U*(z.*radii) : |z| = 1 }, where U is orthogonal matrix of the orientation of E, radii are the axis lengths, and x0 is the center.

Or on generalized conic E = { x : x'*A*x + b'*x + c = 0 }.

The projection is the minimization problem:
min | x - P | (or max | x - P|) for x in E.

Method: solve the Euler Lagrange equation with respect to the Lagrange multiplier, which can be written as polynomial equation (from an idea by Roger Stafford)

MATLAB release MATLAB 7.10 (R2010a)
Other requirements Should work from v 2097A (bsxfun required)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (2)
29 Dec 2013 Cui

Excellent work. It solved my problem. Thanks very very much.

24 May 2010 Mark Shore

It was very interesting to watch this unfold from a simple newsgroup question to this FEX submission. No rating at this point because Bruno has used a number of techniques I'm not familiar with (so my rating would be uninformed), but it seems to work as advertised.

One quick comment: I added alpha(0.5) to his example script to render the ellipsoid semitransparent and make the projection more obvious.

Updates
25 May 2010

Extend to generalized conic (ellipsoid, paraboloid, hyperboloid, etc...)

25 May 2010

Cosmetic changes + Script for test example for 2D conic projection

25 May 2010

Fix a bug, Introducing an adjustable tolerance value for parabola detection

Contact us