Home Â» Conversion from Moore machine to Mealy machine

# Conversion from Moore machine to Mealy Machine

In the Moore machine, the output is associated with every state, and in the mealy machine, the output is given along the edge with input symbol. The equivalence of the Moore machine and Mealy machine means both the machines generate the same output string for same input string.

We cannot directly convert Moore machine to its equivalent Mealy machine because the length of the Moore machine is one longer than the Mealy machine for the given input. To convert Moore machine to Mealy machine, state output symbols are distributed into input symbol paths. We are going to use the following method to convert the Moore machine to Mealy machine.

## Method for conversion of Moore machine to Mealy machine

Let M = (Q, âˆ‘, Î´, Î», q0) be a Moore machine. The equivalent Mealy machine can be represented by Mâ€™ = (Q, âˆ‘, Î´, Î»â€™, q0). The output function Î»â€™ can be obtained as:

### Example 1:

Convert the following Moore machine into its equivalent Mealy machine.

Solution:

The transition table of given Moore machine is as follows:

q0q0q10
q1q0q11

The equivalent Mealy machine can be obtained as follows:

The Î» for state q1 is as follows:

Hence the transition table for the Mealy machine can be drawn as follows:

The equivalent Mealy machine will be,

### Example 2:

Convert the given Moore machine into its equivalent Mealy machine.

Solution:

The transition table of given Moore machine is as follows:

q0q1q00
q1q1q20
q2q1q01

The equivalent Mealy machine can be obtained as follows:

The Î» for state q1 is as follows:

The Î» for state q2 is as follows:

Hence the transition table for the Mealy machine can be drawn as follows:

The equivalent Mealy machine will be,

### Example 3:

Convert the given Moore machine into its equivalent Mealy machine.

q0q0q10
q1q2q01
q2q1q22

Solution:

The transaction diagram for the given problem can be drawn as:

The equivalent Mealy machine can be obtained as follows:

The Î» for state q1 is as follows:

The Î» for state q2 is as follows:

Hence the transition table for the Mealy machine can be drawn as follows:

The equivalent Mealy machine will be,