Perpendicular planes in Matlab figure

  • MATLAB
  • Thread starter tonic
  • Start date
  • #1
1
0
I've got a problem with perpendicular planes in Matlab.

I start with a plane A and a point P in A. I calculate a plane B perpendicular to A through point P. Equation plane A: -21660x + 1036y + 4669z = 9.22e6
Point P: [129, 46, -1925]
If [a,b,c] is the normal vector of plane B, I choose b = 0.5 and c = 1, then calculate a by assuming the dot product of the normal vectors should be zero. This results in a = 2.4
Substituting point P in the formula of B gives me d = 1593.

To check if these planes are perpendicular and both cross point P, I plotted them in Matlab.
Code:
X=0:350; Y=0:300;
[X,Y]=meshgrid(X,Y);
Z = (-d-a*X-b*Y)/c;
mesh(X,Y,Z)

i46.tinypic.com/24yu842.jpg

Now these planes do not seem perpendicular to me. (They do both cross point P, not shown in the image).

Where do I make a mistake?
 

Answers and Replies

Related Threads on Perpendicular planes in Matlab figure

  • Last Post
Replies
4
Views
1K
  • Last Post
Replies
1
Views
745
  • Last Post
Replies
5
Views
5K
Replies
1
Views
3K
  • Last Post
Replies
3
Views
11K
Replies
1
Views
7K
Replies
4
Views
2K
  • Last Post
Replies
7
Views
14K
Replies
2
Views
3K
Replies
7
Views
90K
Top