Post Reply 
Hp 50g Math question: Intersection of 2 triangulars
12-21-2013, 03:44 PM
Post: #6
RE: Math question: Intersection of 2 triangulars
Wow,

I thought this a minor problem, but your answers show that it worth to think a little bit about that topic.

My solution will work in some instances:

1) testing wether the two planes which are defined by the 2 triangulars are truly parallel and don't intersect each other. That can be easly done by the cross product (don't forget I use the hp 50g) and using the Hesse-form for planes:

\[ \vec{n}_1 = \vec{a} \times \vec{b} \] first triangular (trig) \[ \vec{a},\vec{b} \] are defining the two sides of trig 1

\[ \vec{n}_2 = \vec{c} \times \vec{d} \] second trig \[\vec{c},\vec{d}\] are defining the two sides of trig 2

\[ (\vec{x} - \vec{t}_i )\cdot \vec{n}_i = 0 \]

When the two planes are not intersecting the procedure ends, otherwise: (the planes could be identical
or intersect with a line)

2) Now I decide to calculate the the radii-vectors (of the circumcircles) of the two trigs. If they obey the inequality:

\[ \| \vec{r}_2 - \vec{r}_1 \| > \| \vec{r}_1 \| + \| \vec{r}_2 \| \]

then the trigs cannot intersect and the procedure ends (I do this testing because I have two hulls build
with a lot of triangles and a lot of them are not intersecting. Let's say hull 1 has 15 and hull 2 has 20 trigs,
I have to test 300 trigs, that is a challenge for my hp 50g), otherwise

3) If the plane intersect with a line, I consider the the vectors \[\vec{c},\vec{d}\] and \[\vec{d}-\vec{c}\]
as the direction-vectors of three line equalities in analytical geometry:

i. e.: \[ g_1 ~ : ~ \vec{x} = \vec{t} + \gamma\vec{c} \] and so on. Vector \[ \vec{t} \] is the
position-vector of trig 2. With the Hesse form I can find out where are the intersection points with plane 1.
Every point can be expressed as a vector beginning on the position-vector of trig 1. And now this vector can be
expressed as a linear-combination of the vectors \[ \vec{a},\vec{b} \] (which describe the trig 1) \[ \vec{s}=\alpha\cdot\vec{a}+\beta\cdot\vec{b}\] and with the two parameters \[ \alpha, \beta\] it can be decided wether that intersecting point is inside from trig 1 or not.


4) If the plane 1 is identical to plane 2 (We know this from 1) we have the similar work to do as in 3). But we
intersect then lines with lines and not lines with a plane, like in 3).

Statisticaly I expect more trigs, which are not intersecting, but I've the
impression part 3) or 4) is also a lot of work for my calculator. Maybe somebody else knows
a more sharp heuristic argument (as in 2) formulated) for accelerating the program.
My Program has to work a lot with the cross and dot product of the hp 50g.


@Han, a special thank for you, you spend a lot of time formulating your answer and solution. I'm curious about your 3-D solution.

Sincerely
peacecalc
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Math question: Intersection of 2 triangulars - peacecalc - 12-21-2013 03:44 PM



User(s) browsing this thread: 1 Guest(s)