summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--scilab/CHANGES_5.2.X2
-rw-r--r--scilab/modules/compatibility_functions/macros/%b_g_s.sci13
-rw-r--r--scilab/modules/compatibility_functions/macros/%b_h_s.sci13
-rw-r--r--scilab/modules/compatibility_functions/macros/%s_g_b.sci13
-rw-r--r--scilab/modules/compatibility_functions/macros/%s_h_b.sci13
-rw-r--r--scilab/modules/differential_equations/demos/bike/bike1.dem.sce6
-rw-r--r--scilab/modules/differential_equations/demos/bike/bike2.dem.sce6
-rw-r--r--scilab/modules/differential_equations/demos/bike/macros/bike_show.sci (renamed from scilab/modules/differential_equations/demos/bike/macros/show.sci)4
-rw-r--r--scilab/modules/differential_equations/demos/wheel/Readme.txt2
-rw-r--r--scilab/modules/differential_equations/demos/wheel/wheel1.dem.sce6
-rw-r--r--scilab/modules/differential_equations/demos/wheel/wheel2.dem.sce6
-rw-r--r--scilab/modules/differential_equations/demos/wheel/wheel_show.sci (renamed from scilab/modules/differential_equations/demos/wheel/show.sci)2
-rw-r--r--scilab/modules/overloading/macros/%r_p.sci8
-rw-r--r--scilab/modules/scicos/demos/anim_pen.sci46
-rw-r--r--scilab/modules/scicos/demos/go_pend_5.sci4
-rw-r--r--scilab/modules/scicos/demos/inv_pend_anim.dem.sce11
-rw-r--r--scilab/modules/scicos/demos/inverted_pendulum.dem.sce9
-rw-r--r--scilab/modules/scicos/demos/scicos.dem2
-rw-r--r--scilab/modules/scicos/demos/setw.sci9
-rw-r--r--scilab/modules/scicos/macros/scicos_utils/readc_.sci35
-rw-r--r--scilab/modules/scicos/tests/unit_tests/PENDULUM_ANIM.sci2
-rw-r--r--scilab/modules/scicos/tests/unit_tests/anim_pen.sci46
-rw-r--r--scilab/modules/scicos/tests/unit_tests/lincos.dia.ref4
-rw-r--r--scilab/modules/scicos/tests/unit_tests/lincos.tst6
-rw-r--r--scilab/modules/scicos/tests/unit_tests/steadycos.dia.ref4
-rw-r--r--scilab/modules/scicos/tests/unit_tests/steadycos.tst6
-rw-r--r--scilab/modules/signal_processing/macros/wfir.sci12
-rw-r--r--scilab/modules/texmacs/macros/overloading/%r_p.sci12
-rw-r--r--scilab/modules/xcos/demos/inv_pend_anim.dem.sce9
-rw-r--r--scilab/modules/xcos/demos/inverted_pendulum.dem.sce7
30 files changed, 58 insertions, 260 deletions
diff --git a/scilab/CHANGES_5.2.X b/scilab/CHANGES_5.2.X
index 58a5e48..bb60f7c 100644
--- a/scilab/CHANGES_5.2.X
+++ b/scilab/CHANGES_5.2.X
@@ -85,6 +85,8 @@ Bug fixes:
85 85
86* bug 5330 fixed - "help str1 str2" returned a error. 86* bug 5330 fixed - "help str1 str2" returned a error.
87 87
88* bug 5339 fixed - some macros had multiple definitions.
89
88 Changes between version 5.1.1 and 5.2.0-beta1 of Scilab 90 Changes between version 5.1.1 and 5.2.0-beta1 of Scilab
89 ======================================================= 91 =======================================================
90 92
diff --git a/scilab/modules/compatibility_functions/macros/%b_g_s.sci b/scilab/modules/compatibility_functions/macros/%b_g_s.sci
deleted file mode 100644
index 84c4526..0000000
--- a/scilab/modules/compatibility_functions/macros/%b_g_s.sci
+++ /dev/null
@@ -1,13 +0,0 @@
1// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
2// Copyright (C) ???? - INRIA - Scilab
3//
4// This file must be used under the terms of the CeCILL.
5// This source file is licensed as described in the file COPYING, which
6// you should have received as part of this distribution. The terms
7// are also available at
8// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
9
10function r=%b_g_s(a,b)
11// r=a|b
12r=a|(b<>0)
13endfunction
diff --git a/scilab/modules/compatibility_functions/macros/%b_h_s.sci b/scilab/modules/compatibility_functions/macros/%b_h_s.sci
deleted file mode 100644
index 3c4f1a4..0000000
--- a/scilab/modules/compatibility_functions/macros/%b_h_s.sci
+++ /dev/null
@@ -1,13 +0,0 @@
1// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
2// Copyright (C) ???? - INRIA - Scilab
3//
4// This file must be used under the terms of the CeCILL.
5// This source file is licensed as described in the file COPYING, which
6// you should have received as part of this distribution. The terms
7// are also available at
8// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
9
10function r=%b_h_s(a,b)
11// r=a&b
12r=a&(b<>0)
13endfunction
diff --git a/scilab/modules/compatibility_functions/macros/%s_g_b.sci b/scilab/modules/compatibility_functions/macros/%s_g_b.sci
deleted file mode 100644
index 068bed7..0000000
--- a/scilab/modules/compatibility_functions/macros/%s_g_b.sci
+++ /dev/null
@@ -1,13 +0,0 @@
1// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
2// Copyright (C) ???? - INRIA - Scilab
3//
4// This file must be used under the terms of the CeCILL.
5// This source file is licensed as described in the file COPYING, which
6// you should have received as part of this distribution. The terms
7// are also available at
8// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
9
10function r=%s_g_b(a,b)
11// r=a|b
12r=(a<>0)|b
13endfunction
diff --git a/scilab/modules/compatibility_functions/macros/%s_h_b.sci b/scilab/modules/compatibility_functions/macros/%s_h_b.sci
deleted file mode 100644
index 75ff9b1..0000000
--- a/scilab/modules/compatibility_functions/macros/%s_h_b.sci
+++ /dev/null
@@ -1,13 +0,0 @@
1// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
2// Copyright (C) ???? - INRIA - Scilab
3//
4// This file must be used under the terms of the CeCILL.
5// This source file is licensed as described in the file COPYING, which
6// you should have received as part of this distribution. The terms
7// are also available at
8// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
9
10function r=%s_h_b(a,b)
11// r=a&b
12r=(a<>0)&b
13endfunction
diff --git a/scilab/modules/differential_equations/demos/bike/bike1.dem.sce b/scilab/modules/differential_equations/demos/bike/bike1.dem.sce
index b708e72..b5c65b6 100644
--- a/scilab/modules/differential_equations/demos/bike/bike1.dem.sce
+++ b/scilab/modules/differential_equations/demos/bike/bike1.dem.sce
@@ -7,7 +7,7 @@
7 7
8thispath = get_absolute_file_path("bike1.dem.sce"); 8thispath = get_absolute_file_path("bike1.dem.sce");
9 9
10exec(thispath+"macros/show.sci"); 10exec(thispath+"macros/bike_show.sci");
11exec(thispath+"macros/velod.sci"); 11exec(thispath+"macros/velod.sci");
12exec(thispath+"macros/velodp.sci"); 12exec(thispath+"macros/velodp.sci");
13exec(thispath+"macros/velo2.sci"); 13exec(thispath+"macros/velo2.sci");
@@ -17,7 +17,7 @@ x = read(thispath+"data/x1.dat",46,368,"(e10.4)");
17my_handle = scf(100001); 17my_handle = scf(100001);
18clf(my_handle,"reset"); 18clf(my_handle,"reset");
19 19
20show(x(:,300:368),1,1,velo4p); 20bike_show(x(:,300:368),1,1,velo4p);
21 21
22// Clear variable and functions 22// Clear variable and functions
23clear x show get_velo_rti velo1 velo4p poteau arbre velodp velod; 23clear x bike_show get_velo_rti velo1 velo4p poteau arbre velodp velod;
diff --git a/scilab/modules/differential_equations/demos/bike/bike2.dem.sce b/scilab/modules/differential_equations/demos/bike/bike2.dem.sce
index f339a7f..6a2e1af 100644
--- a/scilab/modules/differential_equations/demos/bike/bike2.dem.sce
+++ b/scilab/modules/differential_equations/demos/bike/bike2.dem.sce
@@ -7,7 +7,7 @@
7 7
8thispath = get_absolute_file_path("bike2.dem.sce"); 8thispath = get_absolute_file_path("bike2.dem.sce");
9 9
10exec(thispath+"macros/show.sci"); 10exec(thispath+"macros/bike_show.sci");
11exec(thispath+"macros/velod.sci"); 11exec(thispath+"macros/velod.sci");
12exec(thispath+"macros/velo1.sci"); 12exec(thispath+"macros/velo1.sci");
13 13
@@ -16,8 +16,8 @@ x = read(thispath+"data/xdemo.dat",46,401,"(e10.4)");
16my_handle = scf(100001); 16my_handle = scf(100001);
17clf(my_handle,"reset"); 17clf(my_handle,"reset");
18 18
19show(x(:,1:340),1.6,1.47,velo1); 19bike_show(x(:,1:340),1.6,1.47,velo1);
20 20
21// Clear variable and functions 21// Clear variable and functions
22clear my_axe x; 22clear my_axe x;
23clear show get_velo_rti velo1 velo4p poteau arbre velodp velod; 23clear bike_show get_velo_rti velo1 velo4p poteau arbre velodp velod;
diff --git a/scilab/modules/differential_equations/demos/bike/macros/show.sci b/scilab/modules/differential_equations/demos/bike/macros/bike_show.sci
index 97759d3..d51825b 100644
--- a/scilab/modules/differential_equations/demos/bike/macros/show.sci
+++ b/scilab/modules/differential_equations/demos/bike/macros/bike_show.sci
@@ -5,8 +5,8 @@
5// This file is distributed under the same license as the Scilab package. 5// This file is distributed under the same license as the Scilab package.
6// 6//
7 7
8function []=show(xx,t,p,f_name) 8function []=bike_show(xx,t,p,f_name)
9//[]=show(xx,t,p,[f_name]) 9//[]=bike_show(xx,t,p,[f_name])
10// Just show the bike evolution 10// Just show the bike evolution
11// t and p are the spherical angles of the observation point 11// t and p are the spherical angles of the observation point
12// given in radian 12// given in radian
diff --git a/scilab/modules/differential_equations/demos/wheel/Readme.txt b/scilab/modules/differential_equations/demos/wheel/Readme.txt
index 1dbf1a8..294a3a4 100644
--- a/scilab/modules/differential_equations/demos/wheel/Readme.txt
+++ b/scilab/modules/differential_equations/demos/wheel/Readme.txt
@@ -7,7 +7,7 @@ To run the demo (assuming that your working directory is SCIDIR/demos/wheel2);
73. Enter the command "show(x)" in Scilab for plotting the wheel. 73. Enter the command "show(x)" in Scilab for plotting the wheel.
8 8
9Also you can use the macro wheel (file "wheel.sci") to compute x and 9Also you can use the macro wheel (file "wheel.sci") to compute x and
10plot the results by the macro show (file "show.sci"). 10plot the results by the macro show (file "wheel_show.sci").
11 11
12The fortran files (bigmat.f, constr.f, inigrd.f) are automatically 12The fortran files (bigmat.f, constr.f, inigrd.f) are automatically
13generated by Maple: Invoke Maple and input the command `read roue.ex`: 13generated by Maple: Invoke Maple and input the command `read roue.ex`:
diff --git a/scilab/modules/differential_equations/demos/wheel/wheel1.dem.sce b/scilab/modules/differential_equations/demos/wheel/wheel1.dem.sce
index a531ca1..e3d97be 100644
--- a/scilab/modules/differential_equations/demos/wheel/wheel1.dem.sce
+++ b/scilab/modules/differential_equations/demos/wheel/wheel1.dem.sce
@@ -14,12 +14,12 @@ clf(my_handle,"reset");
14// A precomputed value for 14// A precomputed value for
15// x0=[0;%pi/2+0.1;0;5.0;0.0;4.0;0;0]; 15// x0=[0;%pi/2+0.1;0;5.0;0.0;4.0;0;0];
16 16
17exec(thispath+"show.sci"); 17exec(thispath+"wheel_show.sci");
18x=read(thispath+"x.wrt",8,301); 18x=read(thispath+"x.wrt",8,301);
19 19
20wheelg=wheelgs; 20wheelg=wheelgs;
21show(x); 21wheel_show(x);
22 22
23// Clear variable and functions 23// Clear variable and functions
24clear wheelg wheelgs; 24clear wheelg wheelgs;
25clear show wheeld test_wheel wheel_build_and_load get_wheel_rti; 25clear wheel_show wheeld test_wheel wheel_build_and_load get_wheel_rti;
diff --git a/scilab/modules/differential_equations/demos/wheel/wheel2.dem.sce b/scilab/modules/differential_equations/demos/wheel/wheel2.dem.sce
index b1bd5cf..7db14b3 100644
--- a/scilab/modules/differential_equations/demos/wheel/wheel2.dem.sce
+++ b/scilab/modules/differential_equations/demos/wheel/wheel2.dem.sce
@@ -11,7 +11,7 @@ thispath = get_absolute_file_path("wheel2.dem.sce");
11my_handle = scf(100001); 11my_handle = scf(100001);
12clf(my_handle,"reset"); 12clf(my_handle,"reset");
13 13
14exec(thispath+"show.sci"); 14exec(thispath+"wheel_show.sci");
15 15
16if ~(haveacompiler()) then 16if ~(haveacompiler()) then
17 messagebox(["Scilab doesn''t find a C compiler","This demo is disabled"],"modal"); 17 messagebox(["Scilab doesn''t find a C compiler","This demo is disabled"],"modal");
@@ -44,7 +44,7 @@ x0=[0; // theta
44x=ode(x0,tmin,times,"wheel"); 44x=ode(x0,tmin,times,"wheel");
45 45
46clf(my_handle,"reset"); 46clf(my_handle,"reset");
47show(x); 47wheel_show(x);
48 48
49ystr = [ 'phi';'theta';'psi';'Dpsi';'Dtheta';'Dpsi';'x';'y']; 49ystr = [ 'phi';'theta';'psi';'Dpsi';'Dtheta';'Dpsi';'x';'y'];
50flag = 2; 50flag = 2;
@@ -64,4 +64,4 @@ end
64// ========================================================================= 64// =========================================================================
65 65
66clear wheelg wheelgf tmin tmax nn times x0 x ystr flag; 66clear wheelg wheelgf tmin tmax nn times x0 x ystr flag;
67clear show wheeld test_wheel wheel_build_and_load get_wheel_rti; 67clear wheel_show wheeld test_wheel wheel_build_and_load get_wheel_rti;
diff --git a/scilab/modules/differential_equations/demos/wheel/show.sci b/scilab/modules/differential_equations/demos/wheel/wheel_show.sci
index fee8fd2..516d537 100644
--- a/scilab/modules/differential_equations/demos/wheel/show.sci
+++ b/scilab/modules/differential_equations/demos/wheel/wheel_show.sci
@@ -6,7 +6,7 @@
6// This file is distributed under the same license as the Scilab package. 6// This file is distributed under the same license as the Scilab package.
7// 7//
8 8
9function []=show(xx,t,p) 9function []=wheel_show(xx,t,p)
10 10
11 //[]=show(xx,t,p) 11 //[]=show(xx,t,p)
12 // Just show the wheel evolution 12 // Just show the wheel evolution
diff --git a/scilab/modules/overloading/macros/%r_p.sci b/scilab/modules/overloading/macros/%r_p.sci
index ee8142f..420dc24 100644
--- a/scilab/modules/overloading/macros/%r_p.sci
+++ b/scilab/modules/overloading/macros/%r_p.sci
@@ -8,6 +8,11 @@
8// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt 8// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
9 9
10function %r_p(h) 10function %r_p(h)
11
12if with_texmacs() then
13 texout(h);
14else
15
11//used to display rational fraction with complex coefficients 16//used to display rational fraction with complex coefficients
12//The real case is hard coded 17//The real case is hard coded
13if size(size(h),'*')>2 then 18if size(size(h),'*')>2 then
@@ -71,7 +76,10 @@ while %t
71 if width==[] then break,end 76 if width==[] then break,end
72end 77end
73 78
79end
80
74endfunction 81endfunction
82
75function txt=p2str(p) 83function txt=p2str(p)
76//form display of a single polynomial with complex coefficients 84//form display of a single polynomial with complex coefficients
77lparen='(' 85lparen='('
diff --git a/scilab/modules/scicos/demos/anim_pen.sci b/scilab/modules/scicos/demos/anim_pen.sci
deleted file mode 100644
index e90ec1a..0000000
--- a/scilab/modules/scicos/demos/anim_pen.sci
+++ /dev/null
@@ -1,46 +0,0 @@
1function [blocks] = anim_pen(blocks,flag)
2//** 7 Jan 2009 : updated for Scilab 5.x
3 win = 20000+curblock();
4 if flag<>4 then
5 H=scf(win)
6 end
7 xold = blocks.z
8 rpar = blocks.rpar
9 plen = rpar(1); csiz = rpar(2); phi = rpar(3);
10
11 //** INIT
12 if flag==4 then
13 H = scf(win)
14 clf(H)
15
16 Axe = H.children
17 Axe.data_bounds=rpar(4:7)
18 Axe.isoview='on'
19 S=[cos(phi),-sin(phi);sin(phi),cos(phi)]
20 XY=S*[rpar(4),rpar(5);-csiz/2,-csiz/2]
21
22 drawlater();
23 xsegs(XY(1,:),XY(2,:))
24 x=0; theta=0;
25 x1=x-csiz/2;x2=x+csiz/2;y1=-csiz/2;y2=csiz/2
26 XY=S*[x1 x2 x2 x1 x1;y1,y1,y2,y2,y1]
27 xpoly(XY(1,:),XY(2,:),"lines",1)
28 XY=S*[x,x+plen*sin(theta);0,0+plen*cos(theta)]
29 xsegs(XY(1,:),XY(2,:));
30 drawnow();
31
32 //** UPDATE
33 elseif flag==2 then
34 Axe = H.children
35 x = blocks.inptr(1)(1)
36 theta = blocks.inptr(2)(1)
37 drawlater();
38 XY=Axe.children(2).data' + [cos(phi)*(x-xold);sin(phi)*(x-xold)]*ones(1,5);
39 Axe.children(2).data=XY' ;
40 x1=x*cos(phi);y1=x*sin(phi) ;
41 XY=[x1,x1+plen*sin(theta);y1,y1+plen*cos(theta)] ;
42 Axe.children(1).data=XY' ;
43 blocks.z = x ;
44 drawnow();
45 end
46endfunction
diff --git a/scilab/modules/scicos/demos/go_pend_5.sci b/scilab/modules/scicos/demos/go_pend_5.sci
index 0b62abc..1d10b49 100644
--- a/scilab/modules/scicos/demos/go_pend_5.sci
+++ b/scilab/modules/scicos/demos/go_pend_5.sci
@@ -1,4 +1,4 @@
1getf PENDULUM_ANIM.sci 1exec("SCI/modules/xcos/demos/PENDULUM_ANIM.sci");
2getf anim_pen.sci 2exec("SCI/modules/xcos/demos/anim_pen.sci");
3scicos ("pendulum_anim45.cos"); 3scicos ("pendulum_anim45.cos");
4 4
diff --git a/scilab/modules/scicos/demos/inv_pend_anim.dem.sce b/scilab/modules/scicos/demos/inv_pend_anim.dem.sce
index ea23532..fbec6c8 100644
--- a/scilab/modules/scicos/demos/inv_pend_anim.dem.sce
+++ b/scilab/modules/scicos/demos/inv_pend_anim.dem.sce
@@ -5,12 +5,9 @@
5// This file is distributed under the same license as the Scilab package. 5// This file is distributed under the same license as the Scilab package.
6// 6//
7 7
8thispath = get_absolute_file_path("inv_pend_anim.dem.sce"); 8exec("SCI/modules/xcos/demos/PENDULUM_ANIM.sci");
9exec(thispath+"/PENDULUM_ANIM.sci"); 9exec("SCI/modules/xcos/demos/anim_pen.sci");
10exec(thispath+"/anim_pen.sci");
11
12//scicos_demostration(thispath+"/pendulum_anim5.cosf");
13 10
14// Open the cosf file with xcos 11// Open the cosf file with xcos
15xcos(thispath+"/pendulum_anim5.cosf"); 12xcos("SCI/modules/scicos/demos/pendulum_anim5.cosf");
16clear thispath; 13
diff --git a/scilab/modules/scicos/demos/inverted_pendulum.dem.sce b/scilab/modules/scicos/demos/inverted_pendulum.dem.sce
index 96b2e0a..bd3e619 100644
--- a/scilab/modules/scicos/demos/inverted_pendulum.dem.sce
+++ b/scilab/modules/scicos/demos/inverted_pendulum.dem.sce
@@ -5,11 +5,8 @@
5// This file is distributed under the same license as the Scilab package. 5// This file is distributed under the same license as the Scilab package.
6// 6//
7 7
8thispath = get_absolute_file_path("inverted_pendulum.dem.sce"); 8exec ("SCI/modules/xcos/demos/setw.sci");
9exec (thispath+"/setw.sci");
10
11//scicos_demostration(thispath+"/Inverted_pendulum.cosf");
12 9
13// Open the cosf file with xcos 10// Open the cosf file with xcos
14xcos(thispath+"/Inverted_pendulum.cosf"); 11xcos("SCI/modules/scicos/demos/Inverted_pendulum.cosf");
15clear thispath; 12
diff --git a/scilab/modules/scicos/demos/scicos.dem b/scilab/modules/scicos/demos/scicos.dem
index d0a1bf3..7795f64 100644
--- a/scilab/modules/scicos/demos/scicos.dem
+++ b/scilab/modules/scicos/demos/scicos.dem
@@ -41,7 +41,7 @@ while %t do
41 case 'Discrete-Kalman Filter' then 41 case 'Discrete-Kalman Filter' then
42 scicos('SCI/modules/scicos/demos/Discrete-KalmanFilter.cosf'); 42 scicos('SCI/modules/scicos/demos/Discrete-KalmanFilter.cosf');
43 case 'Inverted Pendulum' then 43 case 'Inverted Pendulum' then
44 exec (SCI+'/modules/scicos/demos/setw.sci'); 44 exec (SCI+'/modules/xcos/demos/setw.sci');
45 scicos('SCI/modules/scicos/demos/Inverted_pendulum.cos'); 45 scicos('SCI/modules/scicos/demos/Inverted_pendulum.cos');
46 case 'Lorentz attractor' then 46 case 'Lorentz attractor' then
47 scicos('SCI/modules/scicos/demos/Lorentz.cos'); 47 scicos('SCI/modules/scicos/demos/Lorentz.cos');
diff --git a/scilab/modules/scicos/demos/setw.sci b/scilab/modules/scicos/demos/setw.sci
deleted file mode 100644
index f1f8eb6..0000000
--- a/scilab/modules/scicos/demos/setw.sci
+++ /dev/null
@@ -1,9 +0,0 @@
1function y=setw(x)
2 mu=size(x,1)
3 y(1:mu,1:mu)=0
4 for j=1:mu
5 for i=1:mu-j+1
6 y(i,j)=x(i+j-1)
7 end
8 end
9endfunction \ No newline at end of file
diff --git a/scilab/modules/scicos/macros/scicos_utils/readc_.sci b/scilab/modules/scicos/macros/scicos_utils/readc_.sci
deleted file mode 100644
index f70a6fc..0000000
--- a/scilab/modules/scicos/macros/scicos_utils/readc_.sci
+++ /dev/null
@@ -1,35 +0,0 @@
1// Scicos
2//
3// Copyright (C) INRIA - METALAU Project <scicos@inria.fr>
4//
5// This program is free software; you can redistribute it and/or modify
6// it under the terms of the GNU General Public License as published by
7// the Free Software Foundation; either version 2 of the License, or
8// (at your option) any later version.
9//
10// This program is distributed in the hope that it will be useful,
11// but WITHOUT ANY WARRANTY; without even the implied warranty of
12// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13// GNU General Public License for more details.
14//
15// You should have received a copy of the GNU General Public License
16// along with this program; if not, write to the Free Software
17// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
18//
19// See the file ./license.txt
20//
21
22function [c]=readc_(unit)
23//Syntaxes : c=readc_(unit)
24// c=readc_()
25//
26//readc_ reads a character string
27//This macro allows one to interrupt an exec file without pause;
28//the exec file stops until carrige return is made.
29//!
30//
31// Copyright INRIA
32[lhs,rhs]=argn(0);
33if rhs<=0 then unit=%io(1); end;
34c=read(unit,1,1,'(a)');
35endfunction
diff --git a/scilab/modules/scicos/tests/unit_tests/PENDULUM_ANIM.sci b/scilab/modules/scicos/tests/unit_tests/PENDULUM_ANIM.sci
index 2a8262a..133233c 100644
--- a/scilab/modules/scicos/tests/unit_tests/PENDULUM_ANIM.sci
+++ b/scilab/modules/scicos/tests/unit_tests/PENDULUM_ANIM.sci
@@ -16,7 +16,7 @@ function [x,y,typ]=PENDULUM_ANIM(job,arg1,arg2)
16 graphics=arg1.graphics;exprs=graphics.exprs 16 graphics=arg1.graphics;exprs=graphics.exprs
17 model=arg1.model;dstate=model.dstate 17 model=arg1.model;dstate=model.dstate
18 while %t do 18 while %t do
19 [ok,plen,csiz,phi,xmin,xmax,ymin,ymax,exprs]=getvalue(.. 19 [ok,plen,csiz,phi,xmin,xmax,ymin,ymax,exprs]=scicos_getvalue(..
20 'Set Scope parameters',.. 20 'Set Scope parameters',..
21 ['pendulum length';'cart size (square side)';'slope'; 21 ['pendulum length';'cart size (square side)';'slope';
22 'Xmin';'Xmax'; 'Ymin'; 'Ymax'; ],.. 22 'Xmin';'Xmax'; 'Ymin'; 'Ymax'; ],..
diff --git a/scilab/modules/scicos/tests/unit_tests/anim_pen.sci b/scilab/modules/scicos/tests/unit_tests/anim_pen.sci
deleted file mode 100644
index e90ec1a..0000000
--- a/scilab/modules/scicos/tests/unit_tests/anim_pen.sci
+++ /dev/null
@@ -1,46 +0,0 @@
1function [blocks] = anim_pen(blocks,flag)
2//** 7 Jan 2009 : updated for Scilab 5.x
3 win = 20000+curblock();
4 if flag<>4 then
5 H=scf(win)
6 end
7 xold = blocks.z
8 rpar = blocks.rpar
9 plen = rpar(1); csiz = rpar(2); phi = rpar(3);
10
11 //** INIT
12 if flag==4 then
13 H = scf(win)
14 clf(H)
15
16 Axe = H.children
17 Axe.data_bounds=rpar(4:7)
18 Axe.isoview='on'
19 S=[cos(phi),-sin(phi);sin(phi),cos(phi)]
20 XY=S*[rpar(4),rpar(5);-csiz/2,-csiz/2]
21
22 drawlater();
23 xsegs(XY(1,:),XY(2,:))
24 x=0; theta=0;
25 x1=x-csiz/2;x2=x+csiz/2;y1=-csiz/2;y2=csiz/2
26 XY=S*[x1 x2 x2 x1 x1;y1,y1,y2,y2,y1]
27 xpoly(XY(1,:),XY(2,:),"lines",1)
28 XY=S*[x,x+plen*sin(theta);0,0+plen*cos(theta)]
29 xsegs(XY(1,:),XY(2,:));
30 drawnow();
31
32 //** UPDATE
33 elseif flag==2 then
34 Axe = H.children
35 x = blocks.inptr(1)(1)
36 theta = blocks.inptr(2)(1)
37 drawlater();
38 XY=Axe.children(2).data' + [cos(phi)*(x-xold);sin(phi)*(x-xold)]*ones(1,5);
39 Axe.children(2).data=XY' ;
40 x1=x*cos(phi);y1=x*sin(phi) ;
41 XY=[x1,x1+plen*sin(theta);y1,y1+plen*cos(theta)] ;
42 Axe.children(1).data=XY' ;
43 blocks.z = x ;
44 drawnow();
45 end
46endfunction
diff --git a/scilab/modules/scicos/tests/unit_tests/lincos.dia.ref b/scilab/modules/scicos/tests/unit_tests/lincos.dia.ref
index 301491c..43f5df0 100644
--- a/scilab/modules/scicos/tests/unit_tests/lincos.dia.ref
+++ b/scilab/modules/scicos/tests/unit_tests/lincos.dia.ref
@@ -7,11 +7,11 @@
7// ============================================================================= 7// =============================================================================
8// <-- ENGLISH IMPOSED --> 8// <-- ENGLISH IMPOSED -->
9ilib_verbose(0); 9ilib_verbose(0);
10load(fullfile(SCI,'modules','scicos','tests','unit_tests','pendulum_anim45.cos')); 10load("SCI/modules/scicos/tests/unit_tests/pendulum_anim45.cos");
11M=10; 11M=10;
12m=3; 12m=3;
13l=3; 13l=3;
14ph=0.1; 14ph=0.1;
15scs_m = scs_m.objs(5).model.rpar; 15scs_m = scs_m.objs(5).model.rpar;
16[X,U,Y,XP] = steadycos(scs_m,[],[],[],[],1,1:$); 16[X,U,Y,XP] = steadycos(scs_m,[],[],[],[],1,1:$);
17 17
diff --git a/scilab/modules/scicos/tests/unit_tests/lincos.tst b/scilab/modules/scicos/tests/unit_tests/lincos.tst
index 8eab260..b9e0e13 100644
--- a/scilab/modules/scicos/tests/unit_tests/lincos.tst
+++ b/scilab/modules/scicos/tests/unit_tests/lincos.tst
@@ -9,9 +9,9 @@
9// <-- ENGLISH IMPOSED --> 9// <-- ENGLISH IMPOSED -->
10ilib_verbose(0); 10ilib_verbose(0);
11 11
12exec(fullfile(SCI,'modules','scicos','tests','unit_tests','PENDULUM_ANIM.sci')); 12exec("SCI/modules/xcos/demos/PENDULUM_ANIM.sci");
13exec(fullfile(SCI,'modules','scicos','tests','unit_tests','anim_pen.sci')); 13exec("SCI/modules/xcos/demos/anim_pen.sci");
14load(fullfile(SCI,'modules','scicos','tests','unit_tests','pendulum_anim45.cos')); 14load("SCI/modules/scicos/tests/unit_tests/pendulum_anim45.cos");
15M=10; 15M=10;
16m=3; 16m=3;
17l=3; 17l=3;
diff --git a/scilab/modules/scicos/tests/unit_tests/steadycos.dia.ref b/scilab/modules/scicos/tests/unit_tests/steadycos.dia.ref
index 5e42a77..239ab9e 100644
--- a/scilab/modules/scicos/tests/unit_tests/steadycos.dia.ref
+++ b/scilab/modules/scicos/tests/unit_tests/steadycos.dia.ref
@@ -7,11 +7,11 @@
7// ============================================================================= 7// =============================================================================
8// <-- ENGLISH IMPOSED --> 8// <-- ENGLISH IMPOSED -->
9ilib_verbose(0); 9ilib_verbose(0);
10load(fullfile(SCI,'modules','scicos','tests','unit_tests','pendulum_anim45.cos')); 10load("SCI/modules/scicos/tests/unit_tests/pendulum_anim45.cos");
11M=10; 11M=10;
12m=3; 12m=3;
13l=3; 13l=3;
14ph=0.1; 14ph=0.1;
15scs_m = scs_m.objs(5).model.rpar; 15scs_m = scs_m.objs(5).model.rpar;
16[X,U,Y,XP] = steadycos(scs_m,[],[],[],[],1,1:$); 16[X,U,Y,XP] = steadycos(scs_m,[],[],[],[],1,1:$);
17 17
diff --git a/scilab/modules/scicos/tests/unit_tests/steadycos.tst b/scilab/modules/scicos/tests/unit_tests/steadycos.tst
index 1446372..91b888a 100644
--- a/scilab/modules/scicos/tests/unit_tests/steadycos.tst
+++ b/scilab/modules/scicos/tests/unit_tests/steadycos.tst
@@ -10,9 +10,9 @@
10 10
11ilib_verbose(0); 11ilib_verbose(0);
12 12
13exec(fullfile(SCI,'modules','scicos','tests','unit_tests','PENDULUM_ANIM.sci')); 13exec("SCI/modules/xcos/demos/PENDULUM_ANIM.sci");
14exec(fullfile(SCI,'modules','scicos','tests','unit_tests','anim_pen.sci')); 14exec("SCI/modules/xcos/demos/anim_pen.sci");
15load(fullfile(SCI,'modules','scicos','tests','unit_tests','pendulum_anim45.cos')); 15load("SCI/modules/scicos/tests/unit_tests/pendulum_anim45.cos");
16M=10; 16M=10;
17m=3; 17m=3;
18l=3; 18l=3;
diff --git a/scilab/modules/signal_processing/macros/wfir.sci b/scilab/modules/signal_processing/macros/wfir.sci
index 2fc263e..9dae9d8 100644
--- a/scilab/modules/signal_processing/macros/wfir.sci
+++ b/scilab/modules/signal_processing/macros/wfir.sci
@@ -44,14 +44,14 @@ if rhs<=0 then,
44 flag=0; 44 flag=0;
45 select nc 45 select nc
46 case 1 then //low pass 46 case 1 then //low pass
47 [ok,fl,forder]=getvalue(gettext('Input filter characteristics'),.. 47 [ok,fl,forder]=scicos_getvalue(gettext('Input filter characteristics'),..
48 [gettext('cut-off frequency (0.<frequ<.5):'); 48 [gettext('cut-off frequency (0.<frequ<.5):');
49 gettext('filter length')],.. 49 gettext('filter length')],..
50 list('vec',1,'vec',1),[' ';' ']) 50 list('vec',1,'vec',1),[' ';' '])
51 ftype='lp' 51 ftype='lp'
52 fh=0; 52 fh=0;
53 case 2 then //high pass 53 case 2 then //high pass
54 [ok,fl,forder]=getvalue(gettext('Input filter characteristics'),.. 54 [ok,fl,forder]=scicos_getvalue(gettext('Input filter characteristics'),..
55 [gettext('cut-off frequency (0.<frequ<.5):'); 55 [gettext('cut-off frequency (0.<frequ<.5):');
56 gettext('filter length (odd value)')],.. 56 gettext('filter length (odd value)')],..
57 list('vec',1,'vec',1),[' ';' ']) 57 list('vec',1,'vec',1),[' ';' '])
@@ -59,14 +59,14 @@ if rhs<=0 then,
59 flag=1; 59 flag=1;
60 ftype='hp' 60 ftype='hp'
61 case 3 then //band pass 61 case 3 then //band pass
62 [ok,fl,fh,forder]=getvalue(gettext('Input filter characteristics'),.. 62 [ok,fl,fh,forder]=scicos_getvalue(gettext('Input filter characteristics'),..
63 [gettext('low cut-off frequency (0.<flow<.5):'); 63 [gettext('low cut-off frequency (0.<flow<.5):');
64 gettext('high cut-off frequency (0.<flow<fhi<.5):'); 64 gettext('high cut-off frequency (0.<flow<fhi<.5):');
65 gettext('filter length')],.. 65 gettext('filter length')],..
66 list('vec',1,'vec',1,'vec',1),[' ';' ';' ']) 66 list('vec',1,'vec',1,'vec',1),[' ';' ';' '])
67 ftype='bp' 67 ftype='bp'
68 case 4 then //stop band 68 case 4 then //stop band
69 [ok,fl,fh,forder]=getvalue(gettext('Input filter characteristics'),.. 69 [ok,fl,fh,forder]=scicos_getvalue(gettext('Input filter characteristics'),..
70 [gettext('low cut-off frequency (0.<flow<.5):'); 70 [gettext('low cut-off frequency (0.<flow<.5):');
71 gettext('high cut-off frequency (0.<flow<fhi<.5):'); 71 gettext('high cut-off frequency (0.<flow<fhi<.5):');
72 gettext('filter length (odd value)')],.. 72 gettext('filter length (odd value)')],..
@@ -94,13 +94,13 @@ if rhs<=0 then,
94 select nc 94 select nc
95 case 1 then 95 case 1 then
96 wtype='kr' 96 wtype='kr'
97 [ok,Beta]=getvalue(gettext('Input window characteristics'),.. 97 [ok,Beta]=scicos_getvalue(gettext('Input window characteristics'),..
98 ['beta>0'],list('vec',1),' ') 98 ['beta>0'],list('vec',1),' ')
99 fpar(1)=Beta 99 fpar(1)=Beta
100 fpar(2)=0; 100 fpar(2)=0;
101 case 2 then 101 case 2 then
102 wtype='ch' 102 wtype='ch'
103 [ok,name,value]=getvalue([gettext('Input window characteristics:'); 103 [ok,name,value]=scicos_getvalue([gettext('Input window characteristics:');
104 ' '; 104 ' ';
105 gettext('dp (dp>0) : the maximum value of the window side-lobe height'); 105 gettext('dp (dp>0) : the maximum value of the window side-lobe height');
106 gettext('df (0<df<.5): the width of the window main lobe') 106 gettext('df (0<df<.5): the width of the window main lobe')
diff --git a/scilab/modules/texmacs/macros/overloading/%r_p.sci b/scilab/modules/texmacs/macros/overloading/%r_p.sci
deleted file mode 100644
index 2584444..0000000
--- a/scilab/modules/texmacs/macros/overloading/%r_p.sci
+++ /dev/null
@@ -1,12 +0,0 @@
1// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
2// Copyright (C) INRIA
3//
4// This file must be used under the terms of the CeCILL.
5// This source file is licensed as described in the file COPYING, which
6// you should have received as part of this distribution. The terms
7// are also available at
8// http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
9
10function %r_p(a)
11texout(a)
12endfunction
diff --git a/scilab/modules/xcos/demos/inv_pend_anim.dem.sce b/scilab/modules/xcos/demos/inv_pend_anim.dem.sce
index bc890b2..d37c1be 100644
--- a/scilab/modules/xcos/demos/inv_pend_anim.dem.sce
+++ b/scilab/modules/xcos/demos/inv_pend_anim.dem.sce
@@ -7,10 +7,7 @@
7// This file is distributed under the same license as the Scilab package. 7// This file is distributed under the same license as the Scilab package.
8// 8//
9 9
10thispath = get_absolute_file_path("inv_pend_anim.dem.sce"); 10exec("SCI/modules/xcos/demos/PENDULUM_ANIM.sci");
11exec("SCI/modules/xcos/demos/anim_pen.sci");
11 12
12exec(thispath+"/PENDULUM_ANIM.sci"); 13xcos("SCI/modules/xcos/demos/pendulum_anim5.xcos");
13exec(thispath+"/anim_pen.sci");
14
15xcos(thispath+"/pendulum_anim5.xcos");
16clear thispath;
diff --git a/scilab/modules/xcos/demos/inverted_pendulum.dem.sce b/scilab/modules/xcos/demos/inverted_pendulum.dem.sce
index 55e1fbd..e1fa1d7 100644
--- a/scilab/modules/xcos/demos/inverted_pendulum.dem.sce
+++ b/scilab/modules/xcos/demos/inverted_pendulum.dem.sce
@@ -7,9 +7,6 @@
7// This file is distributed under the same license as the Scilab package. 7// This file is distributed under the same license as the Scilab package.
8// 8//
9 9
10thispath = get_absolute_file_path("inverted_pendulum.dem.sce"); 10exec("SCI/modules/xcos/demos/setw.sci");
11xcos("SCI/modules/xcos/demos/Inverted_pendulum.xcos");
11 12
12exec(thispath+"/setw.sci");
13
14xcos(thispath+"/Inverted_pendulum.xcos");
15clear thispath;