CTIS 359 Principles of Software Engineering

Size: px
Start display at page:

Download "CTIS 359 Principles of Software Engineering"

Transcription

1 CTIS 359 Principles of Software Engineering Instructor: Cüneyt Sevgi Tel : csevgi@bilkent.edu.tr Web: Office Hours: Tuesday 11:40 12:30 Wednesday 10:40 11:30 Teaching Assistant(s): Leyla ÖKSÜZ loksuz@bilkent.edu.tr (Labs will start the sixth week of classes)

2 OBJECTIVE This course introduces students to the principles of software engineering. It covers software processes, software project management, requirements, design, development, and verification & validation.

3 Grading (Tentative) (Lab)Quizes %20 Midterm %35 Final %45

4 Couse Materials and Textbook Course materials will be on the web Software Engineering 7 th or 8 th Edition, Ian Sommerville, Addison Wesley, 2004, tml Not obligatory but STRONGLY recommended, as a reference book

5 Today s objectives To present key terminology on Software Engineering domain To introduce Software Engineering and to explain its importance To set out the answers to key questions about software engineering

6 What is a Computer Program? A set of instructions, written in a specific programming language (Fortran, C, C++, Fortran), which a computer follows in processing data, performing an operation, or solving a logical problem. Source : faculty.valencia.cc.fl.us/jdelisle/lis2004/glossary.htm

7 What is Software? Computer programs (sometimes several separate programs) + associated documentation +configuration files Software products may be developed for a particular customer or may be developed for a general market Software products may be Generic : developed to be sold to a range of different customers Bespoke (custom) : developed for a single customer according to their specification Source: Textbook

8 Where do we use Software? In computer systems Operating systems (e.g. Windows, Linux...) End-user programs (e.g. Photoshop, Dreamveawer...) Compilers (e.g. javac, pascal, gcc...) Aircrafts, Space Shuttles (e.g. F16, Discovery Space Shuttle ) Cellular Phones (e.g. Symbian OS, Non-OS systems ) Almost in all manufacturing activities (Eg: Powerhouse) Education (e.g. Distance Learning, CCNA courses) Health systems (e.g. Health Record Systems, Therac-25, radiation therapy machine) More and more systems are software controlled everyday

9 Do we need these complex software? Discussion: When Neil Armstrong stepped out of the Apollo Lunar Module onto the surface of the moon, it truly was a giant step for mankind. The Apollo missions journeyed to the moon with a spaceship boasting a computer with 74KB of memory, 4KB vaguely resembling RAM, and no hard drive. (Isn't this amazing.) We can obviously achive many things without software. What do you think?

10 Do we need these complex software? (Cont.) Scientific and technological curiousity (skepticisms) is an inevitable instinct for humankind like food. So More and more systems will be software controlled...

11 What is Engineering? Definition: The application of science and mathematics by which the properties of matter and the sources of energy in nature are made useful to people. Source: Engineers make things WORK by appyling theories + methods + tools where appropirate. Try to discover solutions within CONSTRAINTS.

12 What is Engineering? (Cont.) Principles of any Engineering activity Projects should be completed Within anticipated budget Cost Within anticipated schedule Time With conformance to customers requirements Quality

13 Cost + Time + Quality Cost Time Quality

14 History of Software Engineering In early days of computing, hardware is hard to change, while software is soft If the software did not work, change the it until it will work Because software were not complex The Complexity Barrier Become difficult for one person develop, track, test, maintain, etc. Person Team

15 The Complexity Barrier complexity size

16 An analogy Carpenter Simple house Early programs Engineer Powerplant Skyscraper Todays, complex sofware

17 What is Software Engineering?(Chronological Order) You may encounter many definitions... First Definition Software engineering is the establishment of sound engineering principles in order to obtain economical software that is reliable and works efficiently on real machines [Naur and Randell, 1969]

18 What is Software Engineering?(Cont.) Software engineering is the practical application of scientific knowledge in the design and construction of computer programs and the associated documentation to develop, operate and maintain them. [Boehm, 1976]. The application of a systematic, disciplined, quantifiable approach to the development, operation, and maintenance of software; that is, the application of engineering to software. [IEEE Computer Society, 1990]. The world s leading organization for computer professionals, the Institute of Electrical and Electronics Engineers IEEE Computer Society

19 What is Software Engineering? (Cont) Software engineering is a discipline whose aim is the production of fault-free software, delivered on time and within budget, that satisfies the client s needs. Source: OO & Classical Software Engineering, 7 th Edition, Stephen Schach

20 What is Software Engineering? (Cont) Software engineering is an engineering discipline which is concerned with all aspects of software production Software engineers should adopt a systematic and organised approach to their work and use appropriate tools and techniques depending on the problem to be solved, the development constraints and the resources available Source: Textbook

21 What is Software Engineering? (Cont) Software Engineering includes three key elements Methods: provide technical HOW-TOs. Methods contain various sets of TASKS such as Project planning, estimation, requirement analysis, design, coding, testing etc... Tools: provide (semi) automated to support methods Procedures: glue that holds methods and tools together. Defines the sequence of methods, deliverables, controls, and milestones Source: Pressman

22 What are relations between... Discussion: Put the following concepts in order in terms importance and size in a typical system. IS (ofcourse, computerized Information Systems) IT (Information Technology) Software Hardware

23 What is a IS? IS: is an arrangement of people, data, processes, information presentation, and information technology that interact to support and improve day-to-day operations in a business as well as support the problem-solving and decision-making needs of management and users. Discussion: Is it possible to have IS without computers? Source:Systems Analysis and Design Methods, Whitten,Bentley

24 What is IT? is a contemporary term that describes the combination of computer technology (hardware and software) with telecommunications technology. Source:Systems Analysis and Design Methods, Whitten,Bentley

25 Relations between... IS >>IT IT>Software+Hardware IS>>Software+Hardware

26 Is SWE is SO important? The economies of ALL developed nations are dependent on software More and more systems are software controlled Software engineering expenditure represents a significant fraction of GNP in all developed countries

27 Is SWE is SO important?(cont.) Software costs often dominate system costs. The costs of software on a PC are often greater than the hardware cost Software costs more to maintain than it does to develop. For systems with a long life, maintenance costs may be several times development costs Software engineering is concerned with cost-effective software development

28 Horror Stories Denver automatic baggage handling system (ABHS) Air traffic control (FAA modernization) Opening delayed for 2 years $27 million cost overrun for ABHS $360 million delay cost $5.6 million cost overrun 8 year delay 2 out of 4 systems are canceled, third requirements are %48 decreased USA navy finance system Comanche Helicopter 4 times cost overrun, $230 million Canceled after 9 years In ten years cost increased 10 times, $34.4 million Requirements are %74 decreased

29 Some Recent Horror Stories Completed late, over budget, and/or with features missing; 53,00% The outcomes of over 9236 development projects completed in 2004 Cancelled; 18,00% Successful; 29,00% Source: F. Hayes Chaos is back Computerworld,

30 Software Engineering Profession The use of software engineer as a job title dates back to 1990s. Some traditional engineering practitoners object the use of title engineering. About half of software engineering professionals have computer science degrees. As of 2004, in the U.S. about 50 universities offer software engineering degrees, which teach both computer science and engineering principles and practices.

31 Software Engineering Profession In 2006, Money Magazine and Salary.com rated software engineering as the best job in America in terms of growth, pay, stress levels flexibility in hours and working environment, creativity, and how easy it is to enter and advance in the field. Source:

32 XYZ Engineering vs Software Engineering Discussion: Are they comparable? Why and why not?

33 Continuous Calculus Bridges Testing/analysis is easy: if the bridge holds for 1M kg, it also probably holds 0.99Mkg Software Discrete Logic, Discrete Mathematics Testing/analysis is difficult

34 Bridges Made of physical stuff Some costs are obvious Changes after construction are hard Software Made of virtual stuff All costs are non-obvious Changes should be easy (but they re not) for (int i = 0; i < rows; i++) { for (int j = 0; j < columns; j++) { nextstates [i][j] = getcellat (i, j).getnextstate (); } }

35 Bridges Obvious when it fails Bridge makers get sued Architects need licenses Software Falls down quietly (usually) Software vendors blame user, charge for upgrades Anyone can make software, no one gets sued

36 Bridges Requirements are (usually) obvious and easy to describe A good design is apparent to everyone immediately Software Requirements are mysterious and hard to describe A good design is only apparent to experts but has impact later on CellAutomata GridDisplay Cell is a subtype of (extends) Grid CellState ConwayLifeCell

37 What is the difference between software engineering and computer science? Computer science is concerned with theory and methods that underlie computer and sofware systems. Software engineering is concerned with the practicalities of developing and delivering useful software. Computer science theories are still insufficient to act as a complete underpinning for software engineering (unlike e.g. physics and electrical engineering).

38 What is the difference between software engineering and system engineering? System engineering is concerned with all aspects of computer-based systems development including hardware + software + process engineering. Software engineering is part of this process concerned with developing the software infrastructure, control, applications and databases in the system. System engineers are involved in system (not simply software) specification, overall architecture, system design, integration of different components and deployment of the finished system.

39 What are software engineering methods? Is structured approaches to software development whose aim is to facilitate the production of high-quality software in a costeffective way. Methods include system models, notations, rules, design advice and process guidance Model descriptions: Descriptions of graphical models which should be produced (e.g. DFDs, ER diagrams, ) Rules: Constraints applied to system models (e.g. every entity in the system model must have a unique name) Recommendations: Advice on good design practice (e.g. Design Patterns, max # of associations/class) Process guidance: What activities to follow (e.g. Any cahnge in design must be updated in SRS document)

40 What is the solution There is NO single ideal approach to software engineering. Different types of systems Different types of organization However, there are many many fundamental techniques that can fit to many organizations and systems

41 What is CASE (Computer-Aided Software Engineering) Software systems which are intended to provide automated support for software process activities. CASE systems are often used for method support Upper-CASE Tools to support the early process activities of requirements and design Lower-CASE Tools to support later activities such as programming, debugging and testing

42 Software Characteristics 1) Software is developed or engineered, it is NOT manufactured in the classical sense. Source: Pressman

43 Software Characteristics (Cont.) 1) Software is developed or engineered, it is NOT manufactured in the classical sense. + = Raw material Human Creativity Physical Element e.g. $5 Source: Pressman

44 Software Characteristics (Cont.) 1) Software is developed or engineered, it is NOT manufactured in the classical sense. + = + Human Creativity Human Creativity Logical Element Physical Element e.g. $5M e.g. $0,05 Source: Pressman

45 Software Characteristics (Cont.) 2) Software does NOT wear out (~aşınmak, yıptanmak) but deteriorates (~gerileme).

46 Software Characteristics (Cont.) Failure Curve for Hardware

47 Software Characteristics (Cont.) Deterioration Not Ware Out Failure Curve for Software

48 Software Characteristics (Cont.) 3) Although industry is moving towards tha component based assembly, most software continues to be custom built. for (int i = 0; i < rows; i++) { for (int j = 0; j < columns; j++) { nextstates [i][j] = getcellat (i, j).getnextstate (); } }

49 What are the attributes of good software? The software should deliver the required functionality and performance to the user and should be maintainable, dependable and usable Maintainability Software must evolve to meet changing needs Dependability Software must be trustworthy Efficiency Software should not make wasteful use of system resources Usability Software must be usable by the users for which it was designed

50 What are the key challenges facing software engineering? Coping with legacy systems, coping with increasing diversity and coping with demands for reduced delivery times Heterogeneity challenge Systems are distributed and include a mix of hardware and software Delivery challenge There is increasing pressure for faster delivery of software The trust challenge Software is intertwined with all aspects of our lives. We would like to trust software.

51 Questions to think about... We already have a book that is full of standards and procedures for building software, won't they provide my people with every thing they need to know? My people do have state-of-art software development tools; after all, we buy them the newest computers. If we fall behind schedule, we can add more programmers and catch up. If I decide to outsource the software project to a third party, I can just relax and let that firm built it. If an organization does nor understand how to manage and control software projects internally, it will invariably struggle when it outsource software projects.

52 Questions to think about... (Cont.) A general statement of objectives is sufficient to begin writing programs we can fill in the details later. Project requirements continually change, but change can be accommodated easily be because software is flexible. Once we write the program and get it to work, our job is done. Until I get the program running I have no way of assessing its quality. The only deliverable for a successful project is the working program. Software engineering will make us creating voluminous and unnecessary document, slow us down.

53 END Any questions/suggestions?