In Stage 4 of the paper I have found the line of intersection between the plane of triangle B and triangle A, this a vector t emenating from a point T.
The edge of B that I'm looking for intersection with is defined as a point in B, P plus an edge vector p.
So the equation as given in the paper is of the from
P + d p = T + g t
where d and g are scalar multiples of the vectors p and t.
P,p,T and t are all known. d and g are the unknown scalars I need to solve for.
The goal here is to save operations and avoid using divides. The paper also hints at using determinants to save calculations.
The result is a point where the line T+t and P+p cross.
I re-write the equation to look like this -d p + g t = (P-T) in an attempt to make it look more like what I find in linear algebra texts.
I look at this as a series of 3 equations of 2 variables. Something like:
-d * p.x + g * t.x = (P-T).x
-d * p.y + g * t.y = (P-T).y
-d * p.z + g * t.z = (P-T).z
Now, all the examples I can find show how to solve for 3 equations and 3 variables, or 2 equations and 2 variables, not 3 equations and 2 variables.
Also, the paper says that since the vectors lie in the same plane "2 x 2 equations sets are solved".
Thanks to anyone who can help with this.