Exam Fall 2013 Proposed Solution

Slides:



Advertisements
Similar presentations
Testing Relational Database
Advertisements

Preparing a Decision Table
Introduction to Programming and Software Development CMPCD1017 Session 3:Requirements Analysis and Specification, Cont’d.
1.2 Row Reduction and Echelon Forms
CAP 252 Lecture Topic: Requirement Analysis Class Exercise: Use Cases.
CSCI 639 Topics in Software Engineering Assignment #5 Fall 2008.
Hash Tables1 Part E Hash Tables  
DT211 Stage 2 Databases Lab 1. Get to know SQL Server SQL server has 2 parts: –A client, running on your machine, in the lab. You access the database.
Systems Analysis I Data Flow Diagrams
ITIL Problem Management Tool Guide Gerald M. Guglielmo ITIL Problem Manager CD-doc
Microsoft Office Word 2013 Expert Microsoft Office Word 2013 Expert Courseware # 3251 Lesson 4: Working with Forms.
11 Chapter 4 LOOPS AND FILES. 22 THE INCREMENT AND DECREMENT OPERATORS To increment a variable means to increase its value by one. To decrement a variable.
The Project AH Computing. Functional Requirements  What the product must do!  Examples attractive welcome screen all options available as clickable.
Internet Banking Standard and Standard-Hybrid Registration Intuit Financial Services University Internet Banking Certification Training.
CC0002NI – Computer Programming Computer Programming Er. Saroj Sharan Regmi Week 7.
Project Analysis Course ( ) Week 2 Activities.
Implementation Yaodong Bi. Introduction to Implementation Purposes of Implementation – Plan the system integrations required in each iteration – Distribute.
Schulich School of Medicine & Dentistry Acuity STAR v5.1 Instructor Led Intermediate Level User Training Version 5.1b (December 2010)
JAVA COLLECTIONS LIBRARY School of Engineering and Computer Science, Victoria University of Wellington COMP T2, Lecture 2 Marcus Frean.
Discussion of the main data management or database building issues that may be involved in the early stages of designing a new multicentre, clinical trial.
Lecture 7 Integrity & Veracity UFCE8K-15-M: Data Management.
Excel CREATING A WORKSHEET AND CHART. Personal Budget Worksheet We will create a personal budget worksheet that shows you income each month and your expenses.
ICS 145B -- L. Bic1 Project: Main Memory Management Textbook: pages ICS 145B L. Bic.
Final Exam Review Closed book Closed laptop One sheet of notes permitted SE-0010 Dr. Mark L. Hornick 1.
1. To start the process, Warehouse Stationery (WSL) will invite you to use The Warehouse Group Supplier Electronic Portal and will send you the link to.
Copyright: ©2005 by Elsevier Inc. All rights reserved. 1 Chapter - 2 Basics of Sound Structure Author: Graeme C. Simsion and Graham C. Witt.
(Spring 2015) Instructor: Craig Duckett Lecture 10: Tuesday, May 12, 2015 Mere Mortals Chap. 7 Summary, Team Work Time 1.
1 Tutorial 12 Working with Namespaces Combining XML Vocabularies in a Compound Document.
© 2004 Goodrich, Tamassia Hash Tables1  
Office of Housing Choice Voucher Program Voucher Management System – VMS Version Released October 2011.
Object-Oriented Analysis and Design Use cases Finding classes Collaboration and Sequence diagrams Associations between classes.
Software Requirements Specification Document (SRS)
Medical Eligibility Verifications 1. Medical Eligibility: Verifications Introduction After completing this course, you will be able to: Recognize shared.
Chapter 15 Running Time Analysis. Topics Orders of Magnitude and Big-Oh Notation Running Time Analysis of Algorithms –Counting Statements –Evaluating.
Getting Ready for the NOCTI test April 30, Study checklist #1 Analyze Programming Problems and Flowchart Solutions Study Checklist.
Defects of UML Yang Yichuan. For the Presentation Something you know Instead of lots of new stuff. Cases Instead of Concepts. Methodology instead of the.
Arrays Chapter 7.
Jan Pettersen Nytun, UIA, page 1 Knowledge Representation Part IV The Semantics Web Starting with XML Jan Pettersen Nytun, UiA.
MagicDraw - OCL Validation
Chapter 5 System modeling
ITEC 630 Final Examination Spring 2015
(Winter 2017) Instructor: Craig Duckett
Containers and Lists CIS 40 – Introduction to Programming in Python
Creating Clinical Notes in ZIMS R2
Timing Model Start Simulation Delay Update Signals Execute Processes
Counted Loops.
PubMed Search Options (Basic Course: Module 6)
Arrays, For loop While loop Do while loop
Optimizing Efficiency + Funding
Proposed Solution To Parts Of
Teaching slides Chapter 8.
HEADLINE – Make it interesting
Abstract Class As per dictionary, abstraction is the quality of dealing with ideas rather than events. For example, when you consider the case of ,
CH 9.2 : Hash Tables Acknowledgement: These slides are adapted from slides provided with Data Structures and Algorithms in C++, Goodrich, Tamassia and.
Linear Equations in Linear Algebra
SCViSiON Salumatics Coding Viewer Users Guide
Exam Fall 2012 Proposed Solution
Chapter 2 Modeling Data in the Organization
Exam Fall 2014 Proposed Solution
CH 9.2 : Hash Tables Acknowledgement: These slides are adapted from slides provided with Data Structures and Algorithms in C++, Goodrich, Tamassia and.
Information System Analysis
CS 8532: Advanced Software Engineering
PubMed Search Options (Basic Course: Module 6)
Data Structures & Algorithms
PubMed Search Options (Basic Course: Module 6)
PubMed Search Options and Review (Basic Course: Module 6)
CS210- Lecture 16 July 11, 2005 Agenda Maps and Dictionaries Map ADT
Linear Equations in Linear Algebra
Therapy Guide July 2019.
Presentation transcript:

Exam Fall 2013 Proposed Solution Jan Pettersen Nytun Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA 1 enrolled * - enrolment 1 Student Enrolment Seminar - off - enrolment * - in - name : String - studentId : String - seminarName : String - maxStudents : int - numberOfStudents : int Propose Java code that correspond to the class diagram. - waiting * + addStudent(s:Student):void + getSeminarName():String - waitingOn * onWaitingList 1a – “package enrolment” may be omitted! Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA 1 enrolled * - enrolment 1 Student Enrolment Seminar - off - enrolment * - in - name : String - studentId : String - seminarName : String - maxStudents : int - numberOfStudents : int - waiting * + addStudent(s:Student):void + getSeminarName():String - waitingOn * onWaitingList 1b – Propose an object diagram that conforms to the class diagram above – it should contain information about 2 students that are enrolled at the same seminar. The seminar in question can take maximum 2 students (see attribute maxStudents) and a third student has been put on a waiting list (see association onWaitingList). Fill in slot values that you chose your selves (e.g., choose names for the students). Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA 1 enrolled * - enrolment 1 Student Enrolment Seminar - off - enrolment * - in - name : String - studentId : String - seminarName : String - maxStudents : int - numberOfStudents : int - waiting * + addStudent(s:Student):void + getSeminarName():String - waitingOn * onWaitingList off enrol- ment :Student e1:Enrolment :Seminar name = “Ola” studentId = “100” enrol- ment in seminarName = “RDF” maxStudents = 2 numberOfStudents = 2 in off :Student waitingOn e2:Enrolment :onWaitingList name = “Kari” studentId = “99” enrol- ment enrol- ment waiting :Student name = “Olga” studentId = “101” Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA 1c - Propose an XML document that in some way contains the information of the object diagram above. off enrol- ment :Student e1:Enrolment :Seminar name = “Ola” studentId = “100” enrol- ment in seminarName = “RDF” maxStudents = 2 numberOfStudents = 2 in off :Student waitingOn e2:Enrolment :onWaitingList name = “Kari” studentId = “99” enrol- ment enrol- ment waiting :Student name = “Olga” studentId = “101” <?xml version="1.0"?> <Student name = “Kari” studentId = “99” /> <Student name = “Ola” studentId = “100” /> <Student name = “Olga” studentId = “101” /> <Seminar seminarName= “RDF“ maxStudents= “2” numberOfStudents= “2” > <Enrolment studentId= “99” /> <Enrolment studentId= “100” /> <onWaitingList studentId= “101” /> </ Seminar> One may drop the numberOfStudents and just count entrolments inside the Seminar element. Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA 1d - Do the same as above (i.e., point c), but instead of an XML document, show the content in the form of tables as you find them in relational databases (show table names, column names and data). off enrol- ment :Student e1:Enrolment :Seminar name = “Ola” studentId = “100” enrol- ment in seminarName = “RDF” maxStudents = 2 numberOfStudents = 2 in off :Student waitingOn :onWaitingList e2:Enrolment name = “Kari” studentId = “99” enrol- ment enrol- ment waiting :Student name = “Olga” studentId = “101” Assuming seminar name is unique. Table: Student studentId name Table: Enrolment Table: Seminar 99 Kari studentId seminarName seminarName maxStudents numberOfStudents 100 Ola 99 RDF RDF 2 2 101 Olga 100 RDF Table: WaitingList studentId seminarName Jan Pettersen Nytun - UiA 101 RDF

Jan Pettersen Nytun - UiA 1 enrolled * - enrolment 1 Student Enrolment Seminar - off - enrolment * - in - name : String - studentId : String - seminarName : String - maxStudents : int - numberOfStudents : int * - waiting + addStudent(s:Student):void + getSeminarName():String - waitingOn * onWaitingList 1e) Write an OCL constraint that states that: The number of enrolled students (i.e., number of links from a Seminar object to Enrolment objects) is the same as the value of the numberOfStudents slot of the Seminar object. context Seminar inv: numberOfStudents = enrolment->size() 1f) Write an OCL constraint that states that a student cannot be enrolled for a seminar and at the same time be on the waiting list of the seminar. context Seminar inv: waiting->forAll( stud | self.enrolment.off->excludes(stud)) 1g) Write an OCL constraint that states that there can be no students on waiting list if there is less students enrolled than the value of maxStudents. context Seminar inv: (numberOfStudents < maxStudents) implies (waiting->size() = 0) Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA 1 enrolled Student * - enrolment 1 Enrolment Seminar - off - enrolment * - in - name : String - studentId : String - seminarName : String - maxStudents : int - numberOfStudents : int * - waitingOn - waiting * onWaitingList + addStudent(s:Student):void + getSeminarName():String + addSeminarFullListener( listener : Seminar- FullListener):void -seminarToHandle 1 Some student will probably omit init() – since it is not part of the observer pattern. * «interface» SeminarFullListener + seminarFull() : void FullSeminarHandler + init(sem : seminar) : void + seminarFull() : void 1h) When a seminar gets full, operation seminarFull() in class FullSeminarHandler should be called. Use the observer design pattern with interface and make a class diagram for handling this. (The class diagram should extend the class diagram given above (i.e., the one containing Student, etc.) and contain class FullSeminarhandler.) When seminarFull() is called it will get hold of the seminar name (and in some way prompt a user, but you do not need to care about the prompting of the user). Add classes, interfaces, associations, etc., as you see necessary. You must also make a sequence diagram showing how this is meant to work. (The observer design pattern corresponds to the Listener-pattern found in Java.) Jan Pettersen Nytun - UiA

handler:FullSeminarHandler 1h) – Continues… handler:FullSeminarHandler sem:Seminar init(sem) addSeminarFullListener(self) addStudent(s) alt [numberOfStudents = maxStudents and waiting->size = 0] seminarFull() getSeminarName(self) [else] Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA 2 Nurses need to document the nursing process in regard to individual patients. The nursing process is about doing observations followed by appropriate nursing actions. We choose a nursing process model with the following phases:   Diagnosis (what is the problem?) Planning (how to manage the problem) Implementation (putting plan into action) Evaluation (did the plan work?) Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA 2 continues… Descriptions of the different stages all fit in a patient journal. We consider the process to be sequential and iterative; in practise this means that a patient journal will be structured as follows:   First iteration: Diagnosis (first diagnosis) Planning (first planning) Implementation (first implementation) Evaluation (first evaluation) Second iteration: Diagnosis (second diagnosis) Planning (second planning) Implementation (second implementation) Evaluation (second evaluation) Third iteration: Diagnosis (third diagnosis) Etc. Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA 2 continues… Not all iterations contain all the four phases (e.g., the evaluation phase may be left out). For now we consider the description of one nursing phase to simply be a short text; information about which nurse inserted such a description should be recorded. Name and social security number of the nurses involved are to be recorded. The same information about the patient should also be recorded. Additionally information about what institution (e.g., hospital, nursing home) the description was inserted at should be recorded. Name and address of an institution should be recorded. A patient has one patient journal that is accessible at all institutions. Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA Person Propose a class diagram capturing the information above. name : String SSN : String insertedBy Nurse Patient 1 concerns 1 1 * 1 Iteration PatientJournal iterationNum : Integer 1 0..4 * insertedAt Phase Institution * 1 description : String name : String address : String Diagnosis Plan Implementation Evaluation Jan Pettersen Nytun - UiA

b) Propose an object diagram that conforms to your class diagram above – the object diagram should exemplify two iterations of the process for one patient; the iterations contain all the phases (diagnosis, planning, etc.). You select yourselves the text describing the phases. The phases have been entered by two different nurses working at two different institutions (your object diagram should also show this).

Patient name = “Ola” SSN = 1 concerns : PatientJournal : Iteration : Institution : Iteration iterationNum = 110 name = “Inst.1” address = “addr. 1” iterationNum = 111 : Diagnosis : Nurse : Diagnosis description= “diag. 1” description= “diag. 2” name = ”nurse 1” SSN = 2 : Plan : Plan description= “plan 1” : Nurse description= “plan 2” : Implementation name = ”nurse 2” SSN = 3 : Implementation description= “impl. 1” description= “impl. 2” : Evaluation : Institution : Evaluation description= “eval. 1” description= “eval. 2” name = “Inst.2” address = “addr. 2”

Jan Pettersen Nytun - UiA A nursing home is a place of residence for people who require continual nursing care and have significant deficiencies with activities of daily living. When a patient arrives at a nursing home a nurse is assigned as the patient main contact. The main contact determines a diagnosis together with the patient; the diagnosis is described in the patient journal. The main contact then formulates a treatment plan which is also described in the patient journal and approved by the nursing head (the nurse in charge of the nursing home). If the nursing head do not approve the diagnosis or the plan, then the main contact must redo this and once more get the approval of the nursing head (this will be repeated until it gets approved). During daily care the plan is implemented and evaluated by the main contact and the patient. Once a week a new diagnosis and plan is made (this marks the beginning of a new iteration) by the main contact, and once again the nursing head must give approval and the processes continues as just described. Jan Pettersen Nytun - UiA

c) Given the texts above, make a use case diagram and use case texts. The students may add more or less details! patient arrives nursing head patient main contact Use case text: Patient arrives at a nursing home. Nursing head assigns the patients main contact. Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA make diagnosis patient main contact Use case text: Main contact together with patient determines a diagnosis. Main contact describes/updates the diagnosis in the patient journal. Jan Pettersen Nytun - UiA

Main contact makes treatment plan. make treatment plan and get approval of diagnosis and plan main contact nursing head Use case text: Main contact makes treatment plan. Main contact presents diagnosis and treatment plan to nursing head. If approved, main contact describes the treatment plan in the patient journal. If nursing head do not approve treatment plan but accept diagnosis then this current use case must be repeated. Otherwise, if nursing head do not approve diagnosis then use cases “make diagnosis” and “make treatment plan and get approval of diagnosis and plan” must be repeated. Jan Pettersen Nytun - UiA

Jan Pettersen Nytun - UiA daily care “other” patient main contact Use case text: Main contact, together with others, nurse the patient and implement the treatment plan. Main contact continuously update the implementation and evaluation part of the patient journal. When one week has past the main contact initiate use case “make diagnosis”, etc. Jan Pettersen Nytun - UiA

Nursing head assigns the patients main contact. d) Given the text above, make a high level activity diagram describing the activities being described. Patient Arrives. Nursing head assigns the patients main contact.

One Iteration Patient Main Contact Nursing Head Make diagnosis. Diagnosis described/updated in patient journal. Make treatment plan. Investigate treatment plan and diagnosis. Presents diagnosis and treatment plan to nursing head. [diagnosis not approved] [else] [plan not approved] Describe the treatment plan in the patient journal. [plan approved] Implement treatment plan and continuously update the implementation and evaluation part of the patient journal.

Jan Pettersen Nytun - UiA e) To make analysis more effective the description of the different phases should be more structured (i.e., a phase should not be described only with a text). The kind of analysis in question could be: Find if a medicine is working or not in regard to some sickness. Extend or change your model from above (class diagram from point a) so that it becomes explicit that a medicine is used as part of a plan to treat a sickness being a part of the diagnosis; and further on, that the actual medication is documented as part of the implementation. Also, the effect of the medication should be evaluated in regard to the sickness it is meant to treat – such an evaluation should be one of the following statements: “Medicine works well”, “Medicine does not work”, “Medicine has negative effect”. Assume the medication doses are given in milligram. Add classes, associations and make your own assumptions as you see necessary. Jan Pettersen Nytun - UiA

Some of the original classes are not shown since they are not important in regard to this task. The given solution is not very advanced… Some of the multiplicities may be discussed… * 1 Iteration PatientJournal iterationNum : Integer 1 0..4 Phase description : String Diagnosis Planning Implementation Evaluation 1 1 1 * * Sickness ActualMedication 1 description : String doses : Integer description : String * * * Medication Evaluation 1 medicinName: String medicationProcedure : String dosesPrescribed : Integer medicinName: String medicationProcedure : String dosesPrescribed : Integer * * * *