Software Design: Architecture, Structure Charts and Design Strategies

UNIT 2 • MODULE 2 • LESSON 05

The analysis phase produced a requirements specification for the library: what the system must do. Design answers a different question: how will the system be organised so that it does those things well? A good design is like an architect’s plan for a house. Before anyone lays a block, the plan shows the rooms, how they connect, where the pipes run and what each room is for. In software, the “rooms” are sub-systems and modules, and the “pipes” are the data passed between them.

You already met top-down design and hierarchy charts in Unit 1 • Module 2 • Lesson 02 – Top-Down, Bottom-Up, Stepwise Refinement and Hierarchy Charts, where they helped you design a single algorithm. This lesson places the same thinking inside system design and adds the tools professionals use: structure charts, design strategies and design deliverables.

What you will learn

  • The four design activities: architectural, interface, data structure and algorithm design.
  • System structuring into sub-systems, modules and programs.
  • Top-down and bottom-up design methods.
  • How to read and draw a structure chart, including data couples and control flags.
  • Functional versus object-oriented design strategies.
  • Coupling and cohesion as measures of a good modular design.
  • The deliverables of design: the system architecture and the design specification.

Part 1: The four design activities

ActivityDecidesLibrary example
Architectural designThe overall structure: the sub-systems, the modules within them, and how they relate and communicate.Split into Loans, Catalogue and Membership sub-systems that share one database.
Interface designHow each component communicates: with users (screens, reports) and with other components (parameters, data formats).The loan screen layout; recordLoan takes a member ID, a book ID and a day number.
Data structure designHow data is organised and stored: records, files, tables, arrays.A Loan record with MemberID, BookID, LoanDay, DueDay, ReturnDay; loans held in a table.
Algorithm designThe step-by-step logic of each module.Pseudocode for finding all loans more than 14 days old.

These activities overlap and feed each other. Architectural design usually comes first, because it decides what modules exist. Interface, data and algorithm design then fill in the detail for each one.

System structuring: sub-systems, modules and programs

Large systems are divided into layers of smaller parts:

  • A sub-system is a major part of the system that could almost stand alone, with its own purpose (for example the Loans sub-system).
  • A module is a smaller, named unit within a sub-system that does one job (for example Record loan). In C a module is usually a function, or a source file of related functions.
  • A program is an executable unit built from modules (for example the front-desk loans program that staff run).

Structuring is what makes large systems manageable. Different programmers can build different modules at the same time; each module can be tested alone; and a later change usually affects only one module.

Try it 1Which design activity?

Choose the design activity each decision belongs to.

Part 2: Top-down and bottom-up design

Top-downBottom-up
Starts withThe whole system as one problemSmall, well-understood components
ThenBreaks it into sub-problems, then breaks those down again (stepwise refinement) until each piece is simpleCombines components into larger units until the whole system is built
StrengthsKeeps the overall goal in view; clear structure; easy to divide workReuses existing tested parts; useful low-level pieces are built and tested early
WeaknessesLow-level problems may be found late; can produce duplicate modulesOverall structure may be unclear until late; parts may not fit together

In practice designers mix both. They sketch the system top-down to get the structure, but reuse existing library functions and components bottom-up. Reuse-oriented development from Lesson 02 is largely a bottom-up approach.

Part 3: Structure charts

A structure chart shows the modules of a program and how they call each other, together with the data passed between them. It looks like the hierarchy charts from Unit 1, with extra symbols for data.

Library loansmainRecord loanrecordLoanFind bookfindBookRecord returnrecordReturnFind loanfindLoanPrint overdueprintOverdueDays latedaysLatemember, book, dayokbook, daydaybookindexbookindexloan, daydays
Structure chart for the library loans program. Boxes are modules; lines show which module calls which; small arrows are data couples (open circle) and control flags (filled circle).
SymbolMeaning
RectangleA module (in C, usually a function). The top module controls the others.
Line from a higher to a lower moduleThe higher module calls (uses) the lower one.
Arrow with an open circleA data couple: data passed between modules, in the direction of the arrow.
Arrow with a filled circleA control flag: a signal (such as found, ok, end of file) that affects what the receiving module does.
Curved arrow around lines (optional)The calls are repeated (a loop).
Small diamond at a module (optional)The call is made only if a condition is true (selection).

Reading the chart above. The top module main calls three modules. It passes a member, a book and a day number down to Record loan and receives an ok flag back, which tells main whether to print a confirmation or an error. Record loan calls Find book, passing a book ID and getting back an index (its position in the list of books). Print overdue receives today’s day number and, for each loan, calls Days late. You will turn this exact chart into C in Lesson 07.

Structure chart vs DFD

Do not confuse the two. A DFD (Lesson 04) is an analysis model of how data flows through the whole system, including people and stores. A structure chart is a design model of how a program’s modules are arranged and call each other. A common design step is to turn each DFD process into one or more modules on a structure chart: process 1 Record loan becomes the Record loan module, and so on.

Try it 2Read the structure chart

Use the structure chart above to answer each question.

Worked example: from DFD to structure chart

Here is how the designer produced the chart above from the level 1 DFD in Lesson 04. Follow the same steps for your own systems.

StepWhat the designer didResult
1. One controllerCreate a top module that runs the program and decides which task to do.Library loans (main)
2. One module per DFD processEach numbered process becomes a second-level module, named with the same verb phrase.Record loan, Record return, Print overdue
3. Find repeated or separable jobsLook inside each process for a sub-task that is clearly separate or could be reused.Searching for a book, searching for a loan, working out days late
4. Add data couplesFor each call, ask: what data must go down, and what result must come back?book down, index up; loan and day down, days up
5. Add control flagsWhere a module must report success or failure, add a flag.ok returned from Record loan
6. Check qualityDoes each module do one job? Are couples few and clear?Yes: six small, cohesive modules

Notice what disappeared: the external entities and data stores of the DFD are not boxes on the structure chart. Entities become input and output inside modules (for example, printing the overdue list for the librarian), and data stores become data structures (arrays of records in Lesson 07, or files and database tables in a larger system).

CASE tools in design

The CASE tools from Lesson 04 are just as useful here. Design tools can draw structure charts and class diagrams, keep every module description in the shared repository alongside the data dictionary, check that each data couple on a chart is defined, and in some cases generate function headers or class skeletons directly from the design. As in analysis, the tool records and checks the design; the designer still makes the decisions.

Part 4: Good modular design: coupling and cohesion

Two ideas help judge whether a structure chart is a good design.

  • Cohesion is how closely the parts inside one module belong together. Aim for high cohesion: each module does one clear job. “Find book” is highly cohesive. A module called “Do loan stuff and print report and check password” is not.
  • Coupling is how much modules depend on each other. Aim for low coupling: modules communicate only through a few clearly defined parameters, not through shared global variables. Low coupling means a change inside one module rarely breaks another.

High cohesion and low coupling directly support maintainability (Lesson 01) and make modules easier to test separately (Lesson 08). When a structure chart has a module with many data couples going in and out, or a module that seems to do several unrelated things, that is a sign the design should be improved.

Part 5: Design strategies: functional vs object-oriented

Functional (function-oriented) designObject-oriented design
FocusThe functions (actions) the system performsThe objects (things) in the system and their behaviour
System is built fromFunctions that transform data; data is often shared between themClasses that bundle data (attributes) with the operations (methods) on it
Typical toolsDFDs, structure chartsClass diagrams and other UML diagrams
Library exampleFunctions recordLoan, recordReturn, printOverdue working on loan recordsClasses Member, Book and Loan; a Loan object knows its own due day and can calculate its days late
SuitsSystems with clear processing steps; languages such as CLarge systems with many interacting things; languages such as Java, Python, C++

Because this course uses C, our designs are functional: structure charts of functions. You should still be able to describe the object-oriented alternative and compare the two. A key advantage of object-oriented design is encapsulation: an object’s data can be changed only through its own methods, which protects it from accidental change. A key advantage of functional design is simplicity for smaller, process-driven systems.

Part 6: Deliverables of the design phase

DeliverableContents
System architectureThe sub-systems and modules and how they connect, usually shown as block diagrams and structure charts; hardware and network layout if relevant.
Design specificationThe detailed design: structure charts, module descriptions (inputs, outputs, purpose), data structures and file or database designs, screen and report layouts, and algorithms in pseudocode.

The design specification is what programmers work from in the implementation phase. A good one is detailed enough that two different programmers would produce code that fits together. It also becomes system documentation for later maintainers.

Worked example: a module description

Module: findBook
Purpose: locate a book
  by its ID
In:  book ID (int)
Out: index in books
  array, or -1
Called by: recordLoan
Algorithm: linear search

Every module on the structure chart gets a short description like this. Notice how it links to your Unit 2 Module 1 work: the algorithm is the linear search from Unit 2 • Module 1 • Lesson 07 – Searching in C: Linear Search and Binary Search.

Try it 3Design drill

“Concepts” checks design vocabulary. “Charts” checks structure chart symbols and quality.

Common mistakes

  • Mixing up structure charts and DFDs. Structure charts show calls between program modules; DFDs show data movement through a system.
  • Drawing a structure chart with no data couples. The data passed between modules is a key part of the design.
  • Using a control flag where a data couple is meant, or the reverse.
  • Describing top-down design as "starting with the code". It starts with the whole problem.
  • Forgetting interface design includes interfaces between modules, not just screens.

Summary

IdeaKey point
Four design activitiesArchitectural, interface, data structure, algorithm.
StructuringSystem, sub-systems, modules, programs.
MethodsTop-down (decompose) and bottom-up (compose), often mixed.
Structure chartModules, calls, data couples (open circle), control flags (filled circle).
QualityHigh cohesion, low coupling.
StrategiesFunctional (functions and data flows) vs object-oriented (classes and objects).
DeliverablesSystem architecture and design specification.

Review questions

1. Name and describe the FOUR design activities.

Show answer

Architectural design (overall structure of sub-systems and modules and their relationships); interface design (how components communicate with users and each other); data structure design (how data is organised and stored); algorithm design (the step-by-step logic of each module).

2. What is architectural design?

Show answer

Deciding the overall structure of the system: identifying the sub-systems and modules and the relationships and communication between them.

3. Compare top-down and bottom-up design.

Show answer

Top-down starts with the whole system and breaks it into smaller parts; it keeps the goal in view but may find low-level problems late. Bottom-up builds and combines small components; it reuses tested parts but the overall structure may be unclear until late.

4. Distinguish between a data couple and a control flag.

Show answer

A data couple (open circle) carries data that the receiving module processes, such as a book ID. A control flag (filled circle) carries a signal that affects what the receiving module does, such as found or ok.

5. Explain why low coupling and high cohesion are desirable.

Show answer

High cohesion means each module does one job, so it is easier to understand and test. Low coupling means modules depend on each other little, so a change in one module is unlikely to break others. Both improve maintainability.

6. Compare functional and object-oriented design strategies.

Show answer

Functional design decomposes the system into functions that transform data, using tools such as structure charts. Object-oriented design identifies objects that combine data and operations, using class diagrams; it supports encapsulation and reuse.

7. List THREE items in a design specification.

Show answer

Any three: structure charts; module descriptions; data structures or file and database designs; screen and report layouts; algorithms in pseudocode.

Homework

  1. Draw a structure chart for the sports club system from Lesson 04, with at least five modules, data couples and one control flag.
  2. Write module descriptions (purpose, in, out, called by) for two of your modules.
  3. List the classes you would use for the sports club in an object-oriented design, with two attributes and one method each.
  4. Find a module in one of your own Unit 1 C programs that has low cohesion, and explain how you would split it.

Mastery quiz: Software design

This 10-question quiz is separate from the short Quick quiz at the end of the lesson. Score 8/10 or higher to earn this lesson’s badge. Your best score is saved in this browser on this device.

Mastery quiz: Software Design: Architecture, Structure Charts and Design Strategies

Your course badges: loading saved progress…

View badges

    No course badges earned yet. Score 8/10 in a lesson quiz to earn its badge.

    Saved in this browser on this device. Clearing browser data may remove your badges.

    Answer all 10 questions. Earn this lesson’s badge at 8/10 or higher. Read the explanations, revisit the Try it activities and retry as often as you need. These are self-study badges, not formal grades.

    1. Identifying sub-systems and the relationships between them is
    2. Designing a screen layout is part of
    3. Choosing to store loans in an array of records is
    4. Breaking a whole problem into smaller and smaller parts is
    5. On a structure chart, an arrow with a filled circle shows
    6. A line from module A down to module B shows that
    7. A module that does one well-defined job has
    8. Low coupling means
    9. A design built from classes that bundle data with methods is
    10. The detailed design that programmers code from is the

    Exam tips

    Specimen Unit 2 Paper 01 (2021), Item 28. This item describes the activity of identifying sub-systems and their relationships and asks which design activity it is. Learn a one-line definition of each of the four design activities so that you can match a description to its name quickly.

    For structured questions, a structure chart earns marks for correct hierarchy (who calls whom), sensible module names, and labelled data couples and flags. Use a ruler-straight, top-to-bottom layout and keep labels short.

    When asked to compare strategies or methods, use a two-column comparison: focus, tools, strengths, and a short example.

    Previous: Unit 2 • Module 2 • Lesson 04 – Data Flow Diagrams, Data Dictionaries and CASE Tools. Next: Unit 2 • Module 2 • Lesson 06 – Entity-Relationship Diagrams and User-Interface Design.

    Syllabus link: CAPE Computer Science (CXC A19/U2/21), Software Engineering (Unit 2, Module 2). Specific Objective 5 (first part): design activities (architectural, interface, data structure, algorithm); structure charts and CASE tools; top-down, bottom-up and system structuring (sub-systems, modules, programs); functional versus object-oriented design strategies; deliverables (system architecture, design specification).

    Video search terms

    Search YouTube for: "structure chart data couple control flag", "top down vs bottom up design", "coupling and cohesion explained", "function oriented vs object oriented design".

    Try it 4Quick quiz

    Tap an answer. All eight questions are self-checks on this lesson.

    Updates

    2026/12/01

    - First version of the lesson.

    © 2026 islandclass.org

    Leave a Reply