Implementation for the prime machine, Computer Engineering

Write an implementation for the Prime machine (de?ned at the end of the assignment sheet). Provide a suitable invariant and variant for any loop you use. Provide comments in your machine stating the precondition and postcondition which the initialised loop meets.

An abstract machine, Bu?er is de?ned at the end of this assignment sheet. Provide a re?nement of this machine which stores the queue in an array:

aa : 1 . . qlen → ELEM

When elements are removed from the front of the queue, the array itself is not altered but the positions become available for overwriting. When adding elements, once the end of aa is reached, wrap-around can occur if positions at the front of aa are available. Thus forexample, if the capacity is 8, the sequence [a, b, c, d] may correspond to:

938_implementation for the Prime machine.png

etc (where * indicates any element).

To do this you will need to introduce some further state variables to keep track of the situation in the array and to enable you to relate the state of aa to the state of bu? . Provide the linking invariant which captures this invariant and incorporate it in a re?nement machine BufferR.

Posted Date: 3/8/2013 1:25:36 AM | Location : United States







Related Discussions:- Implementation for the prime machine, Assignment Help, Ask Question on Implementation for the prime machine, Get Answer, Expert's Help, Implementation for the prime machine Discussions

Write discussion on Implementation for the prime machine
Your posts are moderated
Related Questions
ALU ORGANISATION An ALU performs simple arithmetic and logic operation as well as shift operations. Complexity of an ALU relies on the type of instruction set for that it has b


Association and classes betwnn student and university Association and classes are alike in the sense that classes describe objects, and association describe links. Figure shows

Upgrading Magento to the latest version is a fairly easy task. Copy and Paste this key magento-core/Mage_All_Latest VIA Magento Connect where it states Paste extension key to insta

Hi I study master of computer science I have assignment for subject statical natural language processing . I need solved due date on 6 May2014 at 11 pm Australia time I need yo

Explain the generic framework for electronic commerce along with suitable diagram? Generic Framework for electronic commerce comprises the Applications of EC (as like banking,

Normal 0 false false false EN-IN X-NONE X-NONE MicrosoftInternetExplorer4

Inspirations of artificial intelligence: Artificial Intelligence research can be easily understood by following example in terms of how the following question has been answere

The method(s) of payment for online consumers are A) Electronic cash    (B) Credit/debit C) Electronic checks

The following definition of mapping is adapted from the first edition of the Set Book: Mapping concerns the relationship between controls and their effects in the world. Nearly al