Re: Minimum distance from a point to a surface defined by constraints
From: The Qurqirish Dragon (qurqirishd_at_aol.com)
Date: 03/03/05
- Next message: carkaci: "Re: Minimum distance from a point to a surface defined by constraints"
- Previous message: tadchem: "Re: Problem fitting a curve"
- In reply to: carkaci: "Minimum distance from a point to a surface defined by constraints"
- Next in thread: carkaci: "Re: Minimum distance from a point to a surface defined by constraints"
- Reply: carkaci: "Re: Minimum distance from a point to a surface defined by constraints"
- Reply: Richard Groff: "Re: Minimum distance from a point to a surface defined by constraints"
- Messages sorted by: [ date ] [ thread ]
Date: 3 Mar 2005 06:44:49 -0800
Consider the 2- dimensional case:
each constraint defines a half-plane. Assuming they intersect at all
(so there is a solution), this will define a region R bordered by a
convex region, which has vertices at some of the points of
intersections of the lines in the constraints. These points can be
easily soved for, and the ones outside R (all points will be either on
the boundry of R or inside) can be discarded (check the equations to
see which ones fail to satisfy them).
Now, get the distance from P to each vertex. For sake of discussion,
assume that the smallest distance is to vertex v2, with adjacent
vertices v1 and v3, defining lines L1 and L3.
Find the projections onto L1 and L3 of P (normal projections, of
course). If this point lies on R (and at most 1 of these points will do
so), then that is the closest point (since R is convex), and you have
the distance. If neither of these projections lie on R, then v1 is the
closest point.
This should translate naturally into more dimensions, checking
distances to the vertices of the bounded region, and using the adjacent
hyperplanes to v1 for finding the distances. If there aren't enough
constraints to get vertices (e.g. x<0; y>0 in R^3), then use the
smallest-dimensional spaces in the intesections. (in the above example,
the z-axis is the intersection of the planes, so you would use the
distance from P to the z-axis, and the distance from z to the xz and yz
planes.)
- Next message: carkaci: "Re: Minimum distance from a point to a surface defined by constraints"
- Previous message: tadchem: "Re: Problem fitting a curve"
- In reply to: carkaci: "Minimum distance from a point to a surface defined by constraints"
- Next in thread: carkaci: "Re: Minimum distance from a point to a surface defined by constraints"
- Reply: carkaci: "Re: Minimum distance from a point to a surface defined by constraints"
- Reply: Richard Groff: "Re: Minimum distance from a point to a surface defined by constraints"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|