POV-Ray : Newsgroups : povray.general : 3d math - line intersecting a plane : Re: 3d math - line intersecting a plane Server Time
19 Nov 2024 03:48:09 EST (-0500)
  Re: 3d math - line intersecting a plane  
From: Slime
Date: 11 May 2002 15:14:53
Message: <3cdd6dad$1@news.povray.org>
Take the equation of the plane and the equation of the line
(parametrically), and solve them as a system of equations.

For instance...

plane: 2x +4y +5z = 0
line:
x=t
y=2t
z=3t+5

then you plug in x y and z into the plane's equation, and solve for t...

2*t + 4*2*t + 5*3*t + 5*5 = 0
25*t = -25
t = -1

then, once you know t, just plug it in to the line's equation to find the
point of intersection:

x = -1
y = 2*-1 = -2
z = 3*-1 + 5 = 5 - 3 = 2

so the intersection is at <-1,-2,2>. Unless I messed something up, which is
entirely possible...

 - Slime
[ http://www.slimeland.com/ ]


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.