BuyFindarrow_forward

Discrete Mathematics With Applicat...

5th Edition
EPP + 1 other
ISBN: 9781337694193

Solutions

Chapter
Section
BuyFindarrow_forward

Discrete Mathematics With Applicat...

5th Edition
EPP + 1 other
ISBN: 9781337694193
Textbook Problem
1 views

A simplified telephone switching system allows the following strings as legal telephone numbers:
a. A string of seven digits in which neither of the first two digits is a 0 or 1 (a local call string).
b. A 1 followed by a three-digit area code string (any digit except 0 or I followed by a 0 or I followed by any digit) followed by a seven- digit local call string.
c. A 0 alone or followed by a three-digit area code string plus a seven-digit local call string.

Design a finite-state automaton to recognize all the legal telephone numbers in (a), (b), and (c). Include an “error state” for invalid telep hone numbers.

To determine

To design:

A finite-state automaton to recognize all the legal telephone numbers in (a), (b) and (c) and to include an “error state” for invalid telephone numbers.

Explanation

Given information:

A simplified telephone switching system allows the following strings as legal telephone numbers:

  1. A string of seven digits in which neither of the first two digits is a 0 or 1 (a local call string).
  2. A 1 followed by a 3-digit area code string (any digit except 0 or 1 followed by a 0 or 1 followed by any digit) followed by a seven-digit local call string.
  3. A 0 alone or followed by a three-digit area code string plus a seven-digit local call string.

Calculation:

By the given information, we design an automaton with 11 states s0,s1,s2,...,s10 where s0 is the initial state.

Let [09] represent all digits 0,1,2,3,4,5,6,7,8,9 and let [29] represent the digits 2,3,4,5,6,7,8,9.

s0= No input or a 0/1 followed by a 0 or 1, followed by a digit that is not 0 nor 1, followed by a 0 or 1, followed by a digit.

s1= Input is a 0 or 1.

s2= Input is a 0 or 1, followed by a digit that is neither 0 nor 1, followed by a 0 or 1.

s3= Input is a 0 or 1, followed by a digit that is neither 0 nor 1, followed by a 0 or 1.

s4= Input is the string until the first digit in the local call string.

s5= Input is the string until the second digit in the local call string.

s6= Input is the string until the third digit in the local call string.

s7= Input is the string until the fourth digit in the local call string.

s8= Input is the string until the fifth digit in the local call string.

s9= Input is the string until the sixth digit in the local call string.

s10= Input is the string until the seventh digit in the local call string.

s11= Remaining inputs.

If we are at state s0 and the input is 0 or 1, then we move to state s1. If we are at state s0 and the input is another digit, then the input represents the first digit in the local call string and thus we move to state s3.

If we are at state s1 and the input is 0 or 1, then we obtain an invalid telephone number and thus we move to state s11

Still sussing out bartleby?

Check out a sample textbook solution.

See a sample solution

The Solution to Your Study Problems

Bartleby provides explanations to thousands of textbook problems written by our experts, many with advanced degrees!

Get Started

Chapter 12 Solutions

Show all chapter solutions add
Sect-12.1 P-11TYSect-12.1 P-12TYSect-12.1 P-1ESSect-12.1 P-2ESSect-12.1 P-3ESSect-12.1 P-4ESSect-12.1 P-5ESSect-12.1 P-6ESSect-12.1 P-7ESSect-12.1 P-8ESSect-12.1 P-9ESSect-12.1 P-10ESSect-12.1 P-11ESSect-12.1 P-12ESSect-12.1 P-13ESSect-12.1 P-14ESSect-12.1 P-15ESSect-12.1 P-16ESSect-12.1 P-17ESSect-12.1 P-18ESSect-12.1 P-19ESSect-12.1 P-20ESSect-12.1 P-21ESSect-12.1 P-22ESSect-12.1 P-23ESSect-12.1 P-24ESSect-12.1 P-25ESSect-12.1 P-26ESSect-12.1 P-27ESSect-12.1 P-28ESSect-12.1 P-29ESSect-12.1 P-30ESSect-12.1 P-31ESSect-12.1 P-32ESSect-12.1 P-33ESSect-12.1 P-34ESSect-12.1 P-35ESSect-12.1 P-36ESSect-12.1 P-37ESSect-12.1 P-38ESSect-12.1 P-39ESSect-12.1 P-40ESSect-12.1 P-41ESSect-12.2 P-1TYSect-12.2 P-2TYSect-12.2 P-3TYSect-12.2 P-4TYSect-12.2 P-5TYSect-12.2 P-6TYSect-12.2 P-7TYSect-12.2 P-8TYSect-12.2 P-9TYSect-12.2 P-10TYSect-12.2 P-1ESSect-12.2 P-2ESSect-12.2 P-3ESSect-12.2 P-4ESSect-12.2 P-5ESSect-12.2 P-6ESSect-12.2 P-7ESSect-12.2 P-8ESSect-12.2 P-9ESSect-12.2 P-10ESSect-12.2 P-11ESSect-12.2 P-12ESSect-12.2 P-13ESSect-12.2 P-14ESSect-12.2 P-15ESSect-12.2 P-16ESSect-12.2 P-17ESSect-12.2 P-18ESSect-12.2 P-19ESSect-12.2 P-20ESSect-12.2 P-21ESSect-12.2 P-22ESSect-12.2 P-23ESSect-12.2 P-24ESSect-12.2 P-25ESSect-12.2 P-26ESSect-12.2 P-27ESSect-12.2 P-28ESSect-12.2 P-29ESSect-12.2 P-30ESSect-12.2 P-31ESSect-12.2 P-32ESSect-12.2 P-33ESSect-12.2 P-34ESSect-12.2 P-35ESSect-12.2 P-36ESSect-12.2 P-37ESSect-12.2 P-38ESSect-12.2 P-39ESSect-12.2 P-40ESSect-12.2 P-41ESSect-12.2 P-42ESSect-12.2 P-43ESSect-12.2 P-44ESSect-12.2 P-45ESSect-12.2 P-46ESSect-12.2 P-47ESSect-12.2 P-48ESSect-12.2 P-49ESSect-12.2 P-50ESSect-12.2 P-51ESSect-12.2 P-52ESSect-12.2 P-53ESSect-12.2 P-54ESSect-12.3 P-1TYSect-12.3 P-2TYSect-12.3 P-3TYSect-12.3 P-4TYSect-12.3 P-5TYSect-12.3 P-1ESSect-12.3 P-2ESSect-12.3 P-3ESSect-12.3 P-4ESSect-12.3 P-5ESSect-12.3 P-6ESSect-12.3 P-7ESSect-12.3 P-8ESSect-12.3 P-9ESSect-12.3 P-10ESSect-12.3 P-11ESSect-12.3 P-12ESSect-12.3 P-13ESSect-12.3 P-14ESSect-12.3 P-15ESSect-12.3 P-16ESSect-12.3 P-17ESSect-12.3 P-18ES