IMSE Lecture 4 - PowerPoint PPT Presentation

1 / 12
About This Presentation
Title:

IMSE Lecture 4

Description:

input preliminaries are known as the afferent (coming in) processes and include: ... by examining the DFD or by pruning away the afferent and efferent processes: ... – PowerPoint PPT presentation

Number of Views:30
Avg rating:3.0/5.0
Slides: 13
Provided by: LindaS126
Category:
Tags: imse | afferent | lecture

less

Transcript and Presenter's Notes

Title: IMSE Lecture 4


1
IMSE Lecture 4
  • so far all our structure charts have been
    produced from an English description, e.g.
  • - night on the town
  • - meal with caviar
  • - looking for a placement
  • more often well be asked to produce a structure
    chart from a DFD which was drawn up in the
    requirements analysis stage
  • this is the aim of this weeks lecture and
    tutorial
  • the method of transforming a DFD into a structure
    chart is known as transform analysis

2
Revision notes on Data Flow Diagrams
  • Data Flow diagrams show how data passes through
    the system and is transformed by each system
    function.
  • Arrows show the direction of data flow. Their
    name describes the data flowing along that path.
  • Rectangles show functions which transform inputs
    to outputs. Their names indicate their functions.
  • Detailed description of DFDs on p278-280 of
    Sommerville - though slightly different notation
    used.

3
Transform Analysis
  • a strategy for deriving high quality structure
    charts
  • appropriate for any system of the form
    input-process-output
  • 4 steps, producing 3 new diagrams
  • 1) annotate the DFD (without redrawing it)
  • 2) draw intermediate diagram
  • 3) draw first-cut structure chart
  • 4) refine the structure chart
  • today well cover the first 3 steps, the fourth
    step must wait a few weeks

4
Specification
  • Write a program which accepts a set of
    pre-validated examination marks in the range
    0-100. A count of the number of marks entered in
    the following ranges is to be maintained
  • 0-10, 11-20, 21-30, 31-40, ... 81-90, 91-100.
  • When all the marks have been entered the program
    will generate a graph displaying the count for
    each range.

5
Step 1 - Annotate the DFD
  • In step 1 we draw on the DFD itself, making 2
    changes
  • a) identify the central transform
  • b) add a control function

6
Step 1a - Identify the Central Transform
  • the Central Transform is the function (or
    functions) on a DFD which lie between input and
    output
  • the Central Transform starts work on the data
    when the input preliminaries have been completed
    and before the output activities begin

7
Step 1a (contd)
  • input preliminaries are known as the afferent
    (coming in) processes and include
  • input of data into the system
  • validation of the data
  • any necessary refinement before it can be
    processed
  • the Central Transform includes
  • main processing of the refined data
  • any necessary calculations, etc.
  • output activities are known as the efferent
    (going out) processes and include
  • formatting the output
  • producing the output (displaying, printing,
    writing to file...)

8
Step 1a (contd)
  • identify the central transform either by
    examining the DFD or by pruning away the afferent
    and efferent processes
  • - trace each input flow from the outside of the
    DFD towards the middle, stopping at the point
    where the data has not yet been used for
    processing
  • - trace each output flow backwards from the
    outside of the DFD to the middle, stopping at the
    point where the output data has just been
    produced
  • - mark the region of the DFD between these 2
    points (the region must contain at least 1
    process)

9
Step 1b - Control Function
  • step 1b is to add a control function
  • - we simply draw a new upper rectangle (the
    control function) above the central transform

10
Step 2 - Intermediate Diagram
  • step 2 is to draw the first new diagram (known as
    the intermediate diagram) making 3 changes to the
    annotated DFD
  • a) redraw the process boxes as rectangles
  • b) re-route the data flows
  • any data flows which crossed the boundary of
    the central transform are re-routed via the new
    control function
  • c) empty the central transform
  • any processes within the central transform
    slide down below it and are attached to it

11
Step 3 - First Cut Structure Chart
  • step 3 is to redraw the intermediate diagram to
    produce the 2nd new diagram (known as the
    first-cut structure chart) making another 3
    changes
  • a) give the control function a meaningful name
    describing the overall program (in C this control
    function will represent main, but it should NOT
    be given this name on the diagram)
  • b) remove the central transform if it only has
    one process hanging from it (i.e. in VB or C it
    only invokes a single procedure or function),
    otherwise redraw it as a rectangle

12
Step 3c - Altering all the Lines
  • c) alter all the lines on the intermediate
    diagram
  • (i) remove any dangling lines
  • (ii) draw straight lines with arrowheads from
    the bottom of upper modules to the top of lower
    ones
  • (iii) change the curved lines into small arrows
    with names, representing data passed between
    modules
  • your DFD is now transformed into a first-cut
    structure chart.
Write a Comment
User Comments (0)
About PowerShow.com