:






MatLab


MatLab 2 :

logspace(x1, x2) [x1, x2] ;

loglog(x,y(x)) y(x) . plot.

, :

x=logspace(?1,3);

loglog(x,exp(x)./x);

grid on

 

, , . ϳ , :

semilogx(x, y) y(x) 10 y;

semilogy(x, y) y(x) 10 y x.

, y(x) = exp(x) / x : , . ,

subplot (3,1,1);

hc1=loglog(x,exp(x)./x);

grid on;

set (hc1,Color,[0,0,0],LineWidth,2);

subplot (3,1,2);

hc2=semilogx(x,exp(x)./x);

set (hc2,Color,[0,0,0],LineWidth,2);

grid on;

subplot (3,1,3);

hc3=semilogy(x,exp(x)./x);

set (hc3,Color,[0,0,0],LineWidth,2)

grid on;


. bar . , bar(x, y) , , . ex/2 [2,9; 2,9] 0,2.

x=-2.9:0.2:2.9;

hc=bar(x,exp(?x.*x));

get (hc)

CData = [ (4 by 30) double array]

CDataMapping = scaled

FaceVertexCData = [ (151 by 1) double array]

EdgeColor = [0 0 0]

EraseMode = normal

FaceColor = flat

Faces = [ (30 by 4) double array]

LineStyle = ?

LineWidth = [0.5]

Marker = none

MarkerEdgeColor = auto

MarkerFaceColor = none

MarkerSize = [6]

Vertices = [ (151 by 2) double array]

XData = [ (4 by 30) double array]

YData = [ (4 by 30) double array]

ZData = []

FaceLighting = flat

EdgeLighting = none

BackFaceLighting = reverselit

AmbientStrength = [0.3]

DiffuseStrength = [0.6]

SpecularStrength = [0.9]

SpecularExponent = [10]

SpecularColorReflectance = [1]

VertexNormals = [ (151 by 3) double array]

NormalMode = auto

ButtonDownFcn =

Children = []

Clipping = on

CreateFcn =

DeleteFcn =

BusyAction = queue

HandleVisibility = on

HitTest = on

Interruptible = on

Parent = [72.0009]

Selected = off

SelectionHighlight = on

Tag =

Type = patch

UIContextMenu = []

UserData = []

Visible = on

set (hc,FaceColor,black);

title(y(x) = exp(x^2));

xlabel ( );

ylabel ( );

 

. hist :

hist(y, x)

y , , , y, y . , hist 䳿: y(x) = exp(x2) , . 䳿 hist :

v = hist(y, x)

v .

, randn.

x=-3:0.2:3;

y=randn(1000,1);

hist(y,x);

grid on

h=hist(y,x)

Columns 1 through 12

0 0 3 7 8 9 11 23 33 43 57 55

Columns 13 through 24

70 62 83 93 68 70 65 41 35 27 21

Columns 25 through 31

12 5 6 3 2 1 0

 

randn 1000 [3; 3]. .

 

. , , , :

x=?3:0.2:3;

y=randn(1e6,1);

hist(y,x);

grid on

 

, . , . MatLab stairs. :

stairs(y) . ;

stairs(y, x) (), .

 

x=0:0.1*pi:4*pi;

y=sin(x);

hc=stairs(y,x);

set (ch,Color,[0,0,0],LineWidth,2);

 

, .

subplot(2,1,1);

x=0:0.01*pi:4*pi;

y=sin(x);

ch=stairs(x,y);

grid on

set (ch,Color,[0,0,0],LineWidth,2);

v=title(???? 0.01*pi);

set (v,FontName,@Arial Unicode MS, Font-Size,12);

subplot(2,1,2);

x=0:0.3*pi:4*pi;

y=sin(x);

ch=stairs(x,y);

grid on

set (ch,Color,[0,0,0],LineWidth,2);

v=title( ???? 0.01*pi);

set (v,FontName,@Arial Unicode MS, Font?Size,12);

 

, , MatLab plot , . , - . MatLab stairs , , ,



: 2016-06-09

headinsider.info. .