Page 145 - DCAP305_PRINCIPLES_OF_SOFTWARE_ENGINEERING
P. 145

Unit 6: Functional Design



            discipline began. DFDs are very useful in understanding a system and can be effectively used   Notes
            during analysis.

            A DFD shows the flow of data through a system. It views a system as a function that transforms
            the inputs into desired outputs. Any complex system will not perform this transformation in
            a “single step,” and data will typically undergo a series of transformations before it becomes
            the output. The DFD aims to capture the transformations that take place within a system to
            the input data so that eventually the output data is  produced. The  agent that performs  the
            transformation of data from one state to another is called a process (or a bubble). Thus, a DFD
            shows the movement of data through the different transformations or processes in the system.
            The processes are shown by named circles and data flows are represented by named arrows
            entering or leaving the bubbles. A rectangle represents a source or sinks and is a net originator
            or consumer of data. A source or a sink is typically outside the main system of study.
            In this DFD there is one basic input data flow, the weekly timesheet, which originates from the
            source worker. The basic output is the paycheck, the sink for which is also the worker. In this
            system, first the employee’s record is retrieved, using the employee ID, which is contained in
            the timesheet. From the employee record, the rate of payment and overtime are obtained. These
            rates and the regular and overtime hours (from the timesheet) are used to compute the pay. After
            the total pay is determined, taxes are deducted. To compute the tax deduction, information from
            the tax-rate file is used. The amount of tax deducted is recorded in the employee and company
            records. Finally, the paycheck is issued for the net pay. The amount paid is also recorded in
            company records.
            Some conventions used in drawing this DFD should be explained. All external files such as
            employee  record,  company  record,  and  tax  rates  are  shown  as  a  labelled  straight  line.  The
            need for multiple data flows by a process is represented by a “*” between the data flows. This
            symbol represents the AND relationship. For example, if there is a “*” between the two input
            data flows A and B for a process, it means that A AND B are needed for the process. In the
            DFD, for the process “weekly pay” the data flow “hours” and “pay rate” both are needed, as
            shown in the DFD. Similarly, the OR relationship is represented by a “+” between the data
            flows. (See Figure 6.10)


                                    Figure 6.10: Data Flow Diagrams
































                                             LOVELY PROFESSIONAL UNIVERSITY                                   139
   140   141   142   143   144   145   146   147   148   149   150