100% found this document useful (1 vote)
241 views9 pages

Chapter 4 Software Engineering

CHAPTER 4 SOFTWARE ENGINEERING

Uploaded by

noorulainsaleh19
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
241 views9 pages

Chapter 4 Software Engineering

CHAPTER 4 SOFTWARE ENGINEERING

Uploaded by

noorulainsaleh19
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 9

Chapter #4

Requirement Engineering
Exercises
Question: 4.1. Identify and briefly describe four types of requirements that may be defined
for a computer based system.

Answer:
Generally, system requirements are intended to communicate the functions that the system
should provide. And every computer based systems consists of many requirements. They are;

1. User requirements

2. System requirements

3. Functional requirements

4. Non-functional requirements

Description for requirements:

 User requirements: These requirements are the statements in a natural language plus
diagrams of the services the system provides and its operational constraints.
 System requirements: A structured document setting out detailed descriptions of the
system’s functions, services and operational constraints. Defines what should be
implemented. It may be part of a contract between client and contractor.
 Functional requirements: These are the statements of services that the system should
provide, how the system should react to particular inputs and how the system should
behave in particular situations.
 Non-functional requirements: Constraints on the services or functions offered by the
system such as timing constraints, constraints on the development process, standards,
etc.

These requirements are usually applied to the system as a whole rather than individual features
or services.

Question: 4.2. Discover ambiguities or omissions in the following statement of the


requirements for part of a drone system intended for search and recovery:

“The drone, a quad chopper, will be very useful in search and recovery operations, especially in
remote areas or in extreme weather conditions. It will click high-resolution images. It will fly according
to a path preset by a ground operator, but will be able to avoid obstacles on its own, returning to its
original path whenever possible. The drone will also be able to identify various objects and match
them to the target it is looking for”

Answer:

The distinguished ambiguities in a reasonable manner are following.

 In what limit will the robot choose when to snap a photo


 Where will the photographs be put away
 What is the memory capacities of the limit office
 Will the machine have the ability to take pictures around evening time
 Can the ground overseer change the route in the midst of flight
 What will happen if the robot can't locate the principal route after avoidance of impediments
 Can more than one objective be transferred
 What will happen when the goal is found
 Is a zone gotten a good deal on where the goal is found
 In what manner will the robot prompt the ground director that the goal is found
 Can the ground director request the machine to return before the preset way is done

Question: 4.3. Rewrite the above description using the structured approach described in
this chapter. Resolve the identified ambiguities in a sensible way.

Answer:

The above description using the structured approach described in this chapter are following:

 Capacity: Search and Recovery Drone


 Depiction: Drone used in the midst of request and recovery to find the goal on a set way
 Info: Target picture and set way
 Source: Ground director
 Yields High: goals pictures composed to target
 Activity: The robot fly as demonstrated by the preset way and take significant standards
pictures until the goal is composed to the photos taken
 Requires: Preset way and target picture
 Precondition: Target picture must match pictures taken
 Post condition: Target is found
 Reactions: Target isn't found or composed
Question: 4.4. Write a set of non-functional requirements for the drone system, setting out
its expected safety and response time.

Answer:

Depending on the type of drone and its specific application, here are some non-
functional requirements to consider:

1. The drone's flight path should allow it to avoid any obstacles or obstructions upon
which it may crash.

2. Recovery time after system failure should not exceed 0.5 seconds.

3. Within a day, total system downtime should not exceed 5 seconds.

4. The drone should be able to return to the launch site if it meets any unfavourable
conditions while flying.

5. On reliability, this system relies on the durability of the physical user interface, the
network connection in the area the drone is being operated in.

6. The drone will fly below 400 feet above the ground to prevent collisions with FAA
regulated aircraft in public airspace.

Question: 4.5. Using the technique suggested here, where natural language descriptions are
presented in a standard format, write plausible user requirements for the following functions:

An unattended petrol (gas) pump system that includes a credit card reader. The customer swipes the
card through the reader, then specifies the amount of fuel required. The fuel is delivered and the
customer’s account debited.

The cash-dispensing function in a bank ATM.

In an Internet banking system, a facility that allows customers to transfer funds from one account
held with the bank to another account with the same bank.

Answer:

1. An unattended petrol (gas) pump system with a credit card reader. The customer swipes
the card through the reader, then specifies the amount of fuel required. The fuel is
delivered and the customer's account debited.

 Function > Charge customer for amount of gas specified; dispense correct amount of gas.
 Description > Computes the charge for the specified gas amount.

 Inputs > Specified amount of fuel required; credit card information.

 Source > User interface system on gas tank; credit card reader.

 Outputs > Gas; amount to be charged to card (receipt).

 Destination > Customer's car; customer's bank.

 Action > Customer will input the amount of gas they require, program will calculate the
charge for the amount of gas, customer will swipe credit card, gas will be put into the car,
credit card will be charged, receipt printed for customer.

 Precondition > Gas amount desired must be available in the gas tank; credit card number
must be verified before transaction, before gas is dispensed.

 Post Condition > Amount taken from gas tank must be subtracted; charge must be
applied to card; specified amount of gas must be dispensed.

2. The cash-dispensing function in a bank ATM.

 Function > Dispense correct amount of cash.


 Description > Verifies the cardholder's pin number and dispenses the amount of cash
desired.
 Inputs > Amount of cash desired; debit card number (via debit card input); pin number.
 Source > User interface; debit card reader; pin pad.
 Outputs > Cash; receipt; debit card.

 Action > User inputs debit card; user inputs pin; user selects amount of cash desired; ATM
checks if user's account has enough cash to be dispensed; ATM checks if ATM has enough
cash to be dispersed; ATM dispenses cash if these checks are passed; user receives debit
card; user receives receipt.
 Precondition > User must have enough money in their account; ATM must have enough
money; user's pin number must be correct.
 Post Condition > Amount of cash in ATM must be subtracted; transaction must be
recorded.
3. In an internet banking system, a facility that allows customers to transfer funds
from one account held with the bank to another account with the same bank.

 Function > Transfer specified amount of money from one bank account to another, only if
accounts belong to the same bank.
 Description > Transfers funds from one account to the other.
 Inputs > Username; password; bank account to be transferred to; amount to transfer;
submission.
 Source > Reading of amount to be transferred; true if both accounts with the same bank.
 Outputs > Receipt of confirmation sent to user.
 Action > User logs onto online banking system; password is verified; user must choose to
transfer funds; account to be transferred to must be declared; other account my be
checked that it is with the same bank; amount to be transferred must be declared; funds
must be transferred; user sent an email confirmation that the transfer went through
successfully/unsuccessfully.
 Precondition > User must log into the bank system; user must have funds to transfer;
other account must belong with the same bank.
 Post Condition > One account is subtracted from while the other is added to.

Question: 4.6. Suggest how an engineer responsible for drawing up a system requirements
specification might keep track of the relationships between functional and non-functional
requirements.

Answer:

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 also be
related by including them in a table as shown below:
Functional Related non-functional Non-functional
requirement system requirements requirements

Safety requirement: No
release of steam shall be
The system shall provide permitted if maintenance Timing requirement: The valve
must open completely within 2
an operation which allows work is being carried out on
seconds of the operator
operators to open the any steam generation plant. initiating the action
release valve to vent
steam into the atmosphere

Notice that in this example, the system non-functional requirement would normally take
precedence over the timing requirement, which applied to the specific operation.

Question: 4.7. Using your knowledge of how an ATM is used, develop a set of use cases that
could serve as a basis for understanding the requirements for an ATM system.

Answer:
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.

1: Withdraw cash:

• Actors: Customer, ATM, Accounting system

• Inputs: Customer’s card, PIN, Bank Account details

• Outputs: Customer’s card, Receipt, Bank account details

Normal operation:

• The customer inputs his/her card into the machine. He/she s promoted for a PIN which is
entered on the keypad. If correct, he/she is presented with a menu of options. The Withdraw cash
option is selected. The customer is promoted with a request for the amount of cash required and
inputs the amount. If there are sufficient funds in his/her account, the cash is dispensed, a receipt
if printed and the account balance is updated. 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 3attempts, card is retained by
machine and customer advised to seek advice.

• Insufficient balance Transaction terminated. Card returned to customer.

2: Display balance

Actors: Customer, ATM, Accounting system

Inputs: Customer's card, PIN, Bank Account details

Outputs: Customer's card

Normal operation: The customer authenticates using card and PIN as in Withdraw cash and
selects the Display Balance option. The current balance of their account is displayed on the
screen. The card is returned to the customer

Exception: Invalid card. As in Withdraw cash

Incorrect PIN. As in Withdraw cash

3: Print statement:

Actors: Customer, ATM, Accounting system

Inputs: Customer's card, PIN, Bank Account details

Outputs: Customer's card, Printed statement

Normal operation: The customer authenticates using card and PIN as in Withdraw cash and
selects the Print statement option. The last five transactions on their account is printed. The card
is returned to the customer.

Exception: Invalid card. As in Withdraw cash Incorrect PIN. As in Withdraw cash.

4: Change PIN:

Actors: Customer, ATM

Inputs: Customer's card, PIN

Outputs: Customer's card

Normal operation: The customer authenticates as in Withdraw cash and selects the Change PIN
option. He/she is prompted twice to input the new PIN. The PINS input should be the same. The
customer's PIN is encrypted and stored on the card. Card returned to customer.

Exception: Invalid card. As in Withdraw cash Incorrect PIN. As in Withdraw cash.

PINS do not match. The customer is invited to repeat the process to reset his/her PIN.

5: Deposit cash:

Actors: Customer, ATM, Accounting system

Inputs: Customer's card, PIN, Bank Account details, Cash to be deposited


Outputs: Customer's card, Receipt

Normal operation: The customer authenticates as in Withdraw cash and selects the Deposit
option. 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. The customer's account balance is updated with the amount
deposited but this is marked as uncleared funds and is not cleared until checked. A receipt is
issued and the customer's card is returned.

Exception: Invalid card. As in Withdraw cash

Incorrect PIN. As in Withdraw cash

No cash deposited within I minute of envelope being issued. Transaction terminated. Card
returned to customer.

Question: 4.8. To minimize mistakes during a requirements review, an organization decides


to allocate two scribes to document the review session. Explain how this can be done.

Answer:

Requirement Review:

A requirements review is a process where a group of people from the system customer and the system
developer read the requirements document in detail and check for errors, anomalies, and
inconsistencies.

 To minimize the mistakes the note of the scribes should be read through before completing the
review and while going over the notes we should run a few checks to find the defects.
 Normally the defects for the components are found initially during the testing process, and when
the system is integrated then the interface problems are discovered and the program needs to
be debugged.
 It is important to record every defect and look for suggestions improvement of the process so
that the system meets its functional and non-functional requirements.

Question: 4.9. When emergency changes have to be made to systems, the system software
may have to be modified before changes to the requirements have been approved. 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.

Answer:

Incremental model
Incremental model is the best modification in older version are feasible and can be easily
managed.

Incremental model involves the technique of developing software in which the product is
designed implemented and tested in stages until the product is finished. The term finished here
means the product as meet all its requirement.

This model entails development as well as maintenance.

Question: 4.10. You have taken a job with a software user who has contracted your
previous employer to develop a system for them. You discover that your company’s interpretation of
the requirements is different from the interpretation taken by your previous employer. Discuss what
you Chapter 4 ■ References 137 should do in such a situation. You know that the costs to your
current employer will increase if the ambiguities are not resolved. However, you also have a
responsibility of confidentiality to your previous employer.

Answer:
The key thing here is to understand that there is nothing unethical about resolving ambiguities in
software requirements. There are certainly diplomatic ways you can forward your
recommendations to your current employer without breaching the confidentiality to your
previous employer. If you have signed any Non _Disclosure Agreements - NDAs with your
previous employer, make sure you do not go against it.

What are required to do here is to make a detailed report of the ambiguities you've discovered
without any direct reference to your previous employer's interpretation of the requirements.
Make sure your recommendations are genuine and authentic. You may only use your previous
employer's interpretation as a guide.

You might also like