The calculation of the F n value uses those of both F n-1 and F n-2 , which must be computed first. An example of a parallel algorithm for solving this problem using Binet's formula :. Each program calculates the population of a given group, where each group's growth depends on that of its neighbors.
As time progresses, each process calculates its current state, then exchanges information with the neighbor populations. All tasks then progress to calculate the state at the next time step. An audio signal data set is passed through four distinct computational filters.
Each filter is a separate process. The first segment of data must pass through the first filter before progressing to the second. When it does, the second segment of data passes through the first filter. By the time the fourth segment of data is in the first filter, all four tasks are busy.
Each model component can be thought of as a separate task. Arrows represent exchanges of data between components during computation: the atmosphere model generates wind velocity data that are used by the ocean model, the ocean model generates sea surface temperature data that are used by the atmosphere model, and so on.
There are a number of important factors to consider when designing your program's inter-task communications:. Skip to main content. Search form. Introduction to Parallel Computing Tutorial. Why Use Parallel Computing? Who is Using Parallel Computing? Overview What is Parallel Computing? Serial Computing Traditionally, software has been written for serial computation: A problem is broken into a discrete series of instructions Instructions are executed sequentially one after another Executed on a single processor Only one instruction may execute at any moment in time serialProblem.
Screen Shot at 3. Screen Shot at 5. Learn how to make software releases, incident management, and infrastructure migrations seamless and safe. Note: By checking the box you grant InfoQ permission to share your contact info with this sponsor. Deploy faster. Reduce risk. Iterate continuously. Start Free Trial. Like Print Bookmarks. Before you download this book Need an account? Click here to sign up.
Download Free PDF. Software Engineering 9 Solutions Manual. Fantasia Mariam. A short summary of this paper. Download Download PDF. Translate PDF. Neither the author nor the publisher warrants the correctness of these solutions nor accepts any liability for their use.
The solutions may be made available to students on a password-protected intranet but must not be made available on a publicly-accessible WWW server. Each chapter in the book has 10 exercises of different types, which you may set for students either as is or in a modified form. The exercises for which answers have not been supplied are, generally, of one of three types: 1.
Simple exercises whose answers can be found in the text of the chapter. There are typically one or two of these questions in each chapter and they are intended to stimulate students to read the chapter. Design problems for which there is a range of solutions and you have to use your judgment to decide if the solution is appropriate. Supplying a solution here would imply that there is only one right answer to the question.
Ethics-related questions as the aim of these questions is to encourage students to think about the ethics issues involved. I suggest that these questions should be used to stimulate class discussions rather than as part of class tests. It is generally good educational practice to give students credit for what they know and if they produce credible answers that reveal they have thought about the exercise and have some knowledge of the topic, then this should be rewarded.
This solutions manual may be used in conjunction with the associated quiz book, which lists short questions and answers for each chapter in the book. These can be used for short class tests to assess if students have read the material or as self-assessment tests which the students complete in their own time.
If you think that I have made a mistake in some of these answers quite possible , please let me know. In some cases, there are obviously several possible answers and you may disagree with my solutions. What might this mean in practice for users of generic software products?
The essential difference is that in generic software product development, the specification is owned by the product developer. For custom product development, the specification is owned and controlled by the customer.
The implications of this are significant — the developer can quickly decide to change the specification in response to some external change e.
For users of generic products, this means they have no control over the software specification so cannot control the evolution of the product. Suggest four other attributes that may sometimes be significant. Four important attributes are maintainability, dependability, performance and usability. Other attributes that may be significant could be reusability can it be reused in other applications , distributability can it be distributed over a network of processors , portability can it operate on multiple platforms e.
Decompositions of the 4 key attributes e. Problems and challenges for software engineering There are many possible challenges that could be identified. These include: 1. Developing systems that are energy-efficient.
This makes them more usable on low power mobile devices and helps reduce the overall carbon footprint of IT equipment. Developing validation techniques for simulation systems which will be essential in predicting the extent and planning for climate change. Developing systems for multicultural use 4. Developing systems that can be adapted quickly to new business needs 5. Designing systems for outsourced development 6.
Developing systems that are resistant to attack 7. Developing systems that can be adapted and configured by end-users 8. Finding ways of testing, validating and maintaining end-user developed systems 1. Different application types require the use of different development techniques for a number of reasons: 1. Costs and frequency of change.
Some systems such as embedded systems in consumer devices are extremely expensive to change; others, must change frequently in response to changing requirements e. Systems which are very expensive to change need extensive up- front analysis to ensure that the requirements are consistent and extensive validation to ensure that the system meets its specification.
This is not cost- effective for systems that change very rapidly. Different systems have different priorities for non-functional requirements. The techniques used to achieve safety are not required for interactive gaming; the extensive UI design required for games is not needed in safety-critical control systems.
The software lifetime and delivery schedule. Some software systems have a relatively short lifetime many web-based systems , others have a lifetime of tens of years large command and control systems. Some systems have to be delivered quickly if they are to be useful. The techniques used to develop short-lifetime, rapid delivery systems e.
These are possible discussion points - any discussion on this will tend to be wide ranging and touch on other issues such as the nature of professionalism, etc. This is a particular problem in an area where technology developments are very rapid. Anti-lock braking system This is a safety-critical system so requires a lot of up-front analysis before implementation.
It certainly needs a plan-driven approach to development with the requirements carefully analysed. A waterfall model is therefore the most appropriate approach to use, perhaps with formal transformations between the different development stages.
Virtual reality system This is a system where the requirements will change and there will be an extensive user interface components. Incremental development with, perhaps, some UI prototyping is the most appropriate model. An agile process may be used. University accounting system This is a system whose requirements are fairly well-known and which will be used in an environment in conjunction with lots of other systems such as a research grant management system.
Therefore, a reuse-based approach is likely to be appropriate for this. Interactive travel planning system System with a complex user interface but which must be stable and reliable. An incremental development approach is the most appropriate as the system requirements will change as real user experience with the system is gained.
Explain why it is essential to have two separate requirements engineering activities in the process. These activities are: 1. An initial activity where you understand the function of the system and set out broad requirements for what the system should do.
There is a fundamental difference between the user and the system requirements that mean they should be considered separately.
They should be expressed in natural language and may not be expressed in great detail, to allow some implementation flexibility. The system requirements are much more detailed than the user requirements and are intended to be a precise specification of the system that may be part of a system contract. They may also be used in situations where development is outsourced and the development team need a complete specification of what should be developed. The system requirements are developed after user requirements have been established.
Furthermore, the system's environment is dynamic and constantly generates new requirements as a consequence of changes to the business, business goals and business policies. Unless the system is adapted to reflect these requirements, its facilities will become out-of-step with the facilities needed to support the business and, hence, it will become less useful.
Examples of process activities that support change are: 1. Recording of requirements rationale so that the reason why a requirement is included is known.
This helps with future change. Design modeling where the design model documents the structure of the software. Code refactoring that improves code quality and so makes it more amenable to change. An approach to process modeling which is simply based on static activities, such as requirements, implementation, etc. In most cases, the static activities shown in Figure 2.
By separating these from the dynamic perspective i. Furthermore, some of the activities that are required during some of the system phases are in addition to the central static activities shown in Figure 2. These vary from one organization to another and it is not appropriate to impose a particular process in the model.
The principles underlying agile development are: 1. Individual and interactions over processes and tools. By taking advantages of individual skills and ability and by ensuring that the development team know what each other are doing, the overheads of formal communication and process assurance are avoided.
This means that the team can focus on the development of working software. Working software over comprehensive documentation. This contributes to accelerated development because time is not spent developing, checking and managing documentation.
Customer collaboration over contract negotiation. This allows useful functionality to be developed and delivered earlier than would be possible if contracts were required. Responding to change over following a plan. Agile developers argue rightly that being responsive to change is more effective than following a plan-based process because change is inevitable whatever process is used.
There is significant overhead in changing plans to accommodate change and the inflexibility of a plan means that work may be done that is later discarded. Agile methods should probably not be used when the software is being developed by teams who are not co-located. If any of the individual teams use agile methods, it is very difficult to coordinate their work with other teams.
Furthermore, the informal communication which is an essential part of agile methods is practically impossible to maintain. Agile methods should probably also be avoided for critical systems where the consequences of a specification error are serious. In those circumstances, a system specification that is available before development starts makes a detailed specification analysis possible.
However, some ideas from agile approaches such as test first development are certainly applicable to critical systems. Discuss the advantages and disadvantages of this approach to requirements description. Advantages of stories: 1. They represent real situations that commonly arise so the system will support the most common user operations. It is easy for users to understand and critique the stories. They represent increments of functionality — implementing a story delivers some value to the user.
Disadvantages of stories 1. They are liable to be incomplete and their informal nature makes this incompleteness difficult to detect. They focus on functional requirements rather than non-functional requirements. Representing cross-cutting system requirements such as performance and reliability is impossible when stories are used. The relationship between the system architecture and the user stories is unclear so architectural design is difficult.
Reasons why pair programming may be more efficient as the same number of programmers working individually: 1. Pair programming leads to continuous informal reviewing. This discovers bugs more quickly than individual testing. Information sharing in pair programming is implicit — it happens during the process. Individual programmers have to spend time explicitly sharing information and they are not being productive when doing so.. Pair programming encourages refactoring the code must be understandable to another person.
This reduces the costs of subsequent development and change and means that future changes can be made more quickly.
Hence, efficiency is increased. In pair programming, people are likely to spend less time in fine-grain optimization as this does not benefit the other programmer.
This means that the pair focus on the essential features of the system which they can then produce more quickly. That is, they adopt the outlook of the development team and lose sight of the needs of their user colleagues. Suggest three ways how you might avoid this problem and discuss the advantages and disadvantages of each approach. Involve multiple users in the development team.
Advantages are you get multiple perspectives on the problem, better coverage of user tasks and hence requirements and less likelihood of having an atypical user. Disadvantages are cost, difficulties of getting user engagement and possible user conflicts. Change the user who is involved with the team. Advantages are, again, multiple perspectives. Disadvantages are each user takes time to be productive and possible conflicting requirements from different users. Validate user suggestions with other user representatives.
Advantages are independent check on suggestions; disadvantage is that this slows down the development process as it takes time to do the checks. Users select their destination and input a credit card and a personal identification number. The rail ticket is issued and their credit card account charged. When the user presses the start button, a menu display of potential destinations is activated, along with a message to the user to select a destination.
Once a destination has been selected, users are requested to input their credit card. Its validity is checked and the user is then requested to input a personal identifier. When the credit transaction has been validated, the ticket is issued. Ambiguities and omissions include: 1.
Can a customer buy several tickets for the same destination together or must they be bought one at a time? Can customers cancel a request if a mistake has been made? How should the system respond if an invalid card is input? What happens if customers try to put their card in before selecting a destination as they would in ATM machines? Must the user press the start button again if they wish to buy another ticket to a different destination?
Should the system only sell tickets between the station where the machine is situated and direct connections or should it include all possible destinations?
Possible non-functional requirements for the ticket issuing system include: 1. Between and in any one day, the total system down time should not exceed 5 minutes.
Between and in any one day, the recovery time after a system failure should not exceed 2 minutes. Between and in any one day, the total system down time should not exceed 20 minutes.
All these are availability requirements — note that these vary according to the time of day. Failures when most people are traveling are less acceptable than failures when there are few customers. After the customer presses a button on the machine, the display should be updated within 0.
The ticket issuing time after credit card validation has been received should not exceed 10 seconds. When validating credit cards, the display should provide a status message for customers indicating that activity is taking place. This tells the customer that the potentially time consuming activity of validation is still in progress and that the system has not simply failed.
The maximum acceptable failure rate for ticket issue requests is 1: I have not specified the acceptable number of incorrect tickets as this depends on whether or not the system includes trace facilities that allow customer requests to be logged. If so, a relatively high failure rate is acceptable as customers can complain and get refunds. If not, only a very low failure rate is acceptable. Obviously, these requirements are arbitrary and there are many other possible answers. You simply have to examine their credibility.
Keeping track of the relationships between functional and non-functional requirements is difficult because non-functional requirements are sometimes system level requirements rather than requirements which are specific to a single function or group of functions. One approach that can be used is to explicitly identify system-level non- functional requirements that are associated with a functional requirement and list them separately.
All system requirements that are relevant for each functional requirement should be listed. They can be related by including them in a table as shown below. Related non-functional Non-functional Functional requirement system requirements requirements The system shall provide Safety requirement: No Timing requirement: The an operation which allows release of steam shall be valve must open operators to open the permitted if maintenance completely within 2 release valve to vent work is being carried out seconds of the operator steam into the on any steam generation initiating the action.
Notice that in this example, the system non-functional requirement would normally take precedence over the timing requirement, which applied to the specific operation. Obviously, any sensible answer that provides a way of linking functional and non- functional requirements is acceptable here. There are a variety of different types of ATM so, obviously, there is not a definitive set of use cases that could be produced. However, I would expect to see use cases covering the principal functions such as withdraw cash, display balance, print statement, change PIN and deposit cash.
The use case description should describe the actors involved, the inputs and outputs, normal operation and exceptions. The Withdraw cash option is selected.
The customer is promoted with a request for the amount of cash required and inputs the amount. Before the cash is dispensed, the card is returned to the customer who is prompted by the machine to take their card. Exception: Invalid card. Card is retained by machine; Customer advised to seek advice. Incorrect PIN. Customer is request to rekey PIN. If incorrect after 3 attempts, card is retained by machine and customer advised to seek advice.
Insufficient balance Transaction terminated. Card returned to customer. The current balance of their account is displayed on the screen.
The card is returned to the customer. The last five transactions on their account is printed. The PINS input should be the same. As in Withdraw cash. PINS do not match. The customer is promoted with a request for the amount of cash to be deposited and inputs the amount.
He or she is then issued with a deposit envelope in which they should put the cash then return it to the machine. No cash deposited within 1 minute of envelope being issued. Transaction terminated. Suggest a model of a process for making these modifications that will ensure that the requirements document and the system implementation do not become inconsistent. The following diagram shows a change process that may be used to maintain consistency between the requirements document and the system.
The process should assign a priority to changes so that emergency changes are made but these changes should then be given priority when it comes to making modifications to the system requirements. The changed code should be an input to the final change process but it may be the case that a better way of making the change can be found when more time is available for analysis.
Explain why it is not always necessary for such a system model to be complete and correct. Would the same be true if you were developing a model of a new system? You might create and use a model of a system that already exists for the following reasons: 1. To understand and document the architecture and operation of the existing system. To act as the focus of discussion about possible changes to that system. To inform the re-implementation of the system.
You do not need a complete model unless the intention is to completely document the operation of the existing system. The aim of the model in such cases is usually to help you work on parts of the system so only these need to be modelled. Furthermore, if the model is used as a discussion focus, you are unlikely to ne interested in details and so can ignore parts of the system in the model.
This is true, in general, for models of new systems unless a model-based approach to development is taking place in which case a complete model is required. The other circumstances where you may need a complete model is when there is a contractual requirement for such a model to be produced as part of the system documentation. Courses may have limited enrolment, so the registration process must include checks that places are available.
Assume that the student accesses an electronic course catalog to find out about available courses. A relatively simple diagram is all that is needed here. It is best not to be too fussy about things like UML arrow styles as hardly anyone can remember the differences between them. Model the object classes that might be used in the system implementation to represent a mailbox and an e-mail message. Notice that I have not developed the activities representing other services or failed authentication.
What factors should you take into account when deciding whether or not to introduce this new approach to software development? The factors that you have to consider when making this decision include: 1. Is expertise already available or will extensive training be required.
The costs and functionality of the tools available to support MDA. Are tools available in house or will they have to be purchased. The likely lifetime of the software that you are developing. MDA is most suitable for long-lifetime systems 4. Requirements for high performance or throughput MDA relies on code generation that creates code which may be less efficient than hand written code 5. The long term benefits of using MDA are there real cost savings from this approach 6.
The enthusiasm of the software developers. The architecture may have to be designed before specifications are written to provide a means of structuring the specification and developing different sub- system specifications concurrently, to allow manufacture of hardware by sub- contractors and to provide a model for system costing.
Fundamentally, to provide availability, you need to have a replicated components in the architecture so that in the event of one component failing, you can switch immediately to a backup component. You also need to have several copies of the data that is being processed. Security requires minimizing the number of copies of the data and, wherever possible, adopting an architecture where each component only knows as much as it needs to, to do its job. This reduces the chance of intruders accessing the data.
Therefore, there is a fundamental architectural conflict between availability replication, several copies and security specialization, minimal copies. The system architect has to find the best compromise between these fundamentally opposing requirements. You also have to look at how these services are used in particular toolsets. Generally, IDEs are tightly integrated systems and all parts of the reference model may not be applicable.
In this case, comparisons would be drawn using: 1. Data repository services. What kind of data management is supported? Data integration services. How well can data be interchanged with other tools and what support is provided for configuration management? User interface services. What facilities are supported to allow presentation integration? How well integrated at the user interface level are different parts of the systems? Task management services.
This is really for general purpose environments so is probably inapplicable to Java IDEs. Message services. How do different components of the IDE communicate? Students should consider the levels in the information system and should identify components that might be included at each level. You should make reasonable assumptions about the functionality that is required here. System: Weather station Use case: Report status Actors: Weather information system, weather station Data: The weather station sends a status update to the weather information system giving information about the status of its instruments, computers and power supply.
Stimulus: The weather information system establishes a satellite link with the weather station and requests status information. Response: A status summary is uploaded to the weather information system Comments: System status is usually requested at the same time as the weather report.
System: Weather station Use case: Reconfigure Actors: Weather information system, weather station Data: The weather information station sends a reconfiguration command to the weather station.
This places it into remote control mode where further commands may be sent from the remote system to update the weather station software. Stimulus: A command from the weather information system. Response: Confirmation that the system is in remote control mode Comments: Used occasionally when software updates have to be installed.
Use your own experience to decide on the attributes and operations that should be associated with these objects. However, I am only really looking for simple objects which encapsulate the principal requirements of these artefacts. Possible designs are shown in the above diagram. The group diary communicates with the diaries of the participants in turn, modifying the window accordingly as there availability is known.
D2 is then contacted with that availability, not the original window. If there are no mutually available dates in the window, the system reports this to the organizer. Otherwise, a date is selected, entered in all diaries and confirmed to the organizer.
Without configuration management it is easy to lose track of the changes that each developer makes to code and for changes made by one programmer to overwrite changes made by another programmer. For example, one programmer may change a component to improve its performance whilst another may correct a bug in the functionality of the component. Without CM, whoever writes the component last to the shared component store will overwrite and so lose the previous component changes.
Furthermore, systems are usually composed of multiple components, each of which exists in multiple versions, where each version as a specific purpose. For example, there may be a versions of a system for different platforms such as Windows, Linux and MacOS. These versions have some specific components and some shared components and it is potentially error prone if these versions are assembled without CM tool support. It is very easy to include the wrong component in a version and this is likely to lead to subsequent software failure.
New customers usually have specific requirements to be incorporated into their system, and they pay for these to be developed. The company has an opportunity to bid for a new contract, which would more than double its customer base. The new customer also wishes to have some involvement in the configuration of the system.
Explain why, in these circumstances, it might be a good idea for the company owning the software to make it open source. The key benefits of open source are is that it opens up development to a wide range of developers and so accelerates the development and debugging of the product. Doubling the customer base places immense strains on a small company of they have to take on a lot of new staff and so going open source means that the costs of expansion are reduced.
In this case, because the product is specialized to the needs of different users, the company that own the software can still charge these users to make the changes to the system. Hence the loss in revenue from selling the software is compensated by the additional effort available to service more customers. Furthermore, large companies are often reluctant to buy from small companies who may go out of business, To some extent, open source provides reassurance to customers that, even of the original owners of the software are unavailable, they can get access to the source code and hence continue to maintain their system.
Assume that exhaustive testing of a program, where every possible valid input is checked, is impossible true for all but trivial programs. Test cases either do not reveal a fault in the program or reveal a program fault. If they reveal a program fault then they demonstrate the presence of an error. If they do not reveal a fault, however, this simply means that they have executed a code sequence that — for the inputs chosen — is not faulty.
The next test of the same code sequence — with different inputs — could reveal a fault. Explain how the use of automated tests and a testing framework such as JUnit simplifies regression testing. Regression testing is the process of running tests for functionality that has already been implemented when new functionality is developed or the system is changed. Regression tests check that the system changes have not introduced problems into the previously implemented code.
Automated tests and a testing framework, such as JUnit, radically simplify regression testing as the entire test set can be run automatically each time a change is made.
The automated tests include their own checks that the test has been successful or otherwise so the costs of checking the success or otherwise of regression tests is low. A possible scenario for high-level testing of the weather station system is: John is a meteorologist responsible for producing weather maps for the state of Minnesota.
These maps are produced from automatically collected data using a weather mapping system and they show different data about the weather in Minnesota. John selects the area for which the map is to be produced, the time period of the map and requests that the map should be generated.
While the map is being created, John runs a weather station check that examines all remotely collected weather station data and looks for gaps in that data — this would imply a problem with the remote weather station. There are many possible alternative scenarios here. They should identify the role of the actors involved and should discuss a typical task that might be carried out by that role.
Stress testing is where you deliberately increase the load on a system beyond its design limit to see how it copes with high loads. The system should degrade gracefully rather than collapse. To stress test the system, you need to arrange for a many different clinics to try and access the system at the same time and b Large numbers of records to be added to the system. This may involve using a simulation system to simulate multiple users.
Systems must change or become progressively less useful for a number of reasons: 1. The presence of the system changes the ways of working in its environment and this generates new requirements. If these are not satisfied, the usefulness of the system declines. The business in which the system is used changes in response to market forces and this also generates new system requirements.
The external legal and political environment for the system changes and generates new requirements. New technologies become available that offer significant benefits and the system must change to take advantage of them. Suggest how you might set up a program to analyze the maintenance process and determine appropriate maintainability metrics for the company. This is a very open question, where there are many possible answers.
Basically, the students should identify factors which affect maintainability such as program and data complexity, use of meaningful identifiers, programming language, program documentation etc. They should then suggest how these can be evaluated in existing systems whose maintenance cost is known and discuss problems of interaction. The approach should be to discover those program units which have particularly high maintenance costs and to evaluate the cost factors for these components and for other components.
Then check for correlations. Why is it sometimes difficult to distinguish between them? The three main types of software maintenance are: 1.
0コメント