- #1
sparkzbarca
- 7
- 0
So i know the equation of a plane.
Ax + By +Cz = D
Normal is the normal vector to the plane.
A = normal.x
B = normal.y
C = normal.z
p1 and p2 are 2 points on the line (which will intercept a plane at some point)
the .x and .y and .z refer to there respective components of the vector.
X = (p2.x - p1.x)* T + p1.x
Y = (p2.y - p1.y)* T + p1.y
Z = (p2.z - p1.z)* T + p1.z
I also know what D equals I solved for that by moving stuff around
The problem is a need a general solution for T.
It should be something like
A ((p2.x - p1.x) * T + p1.x)) + B ((p2.y - p1.y) * T + p1.y)) + C ((p2.z - p1.z) * T + p1.z)) = D
Except isolated for T (I believe)
In case your curious this is for a programming function. Thats why I'm using nothing but variables.
I can solve for every equation but T, while I can solve for T by myself given specific numbers I am not sure how to isolate it even if I expand out the equation to stuff like
Ap2.x - Ap1.x * AT + Ap1.x ...
I'm thinking maybe I am going down the wrong path here or something.
Any help would be much appreciated. :)
Ax + By +Cz = D
Normal is the normal vector to the plane.
A = normal.x
B = normal.y
C = normal.z
p1 and p2 are 2 points on the line (which will intercept a plane at some point)
the .x and .y and .z refer to there respective components of the vector.
X = (p2.x - p1.x)* T + p1.x
Y = (p2.y - p1.y)* T + p1.y
Z = (p2.z - p1.z)* T + p1.z
I also know what D equals I solved for that by moving stuff around
The problem is a need a general solution for T.
It should be something like
A ((p2.x - p1.x) * T + p1.x)) + B ((p2.y - p1.y) * T + p1.y)) + C ((p2.z - p1.z) * T + p1.z)) = D
Except isolated for T (I believe)
In case your curious this is for a programming function. Thats why I'm using nothing but variables.
I can solve for every equation but T, while I can solve for T by myself given specific numbers I am not sure how to isolate it even if I expand out the equation to stuff like
Ap2.x - Ap1.x * AT + Ap1.x ...
I'm thinking maybe I am going down the wrong path here or something.
Any help would be much appreciated. :)