Defining a plane using only 2 points (and an axis)

Suppose you have a $3$-dimensional space in which there are 2 points ($A$ and $B$) defined (non identical). Now, you can define a line that goes through them but you cannot define a unique plane, because there are infinitely many planes that are rotating along that line.

Now, I've been having trouble defining the following in strict mathematical terms. That's also why I'm asking here, so you'll have to forgive me for being vague or imprecise.

Suppose that you also chose one axis towards which you want the plane to lay 'flat'. Imagine you model this using table and a piece of paper. The axis along the table are $X$ and $Y$ and the axis up is $Z$. You can rotate the paper along two imaginary points, but at one point it would lay flattest towards your $Z$ axis. There would be a clean slope from one point to the other.

How would you figure out the equation of this plane which would be defined using only two points and an 'flatness axis' (for my lack of better words). My thoughts led me towards using a third point ($C$) which would form a vector ($AC$) perpendicular to the vector ($AB$) where the $Z$ coordinate of point $C$ would be the same as point's $A$. Maybe.

And how would you generalize it to $n$-dimensional cases? (2 points, one flatness axis)

EDIT:

I have managed to reduce my problem to the following question: I have a vector $\vec n$ and $\vec m$. I want to find vector $\vec o$, which is perpendicular to the vector $\vec n$ and lies on the plane defined using vectors $\vec n$ and $\vec m$.

• I don't understand what you mean. Do you mean that the axis lies inside the plane? Or is the axis (described by a vector) parallel to the plane? – MrYouMath Mar 24 '18 at 15:25
• Your problem is to describe the plane equation in general? – user Mar 24 '18 at 15:29
• Yes. What I want to get is a plane equation. I have a point A (let's say [1, 1, 0]) and B=[2, 2, 1] and axis of reference (Z in this example) What I want is a equation for a plane in the form Z=a+bX+cY – JonnyRobbie Mar 24 '18 at 15:39
• It's hard to tell if it's what you mean, but you can add the vector describing the axis to one of your points to get a third point (unless the line described by the two points you started with are parallel to the axis), those three points describe a plane that is parallel to the given axis. – Henrik Mar 24 '18 at 15:46
• I've tried explaining it with the table example. you can play around with the paper and rotate it as you want (given two points), but there is one rotation of the paper, which makes it 'as flat as possible' with the respect to 'up'. – JonnyRobbie Mar 24 '18 at 15:55

What you (probably) need (your question is not so clear) is the equation of a plane passing through two given points $A$ and $B$ and parallel to a given line $r$.

If you know a direction vector $\vec r$ of the line, then the vector $$\vec n= (B-A)\times \vec r$$ is perpendicular to the requested plane, whose equation is then $$n_x x+n_y y+n_z z=n_x x_A+n_y y_A+n_z z_A.$$

EDIT.

A vector $o⃗$, which is perpendicular to vector $n⃗$ and lies on the plane defined by vectors $n⃗$ and $m⃗$ can be computed as follows: $$\vec o = \vec n\times(\vec n\times\vec m)= \vec n\,(\vec n\cdot\vec m)-\vec m\,(\vec n\cdot\vec n).$$

This 'flatness axis' is usually called 'normal vector'. It is perpendicular to the plane. Let's call it $\vec{n} = [a, b, c]$. Then we need only one point $P_0 = [x_0, y_0, z_0]$ together with the normal vector to define the plane. For an arbitrary point P on the plane, the vector $\vec{P} - \vec{P_0}$ must be perpendicular to $\vec{n}$. It means that the dot product must be zero $(\vec{P} - \vec{P_0})\cdot\vec{n} = 0$. And here comes the equation:$$(x - x_0)\cdot a + (y - y_0)\cdot b + (z - z_0)\cdot c = 0$$

• That's why gave it quotes. It's not a normal vector. It's an axis, (ie. vector [0, 0, 1]) and that cannot be a normal vector in a general case. But it's 'as flat as possible'...kinda. – JonnyRobbie Mar 24 '18 at 16:47
• If I see now. As far as I understand the 'flatness axis' should lay in the same plane. Then you can find the normal vector using the cross product of the vector between the two points and the axis: $\vec{n} = \vec{AB}\times\vec{f}$ . After that, you can continue as above to find the equation of the plane. – user543143 Mar 24 '18 at 20:49

Given $P$ and $Q$ it suffices consider the infinitely many vectors $\vec n=(a,b,c)$ orthogonal to $P-Q$ then the plane equation is

$$ax+by+cz+d=0$$

and $d$ can be found by the condition that $P$ (or $Q$) belongs to the plane.