9 Nisan 2010 Cuma

Matlab'de size() ve axis() Örneği

m9

%www.ethemsulan.com
close all
clear all
clc
axis([-100 180 -100 100]);
hold on 
ob_1=[10 10 20 20
    20 10 10 20
    1 1 1 1];
t=0:0.01:2*pi;
x=5*sin(t)+15;
y=5*cos(t)+20;
ob_2=[x;y;ones(1,size(x,2))];
plot(ob_1(1,:),ob_1(2,:),'linewidth',3);
hold on
plot(x,y,'linewidth',3,'color','red')
a=6;
b=3;
S=[1 2.6 0;
   2 1 0;
   0 0 1]
ob_1_new=S*ob_1
ob_2_new=S*ob_2
plot(ob_1_new(1,:),ob_1_new(2,:))
hold on
plot(ob_2_new(1,:),ob_2_new(2,:))

Hiç yorum yok:

Yorum Gönder