Mealy Model - mbits-mirafra/digitalDesignCourse GitHub Wiki

What is a Mealy model?

The Mealy model is a type of finite state machine used in digital electronics and computer science. It is named after its creator, George H. Mealy.

In the Mealy model, the outputs of the machine are a function of both its current state and its inputs. This means that the machine can have different outputs for the same input, depending on its current state.

MEALY drawio

Q= Present state of the circuit

Q+=Next state of the circuit

X=Present input

Y=Outputs

The next state is a Boolean function of the present inputs and the present state

Q+=f1(X,Q)

The outputs are also the functions of present inputs and present state

Y=f2(X,Q)

Here is an example for understanding the working of Mealy model.

Design a synchronous circuit using positive edge JK flip flop with minimal combinational gating to generate the following sequence 0-1-2-0 if input X=0 and 0-2-1-0 if input X=1. Provide an output which goes to high to indicate the non zero states in the 0-1-2-0 sequence. Is this a Mealy machine?

Step 1: Draw the state diagram

There are 3 states:

  • 0-00

  • 1-01

  • 2-10

Step 2: Draw the State Table

Since there r only 3 states the 4th state 11 is represented with -

Step 3:Write the excitation table of JK flip flop

Screenshot (537)

Excitation Table with Flip flop inputs

Step 4: Considering the present state and the input, find the equations using Kmap

The Karnaugh maps for simplifying flip-flop inputs and the output are shown below

  • Kmap for JB

JB=X|QA+XQ|A

JB=X^QA

  • Kmap for KB

KB=1

  • Kmap for JA

JA=X'QB' + XQB

JA=(X^QB)'

  • Kmap for KA

KA=1

  • Kmap for Y

Y=X|QB+X|QA

Step 5: Design the Circuit

MEALY1 drawio

Here,

Q={A,B} , Q+={A+,B+}

Q+=f1(X,Q) = f1(X,A,B)

Y=f2(X,Q)=f2(X,A,B) = X|(A+B)

Observe that both the next state and the output are Boolean functions of the input and the present state.

Therefore the given synchronous circuit is a Mealy machine.

Implementation using D flip flop

State Reduction

Overlapping Model

⚠️ **GitHub.com Fallback** ⚠️