MAYBE
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN"
"http:/www.w3.org/TR/html4/frameset.dtd">
<html>
<head>
<title>Left Termination proof of ../tpdb/LP/SGST06/csnake.pl</title>
</head>
<body>
<BR><B>Left Termination</B> of the query pattern
test_snake_in_3(g, g, g)
w.r.t. the given <I>Prolog program</I> could not be shown:<BR><BR><BR><BR><pre>&#8627 <B>Prolog</B></pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Clauses:<BR><BR>test_snake(Pattern, C, R)&#160;:-&#160;','(s2l(C, Cols), ','(s2l(R, Rows), snake(Pattern, Cols, Rows))).<BR>s2l(0, nil).<BR>s2l(s(X), cons(X1, Y))&#160;:-&#160;s2l(X, Y).<BR>snake(Pattern, Cols, Rows)&#160;:-&#160;','(infinite_snake(Pattern, InfSnake, InfSnake), ','(produce_snake(Rows, Cols, InfSnake, Snake), coil_it(Snake, odd))).<BR>infinite_snake(nil, S, S).<BR>infinite_snake(cons(A, R), cons(A, T), S)&#160;:-&#160;infinite_snake(R, T, S).<BR>produce_snake(nil, X, X1, nil).<BR>produce_snake(cons(X, Rows), Cols, InfSnake, cons(Part, Tail))&#160;:-&#160;','(part_of_snake(Cols, InfSnake, NewInfSnake, Part), produce_snake(Rows, Cols, NewInfSnake, Tail)).<BR>part_of_snake(nil, RestSnake, RestSnake, nil).<BR>part_of_snake(cons(X, R), cons(Ring, Rings), RestSnake, cons(Ring, RestRings))&#160;:-&#160;part_of_snake(R, Rings, RestSnake, RestRings).<BR>coil_it(nil, X).<BR>coil_it(cons(Line, Lines), odd)&#160;:-&#160;coil_it(Lines, even).<BR>coil_it(cons(Line, Lines), even)&#160;:-&#160;','(reverse2(Line, Line1), coil_it(Lines, odd)).<BR>reverse2(List, Reversed)&#160;:-&#160;reverse(List, nil, Reversed).<BR>reverse(nil, Reversed, Reversed).<BR>reverse(cons(Head, Tail), SoFar, Reversed)&#160;:-&#160;reverse(Tail, cons(Head, SoFar), Reversed).<BR><BR>Queries:<BR><BR>test_snake(g,g,g).<BR><BR>We use the technique of [30]. With regard to the inferred argument filtering the predicates were used in the following modes:
<BR><FONT COLOR=#0000cc>test_snake_in</font>: (b,b,b)
<BR><FONT COLOR=#0000cc>s2l_in</font>: (b,f)
<BR><FONT COLOR=#0000cc>snake_in</font>: (b,f,f)
<BR><FONT COLOR=#0000cc>infinite_snake_in</font>: (b,f,f)
<BR><FONT COLOR=#0000cc>produce_snake_in</font>: (f,f,f,f)
<BR><FONT COLOR=#0000cc>part_of_snake_in</font>: (f,f,f,f)
<BR><FONT COLOR=#0000cc>coil_it_in</font>: (f,b)
<BR><FONT COLOR=#0000cc>reverse2_in</font>: (f,f)
<BR><FONT COLOR=#0000cc>reverse_in</font>: (f,b,f) (f,f,f)
<BR>Transforming <I>Prolog</I> into the following <B>Term Rewriting System</B>:
<BR>Pi-finite rewrite system:<BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font><BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font><BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font><BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font><BR>
<BR>
<P><B>Infinitary Constructor Rewriting Termination</B> of PiTRS implies <B>Termination</B> of Prolog<P>
<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 <B>PiTRS</B></pre><pre>      &#8627 DependencyPairsProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi-finite rewrite system:<BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font><BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font><BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font><BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font><BR>
<BR><BR>Using Dependency Pairs [1,30] we result in the following initial DP problem:<BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)
<BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)
<BR><FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)
<BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)
<BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)
<BR><FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)
<BR><FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font><BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font><BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font><BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font><BR>
<FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE2_IN_AA</font><BR>
<FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AAA</font><BR>
<FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font><BR>
<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font><BR>
<FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 <B>PiDP</B></pre><pre>          &#8627 DependencyGraphProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)
<BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)
<BR><FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)
<BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)
<BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)
<BR><FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)
<BR><FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font><BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font><BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font><BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font><BR>
<FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE2_IN_AA</font><BR>
<FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AAA</font><BR>
<FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font><BR>
<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font><BR>
<FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>The approximation of the Dependency Graph [30] contains 6 SCCs with 25 less nodes.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font><BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font><BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font><BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font><BR>
<FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)</BLOCKQUOTE><BR>R is empty.<BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 NonTerminationProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font> &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font></BLOCKQUOTE><BR>R is empty.<BR>Q is empty.<BR>We have to consider all (P,Q,R)-chains.<BR>We used the non-termination processor [17] to show that the DP problem is infinite.<BR>Found a loop by semiunifying a rule from P directly.<BR><BR>The TRS P consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font> &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font></BLOCKQUOTE><BR>The TRS R consists of the following rules:none<BR><BR><BR>s = <FONT COLOR=#0000cc>REVERSE_IN_AAA</font> evaluates to  t =<FONT COLOR=#0000cc>REVERSE_IN_AAA</font><BR><BR>Thus s starts an infinite chain as s semiunifies with t with the following substitutions:<BR><UL><LI> Semiunifier: [ ]</LI>
<LI> Matcher: [ ]</LI></UL><BR><BR><hr><BR><B>Rewriting sequence</B><BR><BR>The DP semiunifies directly so there is only one rewrite step from REVERSE_IN_AAA to REVERSE_IN_AAA.<BR><BR><BR><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font><BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font><BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font><BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font><BR>
<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font><BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 Narrowing</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_in_aa</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font> &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>))
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>SoFar</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font>
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>By narrowing [15] the rule <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_in_aa</font>) at position [0] we obtained the following new rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))</BLOCKQUOTE><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 QDP</pre><pre>                        &#8627 Narrowing</pre><pre>                          &#8627 <B>QDP</B></pre><pre>                            &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font> &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>))
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>SoFar</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font>
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 QDP</pre><pre>                        &#8627 Narrowing</pre><pre>                          &#8627 QDP</pre><pre>                            &#8627 UsableRulesProof</pre><pre>                              &#8627 <B>QDP</B></pre><pre>                                &#8627 QReductionProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>SoFar</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font>
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font></BLOCKQUOTE><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 QDP</pre><pre>                        &#8627 Narrowing</pre><pre>                          &#8627 QDP</pre><pre>                            &#8627 UsableRulesProof</pre><pre>                              &#8627 QDP</pre><pre>                                &#8627 QReductionProof</pre><pre>                                  &#8627 <B>QDP</B></pre><pre>                                    &#8627 NonTerminationProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>SoFar</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>We used the non-termination processor [17] to show that the DP problem is infinite.<BR>Found a loop by narrowing to the left:<BR><BR>The TRS P consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>SoFar</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font></BLOCKQUOTE><BR><BR>s = <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>))) evaluates to  t =<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))<BR><BR>Thus s starts an infinite chain as s semiunifies with t with the following substitutions:<BR><UL><LI> Matcher: [<FONT COLOR=#cc0000>Reversed</font> / <FONT COLOR=#0000cc>nil</font>]</LI>
<LI> Semiunifier: [ ]</LI></UL><BR><BR><hr><BR><B>Rewriting sequence</B><BR><BR><B><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>)))</B> &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>))<BR>with rule <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed'</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font> at position [0,0] and matcher [<FONT COLOR=#cc0000>Reversed'</font> / <FONT COLOR=#cc0000>Reversed</font>]<BR><BR><B><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>))</B> &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>)<BR>with rule <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font> at position [0] and matcher [ ]<BR><BR><B><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>)</B> &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)<BR>with rule <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) at position [] and matcher [ ]<BR><BR><B><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</B> &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)<BR>with rule <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) at position [] and matcher [ ]<BR><BR><B><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)</B> &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))<BR>with rule <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))<BR><BR>Now applying the matcher to the start term leads to a term which is equal to the last term in the rewriting sequence<BR><BR><BR>All these steps are and every following step will be a correct step w.r.t to Q.<BR><BR><BR><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font><BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font><BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font><BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font><BR>
<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)</BLOCKQUOTE><BR>R is empty.<BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 NonTerminationProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font></BLOCKQUOTE><BR>R is empty.<BR>Q is empty.<BR>We have to consider all (P,Q,R)-chains.<BR>We used the non-termination processor [17] to show that the DP problem is infinite.<BR>Found a loop by semiunifying a rule from P directly.<BR><BR>The TRS P consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font></BLOCKQUOTE><BR>The TRS R consists of the following rules:none<BR><BR><BR>s = <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font> evaluates to  t =<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font><BR><BR>Thus s starts an infinite chain as s semiunifies with t with the following substitutions:<BR><UL><LI> Semiunifier: [ ]</LI>
<LI> Matcher: [ ]</LI></UL><BR><BR><hr><BR><B>Rewriting sequence</B><BR><BR>The DP semiunifies directly so there is only one rewrite step from PART_OF_SNAKE_IN_AAAA to PART_OF_SNAKE_IN_AAAA.<BR><BR><BR><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font><BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font><BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font><BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font><BR>
<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 Narrowing</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>)
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>By narrowing [15] the rule <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>) at position [0] we obtained the following new rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>))
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)</BLOCKQUOTE><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 QDP</pre><pre>                        &#8627 Narrowing</pre><pre>                          &#8627 <B>QDP</B></pre><pre>                            &#8627 NonTerminationProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>))
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font></BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>)
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>We used the non-termination processor [17] to show that the DP problem is infinite.<BR>Found a loop by narrowing to the left:<BR><BR>The TRS P consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>))
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font></BLOCKQUOTE><BR>The TRS R consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>)
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font></BLOCKQUOTE><BR><BR>s = <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) evaluates to  t =<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)<BR><BR>Thus s starts an infinite chain as s semiunifies with t with the following substitutions:<BR><UL><LI> Semiunifier: [ ]</LI>
<LI> Matcher: [ ]</LI></UL><BR><BR><hr><BR><B>Rewriting sequence</B><BR><BR><B><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)</B> &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font><BR>with rule <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> at position [] and matcher [ ]<BR><BR><B><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font></B> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)<BR>with rule <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)<BR><BR>Now applying the matcher to the start term leads to a term which is equal to the last term in the rewriting sequence<BR><BR><BR>All these steps are and every following step will be a correct step w.r.t to Q.<BR><BR><BR><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font><BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font><BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font><BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font><BR>
<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)</BLOCKQUOTE><BR>R is empty.<BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 QDPSizeChangeProof</pre><pre>              &#8627 PiDP</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>)) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>R is empty.<BR>Q is empty.<BR>We have to consider all (P,Q,R)-chains.<BR>By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem. <P>From the DPs we obtained the following set of size-change graphs:
<UL><LI><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>)) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>)<BR>The graph contains the following edges 1 > 1<P></LI></UL><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font><BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font><BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font><BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font><BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font><BR>
<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)</BLOCKQUOTE><BR>R is empty.<BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 QDPSizeChangeProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>)</BLOCKQUOTE><BR>R is empty.<BR>Q is empty.<BR>We have to consider all (P,Q,R)-chains.<BR>By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem. <P>From the DPs we obtained the following set of size-change graphs:
<UL><LI><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>)<BR>The graph contains the following edges 1 > 1<P></LI></UL><BR>We use the technique of [30]. With regard to the inferred argument filtering the predicates were used in the following modes:
<BR><FONT COLOR=#0000cc>test_snake_in</font>: (b,b,b)
<BR><FONT COLOR=#0000cc>s2l_in</font>: (b,f)
<BR><FONT COLOR=#0000cc>snake_in</font>: (b,f,f)
<BR><FONT COLOR=#0000cc>infinite_snake_in</font>: (b,f,f)
<BR><FONT COLOR=#0000cc>produce_snake_in</font>: (f,f,f,f)
<BR><FONT COLOR=#0000cc>part_of_snake_in</font>: (f,f,f,f)
<BR><FONT COLOR=#0000cc>coil_it_in</font>: (f,b)
<BR><FONT COLOR=#0000cc>reverse2_in</font>: (f,f)
<BR><FONT COLOR=#0000cc>reverse_in</font>: (f,b,f) (f,f,f)
<BR>Transforming <I>Prolog</I> into the following <B>Term Rewriting System</B>:
<BR>Pi-finite rewrite system:<BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<BR>
<P><B>Infinitary Constructor Rewriting Termination</B> of PiTRS implies <B>Termination</B> of Prolog<P>
<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 <B>PiTRS</B></pre><pre>      &#8627 DependencyPairsProof</pre><BR>Pi-finite rewrite system:<BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<BR><BR>Using Dependency Pairs [1,30] we result in the following initial DP problem:<BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)
<BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)
<BR><FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)
<BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)
<BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)
<BR><FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)
<BR><FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE2_IN_AA</font><BR>
<FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AAA</font><BR>
<FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font><BR>
<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font><BR>
<FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 <B>PiDP</B></pre><pre>          &#8627 DependencyGraphProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)
<BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)
<BR><FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)
<BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)
<BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)
<BR><FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)
<BR><FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>TEST_SNAKE_IN_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AGA</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>REVERSE2_IN_AA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE2_IN_AA</font><BR>
<FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_AGA</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AAA</font><BR>
<FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font><BR>
<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_AAA</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font><BR>
<FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_GGG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_AA</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>The approximation of the Dependency Graph [30] contains 6 SCCs with 25 less nodes.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)</BLOCKQUOTE><BR>R is empty.<BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>REVERSE_IN_AAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>REVERSE_IN_AAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 NonTerminationProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font> &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font></BLOCKQUOTE><BR>R is empty.<BR>Q is empty.<BR>We have to consider all (P,Q,R)-chains.<BR>We used the non-termination processor [17] to show that the DP problem is infinite.<BR>Found a loop by semiunifying a rule from P directly.<BR><BR>The TRS P consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>REVERSE_IN_AAA</font> &#8594; <FONT COLOR=#0000cc>REVERSE_IN_AAA</font></BLOCKQUOTE><BR>The TRS R consists of the following rules:none<BR><BR><BR>s = <FONT COLOR=#0000cc>REVERSE_IN_AAA</font> evaluates to  t =<FONT COLOR=#0000cc>REVERSE_IN_AAA</font><BR><BR>Thus s starts an infinite chain as s semiunifies with t with the following substitutions:<BR><UL><LI> Semiunifier: [ ]</LI>
<LI> Matcher: [ ]</LI></UL><BR><BR><hr><BR><B>Rewriting sequence</B><BR><BR>The DP semiunifies directly so there is only one rewrite step from REVERSE_IN_AAA to REVERSE_IN_AAA.<BR><BR><BR><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 Narrowing</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_in_aa</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font> &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>))
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>SoFar</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>SoFar</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font>
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x0</font>, <FONT COLOR=#cc0000>x1</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>By narrowing [15] the rule <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_in_aa</font>) at position [0] we obtained the following new rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))</BLOCKQUOTE><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 QDP</pre><pre>                        &#8627 Narrowing</pre><pre>                          &#8627 <B>QDP</B></pre><pre>                            &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font> &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>))
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>SoFar</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>SoFar</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font>
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x0</font>, <FONT COLOR=#cc0000>x1</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 QDP</pre><pre>                        &#8627 Narrowing</pre><pre>                          &#8627 QDP</pre><pre>                            &#8627 UsableRulesProof</pre><pre>                              &#8627 <B>QDP</B></pre><pre>                                &#8627 QReductionProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>SoFar</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>SoFar</font>)
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font>
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x0</font>, <FONT COLOR=#cc0000>x1</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse2_in_aa</font></BLOCKQUOTE><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 QDP</pre><pre>                        &#8627 Narrowing</pre><pre>                          &#8627 QDP</pre><pre>                            &#8627 UsableRulesProof</pre><pre>                              &#8627 QDP</pre><pre>                                &#8627 QReductionProof</pre><pre>                                  &#8627 <B>QDP</B></pre><pre>                                    &#8627 NonTerminationProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>SoFar</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>SoFar</font>)
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x0</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x0</font>, <FONT COLOR=#cc0000>x1</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>We used the non-termination processor [17] to show that the DP problem is infinite.<BR>Found a loop by narrowing to the left:<BR><BR>The TRS P consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))
<BR><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>SoFar</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font> &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_in_aaa</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>SoFar</font>)
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#0000cc>reverse_out_aaa</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font></BLOCKQUOTE><BR><BR>s = <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>))) evaluates to  t =<FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))<BR><BR>Thus s starts an infinite chain as s semiunifies with t with the following substitutions:<BR><UL><LI> Semiunifier: [ ]</LI>
<LI> Matcher: [ ]</LI></UL><BR><BR><hr><BR><B>Rewriting sequence</B><BR><BR><B><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))</B> &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>)))<BR>with rule <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>Reversed</font>) at position [0,0] and matcher [<FONT COLOR=#cc0000>Reversed</font> / <FONT COLOR=#0000cc>nil</font>]<BR><BR><B><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>)))</B> &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>)<BR>with rule <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font> at position [0] and matcher [ ]<BR><BR><B><FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>)</B> &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)<BR>with rule <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>reverse2_out_aa</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) at position [] and matcher [ ]<BR><BR><B><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>)</B> &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)<BR>with rule <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) at position [] and matcher [ ]<BR><BR><B><FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>)</B> &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))<BR>with rule <FONT COLOR=#0000cc>COIL_IT_IN_AG</font>(<FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_AG</font>(<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>)))<BR><BR>Now applying the matcher to the start term leads to a term which is equal to the last term in the rewriting sequence<BR><BR><BR>All these steps are and every following step will be a correct step w.r.t to Q.<BR><BR><BR><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)</BLOCKQUOTE><BR>R is empty.<BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 NonTerminationProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font></BLOCKQUOTE><BR>R is empty.<BR>Q is empty.<BR>We have to consider all (P,Q,R)-chains.<BR>We used the non-termination processor [17] to show that the DP problem is infinite.<BR>Found a loop by semiunifying a rule from P directly.<BR><BR>The TRS P consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font></BLOCKQUOTE><BR>The TRS R consists of the following rules:none<BR><BR><BR>s = <FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font> evaluates to  t =<FONT COLOR=#0000cc>PART_OF_SNAKE_IN_AAAA</font><BR><BR>Thus s starts an infinite chain as s semiunifies with t with the following substitutions:<BR><UL><LI> Semiunifier: [ ]</LI>
<LI> Matcher: [ ]</LI></UL><BR><BR><hr><BR><B>Rewriting sequence</B><BR><BR>The DP semiunifies directly so there is only one rewrite step from PART_OF_SNAKE_IN_AAAA to PART_OF_SNAKE_IN_AAAA.<BR><BR><BR><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font><BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 Narrowing</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font>
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>)
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>By narrowing [15] the rule <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>) at position [0] we obtained the following new rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>))
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)</BLOCKQUOTE><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 QDP</pre><pre>                        &#8627 Narrowing</pre><pre>                          &#8627 <B>QDP</B></pre><pre>                            &#8627 NonTerminationProof</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>))
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font></BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>)
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font></BLOCKQUOTE><BR>The set Q consists of the following terms:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x0</font>)</BLOCKQUOTE><BR>We have to consider all (P,Q,R)-chains.<BR>We used the non-termination processor [17] to show that the DP problem is infinite.<BR>Found a loop by narrowing to the left:<BR><BR>The TRS P consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>))
<BR><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)
<BR><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font></BLOCKQUOTE><BR>The TRS R consists of the following rules:<BLOCKQUOTE><BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font> &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>)
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font></BLOCKQUOTE><BR><BR>s = <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) evaluates to  t =<FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)<BR><BR>Thus s starts an infinite chain as s semiunifies with t with the following substitutions:<BR><UL><LI> Semiunifier: [ ]</LI>
<LI> Matcher: [ ]</LI></UL><BR><BR><hr><BR><B>Rewriting sequence</B><BR><BR><B><FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)</B> &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font><BR>with rule <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>) &#8594; <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> at position [] and matcher [ ]<BR><BR><B><FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font></B> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)<BR>with rule <FONT COLOR=#0000cc>PRODUCE_SNAKE_IN_AAAA</font> &#8594; <FONT COLOR=#0000cc>U9_AAAA</font>(<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>)<BR><BR>Now applying the matcher to the start term leads to a term which is equal to the last term in the rewriting sequence<BR><BR><BR>All these steps are and every following step will be a correct step w.r.t to Q.<BR><BR><BR><BR><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><pre>              &#8627 PiDP</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>              &#8627 PiDP</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)</BLOCKQUOTE><BR>R is empty.<BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 QDPSizeChangeProof</pre><pre>              &#8627 PiDP</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>)) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>R is empty.<BR>Q is empty.<BR>We have to consider all (P,Q,R)-chains.<BR>By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem. <P>From the DPs we obtained the following set of size-change graphs:
<UL><LI><FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>)) &#8594; <FONT COLOR=#0000cc>INFINITE_SNAKE_IN_GAA</font>(<FONT COLOR=#cc0000>R</font>)<BR>The graph contains the following edges 1 > 1<P></LI></UL><BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 <B>PiDP</B></pre><pre>                &#8627 UsableRulesProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)</BLOCKQUOTE><BR>The TRS R consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>) &#8594; <FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>))
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>0</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>))
<BR><FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>Cols</font>)) &#8594; <FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>))
<BR><FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>) &#8594; <FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>))
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>) &#8594; <FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>))
<BR><FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>T</font>, <FONT COLOR=#cc0000>S</font>)) &#8594; <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>A</font>, <FONT COLOR=#cc0000>T</font>), <FONT COLOR=#cc0000>S</font>)
<BR><FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>InfSnake</font>)) &#8594; <FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>))
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>))
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>nil</font>)
<BR><FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>R</font>, <FONT COLOR=#cc0000>Rings</font>, <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#cc0000>RestRings</font>)) &#8594; <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>R</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>Rings</font>), <FONT COLOR=#cc0000>RestSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Ring</font>, <FONT COLOR=#cc0000>RestRings</font>))
<BR><FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Part</font>)) &#8594; <FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>NewInfSnake</font>, <FONT COLOR=#cc0000>Tail</font>)) &#8594; <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Rows</font>), <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Part</font>, <FONT COLOR=#cc0000>Tail</font>))
<BR><FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>InfSnake</font>, <FONT COLOR=#cc0000>Snake</font>)) &#8594; <FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>X</font>)
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>) &#8594; <FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>))
<BR><FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>) &#8594; <FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>))
<BR><FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>) &#8594; <FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>))
<BR><FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>Tail</font>, <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>SoFar</font>), <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Head</font>, <FONT COLOR=#cc0000>Tail</font>), <FONT COLOR=#cc0000>SoFar</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>, <FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#0000cc>nil</font>, <FONT COLOR=#cc0000>Reversed</font>)) &#8594; <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>List</font>, <FONT COLOR=#cc0000>Reversed</font>)
<BR><FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Line1</font>)) &#8594; <FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>))
<BR><FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>even</font>)
<BR><FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Lines</font>, <FONT COLOR=#0000cc>even</font>)) &#8594; <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>Line</font>, <FONT COLOR=#cc0000>Lines</font>), <FONT COLOR=#0000cc>odd</font>)
<BR><FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>, <FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>Snake</font>, <FONT COLOR=#0000cc>odd</font>)) &#8594; <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)
<BR><FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>, <FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>Cols</font>, <FONT COLOR=#cc0000>Rows</font>)) &#8594; <FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>Pattern</font>, <FONT COLOR=#cc0000>C</font>, <FONT COLOR=#cc0000>R</font>)</BLOCKQUOTE><BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_in_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U1_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_in_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>0</font>&#160; = &#160;<FONT COLOR=#0000cc>0</font><BR>
<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>s2l_out_ga</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U4_ga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U2_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U3_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U5_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_in_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>nil</font>&#160; = &#160;<FONT COLOR=#0000cc>nil</font><BR>
<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>infinite_snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U8_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U6_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>produce_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>produce_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>produce_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U9_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_in_aaaa</font><BR>
<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>part_of_snake_out_aaaa</font><BR>
<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U11_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>, <FONT COLOR=#cc0000>x6</font>, <FONT COLOR=#cc0000>x7</font>)&#160; = &#160;<FONT COLOR=#0000cc>U10_aaaa</font>(<FONT COLOR=#cc0000>x7</font>)<BR>
<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>)&#160; = &#160;<FONT COLOR=#0000cc>U7_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x4</font>)<BR>
<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_in_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>coil_it_out_ag</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>odd</font>&#160; = &#160;<FONT COLOR=#0000cc>odd</font><BR>
<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U12_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>even</font>&#160; = &#160;<FONT COLOR=#0000cc>even</font><BR>
<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U13_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse2_in_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_in_aa</font><BR>
<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U15_aa</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aga</font>(<FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aga</font>(<FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse_in_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_in_aaa</font><BR>
<FONT COLOR=#0000cc>reverse_out_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse_out_aaa</font><BR>
<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>, <FONT COLOR=#cc0000>x4</font>, <FONT COLOR=#cc0000>x5</font>)&#160; = &#160;<FONT COLOR=#0000cc>U16_aaa</font>(<FONT COLOR=#cc0000>x5</font>)<BR>
<FONT COLOR=#0000cc>reverse2_out_aa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>reverse2_out_aa</font><BR>
<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>U14_ag</font>(<FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>snake_out_gaa</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)&#160; = &#160;<FONT COLOR=#0000cc>test_snake_out_ggg</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>, <FONT COLOR=#cc0000>x3</font>)<BR>
<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>For (infinitary) constructor rewriting [30] we can delete all non-usable rules from R.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 <B>PiDP</B></pre><pre>                    &#8627 PiDPToQDPProof</pre><BR>Pi DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>), <FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>X1</font>, <FONT COLOR=#cc0000>Y</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>, <FONT COLOR=#cc0000>Y</font>)</BLOCKQUOTE><BR>R is empty.<BR>The argument filtering Pi contains the following mapping:<BR><FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)&#160; = &#160;<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>cons</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)<BR>
<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>, <FONT COLOR=#cc0000>x2</font>)&#160; = &#160;<FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>x1</font>)<BR>
<BR>We have to consider all (P,R,Pi)-chains<BR>Transforming (infinitary) constructor rewriting Pi-DP problem [30] into ordinary QDP problem [15] by application of Pi.<BR><BR><pre>&#8627 Prolog</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>  &#8627 PrologToPiTRSProof</pre><pre>    &#8627 PiTRS</pre><pre>      &#8627 DependencyPairsProof</pre><pre>        &#8627 PiDP</pre><pre>          &#8627 DependencyGraphProof</pre><pre>            &#8627 AND</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>              &#8627 PiDP</pre><pre>                &#8627 UsableRulesProof</pre><pre>                  &#8627 PiDP</pre><pre>                    &#8627 PiDPToQDPProof</pre><pre>                      &#8627 <B>QDP</B></pre><pre>                        &#8627 QDPSizeChangeProof</pre><BR>Q DP problem:<BR>The TRS P consists of the following rules:<BR><BLOCKQUOTE><BR><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>)</BLOCKQUOTE><BR>R is empty.<BR>Q is empty.<BR>We have to consider all (P,Q,R)-chains.<BR>By using the subterm criterion [20] together with the size-change analysis [32] we have proven that there are no infinite chains for this DP problem. <P>From the DPs we obtained the following set of size-change graphs:
<UL><LI><FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#0000cc>s</font>(<FONT COLOR=#cc0000>X</font>)) &#8594; <FONT COLOR=#0000cc>S2L_IN_GA</font>(<FONT COLOR=#cc0000>X</font>)<BR>The graph contains the following edges 1 > 1<P></LI></UL><BR><BR></body>

