Left Termination of the query pattern ackerman(b,b,f) w.r.t. the given Prolog program could successfully be proven:



PROLOG
  ↳ PrologToPiTRSProof

ackerman3(00, N, s1(N)).
ackerman3(s1(M), 00, Res) :- ackerman3(M, s1(00), Res).
ackerman3(s1(M), s1(N), Res) :- ackerman3(s1(M), N, Res1), ackerman3(M, Res1, Res).


With regard to the inferred argument filtering the predicates were used in the following modes:
ackerman3: (b,b,f)
Transforming PROLOG into the following Term Rewriting System:
Pi-finite rewrite system:
The TRS R consists of the following rules:


ackerman_3_in_gga3(0_0, N, s_11(N)) -> ackerman_3_out_gga3(0_0, N, s_11(N))
ackerman_3_in_gga3(s_11(M), 0_0, Res) -> if_ackerman_3_in_1_gga3(M, Res, ackerman_3_in_gga3(M, s_11(0_0), Res))
ackerman_3_in_gga3(s_11(M), s_11(N), Res) -> if_ackerman_3_in_2_gga4(M, N, Res, ackerman_3_in_gga3(s_11(M), N, Res1))
if_ackerman_3_in_2_gga4(M, N, Res, ackerman_3_out_gga3(s_11(M), N, Res1)) -> if_ackerman_3_in_3_gga5(M, N, Res, Res1, ackerman_3_in_gga3(M, Res1, Res))
if_ackerman_3_in_3_gga5(M, N, Res, Res1, ackerman_3_out_gga3(M, Res1, Res)) -> ackerman_3_out_gga3(s_11(M), s_11(N), Res)
if_ackerman_3_in_1_gga3(M, Res, ackerman_3_out_gga3(M, s_11(0_0), Res)) -> ackerman_3_out_gga3(s_11(M), 0_0, Res)

The argument filtering Pi contains the following mapping:
ackerman_3_in_gga3(x1, x2, x3)  =  ackerman_3_in_gga2(x1, x2)
0_0  =  0_0
s_11(x1)  =  s_11(x1)
ackerman_3_out_gga3(x1, x2, x3)  =  ackerman_3_out_gga1(x3)
if_ackerman_3_in_1_gga3(x1, x2, x3)  =  if_ackerman_3_in_1_gga1(x3)
if_ackerman_3_in_2_gga4(x1, x2, x3, x4)  =  if_ackerman_3_in_2_gga2(x1, x4)
if_ackerman_3_in_3_gga5(x1, x2, x3, x4, x5)  =  if_ackerman_3_in_3_gga1(x5)

Infinitary Constructor Rewriting Termination of PiTRS implies Termination of PROLOG



↳ PROLOG
  ↳ PrologToPiTRSProof
PiTRS
      ↳ DependencyPairsProof

Pi-finite rewrite system:
The TRS R consists of the following rules:

ackerman_3_in_gga3(0_0, N, s_11(N)) -> ackerman_3_out_gga3(0_0, N, s_11(N))
ackerman_3_in_gga3(s_11(M), 0_0, Res) -> if_ackerman_3_in_1_gga3(M, Res, ackerman_3_in_gga3(M, s_11(0_0), Res))
ackerman_3_in_gga3(s_11(M), s_11(N), Res) -> if_ackerman_3_in_2_gga4(M, N, Res, ackerman_3_in_gga3(s_11(M), N, Res1))
if_ackerman_3_in_2_gga4(M, N, Res, ackerman_3_out_gga3(s_11(M), N, Res1)) -> if_ackerman_3_in_3_gga5(M, N, Res, Res1, ackerman_3_in_gga3(M, Res1, Res))
if_ackerman_3_in_3_gga5(M, N, Res, Res1, ackerman_3_out_gga3(M, Res1, Res)) -> ackerman_3_out_gga3(s_11(M), s_11(N), Res)
if_ackerman_3_in_1_gga3(M, Res, ackerman_3_out_gga3(M, s_11(0_0), Res)) -> ackerman_3_out_gga3(s_11(M), 0_0, Res)

The argument filtering Pi contains the following mapping:
ackerman_3_in_gga3(x1, x2, x3)  =  ackerman_3_in_gga2(x1, x2)
0_0  =  0_0
s_11(x1)  =  s_11(x1)
ackerman_3_out_gga3(x1, x2, x3)  =  ackerman_3_out_gga1(x3)
if_ackerman_3_in_1_gga3(x1, x2, x3)  =  if_ackerman_3_in_1_gga1(x3)
if_ackerman_3_in_2_gga4(x1, x2, x3, x4)  =  if_ackerman_3_in_2_gga2(x1, x4)
if_ackerman_3_in_3_gga5(x1, x2, x3, x4, x5)  =  if_ackerman_3_in_3_gga1(x5)


Pi DP problem:
The TRS P consists of the following rules:

ACKERMAN_3_IN_GGA3(s_11(M), 0_0, Res) -> IF_ACKERMAN_3_IN_1_GGA3(M, Res, ackerman_3_in_gga3(M, s_11(0_0), Res))
ACKERMAN_3_IN_GGA3(s_11(M), 0_0, Res) -> ACKERMAN_3_IN_GGA3(M, s_11(0_0), Res)
ACKERMAN_3_IN_GGA3(s_11(M), s_11(N), Res) -> IF_ACKERMAN_3_IN_2_GGA4(M, N, Res, ackerman_3_in_gga3(s_11(M), N, Res1))
ACKERMAN_3_IN_GGA3(s_11(M), s_11(N), Res) -> ACKERMAN_3_IN_GGA3(s_11(M), N, Res1)
IF_ACKERMAN_3_IN_2_GGA4(M, N, Res, ackerman_3_out_gga3(s_11(M), N, Res1)) -> IF_ACKERMAN_3_IN_3_GGA5(M, N, Res, Res1, ackerman_3_in_gga3(M, Res1, Res))
IF_ACKERMAN_3_IN_2_GGA4(M, N, Res, ackerman_3_out_gga3(s_11(M), N, Res1)) -> ACKERMAN_3_IN_GGA3(M, Res1, Res)

The TRS R consists of the following rules:

ackerman_3_in_gga3(0_0, N, s_11(N)) -> ackerman_3_out_gga3(0_0, N, s_11(N))
ackerman_3_in_gga3(s_11(M), 0_0, Res) -> if_ackerman_3_in_1_gga3(M, Res, ackerman_3_in_gga3(M, s_11(0_0), Res))
ackerman_3_in_gga3(s_11(M), s_11(N), Res) -> if_ackerman_3_in_2_gga4(M, N, Res, ackerman_3_in_gga3(s_11(M), N, Res1))
if_ackerman_3_in_2_gga4(M, N, Res, ackerman_3_out_gga3(s_11(M), N, Res1)) -> if_ackerman_3_in_3_gga5(M, N, Res, Res1, ackerman_3_in_gga3(M, Res1, Res))
if_ackerman_3_in_3_gga5(M, N, Res, Res1, ackerman_3_out_gga3(M, Res1, Res)) -> ackerman_3_out_gga3(s_11(M), s_11(N), Res)
if_ackerman_3_in_1_gga3(M, Res, ackerman_3_out_gga3(M, s_11(0_0), Res)) -> ackerman_3_out_gga3(s_11(M), 0_0, Res)

The argument filtering Pi contains the following mapping:
ackerman_3_in_gga3(x1, x2, x3)  =  ackerman_3_in_gga2(x1, x2)
0_0  =  0_0
s_11(x1)  =  s_11(x1)
ackerman_3_out_gga3(x1, x2, x3)  =  ackerman_3_out_gga1(x3)
if_ackerman_3_in_1_gga3(x1, x2, x3)  =  if_ackerman_3_in_1_gga1(x3)
if_ackerman_3_in_2_gga4(x1, x2, x3, x4)  =  if_ackerman_3_in_2_gga2(x1, x4)
if_ackerman_3_in_3_gga5(x1, x2, x3, x4, x5)  =  if_ackerman_3_in_3_gga1(x5)
IF_ACKERMAN_3_IN_3_GGA5(x1, x2, x3, x4, x5)  =  IF_ACKERMAN_3_IN_3_GGA1(x5)
ACKERMAN_3_IN_GGA3(x1, x2, x3)  =  ACKERMAN_3_IN_GGA2(x1, x2)
IF_ACKERMAN_3_IN_1_GGA3(x1, x2, x3)  =  IF_ACKERMAN_3_IN_1_GGA1(x3)
IF_ACKERMAN_3_IN_2_GGA4(x1, x2, x3, x4)  =  IF_ACKERMAN_3_IN_2_GGA2(x1, x4)

We have to consider all (P,R,Pi)-chains

↳ PROLOG
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
PiDP
          ↳ DependencyGraphProof

Pi DP problem:
The TRS P consists of the following rules:

ACKERMAN_3_IN_GGA3(s_11(M), 0_0, Res) -> IF_ACKERMAN_3_IN_1_GGA3(M, Res, ackerman_3_in_gga3(M, s_11(0_0), Res))
ACKERMAN_3_IN_GGA3(s_11(M), 0_0, Res) -> ACKERMAN_3_IN_GGA3(M, s_11(0_0), Res)
ACKERMAN_3_IN_GGA3(s_11(M), s_11(N), Res) -> IF_ACKERMAN_3_IN_2_GGA4(M, N, Res, ackerman_3_in_gga3(s_11(M), N, Res1))
ACKERMAN_3_IN_GGA3(s_11(M), s_11(N), Res) -> ACKERMAN_3_IN_GGA3(s_11(M), N, Res1)
IF_ACKERMAN_3_IN_2_GGA4(M, N, Res, ackerman_3_out_gga3(s_11(M), N, Res1)) -> IF_ACKERMAN_3_IN_3_GGA5(M, N, Res, Res1, ackerman_3_in_gga3(M, Res1, Res))
IF_ACKERMAN_3_IN_2_GGA4(M, N, Res, ackerman_3_out_gga3(s_11(M), N, Res1)) -> ACKERMAN_3_IN_GGA3(M, Res1, Res)

The TRS R consists of the following rules:

ackerman_3_in_gga3(0_0, N, s_11(N)) -> ackerman_3_out_gga3(0_0, N, s_11(N))
ackerman_3_in_gga3(s_11(M), 0_0, Res) -> if_ackerman_3_in_1_gga3(M, Res, ackerman_3_in_gga3(M, s_11(0_0), Res))
ackerman_3_in_gga3(s_11(M), s_11(N), Res) -> if_ackerman_3_in_2_gga4(M, N, Res, ackerman_3_in_gga3(s_11(M), N, Res1))
if_ackerman_3_in_2_gga4(M, N, Res, ackerman_3_out_gga3(s_11(M), N, Res1)) -> if_ackerman_3_in_3_gga5(M, N, Res, Res1, ackerman_3_in_gga3(M, Res1, Res))
if_ackerman_3_in_3_gga5(M, N, Res, Res1, ackerman_3_out_gga3(M, Res1, Res)) -> ackerman_3_out_gga3(s_11(M), s_11(N), Res)
if_ackerman_3_in_1_gga3(M, Res, ackerman_3_out_gga3(M, s_11(0_0), Res)) -> ackerman_3_out_gga3(s_11(M), 0_0, Res)

The argument filtering Pi contains the following mapping:
ackerman_3_in_gga3(x1, x2, x3)  =  ackerman_3_in_gga2(x1, x2)
0_0  =  0_0
s_11(x1)  =  s_11(x1)
ackerman_3_out_gga3(x1, x2, x3)  =  ackerman_3_out_gga1(x3)
if_ackerman_3_in_1_gga3(x1, x2, x3)  =  if_ackerman_3_in_1_gga1(x3)
if_ackerman_3_in_2_gga4(x1, x2, x3, x4)  =  if_ackerman_3_in_2_gga2(x1, x4)
if_ackerman_3_in_3_gga5(x1, x2, x3, x4, x5)  =  if_ackerman_3_in_3_gga1(x5)
IF_ACKERMAN_3_IN_3_GGA5(x1, x2, x3, x4, x5)  =  IF_ACKERMAN_3_IN_3_GGA1(x5)
ACKERMAN_3_IN_GGA3(x1, x2, x3)  =  ACKERMAN_3_IN_GGA2(x1, x2)
IF_ACKERMAN_3_IN_1_GGA3(x1, x2, x3)  =  IF_ACKERMAN_3_IN_1_GGA1(x3)
IF_ACKERMAN_3_IN_2_GGA4(x1, x2, x3, x4)  =  IF_ACKERMAN_3_IN_2_GGA2(x1, x4)

We have to consider all (P,R,Pi)-chains
The approximation of the Dependency Graph contains 1 SCC with 2 less nodes.

↳ PROLOG
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
PiDP
              ↳ PiDPToQDPProof

Pi DP problem:
The TRS P consists of the following rules:

ACKERMAN_3_IN_GGA3(s_11(M), s_11(N), Res) -> ACKERMAN_3_IN_GGA3(s_11(M), N, Res1)
ACKERMAN_3_IN_GGA3(s_11(M), s_11(N), Res) -> IF_ACKERMAN_3_IN_2_GGA4(M, N, Res, ackerman_3_in_gga3(s_11(M), N, Res1))
ACKERMAN_3_IN_GGA3(s_11(M), 0_0, Res) -> ACKERMAN_3_IN_GGA3(M, s_11(0_0), Res)
IF_ACKERMAN_3_IN_2_GGA4(M, N, Res, ackerman_3_out_gga3(s_11(M), N, Res1)) -> ACKERMAN_3_IN_GGA3(M, Res1, Res)

The TRS R consists of the following rules:

ackerman_3_in_gga3(0_0, N, s_11(N)) -> ackerman_3_out_gga3(0_0, N, s_11(N))
ackerman_3_in_gga3(s_11(M), 0_0, Res) -> if_ackerman_3_in_1_gga3(M, Res, ackerman_3_in_gga3(M, s_11(0_0), Res))
ackerman_3_in_gga3(s_11(M), s_11(N), Res) -> if_ackerman_3_in_2_gga4(M, N, Res, ackerman_3_in_gga3(s_11(M), N, Res1))
if_ackerman_3_in_2_gga4(M, N, Res, ackerman_3_out_gga3(s_11(M), N, Res1)) -> if_ackerman_3_in_3_gga5(M, N, Res, Res1, ackerman_3_in_gga3(M, Res1, Res))
if_ackerman_3_in_3_gga5(M, N, Res, Res1, ackerman_3_out_gga3(M, Res1, Res)) -> ackerman_3_out_gga3(s_11(M), s_11(N), Res)
if_ackerman_3_in_1_gga3(M, Res, ackerman_3_out_gga3(M, s_11(0_0), Res)) -> ackerman_3_out_gga3(s_11(M), 0_0, Res)

The argument filtering Pi contains the following mapping:
ackerman_3_in_gga3(x1, x2, x3)  =  ackerman_3_in_gga2(x1, x2)
0_0  =  0_0
s_11(x1)  =  s_11(x1)
ackerman_3_out_gga3(x1, x2, x3)  =  ackerman_3_out_gga1(x3)
if_ackerman_3_in_1_gga3(x1, x2, x3)  =  if_ackerman_3_in_1_gga1(x3)
if_ackerman_3_in_2_gga4(x1, x2, x3, x4)  =  if_ackerman_3_in_2_gga2(x1, x4)
if_ackerman_3_in_3_gga5(x1, x2, x3, x4, x5)  =  if_ackerman_3_in_3_gga1(x5)
ACKERMAN_3_IN_GGA3(x1, x2, x3)  =  ACKERMAN_3_IN_GGA2(x1, x2)
IF_ACKERMAN_3_IN_2_GGA4(x1, x2, x3, x4)  =  IF_ACKERMAN_3_IN_2_GGA2(x1, x4)

We have to consider all (P,R,Pi)-chains
Transforming (infinitary) constructor rewriting Pi-DP problem into ordinary QDP problem by application of Pi.

↳ PROLOG
  ↳ PrologToPiTRSProof
    ↳ PiTRS
      ↳ DependencyPairsProof
        ↳ PiDP
          ↳ DependencyGraphProof
            ↳ PiDP
              ↳ PiDPToQDPProof
QDP
                  ↳ QDPSizeChangeProof

Q DP problem:
The TRS P consists of the following rules:

ACKERMAN_3_IN_GGA2(s_11(M), s_11(N)) -> ACKERMAN_3_IN_GGA2(s_11(M), N)
ACKERMAN_3_IN_GGA2(s_11(M), s_11(N)) -> IF_ACKERMAN_3_IN_2_GGA2(M, ackerman_3_in_gga2(s_11(M), N))
ACKERMAN_3_IN_GGA2(s_11(M), 0_0) -> ACKERMAN_3_IN_GGA2(M, s_11(0_0))
IF_ACKERMAN_3_IN_2_GGA2(M, ackerman_3_out_gga1(Res1)) -> ACKERMAN_3_IN_GGA2(M, Res1)

The TRS R consists of the following rules:

ackerman_3_in_gga2(0_0, N) -> ackerman_3_out_gga1(s_11(N))
ackerman_3_in_gga2(s_11(M), 0_0) -> if_ackerman_3_in_1_gga1(ackerman_3_in_gga2(M, s_11(0_0)))
ackerman_3_in_gga2(s_11(M), s_11(N)) -> if_ackerman_3_in_2_gga2(M, ackerman_3_in_gga2(s_11(M), N))
if_ackerman_3_in_2_gga2(M, ackerman_3_out_gga1(Res1)) -> if_ackerman_3_in_3_gga1(ackerman_3_in_gga2(M, Res1))
if_ackerman_3_in_3_gga1(ackerman_3_out_gga1(Res)) -> ackerman_3_out_gga1(Res)
if_ackerman_3_in_1_gga1(ackerman_3_out_gga1(Res)) -> ackerman_3_out_gga1(Res)

The set Q consists of the following terms:

ackerman_3_in_gga2(x0, x1)
if_ackerman_3_in_2_gga2(x0, x1)
if_ackerman_3_in_3_gga1(x0)
if_ackerman_3_in_1_gga1(x0)

We have to consider all (P,Q,R)-chains.
The head symbols of this DP problem are {ACKERMAN_3_IN_GGA2, IF_ACKERMAN_3_IN_2_GGA2}.
By using the subterm criterion together with the size-change analysis we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs: