**Finding intersection points of 3D line and polygon**Dear all,
does MatLab have a function to find the intersection points of a 3D
line with a 3D polygon. I found the 2D function polyxpoly.
Thanks,
Nick,
...

**Find the equivalent intersection point of multi lines in 3D space**HI everyone, I'm not a native english speaker, so I wonder you could
understand my question very well.
This question originates from my physics experiments. When I catch
several lights from my equipment, the light source is far away, so I
should caculate the position of the equivalent "light source". This
comes the post title. Normally, all these light lines were skew each
other.
For two lines, this is very simple to get the answer, because we can
easily define the equivalent point as the mid-point of the shortest
distance of the two lines. Several algorthms can be found by Goo...

**Intersect Point of a 3D Parametric Line & B-Spline Surface**Hi:
I have the following Mathematica 8.0.4. code that plots a parametric 3D line and a surface using BSplineSurface.
paraLine=ParametricPlot3D[{2+t,2+t 3,t 2}, {t,-1,1},PlotRange -> {{0, 5},{0, 5},{-1, 1}}, PlotStyle->{Red,Thickness[0.004]},ViewPoint->{4,2,1}, AxesLabel -> {"X", "Y", "Z"},Background->LightYellow,ImageSize->500];
cpts={{{1,1,-0.5740579178735179`},{1,2,0.3902669640296943`},{1,3,0.6162142022057271`},{1,4,-0.11572153782589911`},{1,5,0.436662579150056`}},{{2,1,0.8096824307907462`},{2,2,-0.7419265507701529`},{2,3,-0.865915674453...

**line intersecting point in 3d**Hi,
I've read about the basics of vectors, but I still don't know
how to find out if a line intersects a point in 3d space.
If I have a ray starting at origin O, and travelling
with vector V, how do I know if it hits point P?
That is:
Ray = O + Vt
Point = P
Can someone please tell me how to calculate this?
Thanks
jaso <as@email.com> wrote:
> Hi,
> I've read about the basics of vectors, but I still don't know
> how to find out if a line intersects a point in 3d space.
Lines don't really "intersect" points. They go through them. But
this will ...

**How to find surface to cover 3D points?**Hello all:
I used the following code to display color pixel distribution
in 3D space.
I = imread('fox.jpg');
R = I(:,:,1);
G = I(:,:,2);
B = I(:,:,3);
plot3(R(:), G(:), B(:), 'r.');
Does matlab provide function to generate the minimum surface
to cover all those pixels in 3D?
So we can see the volume visualization of pixels in 3D space.
Thank you
-Daniel Alan
Daniel Alan wrote:
>
>
> Hello all:
>
> I used the following code to display color pixel distribution
> in 3D space.
>
> I = imread('fox.jpg');
> R = I(:,:,1);
> G = I(:,:,2);
>...

**3d surface from 3d points**I have hand-segmented points from a CT scan,
delineating an object. 3d plot shows the slices nicely, but the mesh
and surf (after using meshgrid etc) functions interpolated across the
data set -- I want to maintain the *surface* of the data. I should be
able to display this as a tube.
I have also converted the data into a volume -- a binary volume, with
a 1 at these points, but the point set is then too sparse to generate
the surface.
Thanks
suguna
i have the same problem if any one has something please reply
thanks,
anil
S pappu wrote:
>
>
> I have hand-segment...

**Line Line intersection in 3D**Hi all,
I am trying to find the intersection of 2 lines in 3D. I have 4
points which I can use to construct 2 lines. I tried implementing the
linear equations but I believe, its not giving correct intersection
points.
Can anyone help me in finding the intersection points in 3D?
Any help would be appreciated !!!
Thank you,
chandp24@gmail.com wrote:
> Hi all,
> I am trying to find the intersection of 2 lines in 3D. I have 4
> points which I can use to construct 2 lines. I tried implementing the
> linear equations but I believe, its not giving correct intersection
> points.
&...

**How to find interpolating surface from scattered 3D points?**Dear all,
I have a set of 66 points forming a polygonal grid that can be viewed
here:
http://www.greyc.ismra.fr/~bailleul/These/meanshape.jpg
My problem is to determine a smooth closed surface (always of
sphere-eqvt topology) that (preferently) interpolates my unordered set
of points.
As you can see, it is difficult to group the points into "slices" of the
same number of points in a given parametric direction, as we would need
in the tensor-product scheme. I also considered different alternative
methods, but all of them tend to demand a set of input points that are
grouped into par...

**points in common or intersection between two lines in 3d**Hey , I am trying to find the common point between two line in three D , given two equation:
syms t
Line1= P4-t*( P5-P4)
syms z
line2= P6-z*( P7-P6)
I am trying to find the common points between them
"Thibault Twahirwa" <thijos33@gmail.com> wrote in message <ljebdc$jvv$1@newscl01ah.mathworks.com>...
> ... I am trying to find the common point between two line in three D .....
- - - - - - -
In general, two straight three-dimensional lines will not intersect. It is the geometrical equivalent of trying to solve three equations with only two unknowns.
...

**Intersecting point of 3 straight lines in 3D coordinate**Hi everyone, I need a help! I have 3 straight lines of which I know the x, y, and z coordinates of one end each. They intersect each other at the other end. However, the distances of each line at which they intersect, are known. Now, I need to calculate the intersection point.
I have tried using the following equation.
solve('(x-x1)^2+(y-y1)^2+(z-z1)^2=d1^2','(x-x2)^2+(y-y2)^2+(z-z2)^2=d2','(x-x3)^2+(y-y3)^2+(z-z3)^2=d3','x','y','z');
But, the result is very long. I don't know whether the answer is acceptable or not.
Can anyone please he...

**Plotting 3D scattered points and find its fitting surface.**1. Can I use Maple to plot scattered data?
I have data set in (X, Y, Z, Value) pairs.
2. How can I find its fitting surafece?
I found only this one http://www.maplesoft.com/applications/app_center_view.aspx?AID=2032&CID=10&SCID=148
thanks for your replies
easy <easy.lin@gmail.com> writes:
> 1. Can I use Maple to plot scattered data?
> I have data set in (X, Y, Z, Value) pairs.
You can plot scattered points in 3d using pointplot3d in the plots package.
But I don't know what you want to do with the "Value".
> 2. How can I fi...

**intersection of line&&line and point&&line**Hello,
i would like to find intersection of two lines or point and line.
I am using polyxpoly command.
But unfortunately it works only with two lines.
If i have that example:
point:
a = [3 3];
b = [3 3];
line:
c = [1 3];
d = [10 3];
[xi yi] = polyxpoly([a(1) b(1)],[a(2) b(2)], [c(1) d(1)],[c(2) d(2)]);
the resulat of that is:
xi=yi=[];
But there is an intersection in [x y] = [3 3].
How fix it?
Thanks for any advice.
ZaC.
"zac " <sony_1000@o2.pl> wrote in message <i4qqsj$lg3$1@fred.mathworks.com>...
> Hello,
>
> i would like to ...

**point intersection (distance of a point to a line)**I have a problem to solve, could someone help me out.
I have a point P (x1,y1)
and a line L represented by two endpoints (x2, y2) (x3, y3)
How do I find the distance from P to L
I have a solution is that:
1. Find the function of L
2. Find the normal of L
3. Then create a function through (x1, y1)
4. Then solve the two equations to find the intersection.
we cannot use syms, and solve function
Thanks
On Mar 21, 6:37=A0pm, phamtrungth...@gmail.com wrote:
> I have a problem to solve, could someone help me out.
>
> I have a point P (x1,y1)
> and a line L re...

**Display/find points where a 3D Patch object intersects a plane**I have a complicated 3D patch object (an airplane). I am trying to take a cross-section of it. Meaning I would like to see a 2D plot of where the patch intersects a plane. The data I am using to create the patch is in the form of xdata,ydata,zdata as in the example below:
[x y z] = sphere;
h = patch(surf2patch(x,y,z,z));
xdata = get(h,'xdata'); ydata = get(h,'ydata'); zdata = get(h,'zdata');
I would like to be able to specify a simple plane like y = .5 and see a circle in the above example. While the ability to specify any plane would be nice, right now I ...

**3D points representing cubes to 3D surface?**Hi there,
I have a Nx3 matrix where each row has x,y,z coordinates of points.
The points come from a 3D map and were generating by reading obstacle positions via a laser sensor, which were then approximated to the nearest cube center in a 3D cubic grid. This gives me the coordinates of the center of occupied cubes.
How can I transform these points into cubes that can be visualized in 3D? The cubes have a 1 unit side, so two consecutive cubes may have coordinates (20,20,20) and (20,20,21).
Thanks,
Francisco Seixas
"Francisco Seixas" wrote in message <k8ntuj$aii$1@new...

**How to find the intersection point of two intersecting OBBs**I need help understanding how to find the intersection point of two
intersecting oriented bounding boxes.
I am building a rigid body simulator that uses oriented bounding boxes
as the collision boundaries. I have got collision detection working
(via separating axis approach) and am beginning to implement the
collision response. Part of the collision response is to determine the
magnitude of the impulse to apply to the rigid bodies. To accomplish
this, I need the point of intersection of the two OBBs.
I have been using David Eberly's detailed documentation
(http://www.geometrictools.co...

**3D surface: get distance to points on the surface**Hallo,
I want to calculated the distance from one point to a point on a 3D surface.
If one creates a cylinder using the following command
t = 0:pi/10:2*pi;
[X,Y,Z] = cylinder(2+cos(t));
surf(X,Y,Z);
you get a nice surface made with polygons only in the plot. I want to
have the quite simple surface in memory so that I can access it. It is
possible to describe surfaced using some kind of polygon...?
I have already tried to calculate hundreds of point of the cylinder. But
it takes a lot of time, you only get some points of the whole surface
and plotting each of this hundreds point tak...

**Surface fitting to point cloud -> 3D surface**I have set of data points obtained by sensor scanning the surface of
a 3D object. I would like to reconstruct the surface based on the
point cloud that I have now. Any advices on approach will help a lot.
(I read the MATLAB help and found that griddata3 and related
functions can fit surface. But I am not able to implement them !)
please help out.
Prasan
In article <ef06ba6.-1@webx.raydaftYaTP>, Prasan <prasang@yahoo.com>
wrote:
> I have set of data points obtained by sensor scanning the surface of
> a 3D object. I would like to reconstruct the surface based on the
> p...

**3d lines on a 3d surface, invisble image buffers, warp**Hello,
I want to draw 3d lines on a 3d surface. I'm currently using plot3
and surf. The problem with that is there's often some odd clipping
that occurs and the line doesn't totally lay flat on the surface
because the lines are defined at a higher precision than the surface.
What I was thinking of doing is making the 2d image, drawing the
lines on it, converting it to cdata, and using it with warp to
texture map the surface so it will look pretty and be totally flush
with the surface.
If I were to do that, I'd have to draw the 2d figure, do a getframe()
and then use the outp...

**generating points on a line joining 2 points in 3D space**Hallo all,
I need ideas to code the following
Problem definition:
Generating the points on a line to be defined by the start point and
end point(given by user):
start point (x1,y1,z1) , end point(x2,y2,z2) and step size da
(=sqrt(dx2 + dy2 + dz2 )) will be given by the user.
my code shud be able to
- calculate the distance between the two points
- calculate all the points on the line according to the step size
Any ideas in this regard will be of great help to me.
Thanks in advance.
nexus wrote:
>
>
> Hallo all,
> I need ideas to code the following
>
> Problem definition:...

**Find point in 3D convex hull closest to point outside?**Hi guys,
I have two sets of points in 3D, and I would like to interpolate one set at
the points of the other set.
I plan on using triscatteredinterp (other suggestions are welcome). It can
interpolate in the convex hull of the points, however a few of my points in
the other set are just outside the convex hull of the first set and these
points need to be handled in some way.
One way could be to just put them inside the convex hull. For this I would
like to find the points inside (on the edge of cause) that have the shortest
distance to the points outside the convex hull. Any i...

**C for the intersection point between a polygon and a line with points inside/outside.**Hi!
I want the intersection point between a polygon and a line with a
"start" point inside a polygon, and the "stop" point outside. I use a
point in polygon algorithm to determin if the points are inside and
outside.
The line crosses only the polygon at one point.
The polygon is not convex.
Is there any C code available for these algorithms?
Thanks!
J-O Johansson
Sweden
janjo@home.se wrote:
> Hi!
> I want the intersection point between a polygon and a line with a
> "start" point inside a polygon, and the "stop" point outside. I use a
>...

**HELP: Intersection of 1 line and 1 point... (only 3 points known)**I'm trying to solve the following problem.
The points (1,2,3) are 2D (x,y). Using a robot arm, I can locate each
point in 2D space using a sensor.
If you imagine a line (I'll call it 'a') between points 1 and 2,
extended so that you could draw a line('b') from point 3 which is at
90 degrees to the 'a' line.
(this should be readable in a fixed-font)
1
a
a
a
a
2
a
a
a
?bbbb
bbbb
bb3
The point at which these 2 lines intersect is point '?', is what I'm
trying to find.
Googling only really t...

**Compute 3D volume and intersection of 3D objects from point cloud data.**Hello everyone!
Currently, I am running a project that scans two 3D point cloud from two different objects (A and B). My aim is to transfer this point cloud (available in MATLAB workspace, i.e. x,y,z) into a 3D volume. Next step would be to determine whether the object B is partly inside object A, or not (point-wise check for object B is fine as well). If an intersection is detected, the location shall be returned. I can also increase the point density for the data.
I tried already several approaches, but was not successful so far ...
For the first problem, I found the DelaunayTri(x,y...