C SC 100 Lecture Notes
Spring 2008
Pete Sanderson

[ previous | schedule | next ]

major resource: Tomorrow's Technology and You (Complete), Eighth Edition, Beekman and Quinn, Pearson Prentice Hall, 2008

Chapter 14, Systems Design and Development

Problem Solving

Developing a software application is a complex process that requires some guiding principles or methodologies.

George Pólya wrote How to Solve It, a book that has sold over a million copies. In this book he divides the problem solving task into four stages:

  1.  Understanding the Problem
  2.  Devising a Plan
  3.  Carrying out the Plan
  4.  Looking Back (evaluating your solution)


Top Down Design (a.k.a. stepwise refinement)

method for designing programmed solutions to complex problems.

seeks to reduce the complexity of a problem by organizing it in a manageable way.

Top-down design has three major steps:

  1. Break the problem down into simpler subproblems
  2. Solve each subproblem (possibly by using top-down design)
  3. Combine the those solutions to form a solution to the problem
First step is the key.  Break down the problem by finding a natural decomposition of the problem.

Consider building a house.

 Guidelines for finding a natural decomposition: Top-down design can be applied repeatedly to a subproblem which remains complex

Other examples of non-trivial tasks


Software Development Lifecycle

This approach is echoed in what has become known as the Software Development Cycle, consisting of multiple phases:

  1. Investigation
  2. Analysis
  3. Design
  4. Development
  5. Implementation
  6. Maintenance
  7. Retirement

Investigation is the process of determining the feasibility of a proposed system. This addresses such issues as:


Analysis is the process of understanding the problem. Consult client to determine requirements, such as :

The design phase is where the solution plan is devised. The development phase is the system is actually created from the design specification. Major activities here include: Implementation refers to bringing the new system into production. This includes activities such as Maintenance is what happens after it is released for use.   If the work done in the earlier phases was insufficient, this can be more expensive than the development itself.

Retirement occurs when the system has become outmoded and is replaced by a yet newer system


Algorithm

computer program is implementation of an algorithm : a step-by-step description of how the program's task will be accomplished. The task and algorithm may be very complex. A program is a set of instructions that tell the computer how to carry out the algorithm.


Programming Languages

In the beginning, there were machine languages.  Instructions coded as 1’s and 0’s.  OK for computer, hard to humans to do reliably

Assembly languages were developed, giving names to all the machine instructions.  Each assembly instruction corresponds to one machine instruction.  Better, but still hard for humans to do reliably.  Requires assembler to translate into machine language.

High level languages were developed.  Each language instruction corresponds to a (perhaps lengthy) sequence of machine instructions.  Much easier for people.

How many programming languages are there?  Thousands

There are so many because different problems and solutions can be expressed more efficiently using different vocabularies.  No single language includes all vocabularies.

All of them are equally powerful, however, as you will see next.


Theoretical basis for programming languages

Alan Turing, as one of his most important contributions to the field of computer science, developed a mathematical model of computation called the Turing Machine.

The Turing Machine has been shown to be capable of computing anything which is computable (i.e. programmable). Yes, there are things that cannot be programmed!

It has been shown that a programming language is equivalent to a Turing Machine in terms of the problems it can solve if it possesses three simple abilities.

  1. Sequence
  2. Selection
  3. Iteration
Sequence is the ability to specify the relative order of the instructions in a program (i.e., what comes first, etc.).

Selection is the ability to make decisions, of which there are two varieties: deciding for or against and deciding either/or. For or against is a decision of whether to take some course of action, or none at all. Either/or is a decision between two possible courses of action.

Iteration is the ability to repeat an action in a loop.

All the programming languages listed above (and thousands of others) have all these capabilities, and so are equally as powerful as Turing Machines and each other!

Language choice is a matter of how efficiently a solution can be expressed, not whether it can be expressed.


[ Pete Sanderson | Math Sciences server | Math Sciences home page | Otterbein ]

Last updated:
Pete Sanderson (PSanderson@otterbein.edu)