File: qassign.cat

package info (click to toggle)
scilab 2.6-4
  • links: PTS
  • area: non-free
  • in suites: woody
  • size: 54,632 kB
  • ctags: 40,267
  • sloc: ansic: 267,851; fortran: 166,549; sh: 10,005; makefile: 4,119; tcl: 1,070; cpp: 233; csh: 143; asm: 135; perl: 130; java: 39
file content (35 lines) | stat: -rw-r--r-- 777 bytes parent folder | download
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
qassign           Scilab Group           Scilab function            qassign
NAME
   qassign - solves a quadratic assignment problem
  
CALLING SEQUENCE
 [crit,order] = qassign(c,f,d)
PARAMETERS
 c  : real matrix
    
 f  : real matrix
    
 d  : real matrix
    
 crit
     : real scalar
    
 order
     : integer row vector 
    
DESCRIPTION
   qassign solves the quadratic assignment problem i.e. minimize the global
  criterium:  crit = e(1)+...+e(n)   where  e(i) = c(i,l(i))+ fd(i)   where
   fd(i) = f(i,1)*d(l(i),l(1))+...+f(i,n)*d(l(i),l(n))   c, f and d are n x
  n real arrays; their diagonal entries are zero. 
  
EXAMPLE
 n=15;
 d=100*rand(15,15);
 d=d-diag(diag(d));
 c=zeros(n,n);f=c;
 f(2:n,1)=ones(1:n-1)';
 [crit,order]=qassign(c,f,d)
SEE ALSO
   knapsack