Lecture #12 (21 February 2002)

Software Engineering

Overall Reading
Brookshear: Ch. 6.1-6.2, pp. 248-249

Outline:

  • Large-scale Software Design
  • Goals and Issues
  • Software Engineering
  • Programming Techniques
  • Team Development
  • Software Development and Life-Cycle

  • Large-scale Software Design

    People want to write programs. Lots of programs. Large programs.

    How do you create a word processor? A computer game? A database?

  • How do you get started?
  • How long will it take to develop?
  • How do you manage the enormity?
  • How does this process compare to classical engineering?
  • Goals and Issues:

  • Reliability: software must work properly.
    (Imagine trying to build a successful company by selling an operating system which crashes regularly.)

    The issues are how to write programs in a style to avoid mistakes? Given that some mistakes will sneak in, how do we find them and fix them quickly? How do you gain confidence in the correctness of software?

  • Program Efficiency: How many instructions will be executed? How much memory will be required?

  • Adaptability: want to modify and improve existing programs
    Even if a program works, you may later decide on some improvements or some new features which might be added. Do you have to rewrite the program from scratch?

  • Reusability: can part of the code for a previous program be used when desiging a new program?
    You do not always want to start a new program from scratch.

    Imagine that you were at Microsoft long ago and Microsoft Word had just been written. Now the goal was to create a "spreadsheet" to be named Excel. At first glance, software for a spreadsheet has nothing to do with a word processor. But there are some commonalities! (e.g. pull-down menu's, saving files to a disk, etc.) Is it possible to use part of the word-processor source code? Will it need to be modified?

  • Portability: can software easily be made to run on a different type of machine?
    Do you need to modify the code? Does it depend on CPU, Operating System, Input Devices, etc?

  • Team Design: software is not only written by individuals, but also written by (large) groups of people
    But how do you make best use of the team? How do you divide up the project, allowing everyone to make progress concurrently.

  • Development Time: How many human hours are involved in creating the software? How many calendar days?
    As a company executive, would you prefer to hire one person for a month, or ten people for one week?

  • Software Engineering

  • Programming Techniques
    Certain techniques and style will allow for software development which is more productive and less redundant, even when working individually.
  • Use of procedures to avoid redundancy of code
    (e.g. square root)
    See Figure 5.9 of [Br]

  • modular design.
    Break a large software project into many smaller pieces which can be developed as independently as possible.

    Example: Word processor
    Separately develop the pull-down menus, the save/open functionality, the spell-checker.

    Advantages include:

  • Can divide labor by focusing on one piece at a time
  • Provides good organization for testing/maintenance
  • Allows useful portions of a program to be yanked out and re-used elsewhere
  • For more details, see Ch. 6.3 of [Br] (optional)
  • Team Development:
    All of these issus and more become key when trying to develop large systems, over extended periods of time, with numerous people (some of whom come and go). Additional issues to consider:
  • The project leader cannot deal with all levels of detail. Must design the general breakdown of labor and trust others to complete these parts.

  • Of course, the pieces better fit together, and this requires careful specification of how each part should behave and interact.

  • How do you look at a potential project and evaluate the overall development cost? The likelihood of success? The length of time before the product would be ready? All of these issues must be considered in advance of the decision to go ahead and start development.

  • Because a project is developed not in days, but in months or years, it is likely that the original design requirements will be updated along the way.
  • Program Develoment and Life-Cycle:

    Typical software life cycle involves

      Development -> Use -> Modification -> Re-Use
    
    The development phase can be further subdivided as:
      Analysis -> Design -> Implementation -> Testing ->
    

  • comp150 Class Page
    mhg@cs.luc.edu
    Last modified: 21 February 2002