# projection Onto Plane.

``` BBS: Inland Empire Archive
Date: 05-06-92 (23:44)             Number: 149
From: DAVID BLISS                  Refer#: NONE
To: RICH GELDREICH                Recvd: NO
Subj: projection Onto Plane.         Conf: (2) Quik_Bas```
``` >     Lets say we have a four sided plane in 3-D space,
> like this:

>     x----x
>     !    !
>     !    !
>     !    !
>     x----x

>     Where each "x" has an X,Y, & Z coordinate. The
> plane could be in any
> position, not just what you see here.

>     What I need: The coordinate of a point which is
> perpendicular to
> this plane when a line is drawn threw it to the center
> of the plane. If
> that isn't hard enough, the point must also be a
> certain distance from
> the plane too(such as 64 units or so). I can easily

This is so amazingly simple <g> (no offense of course!).
To find X,Y,Z of the point you said (assuming i understand
you), assuming the plane has four corners 1-4 and X,Y,Z of
these are X1-4 Y1-4 and Z1-4 and the point you need is X5
Y5 Z5,

X5=(x1-x2)+(x3-x4)/2   or whichever corners are on same line
Y5=(y1-y2)+(y3-y4)/2   "    "          "     "   "   "    "
Z5=(z1+z2+z3+z4)/4+64

What this does, is find the middle of the left side of the
plane, then the middle of the top side, and then give you a
point 64 units above that point.  very simple geometry <bg>
but then i'm in very advanced math <g>

Hope this helps,
Dave

---
* Origin: The Aliens BBS, Simpsonville SC, 8032347195 (1:3639/4)
```

Echo Basic Postings

Books at Amazon:

Back to BASIC: The History, Corruption, and Future of the Language

Hackers: Heroes of the Computer Revolution (including Tiny BASIC)

Go to: The Story of the Math Majors, Bridge Players, Engineers, Chess Wizards, Scientists and Iconoclasts who were the Hero Programmers of the Software Revolution

The Advent of the Algorithm: The Idea that Rules the World

Moths in the Machine: The Power and Perils of Programming

Mastering Visual Basic .NET