Mealy to Moore Conversion
Mealy to Moore Conversion is slightly more complex than the conversion of moore to mealy Machine. There are two cases of Mealy’s conversion to Moore Machine.
Case 01: When every entering Input in Mealy state provides the same output. Then, simply place that output with the state.
Case 02: When every entering Input in any particular Mealy state provides a different output, we cannot represent more than one output in one state of the Moore Machine. In this case, that particular state is duplicated.
Examples of Mealy to Moore Machine Conversion
Let’s explain some examples of Mealy to Moore Machine Conversions.
Example 01
Consider the following Mealy Machine
As in the above Mealy Machine,
- q0 is the start state, (0,1) are inputs, and “a” is the output.
- Every entering input in the state q0 having the similar output “a”.
- So, simply cut the output “a” over the arrow and place it along with the state “q0”.
After conversion, the Moore Machine is given under
Example 02
Consider the following Mealy Machine
At point q0,
There is no arrow entering into the state q0. So, the output for the q0 is null. As given Below
At point q1,
There are three arrows entering into the state q1. Arrows from q0 and q1 have the input “0” with output “a”, and Arrow from q2 has the input “1” with “b” output.
Output of 2 types (0,1) enter state q1, So One duplicate of q1 is generated with a different output.
So, the output of type “0” is placed along with state q1. The output of type “1” is placed along with the duplicated state (q1) as given below.
Further Proceeding above, Now transitions from both states (original q1 and duplicate q1) for inputs 0 and 1.
- For input “0” transition goes to q1 with “a”.
- For input “1”, the transition goes to q2 with output “b”.
As given below
Now, the remaining state is only q2, which has to be discussed.
There are three arrows entering into the state q2. Arrows from q0 and q2 (itself) have the input “0” with output “a”, and Arrow from q2 has the input “1” with “b” output.
Output of 2 types (0,1) enter into state q2, So One duplicate state of q2 is generated.
By completing the transition from both states (original q2 and duplicate q2) for inputs 0 and 1, the final Mealy machine is given below.
As shown in the following diagram
Important.
If “M” is the number of states and “N” is the number of outputs in the Mealy Machine, then the maximum number of States in the Mealy Machine will be “M” multiplied by “N”.
Suppose if 3 number of states and 2 number of outputs in Mealy, then 6 will be the maximum state in Moore Machine.