# triangulation between two circles

조회 수: 4 (최근 30일)
Yu Li 2020년 4월 26일
편집: Yu Li 2020년 4월 26일
Hi:
I have two circiles which is constructed by points.
With the known coordinated of the points on these two circles respectively, is there anyway generate the triangulation information like figures shown below?
The goal is not to plot the lines that construct the triangles between two circles, I need the triangulation information, i.e. the connectivity that construct those triangles by the node ID.
which is very similiar with the output of function 'triangulation':
Thanks!
Yu

댓글을 달려면 로그인하십시오.

### 답변 (1개)

Image Analyst 2020년 4월 26일
Try this and adapt as needed:
numPoints = 50;
theta = linspace(0, 360, numPoints);
deltaTheta = (theta(2) - theta(1)) / 2
plot(xInner, yInner, 'r.-', 'MarkerSize', 15, 'LineWidth', 2);
hold on;
theta2 = theta + deltaTheta;
plot(xOuter, yOuter, 'r.-', 'MarkerSize', 15, 'LineWidth', 2);
% Plot lines between them
% Need [xinner(1), yInner(1);
% xOuter(1), yOuter(1);
% xinner(2), yInner(2);
% xOuter(2), yOuter(2);
% Interleave the arrays
row = 1;
for k = 1 : length(xInner)
xBoth(row) = xInner(k);
xBoth(row+1) = xOuter(k);
yBoth(row) = yInner(k);
yBoth(row+1) = yOuter(k);
row = row + 2;
end
plot(xBoth, yBoth, 'b-', 'LineWidth', 1);
axis('on', 'square');
grid on;
##### 댓글 수: 1이전 댓글 -1개 표시이전 댓글 -1개 숨기기
Yu Li 2020년 4월 26일
편집: Yu Li 2020년 4월 26일
Hi:
thanks for your reply. but I'm sorry, I did not describe my question clearly.
my goal is not to plot the triangle lines between two circles, I need the triangulation information, i.e.
1. the coordinate of each node (which is known infomation)
2. the connectivity that construct those triangles by the node ID.
which is very similiar with the output of function 'triangulation':
Thanks!
Yu

댓글을 달려면 로그인하십시오.

### 카테고리

Help CenterFile Exchange에서 Triangulation Representation에 대해 자세히 알아보기

### Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by