- Related Questions & Answers
- What is a Moore Machine in TOC?
- What is a finite state machine in TOC?
- Convert the given Moore machine counts into equivalent Mealy machine.
- What is a Derivation tree in TOC?
- What is Inductive Hypothesis in TOC?
- What is unambiguous grammar in TOC?
- What is an epsilon closure in TOC?
- What is the decision problem in TOC?
- What is a Neural Network in Machine Learning?
- What is The Church-Turing Thesis in TOC?
- What is JVM, Java virtual machine?
- What is Java Virtual Machine (JVM)?
- What is an offset printing machine?
- What is time series with respect to Machine Learning?
- Explain what a neuron is, in terms of Neural Network in Machine Learning.

- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who

In a mealy machine, the output symbol depends upon the present input symbol and on the present state of the machine.

The output is represented with each input symbol and each state is separated by /.

The mealy machine can be described by 6 tuples

**(Q, q0, Σ, O, δ, λ')**

Where,

- Q: Finite set of states
- q0: Initial state of machine
- Σ: Finite set of input alphabet
- O: Output alphabet
- δ: Transition function, where Q × Σ → Q
- λ': Output function, where Q × Σ →O

The length of output for a mealy machine is equal to the length of input.

Input − 11

Transition − δ (q0,11)=> δ(q2,1)=>q2

Output − 00 (q0 to q2 transition has Output 0 and q2 to q2 transition also has Output 0)

The transition diagram is as follows −

**Step 1**− q0 is the start state on input ‘0’, it goes to state b and it generates an output ‘0’ and on input ‘1’ it goes to state q2 and generates an output ‘0’.**Step 2**− q1 on input ‘0’ goes to q1 itself generating output ‘0’ and on ‘1’ goes to q2 generates an output ‘1’.**Step 3**− q2 on input ‘1’ goes to q2 itself and generates an output ‘0’ and on ‘0’ goes to state q1 generating output ‘1’.

The state table of a Mealy Machine is shown below −

Present state | Next State | ||||
---|---|---|---|---|---|

Input =0 | Input =1 | ||||

State | Output | State | Output | ||

->q0 | q1 | 0 | q2 | 0 | |

q1 | q1 | 0 | q2 | 1 | |

q2 | q1 | 1 | q2 | 0 |

Design a Mealy machine for a binary input sequence {0,1}

If the input has a substring 101, the output is A.

If the input has substring 110, its output is B Otherwise, its output is C.

The transition diagram is as follows −

The state’s transition table is as follows −

Present state | Next State | ||||
---|---|---|---|---|---|

Input =0 | Input =1 | ||||

State | Output | State | Output | ||

->q0 | q0 | C | q1 | C | |

q1 | q2 | C | q3 | C | |

q2 | q0 | C | A | C | |

q3 | q2 | B | q3 | C |

Advertisements