bos_notes

advertisement
REPORT 1
T is the period a simulation;
J is size of strategy space of a player;
N is number of players;
K is the maximum length of a sequence of strategies;
C1,C2, … ,CK are K JxN matrix presenting the strategy spaces for N players;
L is a JxN matrix presenting the length associated with each strategy in strategy space C
for N players; L contains integers <= K;
m is a 1xN vector presenting the current messages;
mL is a 1xN vector presenting the current lengths;
Algorithm:
strategy matrices [C1,C2, … ,CK] is initialized randomly;
length matrix L is initialized by a given distribution;
randomize message vector m0 and length vector mL0;
FOR T periods
save mt and mLt;
IF “mutate_all”
mutate strategies at the same locations in [C1,C2, … ,CK];
(new value is random)
ELSE IF “mutate_individual”
mutate strategies at the locations in [C1,C2, … ,CK] individually;
(new value is random)
ELSE IF “mutate_length”
mutate lengths in L;
(50% +1, 50% -1)
END IF
FOR J strategies
FOR N players
get length k = L(j,n);
calculate average payoff U(j,n) of periods t-k+1 to t
based on k, strategy space [C1, … ,CK] and history [mt-k+1, …, mt];
END FOR
END FOR
replicate [C1,C2, … ,CK] and L based on U;
select length vector mLt+1 from L based on U;
select message vector m t+1 from [C1,C2, … ,CK] based on U and mLt+1;
END FOR
1
REPORT 2
Examples:
J = [1 2 3];
Length
Strategy
Length
Strategy
t=1
t=2
t=3
t=4
1
2
3
1
t=1
t=2
k=3
2
t=3
t=4
t=5
t=6
3
2
3
2
t=2 t=3
k=3
2
3
t=4
t=5
t=6
1
3
1
t=1
t=2
t=4
t=5
t=6
t=7
1
2
1
2
1
2
t=1
t=2
t=5
t=6
t=7
1
2
t=3 t=4
k=3
3
1
2
3
2
t=1 t=2
k=2
1
2
t=3
t=4
t=5
t=6
3
1
2
t=1
t=3
t=4
t=5
t=6
1
2
3
1
t=4
t=5
t=6
2
3
1
1
t=1
Length
Strategy
Length
Strategy
Length
Strategy
Length
Strategy
Length
Strategy
1
1
t=1
Length
Strategy
1
t=2
k=2
2
t=3
k=3
3
t=2 t=3
k=2
2
1
t=5
t=6
k=3
2
3
t=7
t=8
t=9
t=10
1
2
3
1
t=7 t=8
k=2
3
2
t=9
t=10
3
2
t=7
t=9
t=10
3
1
t=8
k=2
3
1
t=8 t=9
k=2
1
2
t=10
t=8
t=10
t=9
k=2
3
2
t=7
k=3
3
1
1
3
t=8
t=9
t=10
2
3
1
t=7 t=8
k=3
2
3
t=9
t=10
1
2
t=7
t=9
t=10
1
2
t=8
k=3
2
3
2
REPORT 3

This section contains results by the following settings in the Experimentation
1) mutate individual
- randomly choose strategies(vectors of length up to K) in [C1,C2, … ,CK] for mutation;
2) mutate all
- randomly choose strategies(scalars) in each C1,C2, … ,CK strategy spaces
independently for mutation;
3) mutate length
- randomly increment or decrement length only
4) mutate length + mutate individual
5) mutate length + mutate all

Basic settings:
N
= 2;
K
= 3;
init_K_distr = [.33 .33 .33];
J
= 180;
T
= 100;
rho = 0.033;
R ESULTS :
I. Example outputs resulted from one simulation (mutate individual):
In Figure 3.1(a), the top plot is the history of the values players played over a period of T
= 100; the bottom plot is the history of the corresponding lengths over that period.
In Figure 3.1(b), the top plot shows the variance of value in the strategy space [C1,C2, …
,CK] over T period; the bottom plot shows the variance of length in the strategy space
[C1,C2, … ,CK].
Figure 3.1(c) shows the distribution of lengths [1..K] in the strategy space over T period.
Figure 3.1(d), shows the convergence to the patterns the two players played. How the
patterns are estimated are by the following:
3
a) Estimate the converged length for the player, k_conv, which is the most
frequent length at T = 100;
b) divide the history value strategy(figure 3.1(a) top) into segments of length
k_conv, then average the floor(T/k_conv) segments based on the weights that are
the inverse of the strategy variance as shown in figure 3.1(b) top. Therefore,
segments when there's higher variance in strategy space are weighted less, and
segments when there is lower variance are weighted more. Such average of the
segments is the pattern.
c) Once pattern is estimated for both players, we compute the difference between
the history (Figure 3.1(a) top) to the pattern at every k_conv periods as shown by
the two curves in figure 3.1(d).
Note: in the legend of figure 3.1(d), the converged patterns are floating numbers rather
than integer 0 or 1. They are also rounded to the closet integers.
(a)
(b)
(c)
(d)
Figure 3.1
4
II. Example outputs resulted from one simulation (mutate length):
Explanation of the figures is not repeated here.
Note 1:
Since there is no mutation of the strategy-values, the values are only set at the
initialization step. Sometimes the values in the estimated patterns(as shown in the legend
of Figure 3.2(d)) are not close to their rounded integer values 0 or 1.
Note 2:
For this particular simulation, we can see big peaks in the middle of the simulation
around T = 60..80 as shown in figure 3.2(d). This sudden changes correspond to the
altered lengths in the experimentation, as shown in figure 3.2(a) bottom.
(a)
(b)
(c)
(d)
Figure 3.2
III. Example outputs resulted from one simulation (mutate length + mutate all):
Explanation of the figures is not repeated here.
5
Note:
What special about this simulation is in Figure 3.3(b) top, where the variance in
strategy values didn't go down as time went by. This is because only length = 1 was
chosen after T = 60 as shown in figure 3.3(a) bottom and figure 3.3(b) bottom. Hence,
even though the strategies of length = 1(or [C1] ) are homogeneous, but no so in [C2] and
[C3], which wouldn't contribute in computing the payoff, so values in them kept on
mutating. This caused the high variance in Figure 3.3(b) top.
(a)
(b)
(c)
(d)
Figure 3.3
IV. Table summary of results of R = 1000 runs
1) Table 1: Mutate Individual
R=1000 K=1
000
K=2
K=3
16.95 % 10.30 % 7.95 %
6
SUM
35.20 %
001
17.60 % 3.35 %
3.15 %
24.10 %
010
/
3.40 %
3.20 %
6.60 %
011
/
12.40 % 3.10 %
15.50 %
100
/
/
2.95 %
2.95 %
101
/
/
2.35 %
2.35 %
110
/
/
3.35 %
3.35 %
111
/
/
9.95 %
9.95 %
34.55 % 29.45 % 36.00 % 100 %
2). Table 2: Mutate All
R=1000 K=1
K=2
K=3
SUM
000
15.35 % 11.95 % 9.20 %
36.50 %
001
16.20 % 3.00 %
2.80 %
22.00 %
010
/
3.40 %
3.40 %
6.80 %
011
/
13.00 % 2.80 %
15.80 %
100
/
/
3.60 %
3.60 %
101
/
/
3.30 %
3.30 %
110
/
/
3.20 %
3.20 %
111
/
/
8.80 %
8.80 %
31.55 % 31.35 % 37.10 % 100 %
3) Table 3: Mutate Length
R=1000 K=1
K=2
K=3
SUM
000
36.75 % 1.75 % 3.35 %
41.85 %
001
35.10 % 2.50 % 1.30 %
38.90 %
010
/
5.70 %
3.30 % 2.40 %
7
011
/
1.60 % 1.80 %
3.40 %
100
/
/
3.00 %
3.00 %
101
/
/
2.65 %
2.65 %
110
/
/
2.40 %
2.40 %
111
/
/
2.10 %
2.10 %
71.85 % 9.15 % 19.00 % 100 %
4) Table 4: Mutate Individual + mutate length
R=1000 K=1
K=2
K=3
SUM
000
37.65 % 0.10 % 1.75 %
39.50 %
001
38.80 % 2.15 % 1.95 %
42.90 %
010
/
2.15 % 2.25 %
4.40 %
011
/
0.20 % 2.85 %
3.05 %
100
/
/
3.50 %
3.50 %
101
/
/
2.80 %
2.80 %
110
/
/
2.65 %
2.65 %
111
/
/
1.20 %
1.20 %
76.45 % 4.60 % 18.95 % 100 %
5) Table 5: Mutate All + mutate length
R=1000 K=1
K=2
K=3
SUM
000
41.45 % 0.05 % 0.20 %
41.70 %
001
37.80 % 3.70 % 1.95 %
43.45 %
010
/
2.50 % 2.60 %
5.10 %
011
/
0.05 % 1.85 %
1.90 %
100
/
/
2.40 %
2.40 %
8
101
/
/
2.55 %
2.55 %
110
/
/
2.75 %
2.75 %
111
/
/
0.15 %
0.15 %
79.25 % 6.30 % 14.45 % 100 %
Note 1:
As mentioned before, the patterns are usually floating numbers rather than integers, so
they're rounded to form the entries in the 1st columns(blue) of the tables. Sometimes this
rounding is in-accurate especially when the values aren't mutated during the whole
simulation, eg. Figure 3.2(d).
Note 2:
Another observation is that as long as the length is mutated, the frequency playing k = 1
becomes much higher than k = 2 or 3 as shown in table 3-5(last rows). And pattern [0]
and pattern [1] are played around 80% of the time(shown in the first two entries of the 4
columns in the tables). On the other hand, in table 1 and 2, where only values are
mutated, the frequencies of different k's stay approximately the same.
More simulation results and sources can be downloaded at
http://www.sfu.ca/~lshia/econ/bos/result/bos_report3.zip
9
Download