Wolfram Function Repository
Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Show evolution of a combinator expression for a certain number of steps based on defined rules and an evaluation scheme
ResourceFunction["CombinatorEvolveList"][cmb,t] shows evolution of the combinator expression cmb using S and K combinator transformation rules and single leftmost-outermost updating order across t steps. | |
ResourceFunction["CombinatorEvolveList"][cmb,t, scheme] shows evolution of cmb using S and K combinator transformation rules in matches found by scheme. | |
ResourceFunction["CombinatorEvolveList"][rules, cmb,t, scheme] shows evolution cmb using rules in matches found by scheme. |
"FixedPointFailure" | False | whether to return Failure when fixed point is reached |
"MaxSize" | Infinity | maximum leaf count allowed for evolution of cmb |
"SKGlyphs" | {CombinatorS,CombinatorK} | symbols used to specify default transformation rules |
Show the evolution of a combinator expression for five steps using the default S and K combinator transformation rules in the single-match leftmost-outermost updating scheme:
In[1]:= |
Out[1]= |
Show the evolution of a combinator expression for five steps, specifying that only the S combinator rule should be used in an all-match innermost-rightmost updating scheme:
In[2]:= |
Out[2]= |
The evolution stops after the "MaxSize" is surpassed:
In[3]:= |
Out[3]= |
When "FixedPointFailure" is set to True, an exception is thrown to indicate that the proposed evolution surpasses its fixed point:
In[4]:= |
Out[4]= |
This work is licensed under a Creative Commons Attribution 4.0 International License