?? brownian.m
字號(hào):
% BROWNIAN Two-dimensional random walk.
% What is the expansion rate of the cloud of particles?
shg
clf
set(gcf,'doublebuffer','on')
delta = .002;
x = zeros(100,2);
h = plot(x(:,1),x(:,2),'.');
axis([-1 1 -1 1])
axis square
stop = uicontrol('style','toggle','string','stop');
while get(stop,'value') == 0
x = x + delta*randn(size(x));
set(h,'xdata',x(:,1),'ydata',x(:,2))
drawnow
end
set(stop,'string','close','value',0,'callback','close(gcf)')
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -