17709_Software engg(1).ppt
Transcript of 17709_Software engg(1).ppt
-
8/10/2019 17709_Software engg(1).ppt
1/66
Software myths1. If we get behind schedule, we can just add morepeople
Fact: Adding people to a late project makes it evenlater
Someone has to teach the new people
2. A general statement of objectives is enough tostart programming
Fact: Incomplete requirements are a major cause forproject failures.3. Changes in requirements are easy to deal with
because software is flexible Fact: Changes are hard and expensive Especially during coding and after software
deployment
-
8/10/2019 17709_Software engg(1).ppt
2/66
Software myths4. Once we get the program running, we are done
Fact: Most effort comes after the software isdelivered for the first time.
Bug fixes, feature enhancements, etc.
5. The only product is the running program
Fact: Need the entire configuration Documentation of system requirements, design,
programming, and usage
-
8/10/2019 17709_Software engg(1).ppt
3/66
Software development life cyclemodel
A life cycle model prescribes the differentactivities that need to be carried out to
develop a software product andsequencing of these activities. A software life cycle is a series ofidentifiable stages that a software productundergoes during its lifetime.
-
8/10/2019 17709_Software engg(1).ppt
4/66
Why use a life cycle model?
It encourages development of a software insystematic and disciplined manner.
A single person can decide his own stepsto follow to develop a program.When a team works on a project then eachmember needs to abide by the modelspecified by the organisation.
-
8/10/2019 17709_Software engg(1).ppt
5/66
Phase entry and exit criteria
A good life cycle model should clearlydefine the entry and exit criteria for each
phase.
A phase can start only when thecorresponding phase-entry criteria issatisfied.
-
8/10/2019 17709_Software engg(1).ppt
6/66
Classical Waterfall Model
Feasibility Study
Requirement Analysis
Design
Coding and unit testing
Integration and system Testing
Maintenance
-
8/10/2019 17709_Software engg(1).ppt
7/66
Phases of classical waterfallmodel
Phases between feasibility study andtesting
known as development phases.
Among all life cycle phases maintenancephase consumes maximum effort.
Among development phases, testingphase consumes the maximum effort.
-
8/10/2019 17709_Software engg(1).ppt
8/66
Feasibility StudyMain aim of feasibility study : determine whetherdeveloping the product is
financially worthwhile technically feasible.First roughly understand what the customer wants:
different data which would be input to the system, processing needed on these data,
output data to be produced by the system, various constraints on the behaviour of the
system.
-
8/10/2019 17709_Software engg(1).ppt
9/66
Activities performed in FeasibilityStudy
Work out an overall understanding of theproblem.Formulate different solution strategies.
Examine alternate solution strategies interms of:
resources required,cost of development, anddevelopment time.
-
8/10/2019 17709_Software engg(1).ppt
10/66
Activities performed in FeasibilityStudy
Perform a cost/benefit analysis:to determine which solution is the best.you may determine that none of the
solutions is feasible due to:high cost,resource constraints,
technical reasons.
-
8/10/2019 17709_Software engg(1).ppt
11/66
Requirements Analysis andSpecification
Aim of this phase:
understand the exact requirements of the
customer,document them properly.
Consists of two distinct activities:
requirements gathering and analysis.requirements specification.
-
8/10/2019 17709_Software engg(1).ppt
12/66
Requirement Gathering and Analysis
Goal of Requirement gathering:
Collect all relevant information regardingthe product to be developed from thecustomer.
Clearly understand the customers
requirements.
-
8/10/2019 17709_Software engg(1).ppt
13/66
Requirement Gathering and Analysis (Contd..)
Goal of Requirement analysis:Weed out the inconsistencies andincompleteness in the requirements.
Inconsistent requirement is one wheresome part of requirement contradicts withsome other part.
Incomplete requirement is one where someparts of the requirement may have beenomitted advertently.
-
8/10/2019 17709_Software engg(1).ppt
14/66
Requirements Specification:
Requirements gathered and analyzed areorganized into a Software RequirementsSpecification (SRS) document.
Three most important contents of SRSdocument are:
The functional requirements.
The non-functional requirements.
The goals of implementation.
-
8/10/2019 17709_Software engg(1).ppt
15/66
SRS document:
Written according to end user terminology.
Serves as a contract between the
development team and customer.Future disputes between the two parties aresettled by examining the SRS document.
Also consists of formulation of usermanuals, system test plan, etc.
-
8/10/2019 17709_Software engg(1).ppt
16/66
Design
Design phase transforms requirementsspecification: into a form suitable for implementation in
some programming language.Software architecture is derived from SRSdocument.Two design approaches: traditional approach, object oriented approach.
-
8/10/2019 17709_Software engg(1).ppt
17/66
Traditional Design Approach
Consists of two activities: Structured analysis Structured design
Structure analysis of the requirementspecification is carried out where thedetailed structure of the problem isexamined.During structured design, the results ofstructured analysis are transformed intosoftware design.
-
8/10/2019 17709_Software engg(1).ppt
18/66
Structured Analysis Activity
Identify all the functions to be performed.Identify data flow among the functions.
Decompose each function recursively intosub-functions. Identify data flow among the sub-
functions as well.
-
8/10/2019 17709_Software engg(1).ppt
19/66
Structured Analysis Activity(Contd..)
It restricts itself to what needs to bedone aspects of the problem andneglect how to do it aspect.
functional requirements specified inSRS document are decomposed intosub functions and the data flow among
these sub-functions.
-
8/10/2019 17709_Software engg(1).ppt
20/66
Structured Design
Two main activities: Architectural Design (High level Design) Detailed Design (Low Level Design)
High-level design: decompose the system into modules, represent relationships among the
modules. Sometimes referred to as software
architecture.
-
8/10/2019 17709_Software engg(1).ppt
21/66
Structured Design (Contd..)
Detailed design: different modules designed in greater
detail: data structures and algorithms for each
module are designed.
-
8/10/2019 17709_Software engg(1).ppt
22/66
Object Oriented Design
First identify various objects (real worldentities) occurring in the problem: identify the relationships among the
objects. For example, the objects in a pay-roll
software may be:employees,
managers,pay-roll register,Departments, etc.
-
8/10/2019 17709_Software engg(1).ppt
23/66
Object Oriented Design(Contd..)
Object structure further refined to obtain the detailed
design.OOD has several advantages: lower development effort, lower development time, better maintainability.
-
8/10/2019 17709_Software engg(1).ppt
24/66
Coding and Unit testing
Also called as implementation phase.Each component of design isimplemented as a program module.End product is set of modules thathave been individually tested.
-
8/10/2019 17709_Software engg(1).ppt
25/66
Coding and Unit testing (Contd..)
During the implementation phase: each module of the design is coded, each module is unit tested
tested independently as a stand aloneunit, and debugged,
each module is documented.The purpose of unit testing: test if individual modules work correctly.The end product of implementation phase: a set of program modules that have been
tested individually.
-
8/10/2019 17709_Software engg(1).ppt
26/66
Integration and SystemTesting
Different modules are integrated in aplanned manner:
modules are almost never integrated inone shot. Normally integration is carried out through
a number of steps.During each integration step, the partially integrated system is tested.
-
8/10/2019 17709_Software engg(1).ppt
27/66
System Testing
After all the modules have beensuccessfully integrated and tested:
system testing is carried out.Goal of system testing: ensure that the developed system
functions according to its requirements asspecified in the SRS document.
-
8/10/2019 17709_Software engg(1).ppt
28/66
Maintenance
Maintenance of any software product: requires much more effort than the effort
to develop the product itself.development effort to maintenance effort istypically 40:60.
-
8/10/2019 17709_Software engg(1).ppt
29/66
Maintenance (Contd..)
Corrective maintenance: Correct errors which were not discovered
during the product development phases.
Perfective maintenance: Improve implementation of the system enhance functionalities of the system.
Adaptive maintenance: Port software to a new environment,
e.g. to a new computer or to a newoperating system
-
8/10/2019 17709_Software engg(1).ppt
30/66
Shortcomings of ClassicalWaterfall Model
Classical waterfall model considers transitionbetween two phases to be similar to a waterfall.However, developers do commit a large no. oferrors and thus they have to backtrack to some
previous stages to rectify that error, which isnot the case with this model.
All requirements are defined correctly at thebeginning of the project. The customershowever keep on changing the requirements.This model assumes that all phases aresequential. In practical environment phasesoverlap.
-
8/10/2019 17709_Software engg(1).ppt
31/66
Iterative Waterfall Model
Classical waterfall model is idealistic: assumes that no defect is introduced
during any development activity.
in practice: defects do get introduced in almost every
phase of the life cycle.Defects usually get detected much later inthe life cycle: For example, a design defect might go
unnoticed till the coding or testing phase.
-
8/10/2019 17709_Software engg(1).ppt
32/66
Iterative Waterfall Model(Contd..)
Once a defect is detected: we need to go back to the phase where it
was introduced
redo some of the work done during thatand all subsequent phases.
Therefore we need feedback paths in
the classical waterfall model.
-
8/10/2019 17709_Software engg(1).ppt
33/66
Iterative Waterfall Model(Contd..)
Feasibility Study
Req. Analysis
Design
Coding
Testing
Maintenance
-
8/10/2019 17709_Software engg(1).ppt
34/66
Iterative Waterfall Model(Contd..)
Errors should be detected in the same phase in which they are
introduced.
For example: if a design problem is detected in the
design phase itself,
the problem can be taken care of muchmore easily than, if it is identified at theend of the integration and system testingphase.
-
8/10/2019 17709_Software engg(1).ppt
35/66
Phase containment of errors
The principle of detecting errors as close toits point of introduction as possible:
is known as phase containment of errors.Iterative waterfall model is most widely usedmodel.
Almost every other model is derived fromthe waterfall model.
-
8/10/2019 17709_Software engg(1).ppt
36/66
PROTOTYPING MODEL
Before starting actual development, a working prototype of the system should
first be built.
A prototype is a toy implementation of asystem: limited functional capabilities, low reliability, inefficient performance.
-
8/10/2019 17709_Software engg(1).ppt
37/66
Reasons for developing a prototype
Fail early and inexpensively
Gather more accurate requirements
Technically understand the problemResolve conflicts
Rally financial support
File patents more easily
-
8/10/2019 17709_Software engg(1).ppt
38/66
Reasons for developing aprototype
Illustrate to the customer: input data formats, messages, reports, or
interactive dialogs.Examine technical issues associated withproduct development: Often major design decisions depend on
issues like:response time of a hardware controller,efficiency of a sorting algorithm, etc.
-
8/10/2019 17709_Software engg(1).ppt
39/66
Reasons for developing a prototype(Contd..)
The third reason for developing a prototypeis:
it is impossible to ``get it right'' the firsttime,
we must plan to throw away the firstproduct if we want to develop a goodproduct.
-
8/10/2019 17709_Software engg(1).ppt
40/66
Prototype Model (Contd..)
Start with approximate requirements.Carry out a quick design.Prototype model is built using several
short-cuts: Short-cuts might involve using inefficient,
inaccurate, or dummy functions. A function may use a table look-uprather than performing the actualcomputations.
-
8/10/2019 17709_Software engg(1).ppt
41/66
Prototype Model (Contd..)
The developed prototype is submitted to thecustomer for his evaluation:
Based on the user feedback,requirements are refined. This cycle continues until the user
approves the prototype.The actual system is developed using theclassical waterfall approach.
Requirements
PR
-
8/10/2019 17709_Software engg(1).ppt
42/66
RequirementsGathering
Quick Design
Build Prototype
Customer Evaluationof Prototype
Refine RequirementsIncorporating
ustomer Suggestions
Maintain
Test
Implement
Design
ROTOTY
PE DEVELOPMENT
ID
Acceptance By Customer
ITERATIVE DEVELOPMENT
-
8/10/2019 17709_Software engg(1).ppt
43/66
Prototype Model (Contd..)
Requirements analysis and specificationphase becomes redundant: final working prototype (with all user
feedbacks incorporated) serves as ananimated requirements specification.
Design and code for the prototype is usuallythrown away: However, the experience gathered from
developing the prototype helps a greatdeal while developing the actual product
-
8/10/2019 17709_Software engg(1).ppt
44/66
Prototype Model (Contd..)
Even though construction of a workingprototype model involves additional cost ---overall development cost might be lowerfor: systems with unclear user requirements, systems with unresolved technical issues.Many user requirements get properly
defined and technical issues get resolved: these would have appeared later as
change requests and resulted in incurringmassive redesign costs.
-
8/10/2019 17709_Software engg(1).ppt
45/66
Evolutionary Model
Evolutionary model (aka successiveversions or incremental model): The system is broken down into several
modules which can be incrementallyimplemented and delivered.
First develop the core modules of thesystem.
The initial product skeleton is refined intoincreasing levels of capability: by adding new functionalities in
successive versions.
-
8/10/2019 17709_Software engg(1).ppt
46/66
Evolutionary Model (Contd..)
It is sometimes referred as design a little,test a little, deploy a little model.Successive version of the product: functioning systems capable of
performing some useful work. A new release may include new
functionality:also existing functionality in thecurrent release might have beenenhanced.
-
8/10/2019 17709_Software engg(1).ppt
47/66
Evolutionary Models Life Cycle Activities
AB
C
Evolutionary development of a software product
-
8/10/2019 17709_Software engg(1).ppt
48/66
Evolutionary Models Life Cycle Activities
In the evolutionary model, The s/w requirement is first broken down
into several modules, that can be
incrementally constructed and delivered. Development of core modules first. Non-core modules need the services from
core modules. This initial product skeleton is refined into
increasing levels of capability by addingnew functionalities in new versions.
-
8/10/2019 17709_Software engg(1).ppt
49/66
Evolutionary Models Life Cycle Activities
Each evolutionary version may bedeveloped using an iterative waterfallmodel of development.
Each successive version of theproduct is a fully functioning softwarecapable of performing more work than
previous one.
Rough Requirements Specification
-
8/10/2019 17709_Software engg(1).ppt
50/66
Rough Requirements Specification
Identify the core and other parts tobe developed incrementally
Develop the core part using theIterative waterfall model
Collect customer feedback andmodify requirements
Develop the next identified featuresUsing an iterative waterfall model
Maintenance
All Features Complete
Evolutionary Model of Software Development
-
8/10/2019 17709_Software engg(1).ppt
51/66
Advantages of EvolutionaryModel
Users get a chance to experiment with apartially developed system: much before the full working version is
released,Helps finding exact user requirements: much before fully working system is
developed.Core modules get tested thoroughly: reduces chances of errors in final
product.
-
8/10/2019 17709_Software engg(1).ppt
52/66
Disadvantages of EvolutionaryModel
Often, difficult to subdivide problems intofunctional units:
which can be incrementally implementedand delivered.evolutionary model is useful for very largeproblems,
where it is easier to find modules forincremental implementation.
-
8/10/2019 17709_Software engg(1).ppt
53/66
Evolutionary Model with Iteration
Many organizations use a combination ofiterative and incremental development:
a new release may include newfunctionality
existing functionality from the currentrelease may also have been modified.
l i d l i h
-
8/10/2019 17709_Software engg(1).ppt
54/66
Evolutionary Model withIteration
Several advantages:
Training can start on an earlier releasecustomer feedback taken into account
Markets can be created:for functionality that has never beenoffered.
Frequent releases allow developers to fixunanticipated problems quickly.
-
8/10/2019 17709_Software engg(1).ppt
55/66
Spiral Model
Proposed by Boehm in 1988.Each loop of the spiral represents a phaseof the software process:
the innermost loop might be concernedwith system feasibility, the next loop with system requirements
definition, the next one with system design, and so
on.There are no fixed phases in this model, the
phases shown in the figure are just
-
8/10/2019 17709_Software engg(1).ppt
56/66
Spiral model (Contd..)
The team must decide: how to structure the project into phases.Start work using some generic model:
add extra phasesfor specific projects or when problemsare identified during a project.
Each loop in the spiral is split into foursectors (quadrants).
-
8/10/2019 17709_Software engg(1).ppt
57/66
DetermineObjectives
and identifyalternativesolutions
Identify &Resolve Risks
Review andplan for thenext phase
Develop NextLevel of Product
Spiral model of software development
-
8/10/2019 17709_Software engg(1).ppt
58/66
Determineobjectives,alternative,constraints
Evaluatealternatives, identifyandresolverisks
Developverify nextlevel product
Plan nextphases
Quadrant 1: Determine
-
8/10/2019 17709_Software engg(1).ppt
59/66
Quadrant 1: Determineobjectives, alternatives, and
constraints:Objectives : performance,hardware/software interface ,functionality, etc.
Alternatives : design, reuse, buy, etc.
constraints : imposed on technology,cost, schedule, support, and risk.
Once the systems objectives,alternatives, and constraints areunderstood, Quadrant 2 (Evaluatealternatives, identify, and resolve risks)is performed
Quadrant 2: Evaluate
-
8/10/2019 17709_Software engg(1).ppt
60/66
For each identified project risk, a detailed analysis is carried out.
Steps are taken to reduce the risk.For example, if there is a risk that therequirements are inappropriate: a prototype system may be developed.
Quadrant 2: Evaluatealternatives, identify, resolve
risks:
-
8/10/2019 17709_Software engg(1).ppt
61/66
Quadrant 3 and Quadrant 4
Development and Validation (Thirdquadrant): develop and validate the next level of the
product.Review and Planning (Fourth quadrant): review the results achieved so far with
the customer and plan the next iterationaround the spiral.
With each iteration around the spiral: progressively more complete version of
the software gets built.
-
8/10/2019 17709_Software engg(1).ppt
62/66
Summary of Spiral steps:
Each successive phase in the project as a newspiral includes a four steps or phases.Software requirements in the design aregradually developed through a series ofprototypes.
The exact number of spirals necessary for theproject is flexible and depends on the number ofprototypes needed to reach a satisfactory design.Since each phase requires a certain level ofcommitment a cumulative cost of the projectrepresented by the width of the spiralOnce a satisfactory design is reached thesoftware is constructed according the final threeprocess of the waterfall model (Programming Integration-Delivery)
-
8/10/2019 17709_Software engg(1).ppt
63/66
Spiral Model as a meta model
Subsumes all discussed models: Uses waterfall model phases. uses an evolutionary approach --
iterations through the spiral are evolutionarylevels. enables understanding and reacting to
risks during each iteration along the
spiral. uses:
prototyping as a risk reduction mechanismretains the step-wise approach of the waterfallmodel.
-
8/10/2019 17709_Software engg(1).ppt
64/66
Strengths Introduces risk management
Prototyping controls costs Evolutionary development Release builds for beta testing Marketing advantage
Weaknesses Lack of risk management experience
Lack of milestones Management is dubious of spiral process Change in Management Prototype Vs Production
C i f Diff t Lif
-
8/10/2019 17709_Software engg(1).ppt
65/66
Comparison of Different LifeCycle Models
Iterative waterfall model most widely used model. But, suitable only for well-understood
problems .Prototype model is suitable forprojects not well understood:
user requirements technical aspects
Comparison of Different Life
-
8/10/2019 17709_Software engg(1).ppt
66/66
Comparison of Different LifeCycle Models (Contd..)
Evolutionary model is suitable forlarge problems: can be decomposed into a set of modules
that can be incrementally implemented, incremental delivery of the system is
acceptable to the customer.The spiral model:
suitable for development of technicallychallenging software products that aresubject to several kinds of risks.