Operators, Functions, and Properties – part 26

In the previous post in this series, we linked two state machines together, weakly, by arranging to press their Start buttons at the same time and to press their Next buttons at the same time.  As a result, we got a contraption that could crank out the following number pairs:

We will now show a single state machine that produces the same number pairs:

To make this happen, the state of the state machine consists of a pair of numbers.  As in previous posts, those components of the state are given a name – here exponent and power.  If you follow what happens with the exponent component of the state, you see that it is set to 0 when the start button is pressed, and that one is added to it each time the next button is pressed.  Similarly, the power component starts at 1 and is doubled each time the next button is pressed.  This is consistent with the two state machines in the previous post, and is consistent with the table of number pairs that we are trying to generate.  As you can see, the core operations of the state machine are relatively simple: +1 and × 2; most of the details of the state machine have to do with keeping track of what is being done to what, and what triggers what is done when.

Advertisements
This entry was posted in Uncategorized and tagged , , , , , , . Bookmark the permalink.

2 Responses to Operators, Functions, and Properties – part 26

  1. Pingback: Operators, Functions, and Properties – part 27 « Learning and Unlearning Math

  2. Pingback: Operators, Functions, and Properties – part 41 « Learning and Unlearning Math

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s