higher grade computing studies 1. software development cycle higher computing software development...

38
1 Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan Introduction • The development of a piece of software from scratch is a process that takes considerable time. We can classify these stages thus : Analysing the problem: Can we do it? Designing the program: How do we do it? . Implementing the design: Writing the program . Testing the design: Making sure it works ocumenting the design: User guides, Technica valuating the design: Limitations and impro aintaining the software: Correcting, adapting perfecting

Upload: clinton-anthony

Post on 25-Dec-2015

216 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

1

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Introduction

• The development of a piece of software from scratch is a process that takes considerable time. We can classify these stages thus :

1. Analysing the problem: Can we do it?2. Designing the program: How do we do it?3. Implementing the design: Writing the program4. Testing the design: Making sure it works5. Documenting the design: User guides, Technical manuals6. Evaluating the design: Limitations and improvements 7. Maintaining the software: Correcting, adapting and

perfecting

Page 2: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

2

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Iterative

• The cycle is iterative. Iteration means to follow through a process more than once before concluding it. An iterative process is one that incorporates feedback and involves an element of repetition.

• The implementation stage can be iterative because testing may show that the program doesn’t run properly, so the programmer will have to revisit the design and implementation stages.

Page 3: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

3

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Personnel

• The clients are the persons who require the new system. They are the ones who need the new software developed.

• The project manager is the leader of the software house. This person takes sole responsible for the whole project and must supervise all steps and stages required. S/he will liaise with the systems analyst and keep the whole project on track. S/he will also ensure that programmers meet deadlines and have the resources they need, will deliver any reports on time and be kept fully aware of test results.

Page 4: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

4

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Personnel

• The Systems Analyst works for a software house and agrees with the client the exact nature and specification of the software to be written.

• The programmer is responsible, either individually or as part of a team, for turning the design into programming code.

• The Independent Test Group (ITG) carries out the testing of the software. They will test each individual part of the program, larger sections of the program and finally the finished product.

Page 5: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

5

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Analysis

Key Task: To define the extent of the software task to be carried out.Personnel: Client and Systems AnalystDocumentation: The legally binding Software Specification Report

Page 6: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

6

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Analysis

• Analysis is the most important part of the process. Changes can be identified early on thus reducing the amount of extra work and cost involved in trying to make changes later.

• Analysis is a fact finding process aimed at answering the following questions :

• WHO?

• WHAT?

• WHERE?

• WHEN?

• WHY?

Page 7: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

7

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Analysis

• Analysis starts with discussions between the client and a systems analyst. The analyst will carry out three main tasks.

• observe the system currently in use.

• clarify the system currently in use.

• model the system currently in use.

Page 8: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

8

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Analysis

• The particular skills that an analyst needs to have would be:

• to be able to extract the needs of the client who may not be technically skilled.• to be able to document these needs in some formal way.• to be able to communicate these needs to the people who will actually design the computerised system.

Page 9: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

9

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Analysis - Extracting Needs

• This can be called requirements elicitation and can take some time. Difficulties may arise due to either the client’s lack of awareness of the capabilities of the computerised system or the analyst’s lack of knowledge of the client’s business operations.

• The analyst will proceed through:• a series of interviews with the client’s management team,• make observation notes of what actually happens in the workplace,• use questionnaires and literature, e.g. manuals, to determine how the existing system operates.

Page 10: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

10

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Analysis - Documentation

• These discussions will lead to a legally binding requirements specification. This is a detailed document which indicates what the client wants the design team to do and will include a system specification.

Page 11: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

11

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Design

Key Task: To design a method of solving the stated problem.Personnel: Systems Analyst and Project managerDocumentation: A description of how the problem will be solved. This algorithm may be text based (pseudocode) or graphical (structured diagram)

Page 12: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

12

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Design

• Design involves planning the solution to the problem. This would not take place until the specification document had been agreed between the client and the programmer. As with analysis, it is crucial to detect errors at this stage rather than later.• Design can be broken down into :

1. Design of the structure

2. Design of the detailed logic

Page 13: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

13

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Design Methodology - Modular

• A large computer program can be organised into smaller parts called modules, which can be developed at the same time by different programmers and programming teams.

• Modules can be designed, programmed and maintained independently of one another.

• Ideally each module should:

• be small • do one task only

• be self contained so it can be saved and used in other programs.

Page 14: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

14

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Design Methodology - Modular

• There are several design techniques. The one we use is called Top Down Design. In this method, the problem is broken down into smaller sub problems that are then divided in turn into even smaller ones. • This continues until the sub problems are manageable enough to be coded - step wise refinement.

Page 15: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

15

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Design Notations

• The design stage results in a detailed algorithm - a sequence of operations needed to solve the problem. There are several design notations, or methods of representing an algorithm, including:

• pseudocode text is in English but easily converted into language code. Its advantage is it will be close to the final coded program.

• structure chart a diagram showing the component sub problems and how they are linked. It can show the structure of the whole program in a small space.

Page 16: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

16

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Design - Pseudocode

1. Display information

2. Get details

3. Do calculation

4. Display answer

Refine step 2

2.1 display prompt

2.2 get value

2.3 while value out of range

2.4 display error message

2.5 get value

2.6 loop

Notice the numbering system

Top level design

Page 17: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

17

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Design - Structure Chart

Data Flow

In/out In

Page 18: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

18

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Implementation

Key Task: To write code in a chosen programming language.Personnel: Programmer and Project managerDocumentation: A structured listing of the programming code showing formatting features such as commands in bold, indentation, etc.

Page 19: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

19

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Implementation - Language Choice

• For most problems, however, a suitable high level language may be required. Some high level languages have special applications and are suited to certain problem types - for example, Prolog for Artificial Intelligence.

• Others are more general and can be used to solve a wide range of problems - for example, Comal can be used to solve a wide range of programming tasks.

Page 20: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

20

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Structured Listing

• A structured listing is a program printed on paper that uses indentation (formatting) to show the structure of the program.

• A structured listing can also highlight keywords and variable names in a different text colour.

• Advantages

• Easy to understand the structure of the whole program.

• Mistakes are easier to spot.

Page 21: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

21

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Structured Listing

• A structured listing should be readable.

Readable : Easily understood by others e.g. use of meaningful variables, constants, procedure and function names, Suitable internal comments. Good layout with spaces between sections. Description of parameters. Parameter lists are kept short.

Page 22: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

22

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Testing

Key Task: To test that the program meets the specification.Personnel: Independent Test Group (ITG)Documentation: Set of test data and test reports. The test data will have predicted (before running) and actual (after running) output.

Page 23: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

23

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Testing

• Many organisations now employ Independent Test Groups who return the program to the programmers for correction after testing.

• The program is now tested using many sets of test data to check that it gives the correct output under all possible conditions. It is important that the expected results from the test should be known before the test is carried out so that the actual results can be checked.

Page 24: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

24

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Testing - Test Data

• Testing is usually done with three types of test data:

3. Exceptional data - the data is not suitable for the program e.g. (i) values outside agreed ranges(ii) letters instead of numbers.

2. Extreme data - the data is at the extreme limits allowed. e.g. if an age is to be between 0 and 120 then these two values are tested.

1. Normal data - typical data that would be expected.

Page 25: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

25

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Testing - Stages of Testing

• Testing is itself a structured process starting with individual lines of code and building up to a test of the entire system.

2. Component or procedural testing - A procedure can be tested by creating another procedure called a driver procedure to provide the necessary data. Once the test has proved satisfactory, the driver procedure is deleted.

1. Structured Walkthrough - Each line of logic in the code is stepped through using a printed listing.

Page 26: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

26

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Testing - Stages of Testing

4. Sub System testing - In the same way, groups of modules which are designed to communicate are tested.

3. Module testing - This involves testing a number of already tested individual procedures to make sure that they link together correctly as a module. Again a driver procedure is used to call the module procedures in the correct sequence.

5. System testing - Finally, the overall system made up of tested sub systems is tested.

Page 27: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

27

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Testing - Stages of Testing

6. Beta testing - The system may now be trialled with a number of selected users in the real world. A so called ‘beta version’ is issued to users who test it under working conditions and report any faults to the design team. These results are often used to make final changes just before publication.

Page 28: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

28

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Testing - Error Detection & Removal

• There are basically two types of errors:

1. Syntax errors - errors in the code e.g. missing ; where the rules of the language are broken.

2. Run time errors - errors that only occur when the program is executed such as incorrect variable names or division by zero.

Page 29: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

29

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Documentation

Key Task: To produce documentation to be distributed with the software.Personnel: Client, Systems Analyst and programmerDocumentation: User Guide and Technical Guide

Page 30: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

30

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Documentation

1. The Technical Guide

• How to install the software, its memory and processor requirements, version number, help files of systems extensions needed.

• Reference section on trouble-shooting system problems.

• All software comes with two essential pieces of documentation.

Page 31: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

31

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Documentation

2. The User Guide

• A beginners (‘getting started’) guide often in the form of a tutorial in which the USER goes through a number of worked examples.

• A User manual explaining how to use the package.

Frequently, these may be provided in electronic form with an interactive help and tutorial system. The user will have the option to print these if needed.

Page 32: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

32

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Evaluation

Key Task: To report upon the quality of the software according to given criteria.Personnel: Systems Analyst and Project managerDocumentation: A Project report accompanying the software to the client. It compares the software to the original specification and comments on the quality of the software.

Page 33: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

33

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Evaluation

• The finished working program is now compared with the original specification. This involves judging the software against a set of criteria such as :

• a list of the original user requirements

• the quality of the HCI

• choice of suitable language

• attributes of good programming style

• quality of testing

• choice of language

Page 34: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

34

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Maintenance

Key Task: To make changes to the software after it has been handed over to the client.Personnel: Varies but programmer and client will certainly be involvedDocumentation: A Maintenance report will detail and confirm the maintenance carried out.

Page 35: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

35

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Maintenance

• A company will have three maintenance activities;

• Emergence of undetected errors. • Need to be reported and corrected

• Code overtaken by developments in operating systems, CPUs, peripherals leading to code failure or less effective operation. • System needs to be adapted to new conditions

1. Corrective

2. Adaptive

Page 36: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

36

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Maintenance

• Users request changes such as adding new or altering existing functions or general improvements.

3. Perfective (65% of the time)

Page 37: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

37

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Desirable Characteristics Of Software

1. Robust : Input should appear as typed (echoed). Input should be validated and the user asked for re-entry. Should not crash on invalid input. All possible errors trapped e.g. division by 0.

2. Reliable : Free from error. Works for all allowed inputs.

3. Portable : Can be easily adapted for use on other machines by avoiding the use of machine specific commands.

4. Efficient : make good use of time and memory.

Page 38: Higher Grade Computing Studies 1. Software Development Cycle Higher Computing Software Development S. McCrossan 1 Introduction The development of a piece

38

Higher Grade Computing Studies1. Software Development Cycle

Higher Computing Software Development

S. McCrossan

Desirable Characteristics Of Software

5. Maintainable : Easy to change, upgrade and adapt. Needs to be modular i.e. use of procedures, functions and local variables are important, along with short main programs. Use should be made of pre-written Library modules to avoid unnecessary writing of code.