Code:
clc
clear all
close all
figure;
pause(3);
axis square;
t=0:2*pi/3:2*pi;
x=5*cos(t);
y=5*sin(t);
pause(1);
axis square;
hold on;
for i=1:11
m=(x(1)+x(2))/2;
n=(x(2)+x(3))/2;
o=(x(3)+x(4))/2;
p=(y(1)+y(2))/2;
q=(y(2)+y(3))/2;
r=(y(3)+y(4))/2;
plot([m n o m],[p q r p]);
hold on;
pause(1);
axis square;
x=[m n o m];
y=[p q r p];
end
clc
clear all
close all
figure;
pause(3);
axis square;
t=0:2*pi/3:2*pi;
x=5*cos(t);
y=5*sin(t);
pause(1);
axis square;
hold on;
for i=1:11
m=(x(1)+x(2))/2;
n=(x(2)+x(3))/2;
o=(x(3)+x(4))/2;
p=(y(1)+y(2))/2;
q=(y(2)+y(3))/2;
r=(y(3)+y(4))/2;
plot([m n o m],[p q r p]);
hold on;
pause(1);
axis square;
x=[m n o m];
y=[p q r p];
end
Triangles inside triangles | MATLAB video editing software free | |
1 Likes | 1 Dislikes |
17 views views | 1.03K followers |
Science & Technology | Upload TimePublished on 9 Oct 2019 |
Không có nhận xét nào:
Đăng nhận xét