









Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!










Chapter 3 System modeling 1
Topics covered
Context models
Interaction models
Structural models
Behavioral models
Model-driven engineering
Chapter 3 System modeling 2
System modeling
System modeling is the process of developing abstract models of a system, with each model presenting a different view or perspective of that system.
System modeling has now come to mean representing a system using some kind of graphical notation, which is now almost always based on notations in the Unified Modeling Language (UML).
System modelling helps the analyst to understand the functionality of the system and models are used to communicate with customers.
Chapter 3 System modeling 3
Existing and planned system models
Models of the existing system are used during requirements engineering. They help clarify what the existing system does and can be used as a basis for discussing its strengths and weaknesses. These then lead to requirements for the new system.
Models of the new system are used during requirements engineering to help explain the proposed requirements to other system stakeholders. Engineers use these models to discuss design proposals and to document the system for implementation.
In a model-driven engineering process, it is possible to generate a complete or partial system implementation from the system model. Chapter 3 System modeling 4
Context models
Context models are used to illustrate the operational context of a system - they show what lies outside the system boundaries. System boundaries are established to define what is inside and what is outside the system; They show other systems that are used or depend on the system being developed.
Social and organisational concerns may affect the decision on where to position system boundaries.
Architectural models show the system and its relationship with other systems.
Chapter 3 System modeling 7
The context of the MHC-PMS
Chapter 3 System modeling 8
Interaction models
Modeling user interaction is important as it helps to identify user requirements.
Modeling system-to-system interaction highlights the communication problems that may arise.
Modeling component interaction helps us understand if a proposed system structure is likely to deliver the required system performance and dependability.
Use case diagrams and sequence diagrams may be used for interaction modeling.
Chapter 3 System modeling 9
Use case modeling
Use cases were developed originally to support requirements elicitation and now incorporated into the UML.
Each use case represents a discrete task that involves external interaction with a system.
Use cases describe interactions between a system and external actors
Actors in a use case may be people or other systems.
Represented diagrammatically to provide an overview of the use case and in a more detailed textual form.
Chapter 3 System modeling 10
Sequence diagram for View patient information
Chapter 3 System modeling 13
Sequence diagram for Transfer Data
Chapter 3 System modeling 14
Structural models
Structural models of software display the organization of a system in terms of the components that make up that system and their relationships.
Structural models may be static models, which show the structure of the system design, or dynamic models, which show the organization of the system when it is executing.
You create structural models of a system when you are discussing and designing the system architecture.
Chapter 3 System modeling 15
Class diagrams
Class diagrams are used when developing an object- oriented system model to show the classes in a system and the associations between these classes.
An object class can be thought of as a general definition of one kind of system object.
An association is a link between classes that indicates that there is some relationship between these classes.
When you are developing models during the early stages of the software engineering process, objects represent something in the real world, such as a patient, a prescription, doctor, etc. Chapter 3 System modeling 16
Generalization
In modeling systems, it is often useful to examine the classes in a system to see if there is scope for generalization. If changes are proposed, then you do not have to look at all classes in the system to see if they are affected by the change.
In object-oriented languages, such as Java, generalization is implemented using the class inheritance mechanisms built into the language.
In a generalization, The lower-level classes are subclasses that inherit the attributes and operations from their super-classes. These lower-level classes then add more specific attributes and operations. Chapter 3 System modeling 19
A generalization hierarchy
Chapter 3 System modeling 20
Object class aggregation models
An aggregation model shows how classes that are collections are composed of other classes.
Aggregation models are similar to the part-of relationship in semantic data models.
Chapter 3 System modeling 21
The aggregation association
Behavioral models
Behavioral models are models of the dynamic behavior of a system as it is executing. They show what happens or what is supposed to happen when a system responds to a stimulus from its environment.
You can think of these stimuli as being of two types:
Data Some data arrives that has to be processed by the system. Events Some event happens that triggers system processing. Events may have associated data, although this is not always the case.
Chapter 3 System modeling 22
State machine models
These model the behaviour of the system in response to external and internal events.
They show the system’s responses to stimuli so are often used for modelling real-time systems.
State machine models show system states as nodes and events as arcs between these nodes. When an event occurs, the system moves from one state to another.
Statecharts are an integral part of the UML and are used to represent state machine models.
Chapter 3 System modeling 25
State diagram of a microwave oven
Chapter 3 System modeling 26
Model-driven engineering
Model-driven engineering (MDE) is an approach to software development where models rather than programs are the principal outputs of the development process.
The programs that execute on a hardware/software platform are then generated automatically from the models.
Proponents of MDE argue that this raises the level of abstraction in software engineering so that engineers no longer have to be concerned with programming language details or the specifics of execution platforms.
Chapter 3 System modeling 27
Usage of model-driven engineering
Pros
Allows systems to be considered at higher levels of abstraction Generating code automatically means that it is cheaper to adapt systems to new platforms.
Cons
Models for abstraction and not necessarily right for implementation. Savings from generating code may be outweighed by the costs of developing translators for new platforms.
Chapter 3 System modeling 28
Features of executable UML
To create an executable subset of UML, the number of model types has therefore been dramatically reduced to these 3 key types: Domain models that identify the principal concerns in a system. They are defined using UML class diagrams and include objects, attributes and associations. Class models in which classes are defined, along with their attributes and operations. State models in which a state diagram is associated with each class and is used to describe the life cycle of the class.
The dynamic behavior of the system may be specified declaratively using the object constraint language (OCL), or may be expressed using UML’s action language. Chapter 3 System modeling 31