1 / 39

Discover the Modeler in You! – Using Models to Engineer Software

Discover the Modeler in You! – Using Models to Engineer Software. ______________________ Devon M. Simmonds CIS 2046 Computer Science Department University of North Carolina Wilmington simmondsd[@]uncw.edu _____________________________________________________________. Outline.

len
Télécharger la présentation

Discover the Modeler in You! – Using Models to Engineer Software

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Discover the Modeler in You! – Using Models to Engineer Software ______________________ Devon M. Simmonds CIS 2046 Computer Science Department University of North Carolina Wilmington simmondsd[@]uncw.edu _____________________________________________________________

  2. Outline • What is computer science • Problems with solving computing problems • What is software engineering • Engineering software using models

  3. Motivation • Computer science - solving problems with the aid of a computer • Computers are everywhere!

  4. Computer are everywhere!

  5. Motivation • And there are good computer jokes! “Witness testifies on Software Security”

  6. Motivation • And there are good computer jokes! “Witness testifies on Software Speed”

  7. The communication problem ??? • Solving problems with the aid of a computer • instruct the computer to do what we want ? • Humans communicate through naturallanguages: English, Spanish, French, etc. • The computer has its own language! • Bits and bytes, 0’s and 1’s – machine language • So humans and computers speak different languages! • 1st Problem: • How do we give instructions to a computer to do what we want it to do if we speak different languages?

  8. ??? Motivation Employ an Interpreter • What language should the interpreter speak? • Human language • Machine language • Interpreter translates human language into machine language • 2nd Problem: • Human language is ambiguous!

  9. Motivation Programming language Machine language • Solution to 2nd Problem: • Since human language is ambiguous: • Create a language for writing instructionsfor a computer – programming language • Interpreter translates instructions written in a programming language into machine code. • The process of writing instructions for a computer to execute is called programming. • The written instructions is called a program. Interpreter

  10. Writing Programs PEOPLE COMPUTER Communication? Programming language Machine language • Large software systems: 4 x 106 – 100 x 106

  11. ENIAC I - 1946 Hardware vs. Software • The early decades (40s – 60s) • Main focus of attention - computer hardware. • Building faster, simpler, and, more efficient machines. Modern Supercomputer

  12. Software problems • Inability to predict time, effort, and costs. • Projects were often late and ran over budget because there was little experience on which to base predictions • Inability to deliver quality software. • Customers and developers accept that software will always have defects • Software products are released with known “list of bugs” • Lack of enough competent software developers

  13. Wilmington network A Chapel Hill Charlotte C B Rising software complexity! • Complex, critical systems are pervasive! • Quality of life issues • Consequences of errors are far-reaching • Consequences of errors are far-reaching • Consequences of errors are far-reaching

  14. Software Development Mishap:Long-distance phone traffic routing …switch (caseIndex) {case‘A’: route = routeA; … break; …case‘M’: route = routeM;case‘N’: route = routeN; … break;…} Missing break statement Result:Loss of long-distance service in NE USA Cost of approx. $800 M (1990)

  15. Software Development Mishap • Problem: • Patients were given massive overdoses of radiation • Cause: • Safety of software not considered • Software reused without testing • No architectural model. • Result:at least 5 deaths! The radiation therapy: Therac 25 Machine

  16. Help! Help!

  17. Building software pyramids • Building complex software with current tools is akin to building pyramids in ancient Egypt • Or cathedrals in medieval times…

  18. Engineering Software • Computer science - solving problems with the aid of a computer • Artificial intelligence • Database management systems • Distributed systems • Computer graphics • Operating systems • Software engineering

  19. What is engineering? • Engineering is … • The application of scientific principles and methods to the construction of useful structures & machines • Examples • Mechanical engineering • Civil engineering • Chemical engineering • Electrical engineering • Nuclear engineering • Aeronautical engineering

  20. What is Software Engineering (SE)? • Software Engineering is concerned with development of complex systems that are built by teams of developers. • SE techniques are not intended for small problems (e.g., writing a program for sorting a list of numbers). • On the other hand, SE builds upon programming techniques; a good software engineer must also be a good programmer. • SE research focuses on developing mechanisms and methods that help developers manage system complexity.

  21. What is SE? • The establishment and use of sound engineering principles in order to obtain economically software that is reliable and works efficiently on real machines. Bauer/Pressman

  22. Software Design Requirements Analysis Implementation Systems Engineering Testing Deployment Evolution The Software Engineering Lifecycle • The process/activities of developing and evolving software

  23. The Software Engineering Lifecycle • Systems Engineering • Identify needs/problems • Allocation of roles • Hardware • Procedures • Software • Feasibility studies Software Design Requirements Analysis Implementation Systems Engineering Testing Deployment Evolution

  24. The Software Engineering Lifecycle • Requirements Analysis • Define goals, objectives, features of target software Software Design Requirements Analysis Implementation Systems Engineering • Identify needs, problems and allocate roles Testing Deployment Evolution

  25. The Software Engineering Lifecycle • Software design • Creating a blueprint for building the software • Architectural design • Subsystem design • Detailed design • Procedural Design • User Interface Design • Database Design • Data Structures Design • Test case design Software Design Requirements Analysis Implementation Systems Engineering • Define software features • Identify needs, problems and allocate roles Testing Deployment Evolution

  26. The Software Engineering Lifecycle • Implementation • Creating the finished product – the program • Coding • Writing code for the classes and operations • Generate object code • Create Test cases • Create user manuals Software Design Requirements Analysis Implementation • Create blueprint Systems Engineering • Define software features • Identify needs, problems and allocate roles Testing Deployment Evolution

  27. The Software Engineering Lifecycle • Testing • Determining if the software has errors/fulfils its requirements • Test planning • Unit testing • Subsystem testing • Integration testing • Regression testing • Test case design Software Design • Create code Requirements Analysis Implementation • Create blueprint Systems Engineering • Define software features • Identify needs, problems and allocate roles Testing Deployment Evolution

  28. The Software Engineering Lifecycle • Deployment • Making the software available for use • Deployment/installation planning • Develop documentation • Hardware configuration • Installation • Software distribution • Training Software Design • Create code Requirements Analysis Implementation • Create blueprint Systems Engineering • Define software features • Identify needs, problems and allocate roles Testing Deployment • Uncovering errors Evolution

  29. The Software Engineering Lifecycle • Evolution • Managing the software • Configuration management • Controlling change as software evolves • Technical support • Software lifecycle activities Software Design • Create code Requirements Analysis Implementation • Create blueprint Systems Engineering • Define software features • Identify needs, problems and allocate roles Testing Deployment • Uncover errors Evolution • Make software available for use

  30. The Software Lifecycle • General activities • Project management • Software estimation & scheduling • Training • Configuration management Software Design Requirements Analysis Implementation Systems Engineering Testing Deployment Evolution

  31. 1.1 1.2 2.0 4.0 1.3 2.1 2.2 1.4 3.0 1.5 3.1 Configuration Management in Action 1.0

  32. A - Making a V-cut. • B - Receiving Inside Hand-off. Roy Williams Models in Engineering • Benefits of models • Help us understand and manage complex systems • Communicate understanding • Drive implementation • Save resources Engineering is aModel-Driven Discipline!

  33. Model Driven Architecture (MDA) • An initiative to address pervasive middleware features [From OMG website]

  34. CompileModel CreateModel Need modelcompiler Model of the Program A C B Binary instructions Code-centric Development Model-Driven Development (MDD) Using programminglanguage Manually Create Code • Realizing the dream – MDD challenges • Abstraction: specifying models • Model Transformation: creating new models from existing models • Code Generation: generating code from models, i.e. compiling models • Managing middleware: supporting model portability, reusability, etc. • Analysis: determining properties of models Code Using modelinglanguage CompileCode

  35. CreateModel Model A Model B A M A K C C B B P Binary instructions Model-Driven Development (MDD) CompileModel Code class Student { private:       int age;      char name[40]; Address address; public:      void move();      void speak(); } CompileCode

  36. Application program Middleware Transaction management Fault tolerance Security Application program Application program Naming Concurrency Operating System Operating System Replication Query Computer Hardware Computer Hardware Event Quality of service MDD & Middleware • Many middleware technologies • .Net, EJB, SOAP, COM, CORBA, Jini, • Software require many middleware technologies • Middleware technologies evolve • Changing Middleware in code is difficult

  37. Automation: creating models Matlab Simulimk Modeling Languages Together

  38. Bridgepoint codegen Model B M A C K B P Code Generation class Department { private:           char name[40]; Student csc[100]; public:      void manageStudents(){ csc[i]->register(); … csc[i]->grade(); … csc[i]->graduate(); }} OptimalJ

  39. Qu es ti ons? ______________________ Devon M. Simmonds Computer Science Department University of North Carolina Wilmington _____________________________________________________________

More Related