New User Special Price Expires in

Let's log you in.

Sign in with Facebook


Don't have a StudySoup account? Create one here!


Create a StudySoup account

Be part of our community, it's free to join!

Sign up with Facebook


Create your account
By creating an account you agree to StudySoup's terms and conditions and privacy policy

Already have a StudySoup account? Login here

Finite-State Machines

by: Robert Notetaker

Finite-State Machines CS619_683_2

Robert Notetaker

Preview These Notes for FREE

Get a free preview of these Notes, just enter your email below.

Unlock Preview
Unlock Preview

Preview these materials now for free

Why put in your email? Get access to more of this material and other relevant free materials for your school

View Preview

About this Document

A finite-state machine is a model used to represent and control execution flow. It is perfect for implementing AI in games, producing great results without a complex code. A finite state machine c...
Computation, Programs, and Programming
Class Notes
Computer Science
25 ?




Popular in Computation, Programs, and Programming

Popular in Computer Science and Engineering

This 3 page Class Notes was uploaded by Robert Notetaker on Friday October 14, 2016. The Class Notes belongs to CS619_683_2 at Armstrong Atlantic State University taught by Rizwan in Fall 2014. Since its upload, it has received 7 views. For similar materials see Computation, Programs, and Programming in Computer Science and Engineering at Armstrong Atlantic State University.

Popular in Computer Science and Engineering


Reviews for Finite-State Machines


Report this Material


What is Karma?


Karma is the currency of StudySoup.

You can buy or earn more Karma at anytime and redeem it for class notes, study guides, flashcards, and more!

Date Created: 10/14/16
ICS 241: Discrete Mathematics II (Spring 2015) 13.2 Finite-State Machines with Output A finite-state machine M = (S;I;O;f;g;s ) con0ists of ▯ a finite set S of states ▯ a finite input alphabet I ▯ a finite output alphabet O ▯ a transition function f (f : S ▯ I ! S) ▯ an output function g (g : S ▯ I ! O) ▯ an initial state 0 0,1 0,1 State Input 0 1 1,0 1,1 s0 s0, 1 s1, 0 start s0 s1 s2 s1 s0, 1 s2, 1 0,1 1,0 s2 s2, 1 s1, 0 Types of Finite-State Machines ▯ Mealy machines: outputs correspond to transitions between states ▯ Moore machine: output is determined only by the state Example of a Moore Machine 0 0 start s ;1 1 s ;0 1 s ;1 0 1 2 0 1 Language Recognizer Let M = (S;I;O;f;g;s ) be a finite-state machine and L ▯ I . We say that M recognizes (or 0 accepts) L if an input string x belongs to L if and only if the last output bit produced by M when given x as input is a 1. 1 ICS 241: Discrete Mathematics II (Spring 2015) 13.2 pg. 863 # 1 Draw the state diagrams for the finite-state machines with these state tables. a ) State Input 1,1 0 1 1,0 s0 s1, 0 s0, 1 0,0 1,1 s s , 0 s , 1 start s0 s1 s 2 1 0 2 s2 s1, 0 s1, 0 0,0 0,0 b ) State Input 1,0 0 1 1,1 1,0 s0 s1, 0 s0, 0 0,0 0,1 1,1 s s , 1 s , 1 start s0 s 1 s2 s3 1 2 0 s2 s0, 0 s3, 1 s3 s1, 1 s2, 0 0,0 0,1 13.2 pg. 863 # 3 Find the output generated from the input string 01110 for the finite-state machine with the state table in a) Exercise 1(a). The state transition sequence is: s 0 s ! 1 ! s 2 s ! s1 2 1 Our output is: 01010 b) Exercise 1(b). The state transition sequence is: s 0 s ! 1 ! s 0 s ! s0 0 1 Our output is: 01000 Lecture Notes 25 Exercise Construct a finite-state machine with output that produces a 1 if and only if the last 3 input bits read are 0s. 1,0 0,1 State Input 0 1 1,0 s 0 s1, 0 s 0 0 start s0 0,0 s1 0,0 s2 s 1 s2, 0 s 0 0 s 2 s2, 1 s 0 0 1,0 2 ICS 241: Discrete Mathematics II (Spring 2015) 13.2 pg. 864 # 9 Construct a finite-state machine that delays an input string two bits, giving 00 as the first two bits of output. 0,0 0,1 start s0 s 2 1,1 1,0 0,1 0,0 s1 s 3 1,0 1,1 s0corresponds to the last two bits having been 00, s c1rresponds to the last two bits having been 01, s2corresponds to the last two bits having been 10, s co3responds to the last two bits having been 11. 3


Buy Material

Are you sure you want to buy this material for

25 Karma

Buy Material

BOOM! Enjoy Your Free Notes!

We've added these Notes to your profile, click here to view them now.


You're already Subscribed!

Looks like you've already subscribed to StudySoup, you won't need to purchase another subscription to get this material. To access this material simply click 'View Full Document'

Why people love StudySoup

Bentley McCaw University of Florida

"I was shooting for a perfect 4.0 GPA this semester. Having StudySoup as a study aid was critical to helping me achieve my goal...and I nailed it!"

Jennifer McGill UCSF Med School

"Selling my MCAT study guides and notes has been a great source of side revenue while I'm in school. Some months I'm making over $500! Plus, it makes me happy knowing that I'm helping future med students with their MCAT."

Jim McGreen Ohio University

"Knowing I can count on the Elite Notetaker in my class allows me to focus on what the professor is saying instead of just scribbling notes the whole time and falling behind."


"Their 'Elite Notetakers' are making over $1,200/month in sales by creating high quality content that helps their classmates in a time of need."

Become an Elite Notetaker and start selling your notes online!

Refund Policy


All subscriptions to StudySoup are paid in full at the time of subscribing. To change your credit card information or to cancel your subscription, go to "Edit Settings". All credit card information will be available there. If you should decide to cancel your subscription, it will continue to be valid until the next payment period, as all payments for the current period were made in advance. For special circumstances, please email


StudySoup has more than 1 million course-specific study resources to help students study smarter. If you’re having trouble finding what you’re looking for, our customer support team can help you find what you need! Feel free to contact them here:

Recurring Subscriptions: If you have canceled your recurring subscription on the day of renewal and have not downloaded any documents, you may request a refund by submitting an email to

Satisfaction Guarantee: If you’re not satisfied with your subscription, you can contact us for further help. Contact must be made within 3 business days of your subscription purchase and your refund request will be subject for review.

Please Note: Refunds can never be provided more than 30 days after the initial purchase date regardless of your activity on the site.