--> Sayadasite

Multiple Ads

Search

Menu Bar

Structured Design

Structured Design in Software Engineering

1. Definition

Structured Design is a software design technique that divides a large software system into smaller, manageable modules. Each module performs a specific task.

Example: A College Management System can be divided into Student Management, Faculty Management, Examination Management, and Library Management.

2. Diagram of Structured Design

 

 

 

 

 

3. Principles of Structured Design

1.                      Modularity: Dividing software into smaller modules.

Example: A banking system can be divided into account management, deposit, withdrawal, and transaction modules.

2.                      High Cohesion: Each module focuses on one related task.

3.                      Low Coupling: Modules have minimal dependency on one another.

4.                      Functional Independence

Each module should perform one well-defined function.

Modules should depend as little as possible on other modules.

Functional independence is achieved through high cohesion and low coupling.

5.                      Top-Down Design: Designing the main system first and then breaking it into smaller modules.

6.                      Simplicity: Making the software easy to understand and maintain.

7.                      Abstraction: Focus on the essential features of a system while hiding unnecessary details.

Describes what a module does rather than how it does it.

Example: A user withdraws money from an ATM without knowing the internal processing details.

8.                      Information Hiding: Each module should hide its internal data and implementation details.

Other modules should interact with it through clearly defined interfaces.

Example: A bank account module hides the account balance implementation and provides

functions to check or update it.

4. Advantages

·         Easy to develop and test.

·         Easy to maintain and modify.

·         Reduces software complexity.

·         Supports code reuse.

·         Makes debugging easier.

5. Disadvantages

·         Requires careful planning.

·         Changes affecting several modules may be difficult to manage.

·         Less suitable for some highly dynamic or object-oriented designs.

6. Short Answer for Exams

Structured Design is a systematic approach to software design in which a large system is divided into smaller modules. It improves modularity, maintainability, testing, and software quality.

Student System UML Sequence DiagramRemember: Structured Design = Large System → Smaller Modules.

UML Diagrams-

UML Diagrams in Software Engineering

1. Definition

UML (Unified Modeling Language) is a standard visual language used to design, visualize, and document a software system.

It helps developers understand the structure and behaviour of a system before implementation.

 

2. Types of UML Diagrams

UML diagrams are divided into two main categories.

Structural

Shows the structure of a system.

1. Class Diagram

2. Object Diagram

3. Component Diagram

4. Deployment Diagram

5. Package Diagram

Behavioral

Shows the behaviour of a system.

34 Typical Use Case Diagram Examples - Edraw's Top Picks1. Use Case Diagram

2. Activity Diagram

3. State Machine Diagram

4. Sequence Diagram*

5. Communication Diagram*

*Sequence and Communication diagrams are interaction diagrams, a subgroup of behavioral diagrams.

UML 2.x defines 14 diagram types.

3. Important UML Diagrams with Examples

Cohesion and Coupling

 Cohesion and Coupling in Software Engineering

Cohesion and coupling are two important concepts in software design used to measure the quality of a modular system.

1. Cohesion

Definition: Cohesion refers to the degree to which the elements within a single module are related to one another and work together to perform a specific task.

A module with high cohesion performs one well-defined task.

Example: A login module that validates usernames and passwords is highly cohesive because all its functions are related to user authentication.

Types of Cohesion

From weakest to strongest:

1.                      Coincidental cohesion: Unrelated tasks are grouped into one module.

2.                      Logical cohesion: Similar types of tasks are grouped together.

3.                      Temporal cohesion: Tasks performed at the same time are grouped together, such as system initialization.

4.                      Procedural cohesion: Tasks are grouped because they follow a particular sequence.

5.                      Communicational cohesion: Tasks operate on the same data.

6.                      Sequential cohesion: The output of one task becomes the input of another.

7.                      Functional cohesion: All elements contribute to one specific function. This is generally the strongest type.

2. Coupling

Definition: Coupling refers to the degree of dependency between different modules in a software system.

Low coupling means modules are relatively independent of one another.

Example: A payment module communicates with an order module through a clearly defined interface without accessing its internal implementation. This indicates low coupling.

Types of Coupling

From strongest (least desirable) to weakest (most desirable), in the traditional classification:

1.                      Content coupling: One module directly accesses or modifies the internal data or code of another module.

2.                      Common coupling: Multiple modules share global data.

3.                      External coupling: Modules depend on externally imposed formats, protocols, or devices.

4.                      Control coupling: One module passes control information that determines another module's behavior.

5.                      Stamp coupling: Modules pass a complete data structure even though only part of it is needed.

6.                      Data coupling: Modules communicate by passing only the necessary data through parameters.

7.                      Message coupling: Modules communicate through messages or public interfaces with minimal knowledge of one another; commonly emphasized in object-oriented design.

Both coupling and cohesion are important factors in determining the maintainability, scalability, and reliability of a software system. High coupling and low cohesion can make a system difficult to change and test, while low coupling and high cohesion make a system easier to maintain and improve.

3. Difference Between Cohesion and Coupling

Cohesion

Coupling

Measures relationships within a module.

Measures dependencies between modules.

Focuses on a single module.

Focuses on interactions between modules.

High cohesion is desirable.

Low coupling is desirable.

Improves clarity and maintainability.

Reduces the impact of changes between modules.

Example: A module only handles student records.

Example: The student module interacts with the fee module through an interface.

4. Diagrammatic Representation

High Cohesion

Student Module

Add student

Update student

View student

All functions relate to student records.

Low Coupling

Student Module

Public Interface

Fee Module

Modules communicate through a defined interface.

5. Importance of Cohesion and Coupling

  • High cohesion makes individual modules easier to understand, test, and maintain.
  • Low coupling allows one module to change with minimal effect on others.
  • Together, they improve modularity, reusability, flexibility, and software reliability.

Conclusion: A good software design aims for high cohesion and low coupling. This is a fundamental principle of modular design in software engineering.

Software Design

 Software Design

Software Design is the process of planning and defining the structure, components, modules, interfaces, and data of a software system before implementing it through coding.

It explains how the software system will be developed and how its different parts will work together.

Objectives of Software Design

  • Correctness: Meets the specified requirements.
  • Simplicity: Makes the software easy to understand.
  • Efficiency: Uses time and resources effectively.
  • Maintainability: Makes software easy to modify and update.
  • Reusability: Allows components to be reused in other applications.
  • Reliability: Helps the software operate consistently.

Types of Software Design

1.                      Architectural Design: Defines the overall structure of the software system.

2.                      High-Level Design (HLD): Describes major modules and their interactions.

3.                      Low-Level Design (LLD): Describes the internal logic, classes, methods, and algorithms.

4.                      Database Design: Defines tables, relationships, primary keys, and foreign keys.

5.                      Interface Design: Defines how users and software components interact.

Software Design Process

1.                      Requirements Analysis

2.                      Architectural Design

3.                      Detailed Design

4.                      Coding and Implementation

5.                      Testing and Maintenance

The Software Design Process transforms user expectations into a concrete technical blueprint before any code is written. Following your outlined stages, this structured lifecycle ensures reliability, scalability, and efficiency

1. Requirements Analysis

This phase bridges the gap between business needs and technical possibilities. Analysts gather and evaluate what the software must do (functional requirements) and how it must perform (non-functional requirements like security and speed).

·   Key Focus: Understanding the problem space, validating feasibility, and scoping limits.

·   Core Deliverable: Software Requirements Specification (SRS).

2. Architectural Design (High-Level Design)

Architects define the overall macro-structure of the software system. This layout focuses on how major subsystems, databases, external APIs, and hardware components interact with each other.

·   Key Focus: Selecting the tech stack, enforcing security frameworks, and ensuring scalability.

·   Core Deliverable: System Architecture Diagram & High-Level Design (HLD).

3. Detailed Design (Low-Level Design)

Engineers zoom in on the macro-components defined in the architecture phase. This phase maps out the precise logic of individual code modules, class relationships, and data structures.

·   Key Focus: Designing specific algorithms, API endpoints, database schemas, and error-handling routines.

·   Core Deliverable: Software Design Document (SDD).

4. Coding and Implementation

Developers translate the design blueprints into functional source code. Programming languages are chosen, coding standards are enforced, and code repositories are managed using version control systems.

·   Key Focus: Writing efficient code, conducting peer code reviews, and performing initial unit tests.

·   Core Deliverable: Executable Software & Source Code Repository.

5. Testing and Maintenance

The software undergoes rigorous validation before and after it goes live. QA teams execute multi-tier tests to catch bugs, while post-release support keeps the system secure and adaptive to new user requirements.

·   Key Focus: Functional, performance, and user acceptance testing (UAT); releasing security patches and optimization updates.

·   Core Deliverable: Test Reports, Bug Fixes, and Post-Deployment Version Updates.

Are you studying this process for an academic exam or setting up a workflow for a real-world project? If you'd like, we can explore specific SDLC models like Agile or Waterfall to see how these phases adapt.

Principles of Good Software Design

  • Abstraction: Focuses on essential features and hides unnecessary details.
  • Modularity: Divides software into smaller, manageable modules.
  • Encapsulation: Combines data and methods while controlling access.
  • Cohesion: Ensures each module has a clear, focused responsibility.
  • Coupling: Keeps dependencies between modules as low as possible.

Example

For a student management system, software design may include:

  • A student registration module.
  • A marks management module.
  • A database containing student details and marks.
  • A login interface for students and administrators.

7. Characteristics of Good Software Design

A good software design should be:

1.                      Simple and understandable.

2.                      Modular and well-structured.

3.                      Efficient in time and memory.

4.                      Easy to test and maintain.

5.                      Reliable and secure.

6.                      Flexible enough to accommodate future changes.

7.                      Consistent with the specified requirements.

8. Advantages of Software Design

  • Reduces development complexity.
  • Helps identify problems before coding.
  • Improves software quality and reliability.
  • Reduces maintenance costs.
  • Supports teamwork by defining component responsibilities.
  • Makes future enhancements easier.

Design Concepts

Design concepts are the fundamental principles used to design software that is easy to understand, develop, test, and maintain that are reliable, efficient, maintainable, reusable, and easy to understand. They help transform software requirements into a structured design before coding begins.

Important Design Concepts

1. Abstraction: Shows essential features while hiding unnecessary details.

Example: An ATM user can withdraw money without knowing its internal processing steps.

·         Reduces complexity.

·         Makes software easier to understand.

·         Focuses on what a component does rather than how it works.

2. Modularity: Divides a software system into smaller, manageable modules each responsible for a specific task.

Example: A college management system has separate modules for students, fees, and examinations each responsible for a specific task.

Example: An online shopping system may contain separate modules for login, payments, products, and orders.

·         Simplifies development and testing.

·         Makes maintenance easier.

·         Allows modules to be developed independently.

3. Software Architecture: Defines the overall structure of a software system and the relationships between its components.

Common architectural styles include:

  • Layered architecture
  • Client-server architecture
  • Microservices architecture
  • Model-View-Controller (MVC)

Example: A system divided into presentation, business logic, and database layers.

Example: In a client-server system, the client sends requests and the server processes them.

4. Design Patterns: Reusable solutions to commonly occurring software design problems.

Example: Singleton, Factory, and Observer patterns.

Examples include:

  • Singleton: Ensures that a class has only one instance.
  • Factory: Creates objects without exposing all object-creation details.
  • Observer: Notifies dependent objects when an object's state changes.
  • MVC: Separates the model, view, and controller responsibilities.

5. Information Hiding: Hides the internal details of a module and exposes only what other modules need.

Example: A bank account object does not allow direct modification of its private balance.

6. Functional Independence: Designs modules so that each performs a specific task with minimal dependence on other modules. It involves:

  • High cohesion: A module focuses on one related set of tasks.
  • Low coupling: Modules have fewer dependencies on one another.

Example: A report-generation module should generate reports without directly handling user authentication.

7. Refinement: Gradually develops a high-level design into a detailed design.

Example: Breaking the payment process into validation, payment processing, and receipt generation.

8. Separation of Concerns: Divides a system into distinct parts, each addressing a different responsibility.

Example: Separating the user interface from database operations.

Example: In a web application:

  • Presentation layer handles the user interface.
  • Business logic layer processes application rules.
  • Data access layer manages database operations.

This makes software easier to develop, test, and maintain.

9. Refactoring: Improves the internal structure of existing code without changing its external behavior.

Example: Removing duplicate code by creating a reusable function.

Example: Breaking a long function into smaller, meaningful functions while preserving its output.

  • Improves readability.
  • Reduces code duplication.
  • Simplifies future maintenance.

10. Aspects: Handles concerns that affect multiple modules, such as logging, security, and error handling.

Summary Table

Concept

Main Purpose

Abstraction

Hides unnecessary details

Modularity

Divides software into modules

Software Architecture

Defines overall structure

Design Patterns

Provides reusable design solutions

Information Hiding

Protects internal details

Functional Independence

Promotes high cohesion and low coupling

Refinement

Adds design details gradually

Separation of Concerns

Separates different responsibilities

Refactoring

Improves code structure

Aspects

Manages cross-cutting concerns

 

Benefits of Software Design Concepts

  • Maintainability: Makes software easier to modify.
  • Reusability: Allows components to be reused in other applications.
  • Reliability: Helps reduce design errors.
  • Scalability: Supports system growth.
  • Testability: Makes individual components easier to test.
  • Understandability: Makes the system easier for developers to comprehend.

Conclusion

Software design concepts provide the foundation for building high-quality software. Concepts such as abstraction, modularity, encapsulation, information hiding, and functional independence help developers create systems that are easier to understand, test, maintain, and extend.

Architectural Design

1. Architectural Design in Software Engineering

1. Definition

Architectural design is the process of defining the overall structure of a software system, identifying its major components, their relationships, and how they interact with each other.

It provides a high-level blueprint for developing the software system. It helps developers understand how the entire system will work before implementing individual modules.

 

 

 

2. Objectives of Architectural Design

1.                      Define system structure: Identify the major components and subsystems.

2.                      Manage complexity: Divide a large system into smaller, manageable parts.

3.                      Improve performance: Organize components to meet response-time and resource requirements.

4.                      Ensure reliability: Design the system to handle errors and failures effectively.

5.                      Improve maintainability: Make it easier to modify and update software.

6.                      Support scalability: Allow the system to handle increasing users, data, and workloads.

7.                      Enhance security: Define appropriate boundaries and access controls.

8.                      Promote reusability: Encourage the use of reusable components.

9.                      Support communication: Define how components exchange information.

10.             Reduce development risks: Identify architectural problems early in the development process.

3. Architectural Design Process

1. Requirement Analysis

Identify system requirements

Understand functional and non-functional requirements.

Understand what the system must do and the quality attributes it must satisfy.

2. Identify Components

Divide the system into major modules

Determine the main modules and their responsibilities.

Divide the system into logical parts, such as authentication, payment, reporting, and data management.

3. Select Architecture

Choose a suitable architectural style

Choose layered, client-server, MVC, microservices, or another suitable style.( Model-View-Controller)

Choose a structure suitable for the application's requirements.

4. Define Interfaces

Specify communication between components

Specify how components communicate and exchange data.

5. Evaluate and Document

Check quality attributes and document the design

Check performance, security, reliability, and maintainability.

Check whether the design meets important requirements and identify potential risks.

Record the design so developers, testers, and maintainers can understand it.

6: Document the Design

Prepare diagrams, component descriptions, and architectural decisions.

4. Types of Software Architecture

1. Layered Architecture

The system is divided into layers, with each layer performing a specific function.

Example: A web application with presentation, business logic, and data access layers.

Presentation Layer

Business Logic Layer

Data Access Layer

Database

2. Client-Server Architecture

The client sends requests, and the server processes them and returns responses.

Example: A web browser communicating with a web server.

 

3. Model-View-Controller (MVC)

The application is divided into three components:

·         Model: Manages data and business rules.

·         View: Displays information to the user.

·         Controller: Handles user input and coordinates the model and view.

Example: An online shopping website.

4. Repository Architecture

Different components access shared data stored in a central repository.

Example: A system in which multiple application modules use a common database.

5. Pipe-and-Filter Architecture

Data passes through a sequence of processing components called filters. Pipes transfer data between the filters.

Example: A compiler that performs lexical analysis, parsing, semantic analysis, and code generation.

·         Lexical Analysis (Scanning): Reads the raw stream of source characters and groups them into meaningful basic units called tokens (such as keywords, identifiers, operators, and literals) using regular expressions and finite automata.

·         Syntax Analysis (Parsing): Takes the token stream and checks it against the grammatical rules of the programming language, organizing the tokens into a parse tree or abstract syntax tree (AST).

·         Semantic Analysis: Inspects the syntax tree to ensure logical and contextual consistency—such as verifying variable declarations, performing type checking, and resolving scopes.

·         Code Generation: Translates the verified representation (often after intermediate code generation and optional optimization) into the final target machine code or assembly instructions specific to the hardware architecture

6. Microservices Architecture

The application is divided into small, independently deployable services that communicate through APIs or messaging.

Example: An e-commerce application with separate payment, inventory, and order services.

5. Advantages of Architectural Design

·         Provides a clear blueprint for implementation.

·         Reduces system complexity.

·         Improves software quality and reliability.

·         Supports parallel development.

·         Makes testing and maintenance easier.

·         Helps identify design problems early.

·         Supports scalability and future modifications.

6. Conclusion

Architectural design is an important phase of software engineering because it defines the high-level structure of a software system. Choosing an appropriate architecture helps achieve performance, maintainability, security, reliability, and scalability.

Top of Form

Bottom of Form

Modular Design

Modular design is a design approach in which a complex system is divided into smaller, independent units called modules. Each module performs a specific function and can be designed, developed, tested, and maintained separately.

The process of breaking down software into multiple independent modules where each module is developed separately is called Modularization.

 

Key Features of Modular Design

  • Modularity: Divides a large system into smaller modules.
  • Reusability: Modules can be reused in different projects.
  • Independence: Each module performs a specific task.
  • Maintainability: Individual modules can be modified without affecting the entire system.
  • Scalability: New modules can be added when requirements change.
  • Easy testing: Each module can be tested independently.

Example

Consider an online shopping application.

Online Shopping System

User Module

Login and registration

Product Module

Product information

Order Module

Cart and orders

Payment Module

Payment processing

Each module handles a specific responsibility, and all modules work together to form the complete application.

Principles / Characteristics of Modular Design

1.                      High cohesion: Each module should focus on one specific task.

2.                      Low coupling: Dependencies between modules should be minimized.

3.                      Information hiding: Internal implementation details of a module should be hidden from other modules.

4.                      Well-defined interfaces: Modules should communicate through clearly specified interfaces.

5.                      Reusability: Modules should be designed for reuse wherever possible.

Coupling and Cohesion are two key concepts in software engineering that are used to measure the quality of a software system's design.

Definition: The degree of direct interdependence or connection between different software modules.

Definition: The degree to which the internal elements of a single module belong together and work toward a single, well-defined purpose ("do one thing and do it well").

Advantages

1.                      Reduces system complexity.

2.                      Makes software easier to develop and understand.

3.                      Simplifies debugging and maintenance.

4.                      Encourages code reuse.

5.                      Supports parallel development by different teams.

6.                      Makes testing easier.

Disadvantages

1.                      Requires careful planning and module boundaries.

2.                      Communication between modules can increase complexity.

3.                      Integration of modules may cause compatibility issues.

4.                      Poor modular design can create unnecessary dependencies.

 

 

 

Applications

  • Software development
  • Website and mobile application design
  • Building architecture
  • Product and industrial design
  • Hardware and electronic systems

In summary: Modular design divides a complex system into smaller, manageable, and reusable components, making the overall system easier to develop, test, maintain, and expand.