summaryrefslogtreecommitdiffstats
path: root/scilab/modules/metanet
diff options
context:
space:
mode:
authorVincent COUVERT <vincent.couvert@scilab.org>2009-10-02 16:47:38 +0200
committerVincent COUVERT <vincent.couvert@scilab.org>2009-10-02 16:47:38 +0200
commit39cd52feb2c9436c005aebc5175f4ef6cf9ee882 (patch)
treea967ba029e1747fdf1cec7a43d8987e66aeb41a0 /scilab/modules/metanet
parent16d6bb91817b39470a6d2a72af789049748ffe6c (diff)
parent0d8f1f9c3a5ea2f5da09df6006c6783a960b2516 (diff)
downloadscilab-39cd52feb2c9436c005aebc5175f4ef6cf9ee882.zip
scilab-39cd52feb2c9436c005aebc5175f4ef6cf9ee882.tar.gz
Merge commit 'origin/master' into xcos
Conflicts: scilab/configure scilab/modules/hdf5/sci_gateway/cpp/sci_export_to_hdf5.cpp scilab/modules/hdf5/sci_gateway/cpp/sci_import_from_hdf5.cpp scilab/modules/hdf5/src/c/h5_readDataFromFile.c scilab/modules/hdf5/src/c/h5_writeDataToFile.c
Diffstat (limited to 'scilab/modules/metanet')
-rw-r--r--scilab/modules/metanet/Makefile.am5
-rw-r--r--scilab/modules/metanet/Makefile.in42
-rw-r--r--scilab/modules/metanet/help/en_US/mesh2d.xml2
-rw-r--r--scilab/modules/metanet/includes/gw_metanet.h2
-rw-r--r--scilab/modules/metanet/macros/graph_tools/bandwr.sci2
-rw-r--r--scilab/modules/metanet/macros/graph_tools/graph_simp.sci2
-rw-r--r--scilab/modules/metanet/macros/graph_tools/knapsack.sci8
-rw-r--r--scilab/modules/metanet/macros/graph_tools/make_graph.sci2
-rw-r--r--scilab/modules/metanet/macros/graph_tools/mat_2_graph.sci4
-rw-r--r--scilab/modules/metanet/macros/graph_tools/neighbors.sci2
-rw-r--r--scilab/modules/metanet/metanet.iss2
-rw-r--r--scilab/modules/metanet/src/c/connex.c4
-rw-r--r--scilab/modules/metanet/src/c/connex.h10
-rw-r--r--scilab/modules/metanet/src/c/dmtree.c105
-rw-r--r--scilab/modules/metanet/src/c/dmtree.h22
-rw-r--r--scilab/modules/metanet/src/c/files.c37
-rw-r--r--scilab/modules/metanet/src/c/hashtable_metanet.c2
-rw-r--r--scilab/modules/metanet/src/c/loadg.c16
-rw-r--r--scilab/modules/metanet/src/c/loadg.h4
-rw-r--r--scilab/modules/metanet/src/c/metanet.vcproj20
-rw-r--r--scilab/modules/metanet/src/c/paths.h13
-rw-r--r--scilab/modules/metanet/src/c/saveg.h3
-rw-r--r--scilab/modules/metanet/src/c/transc.c6
-rw-r--r--scilab/modules/metanet/src/c/transc.h11
-rw-r--r--scilab/modules/metanet/tests/unit_tests/mesh2d.dia.ref2
-rw-r--r--scilab/modules/metanet/tests/unit_tests/mesh2d.tst2
-rw-r--r--scilab/modules/metanet/tests/unit_tests/plot_graphbug.tst8
27 files changed, 179 insertions, 159 deletions
diff --git a/scilab/modules/metanet/Makefile.am b/scilab/modules/metanet/Makefile.am
index 307248b..0767880 100644
--- a/scilab/modules/metanet/Makefile.am
+++ b/scilab/modules/metanet/Makefile.am
@@ -151,11 +151,6 @@ libscimetanet_la_etc_DATA = etc/metanet.quit etc/metanet.start
151libscimetanet_la_sci_gatewaydir = $(mydatadir)/sci_gateway 151libscimetanet_la_sci_gatewaydir = $(mydatadir)/sci_gateway
152libscimetanet_la_sci_gateway_DATA = sci_gateway/metanet_gateway.xml 152libscimetanet_la_sci_gateway_DATA = sci_gateway/metanet_gateway.xml
153 153
154#### metanet : include files ####
155libscimetanet_la_includedir=$(pkgincludedir)
156libscimetanet_la_include_HEADERS = includes/gw_metanet.h \
157includes/dynlib_metanet.h
158
159#### metanet : Macros #### 154#### metanet : Macros ####
160MACROSDIRSEXT = macros/editor macros/graph_tools 155MACROSDIRSEXT = macros/editor macros/graph_tools
161 156
diff --git a/scilab/modules/metanet/Makefile.in b/scilab/modules/metanet/Makefile.in
index 4b36606..1fa7e02 100644
--- a/scilab/modules/metanet/Makefile.in
+++ b/scilab/modules/metanet/Makefile.in
@@ -37,7 +37,6 @@
37########## 37##########
38 38
39 39
40
41VPATH = @srcdir@ 40VPATH = @srcdir@
42pkgdatadir = $(datadir)/@PACKAGE@ 41pkgdatadir = $(datadir)/@PACKAGE@
43pkgincludedir = $(includedir)/@PACKAGE@ 42pkgincludedir = $(includedir)/@PACKAGE@
@@ -57,8 +56,7 @@ PRE_UNINSTALL = :
57POST_UNINSTALL = : 56POST_UNINSTALL = :
58build_triplet = @build@ 57build_triplet = @build@
59host_triplet = @host@ 58host_triplet = @host@
60DIST_COMMON = $(libscimetanet_la_include_HEADERS) \ 59DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
61 $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
62 $(top_srcdir)/Makefile.incl.am 60 $(top_srcdir)/Makefile.incl.am
63@NEED_JAVA_TRUE@am__append_1 = java 61@NEED_JAVA_TRUE@am__append_1 = java
64subdir = modules/metanet 62subdir = modules/metanet
@@ -106,8 +104,7 @@ am__base_list = \
106am__installdirs = "$(DESTDIR)$(pkglibdir)" \ 104am__installdirs = "$(DESTDIR)$(pkglibdir)" \
107 "$(DESTDIR)$(libscimetanet_la_etcdir)" \ 105 "$(DESTDIR)$(libscimetanet_la_etcdir)" \
108 "$(DESTDIR)$(libscimetanet_la_rootdir)" \ 106 "$(DESTDIR)$(libscimetanet_la_rootdir)" \
109 "$(DESTDIR)$(libscimetanet_la_sci_gatewaydir)" \ 107 "$(DESTDIR)$(libscimetanet_la_sci_gatewaydir)"
110 "$(DESTDIR)$(libscimetanet_la_includedir)"
111LTLIBRARIES = $(pkglib_LTLIBRARIES) 108LTLIBRARIES = $(pkglib_LTLIBRARIES)
112libscimetanet_la_DEPENDENCIES = \ 109libscimetanet_la_DEPENDENCIES = \
113 $(top_builddir)/libs/hashtable/libscihashtable.la \ 110 $(top_builddir)/libs/hashtable/libscihashtable.la \
@@ -176,7 +173,6 @@ SOURCES = $(libscimetanet_la_SOURCES)
176DIST_SOURCES = $(libscimetanet_la_SOURCES) 173DIST_SOURCES = $(libscimetanet_la_SOURCES)
177DATA = $(libscimetanet_la_etc_DATA) $(libscimetanet_la_root_DATA) \ 174DATA = $(libscimetanet_la_etc_DATA) $(libscimetanet_la_root_DATA) \
178 $(libscimetanet_la_sci_gateway_DATA) 175 $(libscimetanet_la_sci_gateway_DATA)
179HEADERS = $(libscimetanet_la_include_HEADERS)
180ETAGS = etags 176ETAGS = etags
181CTAGS = ctags 177CTAGS = ctags
182DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) 178DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
@@ -553,12 +549,6 @@ libscimetanet_la_etc_DATA = etc/metanet.quit etc/metanet.start
553libscimetanet_la_sci_gatewaydir = $(mydatadir)/sci_gateway 549libscimetanet_la_sci_gatewaydir = $(mydatadir)/sci_gateway
554libscimetanet_la_sci_gateway_DATA = sci_gateway/metanet_gateway.xml 550libscimetanet_la_sci_gateway_DATA = sci_gateway/metanet_gateway.xml
555 551
556#### metanet : include files ####
557libscimetanet_la_includedir = $(pkgincludedir)
558libscimetanet_la_include_HEADERS = includes/gw_metanet.h \
559includes/dynlib_metanet.h
560
561
562#### metanet : Macros #### 552#### metanet : Macros ####
563MACROSDIRSEXT = macros/editor macros/graph_tools 553MACROSDIRSEXT = macros/editor macros/graph_tools
564 554
@@ -1163,26 +1153,6 @@ uninstall-libscimetanet_la_sci_gatewayDATA:
1163 test -n "$$files" || exit 0; \ 1153 test -n "$$files" || exit 0; \
1164 echo " ( cd '$(DESTDIR)$(libscimetanet_la_sci_gatewaydir)' && rm -f" $$files ")"; \ 1154 echo " ( cd '$(DESTDIR)$(libscimetanet_la_sci_gatewaydir)' && rm -f" $$files ")"; \
1165 cd "$(DESTDIR)$(libscimetanet_la_sci_gatewaydir)" && rm -f $$files 1155 cd "$(DESTDIR)$(libscimetanet_la_sci_gatewaydir)" && rm -f $$files
1166install-libscimetanet_la_includeHEADERS: $(libscimetanet_la_include_HEADERS)
1167 @$(NORMAL_INSTALL)
1168 test -z "$(libscimetanet_la_includedir)" || $(MKDIR_P) "$(DESTDIR)$(libscimetanet_la_includedir)"
1169 @list='$(libscimetanet_la_include_HEADERS)'; test -n "$(libscimetanet_la_includedir)" || list=; \
1170 for p in $$list; do \
1171 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
1172 echo "$$d$$p"; \
1173 done | $(am__base_list) | \
1174 while read files; do \
1175 echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(libscimetanet_la_includedir)'"; \
1176 $(INSTALL_HEADER) $$files "$(DESTDIR)$(libscimetanet_la_includedir)" || exit $$?; \
1177 done
1178
1179uninstall-libscimetanet_la_includeHEADERS:
1180 @$(NORMAL_UNINSTALL)
1181 @list='$(libscimetanet_la_include_HEADERS)'; test -n "$(libscimetanet_la_includedir)" || list=; \
1182 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
1183 test -n "$$files" || exit 0; \
1184 echo " ( cd '$(DESTDIR)$(libscimetanet_la_includedir)' && rm -f" $$files ")"; \
1185 cd "$(DESTDIR)$(libscimetanet_la_includedir)" && rm -f $$files
1186 1156
1187ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) 1157ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
1188 list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ 1158 list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
@@ -1269,9 +1239,9 @@ distdir: $(DISTFILES)
1269check-am: all-am 1239check-am: all-am
1270 $(MAKE) $(AM_MAKEFLAGS) check-local 1240 $(MAKE) $(AM_MAKEFLAGS) check-local
1271check: check-am 1241check: check-am
1272all-am: Makefile $(LTLIBRARIES) $(DATA) $(HEADERS) all-local 1242all-am: Makefile $(LTLIBRARIES) $(DATA) all-local
1273installdirs: 1243installdirs:
1274 for dir in "$(DESTDIR)$(pkglibdir)" "$(DESTDIR)$(libscimetanet_la_etcdir)" "$(DESTDIR)$(libscimetanet_la_rootdir)" "$(DESTDIR)$(libscimetanet_la_sci_gatewaydir)" "$(DESTDIR)$(libscimetanet_la_includedir)"; do \ 1244 for dir in "$(DESTDIR)$(pkglibdir)" "$(DESTDIR)$(libscimetanet_la_etcdir)" "$(DESTDIR)$(libscimetanet_la_rootdir)" "$(DESTDIR)$(libscimetanet_la_sci_gatewaydir)"; do \
1275 test -z "$$dir" || $(MKDIR_P) "$$dir"; \ 1245 test -z "$$dir" || $(MKDIR_P) "$$dir"; \
1276 done 1246 done
1277install: install-am 1247install: install-am
@@ -1323,7 +1293,6 @@ info: info-am
1323info-am: 1293info-am:
1324 1294
1325install-data-am: install-data-local install-libscimetanet_la_etcDATA \ 1295install-data-am: install-data-local install-libscimetanet_la_etcDATA \
1326 install-libscimetanet_la_includeHEADERS \
1327 install-libscimetanet_la_rootDATA \ 1296 install-libscimetanet_la_rootDATA \
1328 install-libscimetanet_la_sci_gatewayDATA 1297 install-libscimetanet_la_sci_gatewayDATA
1329 1298
@@ -1372,7 +1341,6 @@ ps: ps-am
1372ps-am: 1341ps-am:
1373 1342
1374uninstall-am: uninstall-libscimetanet_la_etcDATA \ 1343uninstall-am: uninstall-libscimetanet_la_etcDATA \
1375 uninstall-libscimetanet_la_includeHEADERS \
1376 uninstall-libscimetanet_la_rootDATA \ 1344 uninstall-libscimetanet_la_rootDATA \
1377 uninstall-libscimetanet_la_sci_gatewayDATA \ 1345 uninstall-libscimetanet_la_sci_gatewayDATA \
1378 uninstall-pkglibLTLIBRARIES 1346 uninstall-pkglibLTLIBRARIES
@@ -1389,7 +1357,6 @@ uninstall-am: uninstall-libscimetanet_la_etcDATA \
1389 install-exec-am install-html install-html-am \ 1357 install-exec-am install-html install-html-am \
1390 install-html-local install-info install-info-am \ 1358 install-html-local install-info install-info-am \
1391 install-libscimetanet_la_etcDATA \ 1359 install-libscimetanet_la_etcDATA \
1392 install-libscimetanet_la_includeHEADERS \
1393 install-libscimetanet_la_rootDATA \ 1360 install-libscimetanet_la_rootDATA \
1394 install-libscimetanet_la_sci_gatewayDATA install-man \ 1361 install-libscimetanet_la_sci_gatewayDATA install-man \
1395 install-pdf install-pdf-am install-pkglibLTLIBRARIES \ 1362 install-pdf install-pdf-am install-pkglibLTLIBRARIES \
@@ -1398,7 +1365,6 @@ uninstall-am: uninstall-libscimetanet_la_etcDATA \
1398 maintainer-clean-generic mostlyclean mostlyclean-compile \ 1365 maintainer-clean-generic mostlyclean mostlyclean-compile \
1399 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ 1366 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
1400 tags uninstall uninstall-am uninstall-libscimetanet_la_etcDATA \ 1367 tags uninstall uninstall-am uninstall-libscimetanet_la_etcDATA \
1401 uninstall-libscimetanet_la_includeHEADERS \
1402 uninstall-libscimetanet_la_rootDATA \ 1368 uninstall-libscimetanet_la_rootDATA \
1403 uninstall-libscimetanet_la_sci_gatewayDATA \ 1369 uninstall-libscimetanet_la_sci_gatewayDATA \
1404 uninstall-pkglibLTLIBRARIES 1370 uninstall-pkglibLTLIBRARIES
diff --git a/scilab/modules/metanet/help/en_US/mesh2d.xml b/scilab/modules/metanet/help/en_US/mesh2d.xml
index 05cee40..70bc699 100644
--- a/scilab/modules/metanet/help/en_US/mesh2d.xml
+++ b/scilab/modules/metanet/help/en_US/mesh2d.xml
@@ -182,7 +182,7 @@ function []=test(X,Y)
182 xset("colormap",rand(2*n,3)); 182 xset("colormap",rand(2*n,3));
183 xfpolys(xpols,ypols,[n/4:n/4+n-1]); 183 xfpolys(xpols,ypols,[n/4:n/4+n-1]);
184endfunction 184endfunction
185N=1000;xbasc();X=rand(1,N); Y=rand(1,N); 185N=1000;clf();X=rand(1,N); Y=rand(1,N);
186xset("wdim",700,700); 186xset("wdim",700,700);
187test(X,Y); 187test(X,Y);
188 ]]></programlisting> 188 ]]></programlisting>
diff --git a/scilab/modules/metanet/includes/gw_metanet.h b/scilab/modules/metanet/includes/gw_metanet.h
index 72dac18..1eb6012 100644
--- a/scilab/modules/metanet/includes/gw_metanet.h
+++ b/scilab/modules/metanet/includes/gw_metanet.h
@@ -20,7 +20,7 @@
20/*--------------------------------------------------------------------------*/ 20/*--------------------------------------------------------------------------*/
21#include "machine.h" 21#include "machine.h"
22#include "dynlib_metanet.h" 22#include "dynlib_metanet.h"
23#include "api_common.h" 23#include "api_scilab.h"
24/*--------------------------------------------------------------------------*/ 24/*--------------------------------------------------------------------------*/
25METANET_IMPEXP int gw_metanet(void); 25METANET_IMPEXP int gw_metanet(void);
26/*--------------------------------------------------------------------------*/ 26/*--------------------------------------------------------------------------*/
diff --git a/scilab/modules/metanet/macros/graph_tools/bandwr.sci b/scilab/modules/metanet/macros/graph_tools/bandwr.sci
index 6535f39..e44b03e 100644
--- a/scilab/modules/metanet/macros/graph_tools/bandwr.sci
+++ b/scilab/modules/metanet/macros/graph_tools/bandwr.sci
@@ -83,7 +83,7 @@ function [iperm,mrepi,profil,ierr]=bandwr(a,b,c,d)
83 ii=int((rand()+1./k)*k); 83 ii=int((rand()+1./k)*k);
84 b=[b a(ii)];a(ii)=[]; 84 b=[b a(ii)];a(ii)=[];
85 end; 85 end;
86 [ss,sk]=sort(b); 86 [ss,sk]=gsort(b);
87 back=sk($:-1:1); 87 back=sk($:-1:1);
88 a=amem+amem'; 88 a=amem+amem';
89 a=a(b,b);a=triu(a); 89 a=a(b,b);a=triu(a);
diff --git a/scilab/modules/metanet/macros/graph_tools/graph_simp.sci b/scilab/modules/metanet/macros/graph_tools/graph_simp.sci
index ca786c3..1b4c592 100644
--- a/scilab/modules/metanet/macros/graph_tools/graph_simp.sci
+++ b/scilab/modules/metanet/macros/graph_tools/graph_simp.sci
@@ -19,7 +19,7 @@ function g1=graph_simp(g)
19 [ir ic]=find(ta==he); 19 [ir ic]=find(ta==he);
20 ta(ic)=[];he(ic)=[]; 20 ta(ic)=[];he(ic)=[];
21 p=round(log(n)/log(10));q=10^(p+4); 21 p=round(log(n)/log(10));q=10^(p+4);
22 w=ta'*q+he';[w1 iw]=sort(w); 22 w=ta'*q+he';[w1 iw]=gsort(w);
23 ww=w1(2:$)-w1(1:($-1)); 23 ww=w1(2:$)-w1(1:($-1));
24 [ir ic]=find(ww==0); 24 [ir ic]=find(ww==0);
25 index=iw(ir); 25 index=iw(ir);
diff --git a/scilab/modules/metanet/macros/graph_tools/knapsack.sci b/scilab/modules/metanet/macros/graph_tools/knapsack.sci
index 95f355b..da311e4 100644
--- a/scilab/modules/metanet/macros/graph_tools/knapsack.sci
+++ b/scilab/modules/metanet/macros/graph_tools/knapsack.sci
@@ -42,13 +42,13 @@ function [earn,ind]=knapsack(profit,weight,capa,bck)
42 weight = matrix(weight,1,-1) 42 weight = matrix(weight,1,-1)
43 capa = matrix(capa,1,-1) 43 capa = matrix(capa,1,-1)
44 //preprocess the data 44 //preprocess the data
45 [s,k]=sort(profit./weight); 45 [s,k]=gsort(profit./weight);
46 [ss,kk]=sort(-k); 46 [ss,kk]=gsort(-k);
47 p=profit(k);w=weight(k); 47 p=profit(k);w=weight(k);
48 np1=n+1; 48 np1=n+1;
49 m=size(capa,2); 49 m=size(capa,2);
50 [s1,k1]=sort(capa); 50 [s1,k1]=gsort(capa);
51 [s2,k2]=sort(k1); 51 [s2,k2]=gsort(k1);
52 kap=s1($:-1:1); 52 kap=s1($:-1:1);
53 mn=m*n;mnp1=m*np1; 53 mn=m*n;mnp1=m*np1;
54 [xstar,vstar]=m6knapsk(n,m,np1,mn,mnp1,p,w,kap,bck); 54 [xstar,vstar]=m6knapsk(n,m,np1,mn,mnp1,p,w,kap,bck);
diff --git a/scilab/modules/metanet/macros/graph_tools/make_graph.sci b/scilab/modules/metanet/macros/graph_tools/make_graph.sci
index fd9b6aa..d4fee6a 100644
--- a/scilab/modules/metanet/macros/graph_tools/make_graph.sci
+++ b/scilab/modules/metanet/macros/graph_tools/make_graph.sci
@@ -45,7 +45,7 @@ function g=make_graph(name,directed,n,tail,head)
45 nodename=string(1:n) 45 nodename=string(1:n)
46 else 46 else
47 ij=[tail' head']; 47 ij=[tail' head'];
48 tri=[ij(:,1)' ij(:,2)'];[atri,indic]=sort(-tri); 48 tri=[ij(:,1)' ij(:,2)'];[atri,indic]=gsort(-tri);
49 atri=-atri; 49 atri=-atri;
50 n1=size(atri,2); 50 n1=size(atri,2);
51 atri1=atri-[0 atri(1:n1-1)]; 51 atri1=atri-[0 atri(1:n1-1)];
diff --git a/scilab/modules/metanet/macros/graph_tools/mat_2_graph.sci b/scilab/modules/metanet/macros/graph_tools/mat_2_graph.sci
index dd2483b..459f594 100644
--- a/scilab/modules/metanet/macros/graph_tools/mat_2_graph.sci
+++ b/scilab/modules/metanet/macros/graph_tools/mat_2_graph.sci
@@ -47,9 +47,9 @@ function g=mat_2_graph(a,directed,mat)
47 end 47 end
48 48
49 he=ij(itab,:); ta=ij(jtab,:) 49 he=ij(itab,:); ta=ij(jtab,:)
50 [s,k]=sort(he(:,2)); he=he(k,:); he=he(:,1) 50 [s,k]=gsort(he(:,2)); he=he(k,:); he=he(:,1)
51 ma=prod(size(k)); he=he(ma:-1:1) 51 ma=prod(size(k)); he=he(ma:-1:1)
52 [s,k]=sort(ta(:,2)); ta=ta(k,:); ta=ta(:,1) 52 [s,k]=gsort(ta(:,2)); ta=ta(k,:); ta=ta(:,1)
53 ma=prod(size(k)); ta=ta(ma:-1:1) 53 ma=prod(size(k)); ta=ta(ma:-1:1)
54 g=make_graph('foo',1,n,he',ta') 54 g=make_graph('foo',1,n,he',ta')
55 55
diff --git a/scilab/modules/metanet/macros/graph_tools/neighbors.sci b/scilab/modules/metanet/macros/graph_tools/neighbors.sci
index 1a18236..401e83c 100644
--- a/scilab/modules/metanet/macros/graph_tools/neighbors.sci
+++ b/scilab/modules/metanet/macros/graph_tools/neighbors.sci
@@ -21,5 +21,5 @@ function d=neighbors(i,g)
21 d1=he(ic); 21 d1=he(ic);
22 [ir,ic]=find(he==i); 22 [ir,ic]=find(he==i);
23 d2=ta(ic); 23 d2=ta(ic);
24 d=-sort(-[d1 d2]); 24 d=-gsort(-[d1 d2]);
25endfunction 25endfunction
diff --git a/scilab/modules/metanet/metanet.iss b/scilab/modules/metanet/metanet.iss
index 36a8fb9..e060a73 100644
--- a/scilab/modules/metanet/metanet.iss
+++ b/scilab/modules/metanet/metanet.iss
@@ -34,7 +34,7 @@ Source: modules\{#METANET}\etc\{#METANET}.start; DestDir: {app}\modules\{#METANE
34; 34;
35Source: modules\{#METANET}\help\addchapter.sce; DestDir: {app}\modules\{#METANET}\help; Flags: recursesubdirs; Components: {#COMPN_METANET} 35Source: modules\{#METANET}\help\addchapter.sce; DestDir: {app}\modules\{#METANET}\help; Flags: recursesubdirs; Components: {#COMPN_METANET}
36; 36;
37Source: modules\{#METANET}\includes\*.h; DestDir: {app}\modules\{#METANET}\includes; Components: {#COMPN_METANET} 37;Source: modules\{#METANET}\includes\*.h; DestDir: {app}\modules\{#METANET}\includes; Components: {#COMPN_METANET}
38; 38;
39Source: modules\{#METANET}\macros\editor\lib; DestDir: {app}\modules\{#METANET}\macros\editor; Components: {#COMPN_METANET} 39Source: modules\{#METANET}\macros\editor\lib; DestDir: {app}\modules\{#METANET}\macros\editor; Components: {#COMPN_METANET}
40Source: modules\{#METANET}\macros\editor\names; DestDir: {app}\modules\{#METANET}\macros\editor; Components: {#COMPN_METANET} 40Source: modules\{#METANET}\macros\editor\names; DestDir: {app}\modules\{#METANET}\macros\editor; Components: {#COMPN_METANET}
diff --git a/scilab/modules/metanet/src/c/connex.c b/scilab/modules/metanet/src/c/connex.c
index ca6963c..7f7664f 100644
--- a/scilab/modules/metanet/src/c/connex.c
+++ b/scilab/modules/metanet/src/c/connex.c
@@ -11,6 +11,10 @@
11 * 11 *
12 */ 12 */
13 13
14#include <string.h>
15#include <stdlib.h>
16#include "MALLOC.h"
17#include "cerro.h"
14#include "connex.h" 18#include "connex.h"
15#include "localization.h" 19#include "localization.h"
16 20
diff --git a/scilab/modules/metanet/src/c/connex.h b/scilab/modules/metanet/src/c/connex.h
index 17bfe76..0cf8c83 100644
--- a/scilab/modules/metanet/src/c/connex.h
+++ b/scilab/modules/metanet/src/c/connex.h
@@ -23,15 +23,9 @@
23#ifndef __CONNEX_H__ 23#ifndef __CONNEX_H__
24#define __CONNEX_H__ 24#define __CONNEX_H__
25 25
26#include <string.h>
27#include <stdlib.h>
28
29#include "MALLOC.h"
30
31#include "cerro.h"
32
33#include "machine.h" 26#include "machine.h"
27#include "dynlib_metanet.h"
34 28
35void C2F(concom)(int *icomp, int *n, int *ncomp, int **ns, int *nsize); 29METANET_IMPEXP void C2F(concom)(int *icomp, int *n, int *ncomp, int **ns, int *nsize);
36 30
37#endif /* ! __CONNEX_H__ */ 31#endif /* ! __CONNEX_H__ */
diff --git a/scilab/modules/metanet/src/c/dmtree.c b/scilab/modules/metanet/src/c/dmtree.c
index 8146e9e..c7a689e 100644
--- a/scilab/modules/metanet/src/c/dmtree.c
+++ b/scilab/modules/metanet/src/c/dmtree.c
@@ -10,65 +10,76 @@
10 * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt 10 * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
11 * 11 *
12 */ 12 */
13 13/*--------------------------------------------------------------------------*/
14#include <string.h> 14#include <string.h>
15#include <stdlib.h> 15#include <stdlib.h>
16#include "machine.h" 16#include "dmtree.h"
17extern void cerro();
18
19#include "MALLOC.h" 17#include "MALLOC.h"
20#include "localization.h" 18#include "localization.h"
19/*--------------------------------------------------------------------------*/
20extern void cerro();
21 21
22#ifdef _MSC_VER 22#ifdef _MSC_VER
23extern int F2C(arbor)(); 23extern int F2C(arbor)();
24#endif 24#endif
25 25/*--------------------------------------------------------------------------*/
26void C2F(dmtree)(int *i0, int *la1, int *lp1, int *ls1, int *m, int *n, int *pred, int *w) 26void C2F(dmtree)(int *i0, int *la1, int *lp1, int *ls1, int *m, int *n, int *pred, int *w)
27{ 27{
28 int i,nndim; 28 int i = 0,nndim = 0;
29 int *alphi,*beta,*f,*g,*ind,*pred1; 29 int *alphi = NULL,*beta = NULL,*f = NULL,*g = NULL,*ind = NULL,*pred1 = NULL;
30 double *z,*zsom; 30 double *z = NULL,*zsom = NULL;
31 int isize,dsize; 31 int isize = 0,dsize = 0;
32 isize = sizeof(int); dsize = sizeof(double); 32
33 isize = sizeof(int);
34 dsize = sizeof(double);
33 35
34 nndim = 2 * *n; 36 nndim = 2 * *n;
35 if ((alphi = (int *)MALLOC(nndim * isize)) == NULL) { 37 if ((alphi = (int *)MALLOC(nndim * isize)) == NULL)
36 cerro(_("Running out of memory")); 38 {
37 return; 39 cerro(_("Running out of memory"));
38 } 40 return;
39 if ((beta = (int *)MALLOC(nndim * isize)) == NULL) { 41 }
40 cerro(_("Running out of memory")); 42 if ((beta = (int *)MALLOC(nndim * isize)) == NULL)
41 return; 43 {
42 } 44 cerro(_("Running out of memory"));
43 if ((f = (int *)MALLOC(nndim * isize)) == NULL) { 45 return;
44 cerro(_("Running out of memory")); 46 }
45 return; 47 if ((f = (int *)MALLOC(nndim * isize)) == NULL)
46 } 48 {
47 if ((g = (int *)MALLOC(nndim * isize)) == NULL) { 49 cerro(_("Running out of memory"));
48 cerro(_("Running out of memory")); 50 return;
49 return; 51 }
50 } 52 if ((g = (int *)MALLOC(nndim * isize)) == NULL)
51 if ((ind = (int *)MALLOC(nndim * isize)) == NULL) { 53 {
52 cerro(_("Running out of memory")); 54 cerro(_("Running out of memory"));
53 return; 55 return;
54 } 56 }
55 if ((pred1 = (int *)MALLOC(nndim * isize)) == NULL) { 57 if ((ind = (int *)MALLOC(nndim * isize)) == NULL)
56 cerro(_("Running out of memory")); 58 {
57 return; 59 cerro(_("Running out of memory"));
58 } 60 return;
59 if ((z = (double *)MALLOC(nndim * dsize)) == NULL) { 61 }
60 cerro(_("Running out of memory")); 62 if ((pred1 = (int *)MALLOC(nndim * isize)) == NULL)
61 return; 63 {
62 } 64 cerro(_("Running out of memory"));
63 if ((zsom = (double *)MALLOC(nndim * dsize)) == NULL) { 65 return;
64 cerro(_("Running out of memory")); 66 }
65 return; 67 if ((z = (double *)MALLOC(nndim * dsize)) == NULL)
66 } 68 {
69 cerro(_("Running out of memory"));
70 return;
71 }
72 if ((zsom = (double *)MALLOC(nndim * dsize)) == NULL)
73 {
74 cerro(_("Running out of memory"));
75 return;
76 }
67 77
68 F2C(arbor)(alphi,beta,f,g,i0,ind,la1,lp1,ls1,m,n,&nndim,pred1,w,z,zsom); 78 F2C(arbor)(alphi,beta,f,g,i0,ind,la1,lp1,ls1,m,n,&nndim,pred1,w,z,zsom);
69 79
70 for (i = 0; i < *n; i++) pred[i] = pred1[i]; 80 for (i = 0; i < *n; i++) pred[i] = pred1[i];
71 81
72 FREE(alphi); FREE(beta); FREE(f); FREE(g); FREE(ind); 82 FREE(alphi); FREE(beta); FREE(f); FREE(g); FREE(ind);
73 FREE(pred1); FREE(z); FREE(zsom); 83 FREE(pred1); FREE(z); FREE(zsom);
74} 84}
85/*--------------------------------------------------------------------------*/ \ No newline at end of file
diff --git a/scilab/modules/metanet/src/c/dmtree.h b/scilab/modules/metanet/src/c/dmtree.h
new file mode 100644
index 0000000..05867e6
--- /dev/null
+++ b/scilab/modules/metanet/src/c/dmtree.h
@@ -0,0 +1,22 @@
1/*
2 * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
3 * Copyright (C) 2009 - DIGITEO - Allan CORNET
4 *
5 * This file must be used under the terms of the CeCILL.
6 * This source file is licensed as described in the file COPYING, which
7 * you should have received as part of this distribution. The terms
8 * are also available at
9 * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
10 *
11 */
12/*--------------------------------------------------------------------------*/
13#ifndef __DMTREE_H__
14#define __DMTREE_H__
15
16#include "machine.h"
17#include "dynlib_metanet.h"
18
19METANET_IMPEXP void C2F(dmtree)(int *i0, int *la1, int *lp1, int *ls1, int *m, int *n, int *pred, int *w);
20
21#endif /* __DMTREE_H__ */
22/*--------------------------------------------------------------------------*/
diff --git a/scilab/modules/metanet/src/c/files.c b/scilab/modules/metanet/src/c/files.c
index 1ffa6dc..c6995b8 100644
--- a/scilab/modules/metanet/src/c/files.c
+++ b/scilab/modules/metanet/src/c/files.c
@@ -47,23 +47,26 @@ int CheckGraphName(char *name,char *dir)
47 47
48char *StripGraph(char *name) 48char *StripGraph(char *name)
49{ 49{
50 char *s; 50 char *s = NULL;
51 int i; 51 int i = 0;
52 char *t; 52 char *t = NULL;
53 53
54 s = name; 54 s = name;
55 i = 0; 55 i = 0;
56 t = (char *)MALLOC((unsigned)strlen(name)+1); 56 t = (char *)MALLOC((unsigned)strlen(name)+1);
57 while ( (t[i++] = *s++) ) { 57 while ( (t[i++] = *s++) )
58 if (*s == '.') { 58 {
59 if (strcmp(++s,"graph") == 0) { 59 if (*s == '.')
60 t[i] = '\0'; 60 {
61 return t; 61 if (strcmp(++s,"graph") == 0)
62 } 62 {
63 t[i++] = '.'; 63 t[i] = '\0';
64 } 64 return t;
65 } 65 }
66 return name; 66 t[i++] = '.';
67 }
68 }
69 return name;
67} 70}
68 71
69#ifndef _MSC_VER 72#ifndef _MSC_VER
diff --git a/scilab/modules/metanet/src/c/hashtable_metanet.c b/scilab/modules/metanet/src/c/hashtable_metanet.c
index 9be8066..a854e57 100644
--- a/scilab/modules/metanet/src/c/hashtable_metanet.c
+++ b/scilab/modules/metanet/src/c/hashtable_metanet.c
@@ -53,7 +53,9 @@ static unsigned int hashfromkey_string(void *ky)
53 str=k->Key_String; 53 str=k->Key_String;
54 54
55 while ((c = *(str++))) 55 while ((c = *(str++)))
56 {
56 hash = ((hash << 5) + hash) + c; /* hash * 33 + c */ 57 hash = ((hash << 5) + hash) + c; /* hash * 33 + c */
58 }
57 59
58 return hash; 60 return hash;
59} 61}
diff --git a/scilab/modules/metanet/src/c/loadg.c b/scilab/modules/metanet/src/c/loadg.c
index d353616..f5d9d71 100644
--- a/scilab/modules/metanet/src/c/loadg.c
+++ b/scilab/modules/metanet/src/c/loadg.c
@@ -23,6 +23,8 @@
23#include "strdup_windows.h" 23#include "strdup_windows.h"
24#endif 24#endif
25 25
26#include "files.h"
27
26static int CompString(char **s1,char **s2) 28static int CompString(char **s1,char **s2)
27{ 29{
28 return strcmp((char*)*s1,(char*)*s2); 30 return strcmp((char*)*s1,(char*)*s2);
@@ -41,20 +43,20 @@ void C2F(loadg)(char *path, int *lpath, char **name, int *lname, int *directed,
41 int *default_edge_hi_width, int *default_font_size, 43 int *default_edge_hi_width, int *default_font_size,
42 int *ndim, int *ma) 44 int *ndim, int *ma)
43{ 45{
44 FILE *fg; 46 FILE *fg = NULL;
45#ifndef _MSC_VER 47#ifndef _MSC_VER
46 DIR *dirp=NULL; 48 DIR *dirp = NULL;
47#endif 49#endif
48 char fname[2 * MAXNAM]; 50 char fname[2 * MAXNAM];
49 char line[5 * MAXNAM]; 51 char line[5 * MAXNAM];
50 char strname[MAXNAM], head_name[MAXNAM], tail_name[MAXNAM]; 52 char strname[MAXNAM], head_name[MAXNAM], tail_name[MAXNAM];
51 int isize,dsize; 53 int isize = 0,dsize = 0;
52 int i,s; 54 int i = 0,s = 0;
53 ENTRY node; 55 ENTRY node;
54 ENTRY *found=NULL; 56 ENTRY *found = NULL;
55 char dir[PATH_MAX]; 57 char dir[PATH_MAX];
56 char *pname=NULL; 58 char *pname = NULL;
57 char **lar=NULL; 59 char **lar = NULL;
58 60
59 path[*lpath] = '\0'; 61 path[*lpath] = '\0';
60#ifndef _MSC_VER 62#ifndef _MSC_VER
diff --git a/scilab/modules/metanet/src/c/loadg.h b/scilab/modules/metanet/src/c/loadg.h
index 5b5deca..8abc1db 100644
--- a/scilab/modules/metanet/src/c/loadg.h
+++ b/scilab/modules/metanet/src/c/loadg.h
@@ -23,9 +23,9 @@
23#ifndef __LOADG_H__ 23#ifndef __LOADG_H__
24#define __LOADG_H__ 24#define __LOADG_H__
25#include "machine.h" 25#include "machine.h"
26#include "files.h" 26#include "dynlib_metanet.h"
27 27
28void C2F(loadg)(char *path, int *lpath, char **name, int *lname, int *directed, int *n, int **tail, int **head, 28METANET_IMPEXP void C2F(loadg)(char *path, int *lpath, char **name, int *lname, int *directed, int *n, int **tail, int **head,
29 char ***node_name, 29 char ***node_name,
30 int **node_type, int **node_x, int **node_y, int **node_color, int **node_diam, int **node_border, 30 int **node_type, int **node_x, int **node_y, int **node_color, int **node_diam, int **node_border,
31 int **node_font_size, 31 int **node_font_size,
diff --git a/scilab/modules/metanet/src/c/metanet.vcproj b/scilab/modules/metanet/src/c/metanet.vcproj
index d5d8cce..c84b0dc 100644
--- a/scilab/modules/metanet/src/c/metanet.vcproj
+++ b/scilab/modules/metanet/src/c/metanet.vcproj
@@ -415,10 +415,18 @@
415 Filter="h;hpp;hxx;hm;inl" 415 Filter="h;hpp;hxx;hm;inl"
416 > 416 >
417 <File 417 <File
418 RelativePath=".\connex.h"
419 >
420 </File>
421 <File
418 RelativePath=".\defs.h" 422 RelativePath=".\defs.h"
419 > 423 >
420 </File> 424 </File>
421 <File 425 <File
426 RelativePath=".\dmtree.h"
427 >
428 </File>
429 <File
422 RelativePath="..\..\includes\dynlib_metanet.h" 430 RelativePath="..\..\includes\dynlib_metanet.h"
423 > 431 >
424 </File> 432 </File>
@@ -435,9 +443,21 @@
435 > 443 >
436 </File> 444 </File>
437 <File 445 <File
446 RelativePath=".\loadg.h"
447 >
448 </File>
449 <File
438 RelativePath=".\paths.h" 450 RelativePath=".\paths.h"
439 > 451 >
440 </File> 452 </File>
453 <File
454 RelativePath=".\saveg.h"
455 >
456 </File>
457 <File
458 RelativePath=".\transc.h"
459 >
460 </File>
441 </Filter> 461 </Filter>
442 <Filter 462 <Filter
443 Name="localization" 463 Name="localization"
diff --git a/scilab/modules/metanet/src/c/paths.h b/scilab/modules/metanet/src/c/paths.h
index 330a5ff..751aec2 100644
--- a/scilab/modules/metanet/src/c/paths.h
+++ b/scilab/modules/metanet/src/c/paths.h
@@ -15,6 +15,7 @@
15#define __PATHS_H__ 15#define __PATHS_H__
16 16
17#include "machine.h" 17#include "machine.h"
18#include "dynlib_metanet.h"
18 19
19 20
20/** NodesToPath converts a vector with node numbers into a path: 21/** NodesToPath converts a vector with node numbers into a path:
@@ -28,14 +29,14 @@
28 * @param lp 29 * @param lp
29 * @param ls 30 * @param ls
30*/ 31*/
31void NodesToPath(int *nodes,int **p,int *psize,int *la,int *lp,int *ls); 32METANET_IMPEXP void NodesToPath(int *nodes,int **p,int *psize,int *la,int *lp,int *ls);
32 33
33/** prevn2p_ computes a path from node i to node j from a 34/** prevn2p_ computes a path from node i to node j from a
34 * vector describing the previous nodes in path: 35 * vector describing the previous nodes in path:
35 * node i belongs to path if pln[i] > 0 36 * node i belongs to path if pln[i] > 0
36 * pln[i] is then the previous node in the sequence 37 * pln[i] is then the previous node in the sequence
37*/ 38*/
38void C2F(prevn2p)(int *i,int *j,int *m,int *n,int *la,int *lp,int *ls,int *direct,int *pln,int **p,int *psize); 39METANET_IMPEXP void C2F(prevn2p)(int *i,int *j,int *m,int *n,int *la,int *lp,int *ls,int *direct,int *pln,int **p,int *psize);
39 40
40 41
41/** ns2p_ converts a node set into a path: 42/** ns2p_ converts a node set into a path:
@@ -43,7 +44,7 @@ void C2F(prevn2p)(int *i,int *j,int *m,int *n,int *la,int *lp,int *ls,int *direc
43 * PATH = [A1,A2,...,An-1] with Ai = (Ni,Ni+1) 44 * PATH = [A1,A2,...,An-1] with Ai = (Ni,Ni+1)
44 * *psize = *nsize - 1 45 * *psize = *nsize - 1
45*/ 46*/
46void C2F(ns2p)(int *nodes,int *nsize,int **p,int *psize,int *la,int *lp,int *ls,int *n); 47METANET_IMPEXP void C2F(ns2p)(int *nodes,int *nsize,int **p,int *psize,int *la,int *lp,int *ls,int *n);
47 48
48 49
49/** p2ns_ converts a path into a node set: 50/** p2ns_ converts a path into a node set:
@@ -51,20 +52,20 @@ void C2F(ns2p)(int *nodes,int *nsize,int **p,int *psize,int *la,int *lp,int *ls,
51 * NODES = [N1,N2,...,Nn+1] => with Ai = (Ni,Ni+1) 52 * NODES = [N1,N2,...,Nn+1] => with Ai = (Ni,Ni+1)
52 * with *nsize = *psize + 1 53 * with *nsize = *psize + 1
53*/ 54*/
54void C2F(p2ns)(int *p,int *psize,int **nodes,int *nsize,int *la,int *lp,int *ls,int *direct,int *m,int *n); 55METANET_IMPEXP void C2F(p2ns)(int *p,int *psize,int **nodes,int *nsize,int *la,int *lp,int *ls,int *direct,int *m,int *n);
55 56
56 57
57 58
58/** edge2st_ computes a spanning tree (root = node 1) from 59/** edge2st_ computes a spanning tree (root = node 1) from
59 * an array alpha of connecting edge numbers 60 * an array alpha of connecting edge numbers
60 */ 61 */
61void C2F(edge2st)(int *n,int *alpha,int **tree,int *treesize); 62METANET_IMPEXP void C2F(edge2st)(int *n,int *alpha,int **tree,int *treesize);
62 63
63 64
64/** prevn2st_ computes a spanning tree (root = node i0) from 65/** prevn2st_ computes a spanning tree (root = node i0) from
65 * a vector nodes describing the previous nodes in tree 66 * a vector nodes describing the previous nodes in tree
66 */ 67 */
67 68
68void C2F(prevn2st)(int *n,int *nodes,int **tree,int *treesize,int *la,int *lp,int *ls); 69METANET_IMPEXP void C2F(prevn2st)(int *n,int *nodes,int **tree,int *treesize,int *la,int *lp,int *ls);
69 70
70#endif /* __PATHS_H__ */ 71#endif /* __PATHS_H__ */
diff --git a/scilab/modules/metanet/src/c/saveg.h b/scilab/modules/metanet/src/c/saveg.h
index 096149b..5f4dbaf 100644
--- a/scilab/modules/metanet/src/c/saveg.h
+++ b/scilab/modules/metanet/src/c/saveg.h
@@ -24,9 +24,10 @@
24#define __SAVEG_H__ 24#define __SAVEG_H__
25 25
26#include "machine.h" 26#include "machine.h"
27#include "dynlib_metanet.h"
27#include "files.h" 28#include "files.h"
28 29
29void C2F(saveg) (char *path, int *lpath, 30METANET_IMPEXP void C2F(saveg) (char *path, int *lpath,
30 char *name, int *lname,int *directed,int *node_number,int *tail,int *head, 31 char *name, int *lname,int *directed,int *node_number,int *tail,int *head,
31 char ***node_name, 32 char ***node_name,
32 int *node_type,int *node_x,int *node_y,int *node_color,int *node_diam,int *node_border, 33 int *node_type,int *node_x,int *node_y,int *node_color,int *node_diam,int *node_border,
diff --git a/scilab/modules/metanet/src/c/transc.c b/scilab/modules/metanet/src/c/transc.c
index 62b9c70..37d6072 100644
--- a/scilab/modules/metanet/src/c/transc.c
+++ b/scilab/modules/metanet/src/c/transc.c
@@ -11,8 +11,14 @@
11 * 11 *
12 */ 12 */
13 13
14#include <string.h>
15#include <stdlib.h>
14#include "transc.h" 16#include "transc.h"
17#include "MALLOC.h"
15#include "localization.h" 18#include "localization.h"
19#include "cerro.h"
20
21extern int F2C(frmtrs) ();
16 22
17void C2F(transc)(int *lp1,int **lpft,int *ls1,int **lsft,int *m,int *lsftdim,int *lpftdim,int *n) 23void C2F(transc)(int *lp1,int **lpft,int *ls1,int **lsft,int *m,int *lsftdim,int *lpftdim,int *n)
18{ 24{
diff --git a/scilab/modules/metanet/src/c/transc.h b/scilab/modules/metanet/src/c/transc.h
index b6724ae..1580ba3 100644
--- a/scilab/modules/metanet/src/c/transc.h
+++ b/scilab/modules/metanet/src/c/transc.h
@@ -23,16 +23,9 @@
23#ifndef __TRANSC_H__ 23#ifndef __TRANSC_H__
24#define __TRANSC_H__ 24#define __TRANSC_H__
25 25
26#include <string.h>
27#include <stdlib.h>
28
29#include "machine.h" 26#include "machine.h"
30#include "MALLOC.h" 27#include "dynlib_metanet.h"
31
32#include "cerro.h"
33
34extern int F2C(frmtrs) ();
35 28
36void C2F(transc)(int *lp1,int **lpft,int *ls1,int **lsft,int *m,int *lsftdim,int *lpftdim,int *n); 29METANET_IMPEXP void C2F(transc)(int *lp1,int **lpft,int *ls1,int **lsft,int *m,int *lsftdim,int *lpftdim,int *n);
37 30
38#endif /* !__TRANSC_H__ */ 31#endif /* !__TRANSC_H__ */
diff --git a/scilab/modules/metanet/tests/unit_tests/mesh2d.dia.ref b/scilab/modules/metanet/tests/unit_tests/mesh2d.dia.ref
index e347bfb..eeb6819 100644
--- a/scilab/modules/metanet/tests/unit_tests/mesh2d.dia.ref
+++ b/scilab/modules/metanet/tests/unit_tests/mesh2d.dia.ref
@@ -108,7 +108,7 @@ function []=test(X,Y)
108 xset("colormap",rand(2*n,3)); 108 xset("colormap",rand(2*n,3));
109 xfpolys(xpols,ypols,[n/4:n/4+n-1]); 109 xfpolys(xpols,ypols,[n/4:n/4+n-1]);
110endfunction 110endfunction
111N=1000;xbasc();X=rand(1,N); Y=rand(1,N); 111N=1000;clf();X=rand(1,N); Y=rand(1,N);
112xset("wdim",700,700); 112xset("wdim",700,700);
113test(X,Y); 113test(X,Y);
114delete(scf()); 114delete(scf());
diff --git a/scilab/modules/metanet/tests/unit_tests/mesh2d.tst b/scilab/modules/metanet/tests/unit_tests/mesh2d.tst
index 8200b89..d17cc56 100644
--- a/scilab/modules/metanet/tests/unit_tests/mesh2d.tst
+++ b/scilab/modules/metanet/tests/unit_tests/mesh2d.tst
@@ -103,7 +103,7 @@ function []=test(X,Y)
103 xset("colormap",rand(2*n,3)); 103 xset("colormap",rand(2*n,3));
104 xfpolys(xpols,ypols,[n/4:n/4+n-1]); 104 xfpolys(xpols,ypols,[n/4:n/4+n-1]);
105endfunction 105endfunction
106N=1000;xbasc();X=rand(1,N); Y=rand(1,N); 106N=1000;clf();X=rand(1,N); Y=rand(1,N);
107xset("wdim",700,700); 107xset("wdim",700,700);
108test(X,Y); 108test(X,Y);
109delete(scf()); 109delete(scf());
diff --git a/scilab/modules/metanet/tests/unit_tests/plot_graphbug.tst b/scilab/modules/metanet/tests/unit_tests/plot_graphbug.tst
index 7d60c9a..2b8829d 100644
--- a/scilab/modules/metanet/tests/unit_tests/plot_graphbug.tst
+++ b/scilab/modules/metanet/tests/unit_tests/plot_graphbug.tst
@@ -22,12 +22,12 @@ g('node_diam')=[30 30 30 60];
22g('edge_color')=[10 0 2 6 11 11 0 0 11]; 22g('edge_color')=[10 0 2 6 11 11 0 0 11];
23rep=[2 2 1 1 2 2 2 2 2 2 2 2 2]; 23rep=[2 2 1 1 2 2 2 2 2 2 2 2 2];
24rep1=[100 -400 650 300]; 24rep1=[100 -400 650 300];
25xbasc(); plot_graph(g,rep,rep1); 25clf(); plot_graph(g,rep,rep1);
26rep=[2 1 1 1 2 2 2 2 2 2 2 2 2]; 26rep=[2 1 1 1 2 2 2 2 2 2 2 2 2];
27xbasc(); plot_graph(g,rep,rep1); 27clf(); plot_graph(g,rep,rep1);
28// plotting using dialogs 28// plotting using dialogs
29xbasc(); plot_graph(g); 29clf(); plot_graph(g);
30xset("thickness",4); 30xset("thickness",4);
31xbasc(); 31clf();
32plot_graph(g); 32plot_graph(g);
33 33