|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?注册
x
本帖最后由 eecsseudl 于 2013-4-29 10:20 编辑
clc;
close all;
clear all;
t = 0:0.01:2*pi;
a = 5;
z = a*(1-sin(t));
b = 0.8;
c = 0.5*b;
d = 2;
x=a*(b*cos(t)-c*cos(d*t));
y=a*(b*sin(t)-c*sin(d*t));
figure;
plot(x,y);grid on
title('Heart');
axis square;
figure;
polar(t,z);
ra = 10;
r = a*t;
scale_1 = 1:315;
figure;
polar(t(scale_1),r(scale_1),'r');axis off
t2 = 2*pi:-0.01:0;
r2 = a*t2;
scale_start = 315;
hold on
polar(t(scale_start:end),r2(scale_start:end),'r');axis off
az = 270;
el = 90;
view(az, el);
|
|