Alphabet

0:a
cons:[c × d] ⟶ d
false:b
filter:[c → b × d] ⟶ d
filter2:[b × c → b × c × d] ⟶ d
map:[c → c × d] ⟶ d
minus:[a × a] ⟶ a
nil:d
plus:[a × a] ⟶ a
quot:[a × a] ⟶ a
s:[a] ⟶ a
true:b

Variables

X:a
Y:a
U:a
V:a
W:a
P:a
X1:a
Y1:a
U1:a
V1:a
W1:a
P1:a
X2:a
Y2:a
U2:a
H2:c → c
I2:c → c
P2:c
X3:d
Z3:c → b
G3:c → b
V3:c
W3:d
J3:c → b
X4:c
Y4:d
G4:c → b
V4:c
W4:d

Rules

minus(X, 0)X
minus(s(Y), s(U))minus(Y, U)
quot(0, s(V))0
quot(s(W), s(P))s(quot(minus(W, P), s(P)))
plus(0, X1)X1
plus(s(Y1), U1)s(plus(Y1, U1))
plus(minus(V1, s(0)), minus(W1, s(s(P1))))plus(minus(W1, s(s(P1))), minus(V1, s(0)))
plus(plus(X2, s(0)), plus(Y2, s(s(U2))))plus(plus(Y2, s(s(U2))), plus(X2, s(0)))
map(H2, nil)nil
map(I2, cons(P2, X3))cons(I2 · P2, map(I2, X3))
filter(Z3, nil)nil
filter(G3, cons(V3, W3))filter2(G3 · V3, G3, V3, W3)
filter2(true, J3, X4, Y4)cons(X4, filter(J3, Y4))
filter2(false, G4, V4, W4)filter(G4, W4)