Skip to content

Commit 216c0fb

Browse files
ZachJHansenteiesti
authored andcommittedMar 25, 2025·
making the SZS status regex flexible enough to capture timeouts
1 parent 9212af1 commit 216c0fb

File tree

5 files changed

+71
-2
lines changed

5 files changed

+71
-2
lines changed
 
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
out
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
tptp_compliance verify --equivalence external --no-proof-search --save-problems $OUT tiling.1.lp tiling.2.lp tiling.ug tiling.U.po

‎res/examples/external_equivalence/tiling/README.md

+4
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ Vladimir Lifschitz, student examples.
77

88
## Usage
99
```
10+
anthem verify --equivalence external -m 4 tiling.{1.lp,2.lp,ug,U.po} -t 200
11+
```
12+
or, using the same proof outline divided into two files,
13+
```
1014
anthem verify --equivalence external -m 4 tiling.{1.lp,2.lp,ug,F.po} -t 100 --direction forward
1115
anthem verify --equivalence external -m 4 tiling.{1.lp,2.lp,ug,B.po} -t 200 --direction backward
1216
```
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
definition: forall I$ J$ (filled2(I$,J$) <->
2+
place(I$,J$,2) or place(I$-1,J$,2) or place(I$-2,J$,2)).
3+
4+
definition: forall I$ J$ (filled3(I$,J$) <->
5+
place(I$,J$,3) or place(I$,J$-1,3) or place(I$,J$-2,3)).
6+
7+
lemma(forward):
8+
filled2(I$,J$) -> h(J$,I$) or h(J$,I$-1) or h(J$,I$-2).
9+
10+
lemma(forward):
11+
filled2(I$,J$) -> covered(J$,I$).
12+
13+
lemma(forward):
14+
filled3(I$,J$) -> v(J$,I$) or v(J$-1,I$) or v(J$-2,I$).
15+
16+
lemma(forward):
17+
filled3(I$,J$) -> covered(J$,I$).
18+
19+
lemma(forward):
20+
filled2(I$,J$) -> h(J$,I$) or h(J$,I$-1) or h(J$,I$-2).
21+
22+
lemma(forward):
23+
filled2(I$,J$) -> covered(J$,I$).
24+
25+
lemma(forward):
26+
filled(I$,J$) ->
27+
place(I$,J$,1) or filled2(I$,J$) or filled3(I$,J$).
28+
29+
lemma(forward):
30+
square(I$,J$) ->
31+
place(I$,J$,1) or filled2(I$,J$) or filled3(I$,J$).
32+
33+
lemma(forward):
34+
square(I$,J$) -> place(I$,J$,1) or covered(J$,I$).
35+
36+
37+
38+
lemma(backward):
39+
place(V1, V2, V3) ->
40+
V3 = 1 and square(V2, V1) and not covered(V2, V1) or
41+
V3 = 2 and h(V2, V1) or
42+
V3 = 3 and v(V2, V1).
43+
44+
lemma(backward):
45+
not(h(R,C) and v(R,C)).
46+
47+
lemma(backward):
48+
not(h(R$,C$) and h(R$,C$+I$) and 1 <= I$ <= 2).
49+
50+
lemma(backward):
51+
not(h(R$,C$) and v(R$,C$+I$) and 0 <= I$ <= 2).
52+
53+
lemma(backward):
54+
not(v(R$,C$) and h(R$+I$,C$) and 0 <= I$ <= 2).
55+
56+
lemma(backward):
57+
not(v(R$,C$) and h(R$+I$,C$-J$) and 0 <= J$ <= 2 and 1 <= I$ <= 2).
58+
59+
lemma(backward):
60+
square(I$,J$) -> place(I$,J$,1) or filled2(I$,J$) or filled3(I$,J$).
61+
62+
lemma(backward): filled2(I$,J$) -> filled(I$,J$).
63+
64+
lemma(backward): filled3(I$,J$) -> filled(I$,J$).

‎src/verifying/prover/mod.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,7 @@ pub mod vampire;
1515

1616
lazy_static! {
1717
static ref STATUS: Regex =
18-
Regex::new(r"(?m)^% SZS status (?<status>[[:word:]]+) for (?<problem>[[:word:]]*)$")
19-
.unwrap();
18+
Regex::new(r"SZS status (?<status>[[:word:]]+) for (?<problem>[[:word:]]*)").unwrap();
2019
}
2120

2221
#[derive(Debug, Error)]

0 commit comments

Comments
 (0)
Please sign in to comment.