610 likes | 771 Views
Software Engineering and Science. Ivica Crnkovic Mälardalen University Department of Computer Science and Engineering ivica.crnkovic@mdh.se http://www.idt.mdh.se/~icc. Contents. What is Software Engineering? Software Engineering and Science Methods of Software Engineering
E N D
Software Engineering and Science Ivica Crnkovic Mälardalen University Department of Computer Science and Engineering ivica.crnkovic@mdh.se http://www.idt.mdh.se/~icc Software engineering and Scientific Methods
Contents • What is Software Engineering? • Software Engineering and Science • Methods of Software Engineering • Software Engineering Research • Example – Software architecture Software engineering and Scientific Methods
What is Software Engineering? • Software engineering is an engineering discipline which is concerned with all aspects of software production from the early stages of system specification through to maintaining the system after gone into use. Ian Sommerville, Software Engineering • We need further explanation of: • Engineering discipline • All aspects of software production Software engineering and Scientific Methods
Engineering Engineers make the things work • Solving problems • understand the problem • analyze the problem • Find solutions • Constructing the solution from parts that address the problem's various aspects - do a synthesis • To achieve the goal engineers • apply theories, methods and tools from different disciplines • Search for solutions even when there is not theory or methods Software engineering and Scientific Methods
Analysis of a problem PROBLEM Identify different aspects of the problem Arrange the problems in clearly definedand understandable sub-problems Subproblem 3 Subproblem 1 Subproblem 2 Software engineering and Scientific Methods
SOLUTION The synthesis Find solutions for subproblems Solution 1 Solution 2 Solution 4 Solution 3 Put together solutions to a consistent view Provide (make) a solution Software engineering and Scientific Methods
Engineering Example – the Vasa Ship A master piece of work! • 1625 King Gustav II Adolf decided to start build Wasa • 1628 - maiden voyage. Length- 69 metres Maximum width - 11.7 metresFrom keel to the top of the main mast - 52.5 metresHeight of the stern - 19.3 metres Crew: 445 men, Seamen – 145, Soldiers - 300 Armament64 guns Thousands of people involved in the project Selecting wood, building different parts Providing food, other services Software engineering and Scientific Methods
Vasa – Example of Bad Engineering • the ship capsized on her maiden voyage in the harbor of Stockholm. Why did the Vasa capsize? Software engineering and Scientific Methods
Why did the Vasa capsize? • The Vasa capsized because it was not stable; • The Vasa capsized because • the building process (or in terms of software engineering, the development project) was inadequate. Software engineering and Scientific Methods
Gravity force Ship weight Buoyancy (bärkraft) Ship’s center of gravity Center of buoyancy (water) displacement How to calculate stability? The forces are of equal size and in the opposite directions Software engineering and Scientific Methods
The ship heels at an angle h h – leverage effect (påtryckning) Ship’s center of gravity Center of buoyancy (water displacement) Has moved right Software engineering and Scientific Methods
Leverage effect (Moment) Torque is defined as the product of radius, force, and the sine of the angle between force and radius: t = r F (sin(X)) X http://members.aol.com/PhysicsDad/calcphys/lecture.html Software engineering and Scientific Methods
The ship heels at an angle h – leverage effect (påtryckning) This Torque (Moment) will force the Ship to return back h Software engineering and Scientific Methods
h h The ship is unstable h – leverage effect (påtryckning) Torque has change the direction The ship will capsized Software engineering and Scientific Methods
The ship is stable If the center of gravity is very low – the ship will be stable h Software engineering and Scientific Methods h
Why the ships heel? Because of wind! Or waves… h Software engineering and Scientific Methods
Stability Curve Torque Wind A S2 B S1 aA a1 aB a2 a Software engineering and Scientific Methods
Why did Vasa capsize? • Engineering – • Solve problems even when there is no formal theory • Experience – best practices • Observations • Rules of thumb • Processes to ensure the feasibility of problem solving • COULD VASA BE SUCSSESFULLY BUILT IN SPITE OF LACK OF THEORY? • WHAT DID PROJECT FAILED TO DO? Software engineering and Scientific Methods
Other reasons why Vasa capsized? • Resource & budget plan. The project was delayed and in its later phases, there was enormous pressure to finish work on time. • Project management. The main builder (or in modern terms, the project manager) unfortunately sickened and died during the building of the ship, and the consequence was weak management and very poor coordination of the groups building different parts. • Changes in requirements. The original requirement for one gun deck was changed to two gun decks when the building of the ship had already begun. Because the king was behind the decision, its possible consequences were not analyzed. • Conflicting requirements and trade-off analysis. The Vasa was intended to be a new type of ship combining superior sailing characteristics and maneuverability with overwhelming striking force. Software engineering and Scientific Methods
Other reasons why Vasa capsized? • Design changes during the construction. The dimensions of the ship were changed several times during its construction with no proper analysis of the consequences. • System design vs. detailed design. In many parts the design of the system was not clear and completed, and the final design was shaped during the implementation. The entire process is reminiscent of prototype building. In combination with poor project coordination this resulted in inadequate dimensions of some parts, such as insufficient space for ballast. • Scalability. Vasa was designed as a smaller ship, and its dimensions were merely proportionally increased. • Validation. The stability and other tests were primitive and not well performed. (Test: running across the deck) Software engineering and Scientific Methods
Vasa Disaster – Similar do Software Projects Similar situation in software development project • No formal/theoretical background for requirements and solution • Feasibility of the requirements not analyzed • Changes in requirements during the project work • Time and Budget not properly planned • No proper verification • Bad quality assurance • Shortage in knowledge in new disciplines .... Software engineering and Scientific Methods
Engineering vs. Software Engineering • Many similarities • Methods and procedures • Base objectives and goals • Many differences • Difference between software and hardware/the real world • Software – no physical limits • Not visible • Modifiable • More complex • Different theories and methods used • Different experiences, traditions • Different maturity level Software engineering and Scientific Methods
All aspects of Software Development • Aspects • Technical (how technicaly solve the problem) • Organisational (how to organize people) • Financial • Marketing • Professional and ethical responsibility • Research and Science Software engineering and Scientific Methods
Problem Computer Science Vs. Software Engineering OTHER SCIENCES CUSTOMER COMPUTER SCIENCE ComputerFunctions Theories SOFTWAREENGINEERING Principles, Methods and Tools to Solve Problem and Construct sSolutions Solution Software EngineeringResearch & Science Software engineering and Scientific Methods
Computer Science Vs. Software Engineering COMPUTER SCIENCE Algorithms and data structures Programming languages Architecture Numerical and symbolic computation Operating systems Software methodology and engineering Databases and information retrieval Artificial intelligence and robotics Human-computer communication Social, ethical, and professional issues SOFTWARE ENGINEERING In many cases a defuse boundaries between SE and CS Software engineering and Scientific Methods
Methods and Technologies Solution Phases Requirements Analysis Design Implementation Test Delivery Maintenance Service Software/Systems Engineering Methods Different Technologies Software engineering and Scientific Methods
Project management Development processes Requirements engineering Reverse engineering Test and Verification Software Maintenance Software Architecture Object-oriented modelling Software analysis Formal specification Software reliability Real-time Tools and environments Software Configuration Management Software engineering and the Internet Component-based SE Software Metrics Education Software Economics ...... SE disciplines - examples Software engineering and Scientific Methods
Software Engineering Methods - Examples Requirements Analysis Design Implementation Test Delivery Maintenance Service Project Management Software Development Models and Processes support Component-based Software Engineering (CBSE) Requirements Engineering Analyse/design methods (UML, OOP, Formal methods, ...) Architectural analysis (tradeoff analysis, quality, attributes…) Programming Methods /Languages Configuration Management Test and Verification Customer support, Maintenance Software engineering and Scientific Methods
What is then Software Engineering Research? • Analyzing natures of problems and their solutions • Finding more general principles that SE can use • Developing methods and tools • Implementing principles on new problem domains • …… Software engineering and Scientific Methods
Software Engineering Research • Different methods used SE • Exemplified by Software Architecture • Presentation extracted from Mary Show’s presentation on ICSE 2001 in Toronto http://www-2.cs.cmu.edu/~Compose/paper_abstracts/etaps-2002.html Software engineering and Scientific Methods
? REAL WORLD Practical problem REAL WORLD Practical Solution Software engineering and Scientific Methods
Research Model Software engineering and Scientific Methods
Example: Software Architecture • The software architecture of a program or computing system is the structure or structures of the system, which comprise software components, the externally visible properties of those components and the relationships among them L. Bass, P. Clements, R. Kazman, Software Architecture In Practise, Addison Wesley, 1998 Software engineering and Scientific Methods
Software architecture – system decomposition System Subsystem subsystem component component component Software engineering and Scientific Methods
Next step - Architectural Style • Recurring structures that occur in software systems AS = {Component types,Connector types,Constraints} Component Component and Connector and Connector Types Types Pipe and Filter Shared Repository Layered Abstract Machines Buss Software engineering and Scientific Methods
Next step: Aspects of Software Architecture • Elements and Form Attachment Connector Arch Component Representation Role Port (sub)System • Rationale • Describes how the architecture satisfies system requirements for both functional and extra-functional properties. Software engineering and Scientific Methods
IComA IComA IComB <<subsystem>> ComA <<subsystem>> ComC <<subsystem>> ComB Next step: Formalization Example - UML Conceptual Architecture Software engineering and Scientific Methods
Research Results • Result Validation SE Research phases • Research Questions Software engineering and Scientific Methods