0% found this document useful (0 votes)
693 views24 pages

Finite State Machines 4

The document describes converting a Mealy machine to a Moore machine. It involves: 1) Considering the transition table and determining the number of different outputs associated with each state. 2) Splitting states that have different outputs into multiple states. 3) Creating a new transition table that reflects the split states and converted Moore machine model. As an example, a state like q1 that has outputs of 0 and 1 in the transition table would be split into two states, q10 and q11, in the Moore machine. The process is demonstrated by converting a sample Mealy machine transition table into an equivalent Moore machine table.

Uploaded by

William Douglas
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
693 views24 pages

Finite State Machines 4

The document describes converting a Mealy machine to a Moore machine. It involves: 1) Considering the transition table and determining the number of different outputs associated with each state. 2) Splitting states that have different outputs into multiple states. 3) Creating a new transition table that reflects the split states and converted Moore machine model. As an example, a state like q1 that has outputs of 0 and 1 in the transition table would be split into two states, q10 and q11, in the Moore machine. The process is demonstrated by converting a sample Mealy machine transition table into an equivalent Moore machine table.

Uploaded by

William Douglas
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 24

MealytoMooreConversion

Consideratransitiontablebelow:
Current State Input q0 0 q1 q2 q3 0 q3 3 q0 q2 q1 NextState Output

1 0 1 1 0

0 q1 1 q3 q2 q0

1 1 0 0 1

37

MealytoMooreConversion
Determinethenumberofdifferentoutputassociatedwith qi inthenextstatecolumn. Wesplitqi intodifferentstatesaccordingtodifferent outputassociatedwithit.Forexample,supposeinthenext statecolumnoftheabovesampletransitiontableofmealy machine,theoutputassociatedwithq1is"0"inthefirst nextstatecolumnand"1"inthesecondnextstatecolumn. sowesplit litq1 1into i t q10 10and dq11 11states. t t similarly i il l check h k othersandsplitthem. Afterapplyingtheconversionsteps,wegettwostates(q1 and dq2) 2)that th tareassociated i t dwith ithdiff different toutputs t t (0and d1). 1) sowesplitbothstatesintoq10,q11andq20,q21. Nowthetransitiontablebecomes
38

MealytoMooreConversion
Consideratransitiontablebelow:
Current State Input q0 0 q10 q11 q20 q21 q3 0 q3 3 q0 q0 q21 q21 q10 NextState Output

1 0 1 1 1 1 0

0 q11 11 q3 q3 q20 q20 q0

1 1 0 0 0 0 1
39

MooreModel
PresentState I Input t q0 q10 q11 q20 q21 q3 0 q3 q0 q0 q21 q21 q10 NextState 1 q11 q3 q3 q20 q20 q0 1 0 1 0 1 0 Output

40

MealyModel
Convertthefollowing gMealy yMachinetoMooreMachine

00/0 01/1 00/0,

10/0 01/0 10/0,

10/0 00/1 /

Example
MealyMachine:
PS A B 00 A,0 A,1 01 10 (x,y) A,1 B,0 B,0 B,0 (NS,z)

MooreMachine:
PS A0 A1 B 00 01 A0 A1 A0 A1 A1 B 10 (x,y) B B B z 0 1 0

MooreMachine

00

MooreMachine

10

10 01

A0/0
10 01 00 00

B/0

A1/1
01

MooretoMealyConversion
Considerthestatetableg givenbelow
CurrentState 0 A B C D B D C A Next State 1 C C B D 1 0 1 1 Output

44

MooreMealy yConversion
ForMooretoMealyconversion,rewritethetableasifitisaMealy machinewithoutthecorrespondingoutputinformation.
CurrentState Input A B C D CurrentState Input A B C D 0 B D C A 0 B D C A NextState 1 C C B D
45

Next State 1 C C B D

Output 1 0 1 1 Output 0 1

MooretoMealyConversion
NowintheMooremachine,theoutputoftheAis1,somaketheoutput ofAinthemealymachinenextstatecolumnoftheabovetableis1.same processisrepeatedforB,CandD.
CurrentState Input A B C D 0 B D C A NextState 1 C C B D 1 0 Output 1

46

MooretoMealyConversion
NowintheMooremachine,theoutputoftheAis1,somaketheoutput ofAinthemealymachinenextstatecolumnoftheabovetableis1.same processisrepeatedforB,CandD.
Current State Input A B C D 0 B D C A NextState 1 C C B D 1 0 0 0 Output 1

47

MooretoMealyConversion
NowintheMooremachine,theoutputoftheAis1,somaketheoutput ofAinthemealymachinenextstatecolumnoftheabovetableis1.same processisrepeatedforB,CandD.
Current State Input A B C D 0 B D C A NextState 1 C C B D 1 1 0 0 Output 1 1 1 0

48

MooretoMealyConversion
NowintheMooremachine,theoutputoftheAis1,somaketheoutput ofAinthemealymachinenextstatecolumnoftheabovetableis1.same processisrepeatedforB,CandD.
Current State Input A B C D 0 B D C A NextState 1 C C B D 0 0 1 1 1 Output 1 1 1 0 1

49

StateDiagram

50

Recheck
Doesthisreally ywork?Letusredotheconversion( (Mealy yto Moore)thatwelookedatearlier.

51

StateTransitionTable
CurrentState 0 a b c d a a d a NextState 1 b c c b 0 0 0 1 Output

52

MooreMealy yConversion
ForMooretoMealyconversion,rewritethetableasifitisaMealy machinewithoutthecorrespondingoutputinformation.
CurrentState Next State Output

0 a b c d
CurrentState

1 b c c b
NextState

a a d a 0 1 b c c b

0 0 0 1
Output 0 1

a b c d

a a d a

53

MooreMealy yConversion
ForMooretoMealyconversion,rewritethetableasifitisaMealy machinewithoutthecorrespondingoutputinformation.
CurrentState Next State Output

0 a b c d
CurrentState

1 b c c b
NextState

a a d a 0 1 b c c b

0 0 0 1
Output 0 0 0 1 0 1 0 0 0 0
54

a b c d

a a d a

MooretoMealyConversion
Itcanbeseenthatstatesaanddareidenticalandcanbe merged.Thenumberofstatesarenotreducedto3,withnew statetable,
CurrentState NextState Output 0 0 0 1 1 0 0 0

0 a b c a a a

1 b c c

55

56

57

58

59

60

You might also like