-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCoverage.ma
More file actions
115 lines (95 loc) · 7.15 KB
/
Coverage.ma
File metadata and controls
115 lines (95 loc) · 7.15 KB
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
[top]
components : coverage
[coverage]
type : cell
dim : (13,13,5)
delay : transport
defaultDelayTime : 100
border : nowrapped
neighbors : coverage(-2,0,0)
neighbors : coverage(-1,-1,0) coverage(-1,0,0) coverage(-1,1,0)
neighbors : coverage(0,-2,0) coverage(0,-1,0) coverage(0,0,0) coverage(0,1,0) coverage(0,2,0)
neighbors : coverage(1,-1,0) coverage(1,0,0) coverage(1,1,0)
neighbors : coverage(2,0,0)
neighbors : coverage(-2,0,1)
neighbors : coverage(-1,-1,1) coverage(-1,0,1) coverage(-1,1,1)
neighbors : coverage(0,-2,1) coverage(0,-1,1) coverage(0,0,1) coverage(0,1,1) coverage(0,2,1)
neighbors : coverage(1,-1,1) coverage(1,0,1) coverage(1,1,1)
neighbors : coverage(2,0,1)
neighbors : coverage(-2,0,-1)
neighbors : coverage(-1,-1,-1) coverage(-1,0,-1) coverage(-1,1,-1)
neighbors : coverage(0,-2,-1) coverage(0,-1,-1) coverage(0,0,-1) coverage(0,1,-1) coverage(0,2,-1)
neighbors : coverage(1,-1,-1) coverage(1,0,-1) coverage(1,1,-1)
neighbors : coverage(2,0,-1)
neighbors : coverage(-2,0,-2)
neighbors : coverage(-1,-1,-2) coverage(-1,0,-2) coverage(-1,1,-2)
neighbors : coverage(0,-2,-2) coverage(0,-1,-2) coverage(0,0,-2) coverage(0,1,-2) coverage(0,2,-2)
neighbors : coverage(1,-1,-2) coverage(1,0,-2) coverage(1,1,-2)
neighbors : coverage(2,0,-2)
neighbors : coverage(0,0,2) coverage(0,0,3) coverage(0,0,4)
initialvalue : 9
initialCellsValue : Coverage.val
localtransition : Existence
zone : Movement { (0,0,1)..(12,12,1) }
zone : SigStrUE { (0,0,2)..(12,12,2) }
zone : BSNum { (0,0,3)..(12,12,3) }
zone : SigStr { (0,0,4)..(12,12,4) }
[Existence]
rule : {randInt(1)} 100 { (0,0,0) = 9 } %Just excute at first.
rule : 0 100 { (0,0,0) = 1 and (0,0,3) = 10 }
rule : 1 100 { (0,0,0) = 1 and (0,0,1) = 6 } %Stay at this cell
rule : 0 100 { (0,0,0) = 1 and (0,1,0) = 0 and (0,0,1) = 2 } %Go East
rule : 0 100 { (0,0,0) = 1 and (1,0,0) = 0 and (0,0,1) = 3 and ((1,-1,0) = 0 or (1,-1,1) != 2) } %Go South
rule : 0 100 { (0,0,0) = 1 and (0,-1,0) = 0 and (0,0,1) = 4 and ((0,-2,0) = 0 or (0,-2,1) != 2) and ((-1,-1,0) = 0 or (-1,-1,1) != 3) } %Go West
rule : 0 100 { (0,0,0) = 1 and (-1,0,0) = 0 and (0,0,1) = 5 and ((-1,-1,0) = 0 or (-1,-1,1) != 2) and ((-2,0,0) = 0 or (-2,0,1) != 3) and ((-1,1,0) = 0 or (-1,1,1) != 4) } %Go North
% cell has coverage input from West input from North input from East input from South
rule : 1 100 { (0,0,0) = 0 and (0,0,3) != 10 and (((0,-1,0) = 1 and (0,-1,1) = 2) or ((-1,0,0) = 1 and (-1,0,1) = 3) or ((0,1,0) = 1 and (0,1,1) = 4) or ((1,0,0) = 1 and (1,0,1) = 5)) }
rule : {1} 100 {(0,0,0) = 1} %When the ruls reach here it means that Cell wants to move but it coulden't
rule : {0} 100 {(0,0,0) = 0} %Nothing happen for this Cell.
[Movement]
rule : 9 100 { (0,0,2) = 10 } %No need to caculate movement because no BS cover this cell.
rule : {randInt(4) + 2} 100 { (0,0,0) = 9 }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 6 }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 0 and (0,-1,-1) = 1 and (0,-1,0) = 2 }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 0 and (-1,0,-1) = 1 and (-1,0,0) = 3 }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 0 and (0,1,-1) = 1 and (0,1,0) = 4 }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 0 and (1,0,-1) = 1 and (1,0,0) = 5 }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 2 and (0,1,-1) = 1 }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 3 and (1,0,-1) = 1 }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 4 and (0,-1,-1) = 1 }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 5 and (-1,0,-1) = 1 }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 2 and ((0,1,-1) != 1 and (0,1,-1) != 0) }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 3 and ((1,0,-1) != 1 and (1,0,-1) != 0)}
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 4 and ((0,-1,-1) != 1 and (0,-1,-1) != 0)}
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 5 and ((-1,0,-1) != 1 and (-1,0,-1) != 0)}
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 3 and (1,-1,-1) = 1 and (1,-1,0) = 2 }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 4 and ( ((0,-2,-1) = 1 and (0,-2,0) = 2) or ((-1,-1,-1) = 1 and (-1,-1,0) = 3) ) }
rule : {randInt(4) + 2} 100 { (0,0,-1) = 1 and (0,0,0) = 5 and ( ((-1,-1,-1) = 1 and (-1,-1,0) = 2) or ((-2,0,-1) = 1 and (-2,0,0) = 3) or ((-1,1,-1) = 1 and (-1,1,0) = 4) ) }
rule : 8 100 { (0,0,-1) != 1 or (0,0,0) != 6 }
rule : 8 100 { (0,0,-1) != 0 or (0,-1,-1) != 1 or (0,-1,0) != 2 }
rule : 8 100 { (0,0,-1) != 0 or (-1,0,-1) != 1 or (-1,0,0) != 3 }
rule : 8 100 { (0,0,-1) != 0 or (0,1,-1) != 1 or (0,1,0) != 4 }
rule : 8 100 { (0,0,-1) != 0 or (1,0,-1) != 1 or (1,0,0) != 5 }
[SigStrUE]
rule : 7 100 { (0,0,1) = 10 } %No need to caculate movement because no BS cover this cell.
rule : 7 100 { (0,0,-2) = 0 and (0,-1,-1) != 2 and (-1,0,-1) != 3 and (0,1,-1) != 4 and (1,0,-1) != 5 }
rule : 7 100 { (0,0,-2) = 1 and (0,0,-1) = 2 and (0,1,-2) = 0 }
rule : 7 100 { (0,0,-2) = 1 and (0,0,-1) = 3 and (1,0,-2) = 0 and ((1,-1,-2) = 0 or (1,-1,-1) != 2) }
rule : 7 100 { (0,0,-2) = 1 and (0,0,-1) = 4 and (0,-1,-2) = 0 and ((0,-2,-2) = 0 or (0,-2,-1) != 2) and ((-1,-1,-2) = 0 or (-1,-1,-1) != 3) }
rule : 7 100 { (0,0,-2) = 1 and (0,0,-1) = 5 and (-1,0,-2) = 0 and ((-1,-1,-2) = 0 or (-1,-1,-1) != 2) and ((-2,0,-2) = 0 or (-2,0,-1) != 3) and ((-1,1,-2) = 0 or (-1,1,-1) != 4) }
rule : 25 100 { (0,0,2) = 20 }
rule : 26 100 { (0,0,2) = 21 }
rule : 27 100 { (0,0,2) = 22 }
rule : 28 100 { (0,0,2) = 23 }
[BSNum]
rule : {10} 100 {(0,0,0) = 10} %Number of BS that can support this cell is 0
rule : {11} 100 {(0,0,0) = 11} %Number of BS that can support this cell is 1
rule : {12} 100 {(0,0,0) = 12} %Number of BS that can support this cell is 2 (It does not mean that the coverage should be betther than the others. It happens in border areas of Cell Network.)
rule : {13} 100 {(0,0,0) = 13} %Number of BS that can support this cell is 3 It does not mean that the coverage should be betther than the others. It happens in border areas of Cell Network.)
rule : 9 100 { (0,0,0) = 9 }
[SigStr]
rule : {20} 100 {(0,0,0) = 20} %No Coverage
rule : {21} 100 {(0,0,0) = 21} %Weak Coverage -- Near the Cell Net border (without CoMP).
rule : {22} 100 {(0,0,0) = 22} %Good Coverage -- Cell has one hop distance from center of Cell Net or It is the border of the Cell Net ans can support by more than one BS (with CoMP).
rule : {23} 100 {(0,0,0) = 23} %Excellent Coverage -- EU is at the center of the Cell Net.
rule : 9 100 { (0,0,0) = 9 }