YES
0 QTRS
↳1 QTRSRRRProof (⇔, 74 ms)
↳2 QTRS
↳3 QTRSRRRProof (⇔, 0 ms)
↳4 QTRS
↳5 RisEmptyProof (⇔, 0 ms)
↳6 YES
natsFrom(N) → cons(N, n__natsFrom(s(N)))
fst(pair(XS, YS)) → XS
snd(pair(XS, YS)) → YS
splitAt(0, XS) → pair(nil, XS)
splitAt(s(N), cons(X, XS)) → u(splitAt(N, activate(XS)), N, X, activate(XS))
u(pair(YS, ZS), N, X, XS) → pair(cons(activate(X), YS), ZS)
head(cons(N, XS)) → N
tail(cons(N, XS)) → activate(XS)
sel(N, XS) → head(afterNth(N, XS))
take(N, XS) → fst(splitAt(N, XS))
afterNth(N, XS) → snd(splitAt(N, XS))
natsFrom(X) → n__natsFrom(X)
activate(n__natsFrom(X)) → natsFrom(X)
activate(X) → X
tail1 > [natsFrom1, activate1] > cons2 > [snd1, 0, nil]
tail1 > [natsFrom1, activate1] > s1 > [snd1, 0, nil]
[sel2, afterNth2] > splitAt2 > u4 > [natsFrom1, activate1] > cons2 > [snd1, 0, nil]
[sel2, afterNth2] > splitAt2 > u4 > [natsFrom1, activate1] > s1 > [snd1, 0, nil]
[sel2, afterNth2] > splitAt2 > u4 > pair2 > [snd1, 0, nil]
take2 > splitAt2 > u4 > [natsFrom1, activate1] > cons2 > [snd1, 0, nil]
take2 > splitAt2 > u4 > [natsFrom1, activate1] > s1 > [snd1, 0, nil]
take2 > splitAt2 > u4 > pair2 > [snd1, 0, nil]
natsFrom1: [1]
cons2: [1,2]
s1: [1]
pair2: multiset
snd1: [1]
splitAt2: [1,2]
0: multiset
nil: multiset
u4: multiset
activate1: [1]
tail1: [1]
sel2: multiset
afterNth2: multiset
take2: multiset
natsFrom(N) → cons(N, n__natsFrom(s(N)))
fst(pair(XS, YS)) → XS
snd(pair(XS, YS)) → YS
splitAt(0, XS) → pair(nil, XS)
splitAt(s(N), cons(X, XS)) → u(splitAt(N, activate(XS)), N, X, activate(XS))
u(pair(YS, ZS), N, X, XS) → pair(cons(activate(X), YS), ZS)
head(cons(N, XS)) → N
tail(cons(N, XS)) → activate(XS)
take(N, XS) → fst(splitAt(N, XS))
afterNth(N, XS) → snd(splitAt(N, XS))
natsFrom(X) → n__natsFrom(X)
activate(X) → X
sel(N, XS) → head(afterNth(N, XS))
activate(n__natsFrom(X)) → natsFrom(X)
activate1 > sel2 > natsFrom1 > nnatsFrom1 > afterNth2 > head1
head_1=1
activate_1=1
n__natsFrom_1=1
natsFrom_1=2
sel_2=1
afterNth_2=0
sel(N, XS) → head(afterNth(N, XS))
activate(n__natsFrom(X)) → natsFrom(X)