Software Engineering - Introduction
Software Engineering Introduction
Introduction to Software Engineering
- Software engineering involves theories, methods, and tools for professional software development.
- Economies of developed nations are highly dependent on software.
- Software controls an increasing number of systems.
- A significant fraction of the GNP in developed countries is spent on software.
Software Costs
- Software costs often exceed hardware costs in computer systems.
- Maintaining software is more expensive than developing it, especially for long-life systems where maintenance can be several times the development cost.
- Software engineering aims for cost-effective software development.
Software Project Failure
- Increasing system complexity demands faster delivery of larger, more complex systems with new capabilities.
- Failure to use software engineering methods leads to more expensive and less reliable software.
Frequently Asked Questions About Software Engineering
- What is software? Computer programs and associated documentation, developed for specific customers or the general market.
- What are the attributes of good software? Good software delivers required functionality and performance, is maintainable, dependable, and usable.
- What is software engineering? Engineering discipline concerned with all aspects of software production.
- What are the fundamental software engineering activities? Software specification, development, validation, and evolution.
- What is the difference between software engineering and computer science? Computer science focuses on theory; software engineering focuses on practical development and delivery.
- What is the difference between software engineering and system engineering? System engineering includes hardware, software, and process engineering; software engineering is a part of this broader process.
- What are the key challenges facing software engineering? Coping with increasing diversity, demands for reduced delivery times, and developing trustworthy software.
- What are the costs of software engineering? Development costs are about 60%, testing costs about 40%. Evolution costs often exceed development costs for custom software.
- What are the best software engineering techniques and methods? Different techniques are appropriate for different systems (e.g., prototyping for games, complete specification for safety-critical systems).
- What differences has the web made to software engineering? The web has enabled software services and distributed service-based systems, leading to advances in programming languages and software reuse.
Software Products
- Generic Products: Stand-alone systems marketed to any customer (e.g., PC software, CAD software).
- Customized Products: Software commissioned by a specific customer to meet their needs (e.g., embedded control systems, air traffic control software).
Product Specification
- Generic Products: The software developer owns the specification and makes decisions on software changes.
- Customized Products: The customer owns the specification and makes decisions on required software changes.
Essential Attributes of Good Software
- Maintainability: Software should evolve to meet changing customer needs, critical due to the changing business environment.
- Dependability and Security: Includes reliability, security, and safety. Software should not cause physical or economic damage, and malicious users should not be able to access or damage the system.
- Efficiency: Software should not waste system resources like memory and processor cycles, including responsiveness, processing time, and memory utilization.
- Acceptability: Software must be understandable, usable, and compatible with other systems used by the target users.
Software Engineering Explained
- Software engineering is an engineering discipline covering all aspects of software production, from specification to maintenance.
- Engineering Discipline: Uses appropriate theories and methods to solve problems within organizational and financial constraints.
- All Aspects of Software Production: Includes technical development, project management, and development of tools and methods to support software production.
Importance of Software Engineering
- Individuals and society increasingly rely on advanced software systems.
- Software engineering methods can produce reliable and trustworthy systems economically and quickly.
- Using software engineering techniques is cheaper in the long run due to lower costs of changing software after deployment.
Software Process Activities
- Software Specification: Defining the software to be produced and its operational constraints.
- Software Development: Designing and programming the software.
- Software Validation: Checking that the software meets customer requirements.
- Software Evolution: Modifying the software to reflect changing customer and market needs.
General Issues Affecting Software
- Heterogeneity: Systems must operate as distributed systems across diverse networks and devices.
- Business and Social Change: Rapid changes require adapting existing software and developing new software quickly.
- Security and Trust: Trust in software is essential as it intertwines with all aspects of life.
- Scale: Software ranges from small embedded systems to Internet-scale, cloud-based systems.
Software Engineering Diversity
- No universal set of software techniques applies to all types of software systems.
- Methods and tools depend on the application type, customer requirements, and the development team's background.
Application Types
- Stand-alone Applications: Run on a local computer (e.g., PC software).
- Interactive Transaction-Based Applications: Execute on a remote computer and are accessed by users (e.g., e-commerce applications).
- Embedded Control Systems: Control and manage hardware devices (most numerous type).
- Batch Processing Systems: Process data in large batches for business purposes.
- Entertainment Systems: Primarily for personal use and entertainment.
- Systems for Modeling and Simulation: Model physical processes or situations for scientists and engineers.
- Data Collection Systems: Collect data from the environment using sensors.
- Systems of Systems: Composed of multiple software systems.
Software Engineering Fundamentals
- Systems should be developed using a managed and understood development process.
- Dependability and performance are important for all systems.
- Understanding and managing software specifications and requirements are important.
- Reuse existing software where appropriate.
Internet Software Engineering
- The Web is a platform for running applications, leading to web-based systems.
- Web services allow application functionality to be accessed over the web.
- Cloud computing provides computer services remotely, with users paying according to use.
Web-Based Software Engineering
- Fundamental principles of software engineering apply to web-based systems.
- Software reuse is dominant, assembling systems from pre-existing components.
- Incremental and agile development are used, as specifying all requirements in advance is impractical.
Web Software Engineering
- Service-Oriented Systems: Software components are stand-alone web services.
- Rich Interfaces: Technologies like AJAX and HTML5 create rich interfaces within web browsers.
Software Engineering Ethics
- Software engineering involves responsibilities beyond technical skills.
- Software engineers must behave honestly and ethically to be respected professionals.
- Ethical behavior involves following morally correct principles, beyond just upholding the law.
Issues of Professional Responsibility
- Confidentiality: Respect the confidentiality of employers or clients.
- Competence: Do not misrepresent competence or accept work beyond capabilities.
- Intellectual Property Rights: Be aware of laws governing patents, copyright, and protect intellectual property.
- Computer Misuse: Do not misuse technical skills, ranging from trivial to serious offenses (e.g., spreading viruses).
ACM/IEEE Code of Ethics
- Professional societies in the US have a code of ethical practice.
- Members agree to the code upon joining.
- The Code contains eight principles related to the behavior and decisions of software engineers.
Rationale for the Code of Ethics
- Computers have a central role in various sectors, and software engineers contribute to software systems.
- Software engineers can do good or cause harm, so they must commit to beneficial and respected profession.
The ACM/IEEE Code of Ethics
- The code summarizes aspirations with examples of how these aspirations change professional behavior.
- A cohesive code is formed by aspirations and details.
- Software engineers commit to making software beneficial and respected, adhering to eight principles for the public's health, safety, and welfare.
Ethical principles
- PUBLIC - Software engineers shall act consistently with the public interest.
- CLIENT AND EMPLOYER - Software engineers shall act in a manner that is in the best interests of their client and employer consistent with the public interest.
- PRODUCT - Software engineers shall ensure that their products and related modifications meet the highest professional standards possible.
- JUDGMENT - Software engineers shall maintain integrity and independence in their professional judgment.
- MANAGEMENT - Software engineering managers and leaders shall subscribe to and promote an ethical approach to the management of software development and maintenance.
- PROFESSION - Software engineers shall advance the integrity and reputation of the profession consistent with the public interest.
- COLLEAGUES - Software engineers shall be fair to and supportive of their colleagues.
- SELF - Software engineers shall participate in lifelong learning regarding the practice of their profession and shall promote an ethical approach to the practice of the profession.
Ethical Dilemmas
- Disagreement with senior management policies.
- Employer acts unethically, releasing a safety-critical system without proper testing.
- Participation in developing military weapons or nuclear systems.
Case Studies
- A personal insulin pump: An embedded system for diabetics.
- A mental health patient management system: Mentcare.
- A wilderness weather station: A data collection system in remote areas.
- iLearn: A digital learning environment for schools.
Insulin Pump Control System
- Collects data from a blood sugar sensor and calculates the insulin required.
- Calculates based on rate of change of blood sugar levels.
- Sends signals to a micro-pump to deliver the correct insulin dose.
- Safety-critical system: low blood sugar can cause brain malfunction, coma, and death; high blood sugar has long-term consequences.
Insulin pump hardware architecture
- The insulin pump hardware architecture includes components such as a needle assembly, insulin reservoir, pump, clock, sensor, controller, alarm, displays, and a power supply.
Activity model of the insulin pump
- The activity model illustrates the flow of data and control within the insulin pump system including blood sensor, analyzing sensor reading, computing insulin dose, and controlling the insulin pump
Essential High-Level Requirements
- The system shall be available to deliver insulin when required.
- The system shall perform reliably and deliver the correct amount of insulin.
- The system must be designed and implemented to ensure that the system always meets these requirements.
- A medical information system maintaining information about patients with mental health problems and their treatments.
- Clinics are in hospitals, local practices, and community centers.
Mentcare
- Information system for use in clinics with a centralized database.
- Designed to run on a PC for sites without secure network connectivity.
- Uses patient information in the database when connected, downloads local copies when disconnected.
Mentcare Goals
- Generate management information for health service managers.
- Provide medical staff with timely information for patient treatment.
The organization of the Mentcare system
- The Mentcare system is organized with Mentcare clients connected through a network to a Mentcare server and a patient database.
Key Features of the Mentcare System
- Individual Care Management: Clinicians can create records, edit information, and view patient history.
- Patient Monitoring: The system monitors records and issues warnings for possible problems.
- Administrative Reporting: The system generates monthly reports showing the number of patients treated, sectioned, drugs prescribed, and their costs.
Mentcare System Concerns
- Privacy: Patient information must be confidential and disclosed only to authorized staff and the patient.
- Safety: The system should warn staff about potentially suicidal or dangerous patients and must be available when needed.
Wilderness Weather Station
- The government deploys weather stations in remote areas.
- Weather stations collect data on temperature, pressure, sunshine, rainfall, wind speed, and direction.
Weather System
- Each instrument is controlled by a software system that periodically takes parameter readings and manages the collected data.
The weather station's environment
- The weather station's environment includes the weather station system, a data management and archiving system, and a station maintenance system.
- Weather Station System: Collects and processes weather data and transmits it to the data management system.
- Data Management and Archiving System: Collects data from stations, processes and analyzes it, and archives the data.
- Station Maintenance System: Monitors the health of weather stations and reports problems.
Additional Software Functionality
- Monitor instruments, power, and communication hardware and report faults.
- Manage system power, ensuring batteries are charged and generators are shut down in damaging weather.
- Support dynamic reconfiguration, replacing software parts and switching to backup instruments in case of failure.
iLearn: A Digital Learning Environment
- A framework with general-purpose and specially designed learning tools and applications.
- Tools are chosen by teachers and learners to suit specific needs.
- Can include spreadsheets, learning management applications, and games and simulations.
Service-oriented systems
- The system is a service-oriented system with replaceable services.
- This allows incremental updates and rapid configuration for different user groups.
iLearn Services
- Utility Services: Provide basic application-independent functionality.
- Application Services: Provide specific applications like email and access to educational content.
- Configuration Services: Adapt the environment with specific services and define how services are shared.
iLearn architecture
- The iLearn architecture includes a browser-based user interface, an iLearn app, configuration services, application services, and utility services.
iLearn Service Integration
- Integrated Services: Offer an API for service-to-service communication.
- Independent Services: Accessed through a browser interface, with information shared through explicit user actions.
Key points
- Software engineering is an engineering discipline that is concerned with all aspects of software production.
- Essential software product attributes are maintainability, dependability and security, efficiency and acceptability.
- The high-level activities of specification, development, validation and evolution are part of all software processes.
- The fundamental notions of software engineering are universally applicable to all types of system development.
- There are many different types of system and each requires appropriate software engineering tools and techniques for their development.
- The fundamental ideas of software engineering are applicable to all types of software system.
- Software engineers have responsibilities to the engineering profession and society. They should not simply be concerned with technical issues.
- Professional societies publish codes of conduct which set out the standards of behaviour expected of their members.