# 3.13 Multiple Transformation Rules

So far we have always considered having just a single possible transformation rule which can be used wherever it applies. It is also possible to have multiple transformation rules which are used wherever they apply. A single transformation rule can either increase or decrease the number of relations, but must do the same every time it is used. With multiple transformations, some can increase the number of relations while others decrease it.

As a minimal example, consider the rule:

{{{x, x}} -> {{y, x}, {x, z}}, {{x, y}, {y, z}} -> {{x, x}}}
RulePlot[ResourceFunction[ "WolframModel"][{{{x, x}} -> {{y, x}, {x, z}}, {{x, y}, {y, z}} -> {{x, x}}}]]

On successive steps, this rule simply alternates between two cases:

ResourceFunction[ "WolframModel"][{{{x, x}} -> {{y, x}, {x, z}}, {{x, y}, {y, z}} -> {{x, x}}}, {{0, 0}}, 7]["StatesPlotsList", ImageSize -> {UpTo, UpTo}]

As another example, consider the rule:

{{{x, x}} -> {{y, x}, {y, x}, {z, x}}, {{x, y}, {z, y}} -> {{y, y}}}
RulePlot[ResourceFunction[ "WolframModel"][{{{x, x}} -> {{y, x}, {y, x}, {z, x}}, {{x, y}, {z, y}} -> {{y, y}}}]]

This rule produces results that alternately grow and shrink on successive steps:

ResourceFunction[ "WolframModel"][{{{1, 1}} -> {{2, 1}, {2, 1}, {3, 1}}, {{1, 2}, {3, 2}} -> {{2, 2}}}, {{1, 1}}, 20]["StatesPlotsList", ImageSize -> {UpTo, UpTo}]

It is fairly common with multiple transformation rules to find that one transformation is occasionally applied. But at least with our standard updating order, it is difficult to find rules in which, for example, the total size of the results varies in anything but a fairly regular way from step to step.