Question

Suppose there are three states where a book can be: on loan, on library’s shelf, or...

Suppose there are three states where a book can be: on loan, on library’s shelf, or on publisher’s stock. A book that is on library’s shelf can be borrowed, a book on loan can be returned to library’s shelf, and a book on publisher’s stock can be bought and put on library’s shelf. Draw a state diagram that represents this scenario for the book object. Your state diagram should have one start state and no end state.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

A book will be printed by a publisher, so "On Publisher's Shelf" will be the initial state. "On Publisher's Shelf" will have a transition to "On Library's Shelf" for bought. "On Library's Shelf" will have a transition to "On Loan" for borrowed. "On Loan" will have a transition to "On Library's Shelf" for returned.

Required State Diagram is:

Add a comment
Know the answer?
Add Answer to:
Suppose there are three states where a book can be: on loan, on library’s shelf, or...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Consider the NFA N with states labeled q1, q2 and q3, where q1 is the start...

    Consider the NFA N with states labeled q1, q2 and q3, where q1 is the start state and q2 and q3 are the final (accepting) states. The transition function for N is δ(q1,a) = {q1}, δ(q1,b) = {q1,q2},  δ(q2,a) = {q3}, δ(q2,b)= ∅, δ(q3,a)= ∅, and δ(q3,b)= ∅. Let L be the language recognized by N i.e. L(N). a) Draw the state diagram for N. b) Describe in plain English what's in the language L. c) Via the construction NFA to...

  • Suppose the economy can only be in one of the following two states: (i) Boom or...

    Suppose the economy can only be in one of the following two states: (i) Boom or “good” state and (ii) Recession or “bad” state. Each of the states can occur with an equal probability. At the beginning of a month, you can purchase the following two securities in the market: • Security 1: It is currently trading at $4. At the end of the month, the stock price is expected to increase by $10 in the good state and expected...

  • Consider a disease, which has three states: "0 (healthy)."1" (impaired), "Z (disease) In state "Z when certain treatments are adopted, the state can be restored to be healthy C&#3...

    Consider a disease, which has three states: "0 (healthy)."1" (impaired), "Z (disease) In state "Z when certain treatments are adopted, the state can be restored to be healthy C'O).When a subject is either at state "O" or 1", she/he can decide whether some preventive actions should be taken so that she/he will be in a new state "3. The state transition probabilities are as follows (5) Assume that the disease process is a first-order time homogenous Markov chain and it...

  • Consider the following FSM state transition diagram: 7. Let's see if there is an equivalent state machine with fewe...

    Consider the following FSM state transition diagram: 7. Let's see if there is an equivalent state machine with fewer states by checking to see if any states in the diagram above are equivalent. Two states are equivalent if (1) they have identical outputs and (2) for each possible combination of inputs they transition to equivalent states. A. Start by filling in a "compatibility table" like the one shown below. Place an "X" in square (SISI) if SI produces a different...

  • Now, back to Earth, where there is gravity. A 1 kg book sits on a frictionless...

    Now, back to Earth, where there is gravity. A 1 kg book sits on a frictionless inclined plane, tilted at an angle of 30◦ above the horizontal. Hint: If you have trouble with this problem, look at the force diagram you drew for the last problem and rotate it by thirty degrees. (a) Draw a force diagram for the book. (b) What are the components of the gravitational force parallel to and perpendicular to the ramp? Draw a right triangle...

  • You need to program a simple book library system. There are three java classes Book.java   //...

    You need to program a simple book library system. There are three java classes Book.java   // book object class Library.java   //library class A2.java //for testing The Book.java class represents book objects which contain the following fields title: a string which represents the book title. author: a string to hold the book author name year: book publication year isbn: a string of 10 numeric numbers. The book class will have also 3 constructors. -The default no argument constructor - A constructor...

  • Question 1: Design a DFA with at most 5 states for the language L1 = {w...

    Question 1: Design a DFA with at most 5 states for the language L1 = {w ∈ {0, 1}∗ | w contains at most one 1 and |w| is odd}. Provide a state diagram for your DFA. Approaching the Solution --since we haven’t really practiced this type of assignment (i.e. had to define our machine based on only having the language given; not the formal 5 tuples), I am providing the steps for how to work through this; you are...

  • 5. A three-heap with n elements can be stored in an array A, where A[O] contains...

    5. A three-heap with n elements can be stored in an array A, where A[O] contains the root of the tree. a) Draw the three-heap that results from inserting 5, 2, 8, 3, 6, 4, 9, 7, 1 in that order into an initially empty three-heap. You do not need to show the array representation of the heap. You are only required to show the final tree, although if you draw intermediate trees. b) Assuming that elements are placed in...

  • Write Java code to implement a FSM machine that recognizes the language for the alphabet {a,b,c} ...

    Write Java code to implement a FSM machine that recognizes the language for the alphabet {a,b,c} consisting of all strings that contain two consecutive c's and end with b.                   Your FSM program should include the following three static methods (Java) or functions (C):                                           a.    int nextState(int state, char symbol)                                  A state-transition function that returns the next state based on the                                  current state and an input symbol. This function should also return                                  -1 when an invalid input character is detected.                                  State...

  • Suppose that price of AAA stock at the end of next year depends on the state...

    Suppose that price of AAA stock at the end of next year depends on the state of the economy. The economy can have three states with the supplied probabilities and prices. What is the standard deviation of AAA’s returns if you purchase AAA today for $100? Also assume that AAA will pay a dividend of $10 at the end of the year. Enter your answer as a percent without the % sign. Round your final answer to 2 decimals. Expansion...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT