~ubuntu-branches/ubuntu/hoary/scilab/hoary

« back to all changes in this revision

Viewing changes to man/metanet/circuit.cat

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2005-01-09 22:58:21 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20050109225821-473xr8vhgugxxx5j
Tags: 3.0-12
changed configure.in to build scilab's own malloc.o, closes: #255869

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
circuit           Scilab Group           Scilab function            circuit
2
 
NAME
3
 
   circuit - finds a circuit or the rank function in a directed graph
4
 
  
5
 
CALLING SEQUENCE
6
 
 [p,r] = circuit(g)
7
 
PARAMETERS
8
 
 g  : graph list
9
 
    
10
 
 p  : row vector of integer numbers of the arcs of the circuit if it
11
 
    exists
12
 
    
13
 
 r  : row vector of rank function if there is no circuit
14
 
    
15
 
DESCRIPTION
16
 
   circuit tries to find a circuit for the directed graph g. It returns the
17
 
  circuit p as a row vector of the corresponding arc numbers if it exists
18
 
  and it returns the empty vector [] otherwise. If the graph has no
19
 
  circuit, the rank function is returned in r,  otherwise its value is the
20
 
  empty vector [].
21
 
  
22
 
EXAMPLE
23
 
 // graph with circuit
24
 
 ta=[1 1 2 3 5 4 6 7 7 3 3 8 8 5];
25
 
 he=[2 3 5 4 6 6 7 4 3 2 8 1 7 4];
26
 
 g=make_graph('foo',1,8,ta,he);
27
 
 g('node_x')=[116 231 192 323 354 454 305 155];
28
 
 g('node_y')=[ 118 116 212 219 117 185 334 316];
29
 
 show_graph(g);
30
 
 p=circuit(g)
31
 
 show_arcs(p)
32
 
 // graph without circuit
33
 
 g=make_graph('foo',1,4,[1 2 2 3],[2 3 4 4]);
34
 
 [p,r]=circuit(g)