Professional Documents
Culture Documents
Unit 2
Unit 2
SYLLABUS:
1
DEFINITIONS
Every member of the development team must become fully familiar application domain
o Correct terminology is essential
We must build a glossary
o That is, a list of technical words used in the domain, and their meaning
Osbert Oglesby, Art Dealer, needs an information system to assist him in buying and
selling paintings
Obtaining domain knowledge is the first step
Osbert is interviewed to obtain the relevant information
2
2.3.1 INTERVIEWING
The requirements team meet with the client and users to extract all relevant information
There are two types of questions
o Close-ended questions requires a specific answer
o Open-ended questions are asked to encourage the person being interviewed to
speak out
There are two types of interviews
o In a structured interview, specific preplanned questions are asked, frequently
close-ended
o In an unstructured interview, questions are posed in response to the answers
received, frequently open-ended
Interviewing is not easy
o An interview that is too unstructured will not yield much relevant information
o The interviewer must be fully familiar with the application domain
o The interviewer must remain open-minded at all times
After the interview, the interviewer must prepare a written report
o It is strongly advisable to give a copy of the report to the person who was
interviewed
A use case models an interaction between the information system itself and the users of
that information system (actors)
Example:
3
Each use case models one type of interaction
o There can be just a few use cases for an information system, or there can be
hundreds
The rectangle in the use case represents the information system itself
An actor is a member of the world outside the information system
It is usually easy to identify an actor
o An actor is frequently a user of the information system
In general, an actor plays a role with regard to the information system. This role is
o As a user; or
o As an initiator; or
o As someone who plays a critical part in the use case
A user of the system can play more than one role
Example: A customer of the bank can be
o A Borrower or
o A Lender
Conversely, one actor can be a participant in multiple use cases
Example: A Borrower may be an actor in
o The Borrow Money use case;
o The Pay Interest on Loan use case; and
o The Repay Loan Principal use case
Also, the actor Borrower may stand for many thousands of bank customers
An actor need not be a human being
Example: The Cardholder Clothing Company information system has to interact with the
credit card company information system
o The credit card company information system is an actor from the viewpoint of the
Cardholder Clothing Company information system
o The Cardholder Clothing Company information system is an actor from the
viewpoint of the credit card company information system
A potential problem when identifying actors
o Overlapping actors
Example: Hospital Information System
o One use case has actor Nurse
o A different use case has actor Medical Staff
o Better:
Actors: Physician and Nurse
Alternatively:
o Actor Medical Staff with two specializations: Physician and Nurse
4
2.4 REQUIREMENTS WORKFLOW- OSBERT OGLESBY CASE STUDY
Osbert wants an information system, running on his laptop computer, that will
o Determine the maximum price he should pay for a painting
o Detect new trends in the art market as soon as possible
To do this, the information system needs to keep a record of all purchases and all sales
Currently, Osbert produces reports of annual sales and purchases by hand
o At only a small additional cost, the information system can also print these two
reports on demand
Osbert wants an information system that can
o Compute the highest price he should pay for a painting; and
o Detect new art trends
Osbert needs an information system that can also
o Provide reports on purchases and sales
It is vital to determine the client’s needs up front, and not after the information system
has been delivered
Osbert has three business activities:
o He buys paintings
o He sells paintings
o He produces reports
Buy a Painting use case
5
For conciseness, all three use cases are combined into a use-case diagram
The only person who uses the current (manual) information system is Osbert
o Osbert is therefore an actor in all three use cases
The customer may initiate the Buy a Painting or the Sell a Painting use case
The customer plays a critical part in both use cases by providing data entered into the
information system by Osbert
o The customer is therefore an actor in both these use cases
Next, the use cases have to be annotated
Here are the initial use-case descriptions
6
Produce a Report use case
The initial business model (the three use cases) shows how Osbert currently does
business
Decide which of these use cases are also requirements of the information system to be
built
o Clearly, all three are requirements
Refine the resulting initial requirements
o The descriptions of the use cases have to be refined
7
Sell a Painting use case
8
o Masterwork, or
o Other painting
Scan worldwide auction records over the past 25 years for the most similar work by the
same artist
Use the auction purchase price of the most similar work as the base price
The maximum purchase price is found by adding 7.5 percent to the base price,
compounded annually, for each year since that auction
Compute the maximum purchase price as if the painting were a masterpiece by the same
artist
If the picture was painted in the 21st century, multiply this figure by 0.25
Otherwise, multiply it by (21 – c) / (22 – c), where c is the century in which the work
was painted (12 < c < 21)
Measure the dimensions of the canvas
The maximum purchase price is then given by the formula F A, where
o F is a constant for that artist (fashionability coefficient), and
o A is the area of the canvas in square centimeters
If there is no fashionability coefficient for that artist, Osbert will not buy the painting
The information system must include a list of artists and their corresponding F values
The value of F can vary from month to month, depending on the current fashionability of
an artist
Osbert determines the value of F on the basis of his knowledge and experience
o He changes the value if prices for work by an artist increase or decrease
The information system must utilize information on auction sales of masterpieces over
the past 25 years worldwide
Each month Osbert receives a CD with updated worldwide auction prices; these prices
are never modified by Osbert
9
Updated Use Cases : Osbert Oglesby Case Study
A report is needed to display all the paintings purchased during the past year
o The average ratio of the purchase price to the suggested maximum price is
required at the end of the report
10
Report of Sales during the Past Year
A report is needed to display all the paintings sold during the past year
o The average ratio of the actual selling price to the target selling price is required
at the end of the report
A report showing artists whose works Osbert has sold at a price that has exceeded the
target selling price in every instance during the past year
o To appear in this report, at least two of the artist’s works must have been sold by
Osbert during that period
11
2.4.4 UPDATED USE-CASE DESCRIPTION: PRODUCE A REPORT
The updated description of the Produce a Report use case, incorporating the details are
listed below
12
2.5 MSG FOUNDATION CASE STUDY-REVISING THE REQUIREMENTS
13
Insurance Premiums
Real-estate taxes paid on a home are treated the same way as insurance premiums
o Monthly installments are deposited in the escrow account
o The annual real-estate tax payment is made from that account
Borrowing Limits
A mortgage will not be granted unless the total monthly payment (P & I plus insurance
plus real-estate taxes) is less than 28% of the borrower’s total income
Other Costs
The finance company requires a lump sum up front in return for lending the money to the
borrower
o Typically, the finance company will want 2% of the principal (“2 points”)
o For the $90,000 loan, this amounts to $1,800
There are other costs involved in buying a house
o Legal costs
o Various taxes
When the deal is “closed,” the closing costs (legal costs, taxes, and so on) plus the points
can easily amount to $7,000
14
Initial Glossary
At the start of each week, MSG estimates how much money will be available that week
to fund mortgages
Low-income couples can apply at any time
An MSG Foundation staff member determines
o Whether the couple qualifies for an MSG mortgage, and
o Whether MSG has sufficient funds on hand to purchase the home
If so, the mortgage is granted
o The weekly mortgage repayment is computed according to MSG rules
This repayment amount may vary from week to week, depending on the couple’s current
income
There are three use cases
15
ESTIMATE FUNDS AVAILABLE FOR WEEK USE CASE
16
COMPUTE WEEKLY REPAYMENT AMOUNT USE CASE
Who Is an Actor?
17
USE-CASE DIAGRAM OF THE INITIAL BUSINESS MODEL
18
INITIAL REQUIREMENTS
It is unclear if all four use cases are all requirements of the product to be developed
o What, exactly, is “a pilot project”?
The best way to proceed is
o Draw up the initial requirements on the basis of what the client wants, and then
iterate
Consider each use case in turn:
Estimate Funds Available for Week is obviously part of the initial requirements
Apply for an MSG Mortgage does not seem to have anything to do with the pilot project,
so it is excluded
Compute Weekly Repayment Amount, & Manage an Investment
o Both appear to be irrelevant to the pilot project
However, the pilot project deals with the “money that is available each week to purchase
homes”
o Some of that money comes from the weekly repayment of existing mortgages,
and from income from investments
19
2.6 MSG - CONTINUING THE REQUIREMENTS WORKFLOW
The systems analysts learn that the MSG Foundation grants a 100% mortgage to buy a
home under the following conditions:
o The couple has been legally married for at least 1 year but not more than 10 years
o Both husband and wife are gainfully employed
o The price of the home must be below the published median price for homes in
that area for the past 12 months
o Their income and/or savings are insufficient to afford a standard fixed-rate 30-
year 90% mortgage
o The foundation has sufficient funds to purchase the home
If the application is approved, then each week for the next 30 years the couple pays MSG
o The total of the principal and interest payment — this never changes over the life
of the mortgage; plus
o The escrow payment, which is 1/52nd of the sum of the annual real-estate tax and
the annual homeowner’s insurance premium
If this exceeds 28% of the couple’s gross weekly income, MSG pays the difference as a
grant
o The couple must provide proof of their current income — the weekly payment
may vary from week to week
1. At the beginning of the week, the estimated annual income from MSG investments is
computed and divided by 52
2. The estimated annual MSG operating expenses are divided by 52
3. The total of the estimated mortgage payments for the week is computed
4. The total of the estimated grants for the week is computed
5. The amount available at the beginning of the week is then (1) – (2) + (3) – (4)
6. If the cost of the home is no more than (5), funds are provided to buy the home
7. At the end of each week, any unspent funds are invested
To keep the cost of the pilot project as low as possible, only those data items needed for
the weekly funds computation will be included
Only three types of data are therefore needed:
o Investment data
o Operating expenses data
o Mortgage data
o Investment Data
Item number
Item name
Estimated annual return
Date estimated annual return was last updated
20
o Operating Expenses Data
o Mortgage Data
Account number
Last name of mortgagees
Original purchase price of home
Date mortgage was issued
Weekly principal and interest payment
Current combined gross weekly income
Date combined gross weekly income was last updated
Annual real-estate tax
Date annual real-estate tax was last updated
Annual homeowner’s insurance premium
Date annual homeowner’s insurance premium was last updated
o Take all the investments, sum the estimated annual return on each investment, and
divide the result by 52
An additional use case, Estimate Investment Income for Week, is needed
o (We still need use case Manage an Investment for adding, deleting, and modifying
investments)
21
Estimate investment income for week use case
To determine the estimated annual operating expenses two additional use cases are
needed
– Use case Update Estimated Annual Operating Expenses models adjustments to
the value of the estimated annual operating expenses
– Use case Estimate Operating Expenses for Week provides the needed estimate of
the operating expenses
22
Update Estimated Annual Operating Expenses Use Case
23
SECOND ITERATION OF REVISED USE-CASE DIAGRAM
Total estimated mortgage payments for the week and Total estimated grant payments for
the week:
Split Compute Weekly Repayment Amount into two separate use cases
o Use case Estimate Payments and Grants for Week, and
o Use case Update Borrowers’ Weekly Income
24
Estimate Payments and Grants for Week Use Case
25
Third Iteration of the Revised Use-Case Diagram
• Use case Estimate Funds Available for Week models the computation that uses the data
obtained from three other use cases
– Estimate Investment Income for Week
– Estimate Operating Expenses for Week
– Estimate Payments and Grants for Week
26
Estimate Funds Available for Week Use Case
«include» Relationship
27
The bottom diagram models use cases
o Estimate Funds Available for Week, and
o Estimate Payments and Grants for Week
o as two independent use cases
o However, a use case models an interaction between the product itself and users of
the product (actors)
Use case Estimate Payments and Grants for Week does not interact with an actor and
therefore cannot be a use case in its own right
o Instead, it is a portion of use case Estimate Funds Available for Week, as reflected
in the top diagram
28
Fourth Iteration of the Revised Use-Case Diagram
29
Produce a Report Use Case
30
Fifth Iteration of the Revised Use-Case Diagram
31
Accordingly, use case Update Borrowers’ Weekly Income is superfluous, and must be
deleted
32
o Estimate Funds Available for Week, and
o Produce a Report
o have to be modified (the use cases do not change)
33
Modified Description — Estimate Funds Available for Week
The usual reason for an «include» relationship is where one use case is part of two or
more other use cases
o Example: U.S. tax forms—avoiding triplication
o
34
Seventh Iteration of Revised Use-Case Diagram
35
Revised Description of Use Case
36