creation of a circular plane passing through three nodes and for central node
Show older comments
Hi. I would like to generate a circular plane from three nodes + center nodes.
I'm using this code but I don't understand why a plane is generated that doesn't go through those three nodes (it only goes through the center node).
A = [28.9646 -21.3886 97.3614
23.1935 -19.9821 97.2254
27.9585 -16.222 95.2403];
A_mean = mean(A);
R = 5;
t = (0:359)';
a_A = A(1);
b_A = A(2);
c_A = A(3);
plane = R*[cosd(t),sind(t)]*null([a_A,b_A,c_A])' + A_mean(:)';
figure
plot3(A(:,1),A(:,2),A(:,3),'r.','Markersize',27);
hold on
plot3(A_mean(:,1),A_mean(:,2),A_mean(:,3),'r.','Markersize',27);
patch(plane(:,1),plane(:,2),plane(:,3),'k.');
hold off
axis equal

Accepted Answer
More Answers (0)
Categories
Find more on Creating and Concatenating Matrices in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!