~ubuntu-branches/ubuntu/karmic/scilab/karmic

« back to all changes in this revision

Viewing changes to man/metanet/contract_edge.man

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2002-03-21 16:57:43 UTC
  • Revision ID: james.westby@ubuntu.com-20020321165743-e9mv12c1tb1plztg
Tags: upstream-2.6
ImportĀ upstreamĀ versionĀ 2.6

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
.TH contract_edge 1 "September 1996" "Scilab Group" "Scilab function"
 
2
.so ../sci.an
 
3
.SH NAME
 
4
contract_edge - contracts edges between two nodes
 
5
.SH CALLING SEQUENCE
 
6
.nf
 
7
g1 = contract_edge(i,j,g)
 
8
.fi
 
9
.SH PARAMETERS
 
10
.TP 2
 
11
i
 
12
: integer, number of start or end node of edge
 
13
.TP 2
 
14
j
 
15
: integer, number of end or start node of edge
 
16
.TP 2
 
17
g
 
18
: graph list
 
19
.TP 3
 
20
g1
 
21
: graph list of the new graph 
 
22
.SH DESCRIPTION
 
23
\fVcontract_edge\fR returns the graph \fVg1\fR, the edges between the nodes
 
24
number \fVi\fR and \fVj\fR being deleted, the nodes being reduced to one
 
25
node with the same name as node \fVi\fR and located at the middle point 
 
26
between the 2 previous nodes.
 
27
.SH EXAMPLE
 
28
.nf
 
29
ta=[1 1 2 2 2 3 4 5 5 7 8 8 9 10 10 10 10 10 11 12 13 13 13 14 15 16 16 17 17];
 
30
he=[2 10 3 5 7 4 2 4 6 8 6 9 7 7 11 13 13 15 12 13 9 10 14 11 16 1 17 14 15];
 
31
g=make_graph('foo',1,17,ta,he);
 
32
g('node_x')=[283 163 63 57 164 164 273 271 339 384 504 513 439 623 631 757 642];
 
33
g('node_y')=[59 133 223 318 227 319 221 324 432 141 209 319 428 443 187 151 301];
 
34
show_graph(g);
 
35
g1=contract_edge(10,13,g);
 
36
show_graph(g1,'new');
 
37
.fi
 
38
.SH SEE ALSO
 
39
add_edge, add_node, delete_arcs, delete_nodes