Find the intersection of a line with a plane: Difference between revisions

Content added Content deleted
(add REXX)
m (→‎{{header|REXX}}: disclaimer for line being parallel to or within the plane)
Line 103: Line 103:


=={{header|REXX}}==
=={{header|REXX}}==
This program does NOT handle the case when the line is parallel to or within the plane.
<lang rexx>/* REXX */
<lang rexx>/* REXX */
Parse Value '0 0 1' With n.1 n.2 n.3 /* Normal Vector of the plane */
Parse Value '0 0 1' With n.1 n.2 n.3 /* Normal Vector of the plane */
Line 124: Line 125:
{{out}}
{{out}}
<pre>0*x + 0*y + 1*z = 5
<pre>0*x + 0*y + 1*z = 5
Intersection: P(0,-5,5)</pre>
Intersection: P(0,-5,5)</pre>


=={{header|Sidef}}==
=={{header|Sidef}}==