File: lorenz2.dem

package info (click to toggle)
scilab 2.4-1
  • links: PTS
  • area: non-free
  • in suites: potato, slink
  • size: 55,196 kB
  • ctags: 38,019
  • sloc: ansic: 231,970; fortran: 148,976; tcl: 7,099; makefile: 4,585; sh: 2,978; csh: 154; cpp: 101; asm: 39; sed: 5
file content (39 lines) | stat: -rw-r--r-- 796 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
kp=xget("pixmap");
// Copyright INRIA
dr=driver()
driver('X11')
if kp==0, xset("pixmap",1);end;

m=228;
n = fix(3/8*m);
r = [(1:n)'/n; ones(m-n,1)];
g = [zeros(n,1); (1:n)'/n; ones(m-2*n,1)];
b = [zeros(2*n,1); (1:m-2*n)'/(m-2*n)];
h = [r g b];
r1=[(1:m)'/m];g1=zeros(r1);b1=g1;
h1=[r1 g1 b1];
h2=[r1 r1 r1];
xset('colormap',h);

lpat=xget("lastpattern");
wid=30
N=2000;
Max_v=50;
t=linspace(0,Max_v,N*wid);
y=ode(1.e-8*[1;1;1],0,t,'loren'); 
ds=xget("dashes");
param3d(y(1,:),y(2,:),y(3,:),60,45,'X@Y@Z',[2,4]);
xset('wwpc');
y1=y(1,:);y1=matrix(y1,wid,N);
y2=y(2,:);y2=matrix(y2,wid,N);
y3=y(3,:);y3=matrix(y3,wid,N);
clear y;
for i=1:N,
	param3d1(y1(:,i),y2(:,i),list(y3(:,i),lpat*i/N),60,45,...
	'X@Y@Z',[0,0]);
	xset("wshow");
end
if kp==0, xset("pixmap",0);end;
driver(dr)
xset('default')