Documentos de Académico
Documentos de Profesional
Documentos de Cultura
Requirement
Analysis
Requirement
Engineering
Requirement
Documentation
Requirements
SRS Review
• Team is then divided into smaller subteams,each work to develop mini-specifications for 1 or more entries
of lists.
• Each subteam then presents mini-specifications to all FAST attendees.
• After discussion, additions or deletions are made to list and final list is prepared.
4. QFD (Quality function deployment)
Its quality management technique that helps to incorporate voice of customer.
QFD has foll. Steps:
1. Identify all stakeholders e.g. customers and developers.
2. List out requirements from customer;inputs;considering different viewpoints.
Some customer’s expectations may be unrealistic or ambiguous and may be translated into realistic or
unambiguous requirements if possible.
3. Value indicating degree of importance, is assigned to each requirement on a scale of 1 to 5.
It may be based on cost/benefit analysis particular to project.
5 points: Very Important
4 points: Important
3 points: Not Important, but nice to have
2 points: Not Important
1 points: Unrealistic, requires further exploration
Stakeholders will have their own unique set of criteria for determining the “value” of a requirement.
3 types of requirements are identified:
1. Normal requirements
2. Expected Requirements(so obvious that customer does not explicitly state
them. Ex: protection from unauthorised access, warning message for wrong
entry of data)
3. Exciting requirements(features that go beyond customer’s expectations. EX: if
an unauthorised access is noticed by s/w, it should immediately shut down all
proceses and an email is generated to system administrator )
Requirement engineers may review final list of requirements and categories like:
a. it’s possible to achieve.
b. It should be deferred and reason thereof.
c. It’s impossible and should be dropped from consideration.
If time and effort permits, second category requirements may be reviewed and few
of them may be transferred to category first for implementation.
5. Use case Approach
• This approach uses a combination of text and pictures in order to improve understanding of requirements.
• Use cases are structured outline/template for description of user requirements, modelled in structured
language like English.
• They only give functional view of system. Use case describes “What of system” and not “How”.
Actor Use case Relationship b/wactors and use case and/or b/w use cases
Update Train Information
Report Generation
Admin
Login
Cancellations
Fig: Use Case Diagram for Railway Reservation System
(III) Student/ Teacher
Requirement Analysis:
Important activity after elicitation.
We analyse, refine and scrutinize gathered requirements in order to make consistent and unambiguous requirements.
Review all the requirements and provide a graphical view of entire system.
Draw
context Develop
diagram Prototypes Model
(optional) Requirements Finalise
requirements
Steps of RA:
• We may interact with customer to clarify points of confusion.
• After the completion of analysis, it's expected that understandability of project
may improve significantly.
Step-1: Draw Context Diagram
It’s simple model that defines boundaries and interfaces of proposed system with
external world.
It identifies entities outside proposed system that interact with system.
Fig: CD for Student result management system Administrator Subject Information Entry Marks Entry Operator
Student Information Entry Marks entry
Student result
management
system
Student information report generated Student performance report generated
Marksheet generated
Step-2: Development of Prototype(optional)
• Use customer’s feedback to continuously modify prototype until customer is satisfied.
• Parts of system represented by each of these bubbles are then decomposed and documented as more
and more detailed DFDs.
• This process may be repeated at as many levels as necessary until problem at hand is well understood.
Level 1 - overview diagram
• gives overview of full system
• identifies major processes and data flows between them
• identifies data stores that are used by the major processes
• boundary of level 1 is the context diagram
Level 2 - detailed diagram
• level 1 process is expanded into more detail
• each process in level 1 is decomposed to show its constituent
processes
• boundary of level 2 is the level 1 process
Sales Forecast is process of estimating future sales.
Payroll: list of company’s employees and amount of money they are to be paid.
EX:
Data Dictionaries
M:M relationships
• Each student may complete more than 1 subject and more than 1
student may complete each subject.
• Degree=2 as there are 2 entity types(STUDENT and SUBJECT)
Degree of relationships:
1. Unary (DEGREE 1)
2. Binary (DEGREE 2)
3. Ternary (DEGREE 3)
Degree: number of entity types that participate in that relationships.
Higher degree relationships: possible but rarely encountered.
PREVIOUS SLIDE:
Degree=2 as there are 2 entity types(STUDENT and SUBJECT)
Unary Relationship
• Also called recursive relationship
• It’s relationship b/w instances of 1 entity type.
• ex: there is one STUDENT entity type in universities but there may be hundreds of
instances of this entity type in database.
• Is-married-to: 1:1 relationship b/w instances of PERSON entity type
• Means each person is currently married to one other person.
PERSON Is Is
married STUDENT friend
to of
• 1:M: indicate that PROGRAMME may have many students and each
student belongs to 1 programme.
• M:M: shows that STUDENT may register for more than 1 subject and
each subject may have many student registrants.
Is
STUDENT assigned STUDENT-ID 1:1
PROGRAMME STUDENTS
Registers 1:M
Registers- M:M
SUBJECT
STUDENT for
Ternary Relationship
• It’s simultaneous relationship amongst instances of 3 entity types.
• Association of 3 entities: TEACHER, STUDENT, SUBJECT
• There may be 1 or many participants in ternary relationship.
• In given ex. All 3 entries are M:M participants.
TEACHER
E_id
Candidate key and identifier
• Candidate key is attribute or combination of attributes that uniquely
identifies each instance of an entity type.
• Ex: 1 candidate key for EMPLOYEE is E_id.
2nd is combination of E_name and E_address.
If there is more than 1 candidate key,designer must choose 1 of
candidate keys as identifier.
STUDENT
S_id S_contact
Completes SUBJECT
STUDENT
Cardinality of relationships:
• Used to identify relationships b/w entity types.
Mandatory 1 cardinality
Optional 0 or 1 cardinality
Strictly 1
1 or many
O or many
Entity Relationship (ER) model for a college database
SOFTWARE PROTOTYPING
• Prototyping: technique of constructing partial implementation of system so that customers, users or developers
can learn more about a problem or solution to that problem.
• It allows users to explore, give feedback and criticize proposed system before undergoing the cost of full-scale
development.
2 prototyping technologies:
1. Throw-away
2. Evolutionary
In throw-away approach, prototype s/w is constructed in order to learn about problem or it’s solution and is usually
discarded after desired knowledge is gained and final system is built from scratch.
• Built quickly so as to enable user to rapidly interact with requirements determination early.
• As it’s discarded, it need not to be operating, maintainable.
Common steps:
1. Writing preliminary SRS.
2. Implementing prototype based on those requirements.
3. Achieving user experience with prototype
4. Writing real SRS
5. Developing real product.
• In evolutionary approach, prototype is constructed in order to learn about
problem or it’s solution in successive steps.
• Prototype is built with ideas that it will eventually be converted into final system.
• Once prototype has been used and requisite knowledge is gained, prototype is
then adapted to satisfy, now-better understand needs.
• Prototype is then used again, more is learned and prototype is re-adapted.
• This process repeats indefinitely until prototype satisfies all needs and thus
evolve into real system, final product.
• Here prototype emerges as actual system downstream in s/w life cycle.
• As with each iteration in development, functionality is added and then
translated to an efficient implementation.
• Obtain experience using it,then based on that experience go back and redo
requirements, redesign, recode, retest and redeploy.
• After gaining more experience, it’s time to repeat entire process again.
BENEFITS OF DEVELOPING PROTOTYPE EARLY
IN S/W PROCESS
1. MISUNDERSTANDING b/w s/w developers and customers may be identified.
2. Missing user requirements may be detected.
3. Difficult to use or confusing user requirements may be identified and refined.
4. Working system is available quickly
5. Prototype serve as basis for writing specifications of system.
Pitfalls:
1. High expectations for productivity with insufficient effort.
2. Large investment
Requirement documentation
• Important activity after requirement elicitation and analysis.
• Way to represent requirements in consistent format.
• SRS: It’s a specification for particular s/w product that performs cerain
functions in specific environment.
• It serves number of purposes depending on who is writing it.
• SRS could be written by customer of system or by developer of system
• SRS: defines needs and expectations of user.
• SRS: Contract document b/w customer and developer.
• This reduces probability of customer being disappointed with final product.
NATURE OF SRS
• Basic issues that SRS writers shall address are following:
1. Functionality: what s/w is supposed to do?
2. External interface: how does s/w interact with people, system’s h/w, other h/w and
other s/w?
3. Performance: What’s speed,availability,response time,recovery time etc of various
s/w functions?
4. Attributes: What are consideration for portability, correctness, maintainability,
security, reliability etc
5. Design constraints imposed on an implementation:
Are there any standards,implementation language, policies for database
integrity,resource limits?
• SRS
1. Should correctly define all s/w requirements.
2. Should not describe any design or implementation details.
3. Should not impose additional constraints on s/w.
Characteristics of good SRS
• SRS should be:
1. Correct
2. Unambiguous
3. Complete
4. Consistent
5. Ranked for importance and/or stability
6. Verifiable
7. Modifiable
8. Traceable
1. correct: if every requirement stated therein is one that s/w shall meet. There is no tool/procedure
that assures correctness.
2. Unambiguous: if every requirement(each sentence in SRS) stated therein has only 1(unique)
interpretation.
If given to 10 people: single interpretation
Term used in SRS: if have multiple meaning, glossary should tells it’s meaning.
Use natural language to write SRS, it must be reviewed to identify ambiguous use of langage.
6. Verifiable:
Means there exists some cost-effective process to check that the s/w meets requirements.
Else such requirements should be removed.
Ex statement: o/p of program shall be produced within 20 seconds of event.
7. Modifiable: if SRS structure and style are such that any changes to requirements can be made easily, completely
and consistently while retaining its structure and style.
Not include redundant requirements: as leads to errors
8. Traceable: if origin of each of requirements is clear and if it facilitates referencing of each requirement in future
development or enhancement documentation.
2 types of traceability:
1. Backward Traceability: each requirement referencing its source in earlier documents.
2. Forward Traceability: each requirement in SRS have unique name and reference number.
FT is important when s/w product enters operation and maintenance phase.
Specifying behavioral requirements
• Behavioral requirements of the system are described using use case view.
• Behavioral requirements include any and all information necessary to
determine if run-time behavior.
• It define all constraints on system outputs(ex: value,accuracy,timing) and
resulting system state for all possible inputs and current state system.
• Security, safely, performance, timing and fault-tolerance are all behavioral
requirements.
Finite state machine
• Requirement models are used to clarify and improve requirements consistency,
unambiguity, correctness and completeness.
• FSM model is very popular with requirement engineers and developers.
• FSM also known as Finite State Automation (FSA), are models of behaviors of a
system or a complex object, with a limited number of defined conditions or
modes, where mode transitions change with circumstance.
FSM consist of 4 main elements:
• states which define behavior and may produce actions
• state transitions which are movement from one state to another
• rules or conditions which must be met to allow a state transition
• input events which are either externally or internally generated, which may
possibly trigger rules and lead to state transitions
FSM
Traffic Light
States: RED, YELLOW, GREEN (simplest example)
Transitions: After a timer change RED to GREEN, GREEN to
YELLOW, and YELLOW to RED.
light system example
Advantages of FSM
•Their simplicity make it easy for inexperienced developers to implement with little to no extra
knowledge (low entry level).
•Predictability (in deterministic FSM), given a set of inputs and a known current state, the state
transition can be predicted, allowing for easy testing
•Due to their simplicity, FSMs are quick to design, quick to implement and quick in execution
•FSM is an old knowledge representation and system modeling technique, and its been around
for a long time, as such it is well proven.
•FSMs are relatively flexible. There are a number of ways to implement a FSM based system.
•Easy to transfer from a meaningful abstract representation to a coded implementation
•Easy determination of reachability of a state, when represented in an abstract form, it is
immediately obvious whether a state is achievable from another state, and what is required to
achieve the state
Disadvantages of FSM
•Predictable nature of deterministic FSMs can be unwanted in some domains such as computer
games (solution may be non-deterministic FSM).
•Larger systems implemented using a FSM can be difficult to manage and maintain without a
well thought out design.
•Not suited to all problem domains, should only be used when a systems behavior can be
decomposed into separate states with well defined conditions for state transitions. This means
that all states, transitions and conditions need to be known up front and be well defined
IT extra topics: not for CSE
• SRD(structured requirement definition): nothing but requirement
engineering
• structured analysis & design techniques(analysis tools)
• Decision tables and trees
• Code object diagram
• PDL
• structured analysis & design techniques
• Analysts use various tools to understand and describe the information system. One of the
ways is using structured analysis.
• Structured Analysis is a development method that allows the analyst to understand the
system and its activities in a logical way.
• It is a systematic approach, which uses graphical tools that analyze and refine the objectives
of an existing system and develop a new system specification which can be easily
understandable by user.
Structured Analysis Tools
During Structured Analysis, various tools and techniques are used for system development:
1. Data Flow Diagrams
2. Data Dictionary
3. Decision Trees
4. Decision Tables
5. Structured English
6. Pseudocode
• In software engineering, structured analysis (SA) and its allied technique, structured design (SD), are methods for analyzing and
converting business requirements into specifications and ultimately, computer programs, hardware configurations and related manual
procedures.
• Structured analysis and design techniques are fundamental tools of systems analysis.
• Structured analysis consists of interpreting the system concept (or real world situations) into data and control terminology represented
by data flow diagrams, ER diagrams etc..
• Result of structured analysis is a set of related graphical diagrams, process descriptions, and data definitions.
Structured analysis & design techniques:
• Context diagram
• Data flow diagram
• Data dictionary
• ER diagrams
• Structured design (SD) is concerned with development of modules and synthesis of these modules in a so-called "module hierarchy".
• In order to design optimal module structure and interfaces two principles are crucial:
• Cohesion which is "concerned with grouping of functionally related processes into a particular module",and
• Coupling relates to "the flow of information or parameters passed between modules.
Decision Table
• 2D mapping of conditions against actions
• Conditions evaluate to Boolean
• Actions correspond to expected activity
• Each column in the table corresponds to a test case for functional testing
• Cause-effect graph and decision table are relatives
• Map causes as conditions
• Map effects as actions
• each column of the decision table corresponds to a test case for functional testing.
• Draw causes on the LHS
• Draw effects on the RHS
• Draw logical relationship between causes and effects
• as edges in the graph.
Decision table
• It’s a graphical method for explaining the logic of making decision in tabular format.
• It is a set of conditions + set of actions and different combinations of decisions.
• “It is a matrix representation of logic of decisions which specify possible conditions for decision and resulting actions.”
is a good way to deal with combinations of things (e.g. inputs). Also called ’cause-effect’ table.
Three Parts of a Decision Table:
1. Condition stubs: Lists condition relevant to decision
2. Action stubs: Actions that result from a given set of conditions
3. Rules: Specify which actions are to be followed for a given set of conditions.
Indifferent Condition: Condition whose value does not affect which action is taken for two or more rules
Procedure for Creating Decision Tables
• Name the condition and values each
condition can assume
• Name all possible actions that can occur
• List all rules
• Define the actions for each rule
• Simplify the table
• Credit card example:
Let’s take another example. If you are a new customer and you want to open a credit card account then
there are 3 conditions
first you will get a 15% discount on all your purchases today,
second if you are an existing customer and you hold a loyalty card, you get a 10% discount and
third if you have a coupon, you can get 20% off today (but it can’t be used with the ‘new customer’ discount). Discount amounts are added, if applicable.
This is shown in Table 4.8.
105
Example of Decision Tree
Yes
1 Pay base salary
No Yes
2 Pay hourly wage;
Absence report
No
Yes
Legend: 3 Pay hourly wage
1) Salaried?
2) Hours worked < 40?
No
3) Hours worked > 40? Pay hourly wage;
Pay overtime wage
An email management decision tree might begin with a box labeled “Receive new message.” From that, one branch leading off
might lead to “Requires immediate response.”
Class ATM {
// declaration here
public static void main (string args[]) InvalidCard {
try {
thisCard.read(); //may throw Invalid card exception
pin = KeyPaD.READpIN(); attempts = 1;
While (!thisCard.pin.equal(pin) & attempts < 4)
pin = KeyPad.readPin(); attempts += 1;
.
.
. 109
code object diagram
• An object diagram in the Unified Modeling Language (UML), is a diagram that shows a complete or
partial view of the structure of a modeled system at a specific time.
• In the UML, an object diagram focuses on some particular set of objects and attributes and the links
between these instances.
• Object diagrams are derived from class diagrams so object diagrams are dependent upon class
diagrams.
• Object diagrams represent an instance of a class diagram.
• The basic concepts are similar for class diagrams and object diagrams. Object diagrams also represent
the static view of a system but this static view is a snapshot of system at a particular moment.
• Object diagrams are used to render a set of objects and their relationships as an instance.
• Also called Instance diagrams. Like class diagrams, they also show the relationship between objects but
they use real world examples.
• They are used to show how a system will look like at a given time. Because there is data available in the
objects, they are often used to explain complex relationships between objects.
Purpose
• The difference is that a class diagram represents an abstract model
consisting of classes and their relationships. But an object diagram
represents an instance at a particular moment which is concrete in nature.
• Object diagram is more close to actual system behavior. Purpose is to
capture the static view of a system at a particular moment and can be
summarized as:
• Forward and reverse engineering.
• Object relationships of a system
• Static view of an interaction.
• Understand object behavior and their relationship from practical
perspective
Object diagrams : consist of objects.
The link in object diagram is used to connect objects.
Objects and links are the two elements used to construct an object diagram.
The customer is having the following three orders with different numbers (12, 32 and 40) for the particular time considered.
customer can increase number of orders in future and in that scenario the object diagram will reflect that.
If order, special order and normal order objects are observed then you will find that they are having some values.
For orders the values are 12, 32, and 40 which implies that the objects are having these values for the particular moment (here the particular
time when the purchase is made is considered as the moment) when the instance is captured. Same is for special order and normal order objects
which are having number of orders as 20, 30 and 60. If a different time of purchase is considered then these values will change accordingly.
Where to use Object Diagrams?
Object diagrams can be imagined as snapshot of a running system at a particular moment. Now to clarify it we can take an
example of a running train.
Now if you take a snap of the running train then you will find a static picture of it having the following:
A particular state which is running
A particular number of passengers. which will change if the snap is taken in a different time.
So here we can imagine the snap of the running train is an object having the above values. And this is true for any real life
simple or complex system.