Modeling Methods

Modeling Methods
How to structure the problem?

The answer is just Simple, use MODELS

Model
Is a presentation of reality. Just a picture is worth a thousand of words, most system models are pictorial representations AN of reality. PL
SA R OO L EF L MP

Models
Logical Models
Show what a system is or does? Other names: Essential model Conceptual model Business model

Physical Models
Show not only what a system is or does? But also how the system is implemented. Other names: Implementation Model Technical model

including other information systems. Context Diagram Illustrate the system’s interface to the business and outside world. and procedures to be implemented by a system’s Processes. policies.Process Modeling Process Modeling Is a technique for organizing and documenting the structure and flow of data through a system’s Processes . .

Member Application Admission card Library System Supplier System boundary Whole system as one process Librarian E.g.Process Modeling… Context Diagram… Shows the major data flows into and from the application. and the system boundaries. Context Diagram of a Library System .

and the system boundaries. Top level function is then decomposed to its component functions (5-9 typically).Process Modeling… Context Diagram… Shows the top level function defined to cover the scope of the application. . It also shows the major data flows into and from the application.

Document Flow Diagram can be the er Ord Starting point ice Invo Purchasing Dept.Process Modeling… Process Models DFD (data flow diagram) Data flow diagram (DFD) DFD is a tool that depicts the flow of data through a system and the processing performed by that system. Supplier Delivery notes Stores .

creditor. E. etc. supplier. .g.: bank. etc. E.Process Modeling… Gane and Sarson Symbols Rounded rectangle Pay a bill Represent processes or work to be done.: pay a bill. withdraw money.g.. Bank Square Represent external agent..

: payment..g. withdraw. E. E. etc. bill.: bank. There are several competing symbols set for DFDs. supplier. Arrows Represent data flows or input and output. etc The above notation is called “Gane and Sarson”.Process Modeling… Open end box Bank Accounts Represent data store which is some times called files. .g. creditor.

20 Output Salary Rs. 1040 . incoming data flows or conditions. 52.Process Modeling… process A process is work performed on. Feed back 0 Input Payroll Hrs. Rtae Rs. or in response to.

1.1.1 1.2 Process 2 Registration sub System 2.1.2 Sub Process 2.1.1 Process 1.1 Sub Process 1.2 1.2 Process . 0 UCSC System e of nt styl fere ms . processes.Process Modeling… Process Decomposition Is a act of breaking a system into its component subsystems. and sub processes.1 Process 1.1. are dif diagra There ition ompos dec 1 Payroll sub system 1.1.

Decomposition continues until the functions ‘elementary’ level.Process Modeling… Process Decomposition… Advantages Improved… Communication Analysis Design. (cannot be further decomposed) reach .

The account is checked for appropriate balance.Process Modeling… Example: Consider a system in a bank whereby account holders get their withdrawals affected. the cash is paid and the account is updated. . If balance exists. he presents a cheque or withdrawal slip. Whenever an account holder wants to withdraw some cash.

. Processes in the system specification should be specified in such a way that they can be converted to computer program. Use process description methods.Process Modeling… Process Description The name of the process is insufficient to explain the logic to implement the process. How can I? I am Kamal. Hey! Not enough tell more.

Process Modeling… Process Description… Methods of process description • Structured English • Decision Tree If my IT marks more than 70 then grade is Distinction • Decision Table Else if mark more than 40 then Pass Else Fail * >70 IT Subject Distinction * >40 Pass Fail .

1000/= THEN refuse credit ELSE refer to manager ELSE allow credit . Example: IF credit limit exceeded THEN IF Customer has bad payment history THEN refuse credit ELSE IF PURCHASE ABOVE Rs.Process Modeling… Process Descriptions… Structured English Syntax is very similar to block structured languages.

1000/= Refer to Manager Purchase above Rs 1000 Refuse credit Bad payment history Credit limit not exceeded Refuse credit Allow credit .Process Modeling… Process Descriptions… Decision Tree Good payment History Credit limit exceeded Purchase below Rs.

1000/= Y Y Y Y N N N N Y Y N N Y Y N N Y N Y N Y N Y N X X X X X X X X on Ac ti Allow Credit Refuse Refer Manager Y-TRUE N-NOT TRUE X-TAKE ACTION Better way of describing logic involving multiple condition .Process Modeling… Process Descriptions… Decision Table Co nd itio n Credit limit exceeded Good payment history Purchase above Rs.

g. Data flow Represent an input of data to a process or the output of data (or information) from a process Data flow name Data flow symbol Data flow names should be descriptive noun and noun phrases that are singular. E.Process Modeling… Data flows Data flows are the communication between processes and the system environment. Order not Orders .

I have to get up @ 5.m. Control flow name Control flow symbol .Process Modeling… Control flow Represents a condition or non data event that triggers a process.00 a.

Process Modeling… Illegal vs. legal data flow B1 B2 B1 P1 B1 B1 DS1 B1 DS2 B1 DS1 P1 P1 DS1 B1 DS1 DS1 P1 DS1 .

– Whenever an account holder wants to withdraw some cash. he presents a cheque or withdrawal slip. the cash is paid and the account is updated.Process Modeling… Example : DFD – Consider a system in a bank whereby account holders get their withdrawals affected. – If balance exists. . – The account is checked for appropriate balance.

Process Modeling…
Example… Step 1 - Context Diagram
Account Holder Account Holder

Cheque/Withdraw al Slip

Withdrawal Acknowledge

Bank Payment System
Using Gane and Sarson, notation

Process Modeling…
Example… Step 2 - First Level DFD
1 Verify A/C Balance
Cheque/Withdrawal Slip Current Balance Valid Balance Withdrawal Acknowledge

Account Holder

New Balance

Account Holder

Account Master

2 Debit Withdrawal Amount

Data Modeling
A model is a representation of reality.
Logical model • Logical functions describe any changes
of value made by the processes on logical data. •Whereas logical functions more closely mirror the subject world. • Logical DFDs only illustrate what occurs without showing how it occurs.

Physical model • Physical-level functions are closer to the
usage world (real world). • Usually a physical device is used to transform data. E.g. Computer, person, etc. • Physical DFDs show things happen, or the physical components.

Data Modeling… Entity Relationship Diagrams Depicts data in terms of the entities and relationships described by data. Synonyms – entity type and entity class Example: Employee Paris Ball Payment Concepts . Entities An entity is something about which the business needs to store data.

An entity instance is a single occurrence of an entity. Every entity must have an identifier or key to uniquely identify each instance. .Data Modeling… Entity Relationship Diagrams… Entity: is a class of Persons Places Objects Events Concepts about which we need to capture and store data.

EMPLOYEE DEPARTMENT The named rounded rectangle represent the entity.Data Modeling… Entity Relationship Diagrams… Symbol: Consider Martin notations. – . – A line represent the relationship.

and field. It is some time called an identifier. property. …. …. EMPLOYEE NIC_NO Name Address Age …. Sometimes called as element.Data Modeling… Entity Relationship Diagrams… Attribute: is a descriptive property or characteristics of an entity. or group of attributes that assumes a unique value for each entity instance. This person can be identified using his ID number. . A key is an attribute.

composite attribute. Synonyms. concatenated attribute data structure.Data Modeling… Entity Relationship Diagrams… Compound Attribute is one that actually consist of other attributes. Example : Address Street Address City Country Postal Code .

Default – Is the value that will be recorded if not specified by the user. 3.Data Modeling… Entity Relationship Diagrams… The values for each attribute are defined in terms of three properties: 1. Domain – What values an attribute can legitimately take on. . Data type – What type of data can be stored in that attribute. 2.

an EMPLOYEE assigns to a JOB Assigns Person married relation EMPLOYEE JOB .Data Modeling… Entity Relationship Diagrams… Relationships Natural business association that exists between one or more entities May represent an event that links the entities or logical affinity that exits between the entities.. E.g.

Exactly one xa E m : le p or Person married relation .Data Modeling… Entity Relationship Diagrams… Cardinality Defines the minimum and maximum number of occurrences of one entity that may be related to a single occurrences of the other entity.

one or more I may have some friends or none… .Data Modeling… Entity Relationship Diagrams… Cardinality Zero or one I might be married or not… Zero.

More than one I am working on many projects.Data Modeling… Entity Relationship Diagrams… Cardinality… One or more I have to work at least one. or more projects. .

Data Modeling… Entity Relationship Diagrams… Degree Number of entities that participate in the relationship Degree =1 Recursive Relationship – Relationship that exists between different instances of the same entity. Supervise EMPLOYEE .

When two different entities participates in a relationship DEPARTMENT Works for EMPLOYEE .Data Modeling… Entity Relationship Diagrams… Degree… Degree =2 Binary Relationship .

ASSIGNMENT EMPLOYEE LOCATION .Data Modeling… Entity Relationship Diagrams… Degree… PROJECT Degree =3 Ternary or 3-ary Relationship When more than two different entities participates in a relationship.

all three components are integrated together into objects. .Object Modeling Introduction The object oriented approach differs from structured systems analysis and design. E-R diagrams or process descriptions. Thus. rather than modeling systems by data flows.

Object Modeling Introduction… In Object Analysis you do not need to think in terms of building one large system. . Such objects exchange messages between themselves to achieve a global goal of the large system. Instead we identify objects as independent entities having their own local goals.

Objects have recognizable identities or properties (what it knows) and particular behaviors or methods (What an object does) These identities and behaviors enables us to recognize them as discrete things .Object Modeling Introduction… What is an Object? Objects are the elements through which we understand the world around us.

Object Modeling Human is an object Behavior • Smile • Run • Walk • Etc s bject o other e ck ar ti all. S B Properties • Skin tone • Height • Weight • Etc .

all three components are integrated together into objects.Object Modeling… Introduction The object oriented approach differs from structured systems analysis and design. rather than modeling systems by data flows. Thus. E-R Model Data model Data flow . E-R diagrams or process descriptions.

Object Modeling… Object-oriented analysis (OOA) OOA is a technique used to: Reuse existing components Reuse Define new or modified objects that will be combined with existing objects New Modify In order to produce useful business computing application. .

Class room Identified objects in class room Teacher Book Etc… Chair Student .Object Modeling… Object modeling (OM) OM is a technique for identifying objects within the systems environment and the relationships between those objects.

… Book ISBN author type title copyright Student Name Age Grade Smile ( ) Run ( ) Study ( ) Open() Close() de u St n s la tC s ok Bo s la C s . A class is sometimes referred to as an object class.Class Object Modeling… A class is a set of objects that share common attributes and behavior.

Object Modeling… Generalization/Specialization Person Name Age Gender Smile ( ) Run ( ) Eat ( ) Person Teacher Student Generalization/specializa tion is a technique wherein the attributes and behaviors that are common to several types of object classes are grouped into their own class. called a supertype. The attributes and methods of the supertype object class are then inherited by those object classes. .

Object Modeling… Generalization/Specialization… Person Name Age Gender Smile ( ) Run ( ) Eat ( ) Person A class supertype is an object class whose instances store attributes that are common to one or more class subtypes of the object. Teacher Student .

and then add other attributes that are unique to an instance of the subtype.Object Modeling… Generalization/Specialization… Person Name Age Gender Smile ( ) Run ( ) Eat ( ) Person A class subtype is an object class whose instances inherit some common attributes from a class supertype. Student Teacher .

Object Modeling… Generalization/Specialization… Example: Supertype Subtype Department Staff Academic Staff Postgraduate Student Non Academic Staff Under Graduate .

P No: Address Submit() Sent() Student Name ID T.Object Modeling… Department Generalization/Specialization… Name ID T.P No: Address Approval() Sent() Receive() Arrowhead indicates Generalization/ Specialization relationship Staff Name ID T.P No: Address Schedule set() Lecture() UML Representation of Generalization/Specialization .

• Although objects can be developed independently of other objects. they also have a relationship to other objects.Object Modeling… Object/Class relationship is a natural business association that exists between one or more objects/classes. • One such relationship is to use a link directly from one object to another : Association 1 Studies 1* Class Student Example: There are many student in the each class .

Object Modeling… Multiplicity Multiplicity defines how many instances of one object/class can be associated with one instance of another object/class. Library 1 1* Books g vin ha s ook of b t a lo e ll th A y rar lib .

Object Modeling… Multiplicity… Exactly one .1 Employee Works for 1 Department I am working for one and only department Employee Works for Department 1 or leave blank .

* Some customers are paying much but some are not Customer Makes 0.* Payment Customer Makes * Payment .Object Modeling… Multiplicity… Zero or more – 0...

1 Spouse I am not married ..1 I am married Employee Has 0..Object Modeling… Multiplicity… Zero or one – 0.

* Course University Offers ..* We offer one or more courses 1.Object Modeling… Multiplicity… One or more – 1..

.9 Games Game In year 2004 BRAZIL have to play 7.. 8.Object Modeling… Multiplicity… Specific range – 7.9 d le u ed ch s We have to play 7 to 9 games in 2004 Team as H 7. or 9 games Brazil 2004 .

.Indicates Composition Aggregation Relationship SA fo r D BI T 1.Object Modeling… Aggregation Relationship Composition Aggregation Relationship 1.* Book Chapter Black filled diamond ..* There are no books without chapter .

* Player 0.Object Modeling… Aggregation Relationship… Shared Aggregation Relationship Diamond without filled 0..* Indicates shared Aggregation Relationship Team may have Ronaldo or not ..* Team 0..

Object Modeling… Message A Message is passed when one object invokes one or more of another object’s methods to request information or some action. Catch the cat The catch message call catch() method of dog then the catch method automatically call the run method. Dog can run & catch .

Polymorphism means “many forms” applied to object oriented technique. sl id in g O pe n a do or .Object Modeling… Polymorphism It mean that the same named behavior may be completed differently for different objects.

Example: Well known Housing industry where they use lot of diagrams. FLOOR PLAN ARCHITECTURAL PLAN ELEVATION . UML – Diagrams Gives five different groups of diagrams to model a system.Object Modeling… Unified Modeling Language (UML) Only a notation that is now widely accepted as a standard for object modeling. These deferent diagrams provides the development team a deferent perspective of the information system.

Object Modeling… UML – Diagrams… Use Case Diagrams Graphically describe who will use the systems and in what ways the user expects to interact with the system. .

.Object Modeling… UML – Diagrams… Class Diagrams Shows object classes that the system is composed of as well as the relationship between those objects.

but instead of depicting object classes.Object Modeling… UML – Diagrams… Object Diagrams Similar to class diagrams. Provide snap shot of the system’s objects at one point in time . they model actual object instances.

.Object Modeling… UML – Diagrams… Sequence Diagram Graphically depict how object interact with each other via messages in the execution of a use case or operation.

Object Modeling… UML – Diagrams… Collaboration Diagrams Similar to sequence diagrams but do not focus on the timing or sequence of messages. . Instead they represent the interaction between the objects in a network format.

During the life cycle the object can change to various states. They illustrate an objects life cycle. .Object Modeling… UML – Diagrams… State Diagrams Use to model the dynamic behavior of particular model.

Object Modeling… UML – Diagrams… Activity Diagrams Graphically depict the sequential flow of activities of either a business process or use case. .

.Object Modeling… UML – Diagrams… Components Diagrams Used to graphically depict the physical architecture of the system.

.Object Modeling… UML – Diagrams… Deployment Diagrams Describe the physical architecture of the hardware and software in the system.

Sign up to vote on this title
UsefulNot useful