Quadratic Assignment Problem: Cost function

R

Rasmus Rasmussen

How do I create a formula like this:
∑ iεM ∑ jεM ∑ kεN ∑ lεN (bij x akl x Uik x Ujl)

I have a symmetric matrix of size M of distances b(ij)
between different areas, and another symmetric matrix of
size N of interaction between different services a(kl).

I have made a small spreadsheet where both matrixes are
of size 4.

The matrix U of size MxN consists binary entries, which
allocates the services to the areas.

The formula in the top is the cost function.

A B C D E F
1 Distances (b)
2 Area a b c d
3 a 0 1 2 4
4 b 1 0 1 3
5 c 2 1 0 2
6 d 4 3 2 0
7
8
9 Interaction (a)
10 Service 1 2 3 4
11 1 0 7 8 4
12 2 7 0 7 0
13 3 8 7 0 5
14 4 4 0 5 0
15
16
17 Allocation (U)
18 1 2 3 4
19 a 1
20 b 1
21 c 1
22 d 1


Can I make the formula directly, or do I have to create
one or more cost matrixes to add up the total costs?

Regards,
Rasmus Rasmussen
 
R

Rasmus Rasmussen

The formula should look like this:

Sum i in M Sum j in M Sum k in N Sum l in N (b[ij] x a[kl] x U[ik] x U[jl])



(I see that symbols are not displayed in the text, so my original formula is
not readable. The tables also becomes a mess, but they are just examples,
and not important.)



Anyone having suggestions for such a formula?



Regards,

Rasmus
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top