Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

You have been requested to develop a healthcare system with the following charac

ID: 3836067 • Letter: Y

Question

You have been requested to develop a healthcare system with the following characteristics: A hospital plans to build a healthcare system, which manages patient information. A hospital has a CEO, 5 doctors, 5 nurses and 3 staff. A doctor works with his/her nurse for treating a patient. A patient can make an appointment, change, or cancel the appointment by calling a staff in the hospital. When a patient makes an appointment, the patient tells a doctor name to a staff who checks if a doctor is available time from 9 am to 5 pm on a half hourly basis. The appointment is recorded in the system, and updated whenever the patient change or cancel the appointment. An appointment will be cleared when a patient visits the doctor in the hospital. In case of no-show appointments, the system clears the appointments automatically at 8 pm on a daily basis and charges a penalty $25 to each no-show patient. The hospital does not accept walk-in patients. When a new patient arrives at the hospital, a staff enters to the system the patient information, which includes patient name, address, phone number, email, social security number, and insurance name. Then the staff creates a patient treatment record for the day visit, and adds the record to a list of patients being served by each doctor. For a returning patient, the staff just creates a patient treatment record and adds it to the list of patients for a doctor. A patient treatment record has the patient name, date to visit a doctor, reason to visit a doctor, patient’s weight, height, blood pressure, doctor’s treatment content, and prescription if any. The nurse measures a patient’s weight, height, and blood pressure every time a patient visits a doctor, updating the patient record with the measurements. The nurse also adds the reason of patient’s visit to the doctor to the patient treatment record. A doctor can look at the next patient record before he/she meets a patient. After treating a patient, a doctor updates a patient record with his treatment content and, if any, prescription. A patient pays for the copay of a doctor visit to the staff just after getting a treatment. A patient can pay it by credit/debit/check/cash. In cases of credit or debit card payment, the payment is validated by the card company, and then the company sends back to the hospital a reference number, which is stored with the patient payment information. A patient receives a receipt for the payment. In addition, a patient pays an invoice (except for the copay for a doctor’s visit) for his/her medical services on-line via the healthcare system. The hospital sends to a patient his/her invoice for any medical services using emails. The patient can access his/her account with the invoice number to pay the invoice using a credit or debit card. The system generates a receipt for the patient’s on-line payment and emails it to the patient if the patient wants to receive the receipt using his/her email. The system generates a daily summary report at 9 pm every business day and a monthly report at the end of each month. The report shows the information on doctors’ performance for a day or a month. The report contains each doctor name, the number of patients served by a doctor in a day, and health service income. The monthly report is a summary of daily reports for a month. The daily and monthly reports are stored in the system so that the CEO looks at them any time. The employees in the hospital are allowed to access patient records in the system based on each person’s role, such as CEO, doctor, nurse, and staff. A doctor has all permission on read/write on his patient information and treatment information. A nurse has read/write permission on his/her patient information and treatment information, but he/she cannot write treatment. A doctor or nurse can access only his/her patients’ records. A doctor and a nurse are a pair who works together. A staff can create, read/write patient information, create a patient treatment record, and read/write patient payment information. The CEO can look at the daily and monthly reports.

a.) Develop the interaction model (using communication diagram or sequence diagram) that depicts objects participating in each use case and the sequence of interactions among the objects. A use case is modeled using a communication diagram or sequence diagram.

b.) Design the software architectural model for the healthcare system where the model is defined in terms of subsystems and their interactions. Each subsystem should be represented with objects supporting the subsystem. Define the communication styles between subsystems.

c.) Identify the operations of classes using the interaction model in (a).

d.) Design database tables for the healthcare system. Define the relational database tables for the system. Define the primary key and/or secondary key for each database table, and describe data schema for each database table

Explanation / Answer

#include<iostream.h>

#include<conio.h>

#include<string.h>

#include<stdlib.h>

/characterize most extreme number of patients in a line

#define MAXPATIENTS 100

/characterize structure for patient information

struct quiet

{

singe FirstName[50];

singe LastName[50];

singe ID[20];

};

/characterize class for line

class line

{

open:

line (void);

int AddPatientAtEnd (quiet p);

int AddPatientAtBeginning (quiet p);

persistent GetNextPatient (void);

int RemoveDeadPatient (persistent * p);

void OutputList (void);

scorch DepartmentName[50];

private:

int NumberOfPatients;

persistent List[MAXPATIENTS];

};

/announce part works for line

queue::queue ()

{

/constructor

NumberOfPatients = 0;

}

int queue::AddPatientAtEnd (quiet p)

{

/adds a typical patient to the finish of the line.

/returns 1 if fruitful, 0 if line is full.

on the off chance that (NumberOfPatients >= MAXPATIENTS)

{

/line is full

return 0;

}

/put in new patient

else

List[NumberOfPatients] = p; NumberOfPatients++;

return 1;

}

int queue::AddPatientAtBeginning (quiet p)

{

/adds a basically sick patient to the start of the line.

/returns 1 if fruitful, 0 if line is full.

int i;

in the event that (NumberOfPatients >= MAXPATIENTS)

{

/line is full

return 0;

}

/move all patients one position back in line

for (i = NumberOfPatients-1; i >= 0; i- - )

{

List[i+1] = List[i];

}

/put in new patient

List[0] = p; NumberOfPatients++;

return 1;

}

quiet queue::GetNextPatient (void)

{

/gets the patient that is first in the line.

/returns understanding with no ID if line is unfilled

int i; persistent p;

in the event that (NumberOfPatients == 0) {

/line is vacant

strcpy(p.ID,"");

return p;}

/get first patient

p = List[0];

/move every staying understanding one position forward in line

NumberOfPatients- - ;

for (i=0; i<NumberOfPatients; i++)

{

List[i] = List[i+1];

}

/return tolerant

return p;

}

int queue::RemoveDeadPatient (tolerant * p)

{

/expels a patient from line.

/returns 1 if effective, 0 if tolerant not found

int i, j, discovered = 0;

/scan for patient

for (i=0; i<NumberOfPatients; i++)

{

on the off chance that (stricmp(List[i].ID, p->ID) == 0)

{

/tolerant found in line

*p = List[i]; discovered = 1;

/move every single after patient one position forward in line

NumberOfPatients- - ;

for (j=i; j<NumberOfPatients; j++)

{

List[j] = List[j+1];

}

}

}

return found;

}

void queue::OutputList (void)

{

/records whole line on screen

int i;

on the off chance that (NumberOfPatients == 0)

{

cout << "

Line is void";

}

else

{

for (i=0; i<NumberOfPatients; i++)

{

cout << "

" << List[i].FirstName;

cout << " << List[i].LastName;

cout << " << List[i].ID;

}

}

}

/pronounce capacities utilized by primary:

quiet InputPatient (void)

{

/this capacity approaches client for patient information.

quiet p;

cout << "

It would be ideal if you enter information for new patient

To start with name: ";

cin.getline(p.FirstName, sizeof(p.FirstName));

cout << "

Last name: ";

cin.getline(p.LastName, sizeof(p.LastName));

cout << "

Government disability number: ";

cin.getline(p.ID, sizeof(p.ID));

/check if information substantial

on the off chance that (p.FirstName[0]==0 || p.LastName[0]==0 || p.ID[0]==0)

{

/rejected

strcpy(p.ID,"");

cout << "

Mistake: Data not legitimate. Operation wiped out.";

getch();

}

return p;

}

void OutputPatient (tolerant * p)

{

/this capacity yields tolerant information to the screen

on the off chance that (p == NULL || p->ID[0]==0)

{

cout << "

No patient";

return;

}

else

cout << "

Tolerant information:";

cout << "

Initially name: " << p->FirstName;

cout << "

Last name: " << p->LastName;

cout << "

Government disability number: " << p->ID;

}

int ReadNumber()

{

/this capacity peruses a whole number from the console.

/it is utilized on the grounds that contribution with cin >> doesn't work appropriately!

singe buffer[20];

cin.getline(buffer, sizeof(buffer));

return atoi(buffer);

}

void DepartmentMenu (line * q)

{

/this capacity characterizes the UI with menu for one

office

int decision = 0, achievement; quiet p;

while (decision != 6)

{

/clear screen

clrscr();

/print menu

cout << "

Welcome to office: " << q->DepartmentName;

cout << "

It would be ideal if you enter your decision:";

cout << "

1: Add typical patient";

cout << "

2: Add basically sick patient";

cout << "

3: Take out patient for operation";

cout << "

4: Remove dead patient from line";

cout << "

5: List line";

cout << "

6: Change division or exit

";

/get client decision

decision = ReadNumber();

/do showed activity

switch (decision)

{

case 1:/Add typical patient

p = InputPatient();

in the event that (p.ID[0])

{

achievement = q->AddPatientAtEnd(p);

clrscr();

in the event that (achievement)

{

cout << "

Persistent included:

";

}

else

{

/blunder

cout << "

Blunder: The line is full. Can't include persistent:";

}

OutputPatient(&p);

cout << "

Press any key";

getch();

}

break;

case 2:/Add basically sick patient

p = InputPatient();

in the event that (p.ID[0])

{

achievement = q->AddPatientAtBeginning(p);

clrscr();

in the event that (achievement)

{

cout << "

Quiet included:

";

}

else

{

/blunder

cout << "

Blunder: The line is full. Can't include

quiet:";

}

OutputPatient(&p);

cout << "

Press any key";

getch();

}

break;

case 3:/Take out patient for operation

p = q->GetNextPatient();

clrscr();

in the event that (p.ID[0])

{

cout << "

Patient to work:

";

OutputPatient(&p);}

else

{

cout << "

There is no patient to work.";

}

cout << "

Press any key";

getch();

break;

case 4:/Remove dead patient from line

p = InputPatient();

on the off chance that (p.ID[0])

{

achievement = q->RemoveDeadPatient(&p);

clrscr();

in the event that (achievement)

{

cout << "

Persistent evacuated:

";

}

else

{

/blunder

cout << "

Blunder: Cannot discover understanding:

";

}

OutputPatient(&p);

cout << "

Press any key";

getch();

}

break;

case 5:/List line

clrscr();

q->OutputList();

cout << "

Press any key";

getch(); break;

}

}

}

/primary capacity characterizing lines and fundamental menu

void fundamental ()

{

int i, MenuChoice = 0;

/characterize three lines

line departments[3];

/set office names

strcpy (departments[0].DepartmentName, "Heart facility");

strcpy (departments[1].DepartmentName, "Lung facility");

strcpy (departments[2].DepartmentName, "Plastic surgery");

while (MenuChoice != 4)

{

/clear screen

clrscr();

/print menu

cout << "

Welcome to Software City Hospital";

cout << "

If you don't mind enter your decision:

";

for (i = 0; i < 3; i++)

{

/compose menu thing for division i

cout << "

" << (i+1) << ": " << departments[i].DepartmentName;

}

cout << "

4: Exit

";

/get client decision

MenuChoice = ReadNumber();

/is it a division name?

on the off chance that (MenuChoice >= 1 && MenuChoice <= 3)

{

/call submenu for division

/(utilizing pointer mathematics here:)

DepartmentMenu (divisions + (MenuChoice-1));

}

}

}

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote