Digital Notes: (Department of Computer Applications)

Download as pdf or txt
Download as pdf or txt
You are on page 1of 21

MAHARANA PRATAP GROUP OF INSTITUTIONS

KOTHI MANDHANA, KANPUR


(Approved by AICTE, New Delhi and Affiliated to Dr. AKTU, Lucknow)

Digital Notes
[Department of Computer Applications]
Subject Name : Software Engineering
Subject Code : KCA-203
Course : MCA
Branch : MCA
Semester : III
Prepared by : Mr. Yogendra Singh

Reference No./MCA/Yogendra Singh/KCA-302/3/2


UNIT-1: Introduction to Software Engineering

The term software engineering is composed of two words, software and engineering.

Definition of Software:
Software is a set of instructions that provide desired functionality when executed.
Software = programs + documentation + operating procedures.

There are three components of the software as shown in fig:

Figure: Components of software

Types of Software:
Computer software is mainly divided into two types.
1. System software:
System software includes the operating system & all the utilities to enable the computer
to run.
Example: window operating system, Linux etc.

2. Application software:
Application software consists of programs to perform user oriented tasks.
Example: MS Office, paint etc.
Why Study Software Engineering?
 To acquire skills to develop large programs
 Learn systematic techniques of:
-Specification, design, user interface development, testing, project management,
maintenance, etc.
 To acquire skills to be a better programmer:
i. Higher Productivity
ii. Better Quality Programs
 Ensure high quality of software.

Engineering is the process of using knowledge and principles to design, build and analyze
objects.

Definition of Software Engineering:

 Software engineering is a systematic, disciplined, cost-effective techniques for software


development.
or
 Software engineering is the systematic application of engineering approaches to the
development of software.
or
 According to IEEE Definition:

“Software engineering is the application of systematic, discipline and quantifiable


manner or approach to the development, operations, and maintenance of software; that is,
application of engineering to software”.
Characteristics of Software
The main characteristics of software are:

Fig: Bathtub curve for hardware Fig: Bathtub curve for software

1. Software does not “wear out”.


 Above figure is called as bathtub curve’ which indicates that the hardware have
high failure rate early in its life .then defects are corrected and failure rate drops to
steady level for some period of time.

As time passes, the failure rate rises again because of environmental melodies like
excess use, dust. Vibrations etc. and finally hardware begins to wear out. But the
software does not wear out like hardware.
2. Software is developed or engineered:
 The software is developed not manufactured.
 In both software development and hardware manufacturing the focus is on quality.
 Software projects cannot manage like hardware manufacturing projects.

3. Software gives components based construction, and gives Reusability of components:


We can use software programming to any other software.

4. Software is flexible: we can change any software.


Software Crisis:
 The term software crisis refers to a set of problems encountered in the development of
computer software during1960’s.
 Software crisis term was used in the late1960s when many companies failed to develop
software projects.

Reasons of Software Crisis:-


There was many reasons of software crisis include:
 Projects running over-budget.
 Projects running over-time.
 Software was very inefficient.
 Software was of low quality.
 Software often did not meet requirements.
 Software quality is usually unreliable.
 Projects were unmanageable and code difficult to maintain. (difficult to modify, add new -
function, reuse)

Solution of Software Crisis:


The main problem creating the software crisis is an unorganized way of work. So software
engineering is only way that helps the software company to work in an organized manner
systematically and disciplined way.

Actually learn programming only does not means you will develop a good quality software. You
should also understand the software engineer concept and practice it, which helps to create a
professional and disciplined environment.

Examples of Software Crisis:


Y2K problem/ Year 2000 Problem/ Milennium Bug
 The Y2K problem was the most crucial problem of last century. It was simply the ignorance about
the adequacy or otherwise of using only last two digits of the year. The 4-digit date format, like
1964, was shortened to 2-digit format, like 64. The developers could not visualize the problem of
year 2000. Millions of rupees have been spent to handle this practically non-existent problem.
 “One little bug, one big crash” of Ariane-5 space rocket, developed at a cost of $7000 M over a
10 year period.

Differences between Conventional Engineering and Software Engineering Process


Conventional Engineering Software Engineering

1. It is also knows traditional 1. It is also known as software development


engineering. analysis.
2. Conventional engineering concern 2. Software engineering concern with cost of
with cost of production and reliability development and reliability by the no. of
by time to failure. errors per thousand lines of source code.
3. Conventional engineering construct 3. Software engineering constructs not real
real artifacts.. artifacts.
4. In Conventional engineering there 4. In software engineering we use SDLC
were no SDLC models. models.
5. In this engineering, engineers 5. In this engineering often apply new and
generally try to apply known and untested elements in software projects.
tested principal and unit. 6. Software engineering process is mainly
6. Conventional engineering building related with computer programming codes.
cars, machine and hardware.

Software Process (Software Engineering Process):

“Software process is defined as a collection of activities to develop software product according


to goals or customer requirements.”

Phases of Software Process


It involves the following phases:

1. Software specifications: The functionality of the software and constraints on its


operation must be defined.
2. Software development where the software is designed and programmed.
3. Software validation: The software must be validated to ensure that it does what the
customer wants.
4. Software evolution: The software must evolve to meet changing client needs.

SDLC (Software Development Life Cycle)

 Software Development Life Cycle (SDLC) a process used by the software industry to
design, develop and test high quality software

 The purpose of SDLC is to produce high quality software that meets customer
expectations, reaches completion within time and cost estimates.

Phases of SDLC:-
There are following phases in the SDLC model:
1. Feasibility Study
2. Requirement analysis and specifications
3. System Design
4. Coding / Implementation / Development Phase
5. Testing
6. Maintenance

Let us see the process briefly-

1. Feasibility Study:
The main aim of feasibility study is to determine whether developing the software is:
i. Financially worthwhile
ii. Technically feasible.

2. Requirement Analysis and Specifications:


i. The aim of the requirements analysis and specification phase is to understand the exact
requirements of the customer and to document them properly.

ii. This phase consists of two distinct activities, namely


1. Requirements gathering and analysis,
2. Requirements specification
3. System Design
 The goal of the design phase is to transform the requirements specified in the SRS
document into a structure that is suitable for implementation in some programming
language.
 In technical terms, during the design phase the software architecture is derived from the
SRS document.
 Two commonly used design approaches:
1. Traditional design approach,
2. object-oriented design approach

4. Implementation Phase:
 The purpose of the coding and unit testing phase (sometimes called the implementation
phase) of software development is to translate the software design into source code. Each
component of the design is implemented as a program module. The end-product of this
phase is a set of program modules that have been individually tested.

 During this phase, each module is unit tested to determine the correct working of all the
individual modules. It involves testing each module in isolation as this is the most
efficient way to debug the errors identified at this stage.

5. Integration and System Testing


Integration of different modules is undertaken once they have been coded and unit tested. During
the integration and system testing phase, the modules are integrated in a planned manner. The
different modules making up a software product are almost never integrated in one shot.
Integration is normally carried out incrementally over a number of steps. During each integration
step, the partially integrated system is tested and a set of previously planned modules are added
to it. Finally, when all the modules have been successfully integrated and tested, system testing is
carried out.

The goal of system testing is to ensure that the developed system conforms to its requirements
laid out in the SRS document.

6. Maintenance: Maintenance after deployment is conducted


Types of SDLC Models:-
There are various software development life cycle models defined:

1. Classical Waterfall Model


2. Iterative Waterfall Model
3. Prototype Model
4. Spiral Model
5. Evolutionary Development Models
6. Iterative Enhancement Model.

Waterfall Model:
The waterfall life cycle model was originally proposed by Winston Royce in 1970. This is an
engineering model designed to apply to the development of software.

There are two variations of waterfall model:

1. Classical Waterfall Model


2. Iterative Waterfall Model

1. Classical Waterfall Model:


 The waterfall model is a sequential software development process, in which progress is
seen as flowing steadily downwards (like a waterfall) through the phases of Conception,
Initiation, analysis, design, Construction, testing and maintenance.

 In the classical waterfall model development process, the various phases of development
are completed sequentially, one after the other.
 It is linear model because after completion of one phase, it enters into next phase.
 The output of one phase is given as input for next phase so if output is wrong it effects
next phase.
The classical waterfall model divides the life cycle into the following phases as shown in fig.:

Phases of the classical waterfall model


1. Feasibility Study:
The main focus of the feasibility study stage is to determine whether it would be financially and
technically feasible to develop the software.

2. Requirement Analysis and Specifications:


i. The aim of the requirements analysis and specification phase is to understand the exact
requirements of the customer and to document them properly.

ii. This phase consists of two distinct activities, namely


1. Requirements gathering and analysis, and
2. Requirements specification
3. System Design
 The goal of the design phase is to transform the requirements specified in the SRS
document into a structure that is suitable for implementation in some programming
language.
 In technical terms, during the design phase the software architecture is derived from the
SRS document. Two distinctly different approaches are available:
1. Traditional design approach,
2. Object-oriented design approach
4. Coding and unit testing:
The purpose of the coding and unit testing phase is to translate the software design into source
code, and to ensure that individually each function is working correctly. The coding phase is also
sometimes called the implementation phase.

Each component of the design is implemented as a program module. The end-product of this
phase is a set of program modules that have been individually tested.

During this phase, each module is unit tested to determine the correct working of all the
individual modules. It involves testing each module in isolation as this is the most efficient way
to debug the errors identified at this stage.

5. Integration and System Testing


Integration testing is carried out to verify that the interfaces among different units are working
satisfactorily. On the other hand, the goal of system testing is to ensure that the developed system
conforms to the requirements that have been laid out in the SRS document.

6. Maintenance: Maintenance after deployment is conducted


Maintenance is required in the following three types of situations:
i. Corrective maintenance
ii. Perfective maintenance
iii. Adaptive maintenance

The situation when it is applicable:


 The projects which follows sequential flow for such projects this model can apply.
 Projects which not focus on changing requirements
 Requirements are very well known.
 Technology is understood.
Shortcomings of the classical waterfall model
i. No feedback paths
ii. No overlapping of phases
iii. Inefficient error corrections

Advantages of Waterfall Model:


 This model is simple & easy to understand & use.
 Waterfall model works well for small projects where requirements are very well
understood.
 Phases are processed & completed one at a time.
 Phases do not overlap.
 Easy to manage

Disadvantages of Waterfall Model:


 If requirements may change the waterfall model may not work.
 Not a good model for complex projects.
 A working model is not available until late in the project time plan
 High amount of risk.
 Not handle large project.

2. Iterative Waterfall Model:


The main change brought about by the iterative waterfall model to the classical waterfall model
is in the form of providing feedback paths from every phase to its preceding phases.

The feedback paths allow for correcting errors committed by a Programmer during some phase,
as and when these are detected in a later phase

The feedback paths introduced by the iterative waterfall model are shown in Figure
Figure: Iterative Waterfall Model
Shortcomings of the iterative waterfall model
i. Phase overlap not supported
ii. Incremental delivery not supported
iii. Limited customer interactions
iv. No support for risk handling and code reuse

3. Prototyping Model:
This model suggests building a working prototype of the system, before development of the
actual software.
A prototype is a toy implementation of the system. A prototype usually exhibits limited
functional capabilities, low reliability, and inefficient performance compared to the actual
software.
 First develop a working prototype of the software instead of the actual software.
 Prototype gives idea about the software system; it does not perform all functions of
the final system.
 Because of prototype the customer can get a actual feel of software. So he can easily
understand the requirements.
 After this, the software is handed over to the customer and check the prototype and
then suggest what changes need in the software.
 This Prototype is used when customer is unclear about the detailed information of the
input process & output needs of the software.

Examples: A prototype of the actual product is preferred in situations such as:


• User requirements are not complete
• Technical issues are not clear

Following is the stepwise approach to design a software prototype:

Figure: Prototyping model

1. Requirement Identification:
-Prototyping begins with the requirements gathering.
2. Quick Design:-
 It focuses on those aspects of software that will visible to user.
 Analyst estimates prototype cost &give idea to the management.
3. Developing the Initial Prototype:
 The design of prototype is developed.
 Prototype represents the input screen format & output screen format.
4. Customer Evaluation of Prototype:
 The prototype is evaluated by the user and is used to refine the requirements for the
software to be developed.
 User or customer works on prototype to evaluate its features & operations.
5. Revise And Enhance The Prototype:
 The prototype is refined after getting information from user about what they want and
what they do not want.
 Developer should understand the need of customer properly for making modifications in
the prototype.
Advantages of Prototype Model:

The advantages of prototype model are:-

 Users are actively involved in the development.


 More accurate user requirements are obtained.
 Errors can be detected much earlier
 Missing functionality can be identifies easily.
 High user satisfaction.
 Requirements clarification.
 If customer not satisfied with prototype than we can develop a new prototype
 Prototype model is useful when requirements changing rapidly.

Disadvantages of Prototype Model:


 If user is not satisfied by the developed prototype, then new prototype is developed.
 This process goes until a perfect prototype is developed. Thus, this model is time
consuming and expensive.
 It is impossible to know how long it will take.
 There is no way to know the number of iteration will be requirement.
 It will take more time as compare to waterfall model.

When To Use Prototype Model?


A prototype of the actual software is preferred in situations such as:

 User requirements are not complete.


 Complicated and large system.
 Technical issues are not clear.
 Prototype is used when customer is unclear about the details of the input process &
output needs of the software.
 It can also be used if requirement are changing quickly.

4. Spiral Model:
 The Spiral model was developed by Boehm in 1986.
 Spiral model can handle large amount of risk.
 The spiral model is emphasis placed on risk analysis.
 The diagrammatic representation of this model appears like a spiral with many loops.
 The exact number of loops in the spiral is not fixed. Each loop of the spiral represents a
phase of the software process.
Each phase in this model is split into four quadrants as shown in fig.
Fig: Spiral Model

The following activities are carried out during each phase of a spiral model.
Phases of the Spiral Model
Each phase in spiral model is split into four quadrants as shown in Figure

1. First quadrant (Objective Setting)

 During the first quadrant, it is needed to identify the objectives of the phase.
 Examine the risks associated with these objectives.

2. Second Quadrant (Risk Assessment and Reduction)


 A detailed analysis is carried out for each identified project risk.
 Steps are taken to reduce the risks. For example, if there is a risk that the requirements
are inappropriate, a prototype system may be developed.

3. Third Quadrant (Development and Validation)


Develop and validate the next level of the product after resolving the identified risks.
4. Fourth Quadrant (Review and Planning)
 Review the results achieved so far with the customer and plan the next iteration around
the spiral.
 The customer evaluates the work product and makes suggestions & modifications.

When To Use Spiral Model:


The spiral model is useful in following situations:

 When the project is large.


 Where the amount of risk is large.
 When use requirements kept changing.
 For high risk projects.
 If requirements are more complicated for large project.

Advantages of Spiral Model:


 Best model for analyze risk handling.
 It uses prototyping for risk reduction.
 Development is fast.
 Risk evaluation is proper.
 More features are added in a systematic way.
 Good for large projects
 Customer satisfaction.

Disadvantages of Spiral Model:-


 It is costly for smallest project.
 Spiral model may go infinity

5. Evolutionary Development Models:


Evolutionary model is a combination of iterative and incremental model of software
development life cycle.
Incremental model first implement a few basic features and deliver to the customer. Then build
the next part and deliver it again and repeat this step until the desired system is fully realized. No
long-term plans are made.

Iterative model main advantage is its feedback process in every phase .

Figure: Evolutionary model

Applicability of the evolutionary model


The evolutionary model is well-suited to use in object-oriented software development projects.

Advantages
The evolutionary model of development has several advantages.

 Effective elicitation of actual customer requirements


 Easy handling change requests

6. Iterative Enhancement Model:


 This model is having same phases as waterfall model.
 Phases occur in same order as in the waterfall model but several cycles.
 A usable product is released at the end of each cycle.
 Major requirement are specified by the customer at beginning & SRS will present.
 Complete software is divided into releases.
 The first release may be available within few weeks or months.
 In last release deliver complete software.

Figure: Iterative Enhancement Model

Advantages of Enhancement Model:-

 This model is flexible.


 Generate working s/w quickly.
 Lower the initial deliver.

Disadvantages of Enhancement Model:-

 Need good planning and design.


 Total cost is higher than waterfall.

When to use iterative model:

1. Requirements of the complete system are clearly defined and understood.


2. When the projects is big.
3. Major requirements must be defined; however, some details can evolve with time.

You might also like