Commit b34dd76e authored by Tobias MEGGENDORFER's avatar Tobias MEGGENDORFER
Browse files

Snapshot

parent 346051ee
......@@ -62,7 +62,7 @@ configurations {
application {
mainClass.set("com.cges.Main")
applicationDefaultJvmArgs = listOf("-ea")
// applicationDefaultJvmArgs = listOf("-ea")
}
tasks.generateGrammarSource {
......
import sys
import json
if __name__ == "__main__":
n = int(sys.argv[1])
json.dump({
"name": f"gossip{n}",
"ap": [f"g{i}" for i in range(1, n + 1)],
"modules": {
f"A{i}": {
"goal": f"G F g{i}",
"payoff": "?",
"actions": ["a", "g", "w"],
"labels": [f"g{i}"],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},
{
"action": "g",
"guard": "true",
"to": "s2"
}
]
},
"s2": {
"labels": [f"g{i}"],
"transitions": [
{
"action": "w",
"guard": " & ".join(f"!g{j}" for j in range(1, n+1) if j != i),
"to": "s2"
},
{
"action": "g",
"guard": " | ".join(f"g{j}" for j in range(1, n+1) if j != i),
"to": "s2"
}
]
}
}
} for i in range(1, n+1)
}
}, sys.stdout)
{
"name": "gossip2",
"name": "gossip3",
"ap": [
"g1",
"g2",
......@@ -8,7 +8,7 @@
"modules": {
"A1": {
"goal": "G F g1",
"payoff": true,
"payoff": "?",
"actions": [
"a",
"g",
......@@ -55,7 +55,7 @@
},
"A2": {
"goal": "G F g2",
"payoff": true,
"payoff": "?",
"actions": [
"a",
"g",
......@@ -102,7 +102,7 @@
},
"A3": {
"goal": "G F g3",
"payoff": true,
"payoff": "?",
"actions": [
"a",
"g",
......
{
"name": "gossip4",
"ap": [
"g1",
"g2",
"g3",
"g4"
],
"modules": {
"A1": {
"goal": "G F g1",
"payoff": "?",
"actions": [
"a",
"g",
"w"
],
"labels": [
"g1"
],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},
{
"action": "g",
"guard": "true",
"to": "s2"
}
]
},
"s2": {
"labels": [
"g1"
],
"transitions": [
{
"action": "w",
"guard": "!g2 & !g3 & !g4",
"to": "s2"
},
{
"action": "g",
"guard": "g2 | g3 | g4",
"to": "s2"
}
]
}
}
},
"A2": {
"goal": "G F g2",
"payoff": "?",
"actions": [
"a",
"g",
"w"
],
"labels": [
"g2"
],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},
{
"action": "g",
"guard": "true",
"to": "s2"
}
]
},
"s2": {
"labels": [
"g2"
],
"transitions": [
{
"action": "w",
"guard": "!g1 & !g3 & !g4",
"to": "s2"
},
{
"action": "g",
"guard": "g1 | g3 | g4",
"to": "s2"
}
]
}
}
},
"A3": {
"goal": "G F g3",
"payoff": "?",
"actions": [
"a",
"g",
"w"
],
"labels": [
"g3"
],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},
{
"action": "g",
"guard": "true",
"to": "s2"
}
]
},
"s2": {
"labels": [
"g3"
],
"transitions": [
{
"action": "w",
"guard": "!g1 & !g2 & !g4",
"to": "s2"
},
{
"action": "g",
"guard": "g1 | g2 | g4",
"to": "s2"
}
]
}
}
},
"A4": {
"goal": "G F g4",
"payoff": "?",
"actions": [
"a",
"g",
"w"
],
"labels": [
"g4"
],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},
{
"action": "g",
"guard": "true",
"to": "s2"
}
]
},
"s2": {
"labels": [
"g4"
],
"transitions": [
{
"action": "w",
"guard": "!g1 & !g2 & !g3",
"to": "s2"
},
{
"action": "g",
"guard": "g1 | g2 | g3",
"to": "s2"
}
]
}
}
}
}
}
{
"name": "gossip6",
"ap": [
"g1",
"g2",
"g3",
"g4",
"g5",
"g6"
],
"modules": {
"A1": {
"goal": "G F g1",
"payoff": "?",
"actions": [
"a",
"g",
"w"
],
"labels": [
"g1"
],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},
{
"action": "g",
"guard": "true",
"to": "s2"
}
]
},
"s2": {
"labels": [
"g1"
],
"transitions": [
{
"action": "w",
"guard": "!g2 & !g3 & !g4 & !g5 & !g6",
"to": "s2"
},
{
"action": "g",
"guard": "g2 | g3 | g4 | g5 | g6",
"to": "s2"
}
]
}
}
},
"A2": {
"goal": "G F g2",
"payoff": "?",
"actions": [
"a",
"g",
"w"
],
"labels": [
"g2"
],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},
{
"action": "g",
"guard": "true",
"to": "s2"
}
]
},
"s2": {
"labels": [
"g2"
],
"transitions": [
{
"action": "w",
"guard": "!g1 & !g3 & !g4 & !g5 & !g6",
"to": "s2"
},
{
"action": "g",
"guard": "g1 | g3 | g4 | g5 | g6",
"to": "s2"
}
]
}
}
},
"A3": {
"goal": "G F g3",
"payoff": "?",
"actions": [
"a",
"g",
"w"
],
"labels": [
"g3"
],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},
{
"action": "g",
"guard": "true",
"to": "s2"
}
]
},
"s2": {
"labels": [
"g3"
],
"transitions": [
{
"action": "w",
"guard": "!g1 & !g2 & !g4 & !g5 & !g6",
"to": "s2"
},
{
"action": "g",
"guard": "g1 | g2 | g4 | g5 | g6",
"to": "s2"
}
]
}
}
},
"A4": {
"goal": "G F g4",
"payoff": "?",
"actions": [
"a",
"g",
"w"
],
"labels": [
"g4"
],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},
{
"action": "g",
"guard": "true",
"to": "s2"
}
]
},
"s2": {
"labels": [
"g4"
],
"transitions": [
{
"action": "w",
"guard": "!g1 & !g2 & !g3 & !g5 & !g6",
"to": "s2"
},
{
"action": "g",
"guard": "g1 | g2 | g3 | g5 | g6",
"to": "s2"
}
]
}
}
},
"A5": {
"goal": "G F g5",
"payoff": "?",
"actions": [
"a",
"g",
"w"
],
"labels": [
"g5"
],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},
{
"action": "g",
"guard": "true",
"to": "s2"
}
]
},
"s2": {
"labels": [
"g5"
],
"transitions": [
{
"action": "w",
"guard": "!g1 & !g2 & !g3 & !g4 & !g6",
"to": "s2"
},
{
"action": "g",
"guard": "g1 | g2 | g3 | g4 | g6",
"to": "s2"
}
]
}
}
},
"A6": {
"goal": "G F g6",
"payoff": "?",
"actions": [
"a",
"g",
"w"
],
"labels": [
"g6"
],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},
{
"action": "g",
"guard": "true",
"to": "s2"
}
]
},
"s2": {
"labels": [
"g6"
],
"transitions": [
{
"action": "w",
"guard": "!g1 & !g2 & !g3 & !g4 & !g5",
"to": "s2"
},
{
"action": "g",
"guard": "g1 | g2 | g3 | g4 | g5",
"to": "s2"
}
]
}
}
}
}
}
{
"name": "gossip8",
"ap": [
"g1",
"g2",
"g3",
"g4",
"g5",
"g6",
"g7",
"g8"
],
"modules": {
"A1": {
"goal": "G F g1",
"payoff": "?",
"actions": [
"a",
"g",
"w"
],
"labels": [
"g1"
],
"initial": "s1",
"states": {
"s1": {
"labels": [],
"transitions": [
{
"action": "a",
"guard": "true",
"to": "s1"
},