0% found this document useful (0 votes)
154 views

Nehru Smaraka Vidyalaya Bangalore: Investigatory Project in Computer Science Topic

This document appears to be a student project report on developing a hospital management system. It includes an introduction outlining the need for automating hospital record keeping. It then lists the objectives of creating a system to computerize patient and hospital details, schedule doctors and services, track medical store inventory, and maintain patient test reports and records. It also provides requirements for the software and hardware interfaces needed and describes some key header files used in the code like conio.h for console input/output and stdio.h for standard input/output functions. A flowchart and source code are included to implement the queue data structure and functions for managing patients.

Uploaded by

yajurthejas
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
154 views

Nehru Smaraka Vidyalaya Bangalore: Investigatory Project in Computer Science Topic

This document appears to be a student project report on developing a hospital management system. It includes an introduction outlining the need for automating hospital record keeping. It then lists the objectives of creating a system to computerize patient and hospital details, schedule doctors and services, track medical store inventory, and maintain patient test reports and records. It also provides requirements for the software and hardware interfaces needed and describes some key header files used in the code like conio.h for console input/output and stdio.h for standard input/output functions. A flowchart and source code are included to implement the queue data structure and functions for managing patients.

Uploaded by

yajurthejas
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 24

NEHRU SMARAKA VIDYALAYA

BANGALORE

Investigatory Project in Computer Science


Topic:
Hospital Management System

Submitted to
Mrs. Suma
Submitted by
M. Anjan Yajur
Grade XI

1
NEHRU SMARAKA VIDYALAYA

Certificate
This is to certify that M. Anjan Yajur bona fide
student of class XI has successfully
Completed the project titled Hospital
Management System in the laboratory of Nehru
Smaraka Vidyalaya prescribed by the Central
Board of Secondary Education for the AISSCE for
the year 2018-19

Teacher in–charge HOD Principal

External Examiner
Date:

2
Acknowledgement

I wish to express my gratitude to my


Computer Science teacher who has been
instrumental in helping me complete this
project.

I also wish to express my sincere thanks to


our beloved Principal Dr. Arokia Raj .P, The
Management of BIGI for having changed our
focus from exam-based learning to
knowledge-learning which I now understand
will go a long way in molding my future
ahead for better prospects.

I wish to thank my parents, friends and all


those who have directly or indirectly
contributed towards completion of this
project effectively.

3
Index

1 Introduction 5
2 Objective 6
3 Requirements 7
4 Header Files and Their Purpose 8
5 Flow Chart 9
6 Source Code 10
7 Output 18
8 Limitations 21
9 Conclusion 23
10 Bibliography 24

4
Introduction

Hospital are the essential part of our lives, providing best medical
facilities to people suffering from various ailments, which may be due
to change in climatic conditions, increased workload, emotional trauma
stress etc. It is necessary for the hospitals to keep track of its day-to-
day activities & records of its patients, doctors, nurses, ward boys and
other staff personals that keep the hospital running smoothly &
successfully. But keeping track of all the activities and their records on
paper is very cumbersome and error prone. It also is very inefficient
and a time-consuming process. Observing the continuous increase in
population and number of people visiting the hospital.

Recording and maintaining all these records is highly unreliable,


inefficient and error-prone. It is also not economically & technically
feasible to maintain these records on paper. Thus keeping the working
of the manual system as the basis of our project. We have developed an
automated version of the manual system, named as “Hospital
Management System”.

The main aim of our project is to provide automation of the existing


systems.

5
Objective

The project “Hospital management system” is aimed to develop to


maintain the day –to-day state of admission/discharge of patients, list
of doctors, reports generation, and etc. It is designed to achieve the
following objectives:

To computerize all details regarding patient details & hospital details.

Scheduling the services of specialized doctors and emergency properly


so that facilities provided by hospital are fully utilized in effective and
efficient manner.

If the medical store issues medicines to patients, it should reduce the


stock status of the medical store and vice-versa.

It should be able to handle the test reports of patients conducted in the


pathology lab of the hospital.

The inventory should be updated automatically whenever a transaction


is made.

The information of the patients should be kept up to date and there


record should be kept in the system for historical purposes.

6
Requirements

Software Requirement Specification

A Software requirements specification (SRS), a requirements


specification for a software system, is a complete description of the
behavior of a system to be developed and may include a set of use cases
that describe interactions the users will have with the software. In
addition it also contains non-functional requirements. Non-functional
requirements impose constraints on the design or implementation (such
as performance engineering requirements, quality standards, or design
constraints).

Hardware Interfaces

Processor: Pentium IV AND motherboard

RAM: 512MB or above

Hard Disk: 40GB or above

Input Devices: Keyboard, Mouse

Output Devices: Monitor; -14” VGA

Software Interfaces

Operating System: Windows XP

Front End: Microsoft Visual Basic 6.0

Back End: Microsoft Access

7
Header Files and Their Purpose
Conio.h:- conio.h is a C header file used mostly by MS-DOS compilers
to provide console input/output. It is not part of the C standard library
or ISOC, nor is it defined by POSIX. This header declares several
useful library functions for performing "console input and output" from
a program.

Stdio.h:- is a statement which tells the compiler to insert the contents


of stdio at that particular place.

String.h:-Provides many "string" handling functions. Arguments are


character arrays, or occasionally integers designating a length and/or
location.

Iostream.h:- is used so that we can use ‘cout’ and ‘cin’ in the C++
program. They both are the part of input output library files.

Stdlib.h:- is the header of the general purpose standard library of C


programming language which includes functions involving memory
allocation, process control, conversions and others.

8
Flow Chart

9
Source Code

#include<iostream.h>
#include<conio.h>
#include<string.h>
#include<stdlib.h>
// define maximum number of patients in a queue
#define MAXPATIENTS 100
// define structure for patient data
struct patient
{
char FirstName[50];
char LastName[50];
char ID[20];
};
// define class for queue
class queue
{
public:
queue (void);
int AddPatientAtEnd (patient p);
int AddPatientAtBeginning (patient p);
patient GetNextPatient (void);
int RemoveDeadPatient (patient * p);
void OutputList (void);
char DepartmentName[50];
private:
int NumberOfPatients;
patient List[MAXPATIENTS];
};
// declare member functions for queue
queue::queue ()
{
// constructor
NumberOfPatients = 0;
}
int queue::AddPatientAtEnd (patient p)
{
// adds a normal patient to the end of the queue.
// returns 1 if successful, 0 if queue is full.
if (NumberOfPatients >= MAXPATIENTS)
{

10
// queue is full
return 0;
}
// put in new patient
else
List[NumberOfPatients] = p; NumberOfPatients++;
return 1;
}
int queue::AddPatientAtBeginning (patient p)
{
// adds a critically ill patient to the beginning of the queue.
// returns 1 if successful, 0 if queue is full.
int i;
if (NumberOfPatients >= MAXPATIENTS)
{
// queue is full
return 0;
}
// move all patients one position back in queue
for (i = NumberOfPatients-1; i >= 0; i--)
{
List[i+1] = List[i];
}
// put in new patient
List[0] = p; NumberOfPatients++;
return 1;
}
patient queue::GetNextPatient (void)
{
// gets the patient that is first in the queue.
// returns patient with no ID if queue is empty
int i; patient p;
if (NumberOfPatients == 0)
{
// queue is empty
strcpy(p.ID," ");
return p;
}
// get first patient
p = List[0];
// move all remaining patients one position forward in queue
NumberOfPatients--;
for (i=0; i<NumberOfPatients; i++)

11
{
List[i] = List[i+1];
}
// return patient
return p;
}
int queue::RemoveDeadPatient (patient * p)
{
// removes a patient from queue.
// returns 1 if successful, 0 if patient not found
int i, j, found = 0;
// search for patient
for (i=0; i<NumberOfPatients; i++)
{
if (stricmp(List[i].ID, p->ID) == 0)
{
// patient found in queue
*p = List[i]; found = 1;
// move all following patients one position forward in queue
NumberOfPatients;
for (j=i; j<NumberOfPatients; j++)
{
List[j] = List[j+1];
}
}
}
return found;
}
void queue::OutputList (void)
{
// lists entire queue on screen
int i;
if (NumberOfPatients == 0)
{
cout << "\n Queue is empty";
}
else
{
for (i=0; i<NumberOfPatients; i++)
{
cout << " " << List[i].FirstName;
cout << " " << List[i].LastName;
cout << " " << List[i].ID;

12
}
}
}
// declare functions used by main:
patient InputPatient (void)
{
// this function asks user for patient data.
patient p;
cout << "\n Please enter data for new patient:\n First name: ";
cin.getline(p.FirstName, sizeof(p.FirstName));
cout << "\n Last name: ";
cin.getline(p.LastName, sizeof(p.LastName));
cout << "\n Phone Number: ";
cin.getline(p.ID, sizeof(p.ID));
// check if data valid
if (p.FirstName[0]==0 || p.LastName[0]==0 || p.ID[0]==0)
{
// rejected
strcpy(p.ID," ");
cout << "\n Error: Data not valid. \n Operation cancelled.";
getch();
}
return p;
}
void OutputPatient (patient * p)
{
// this function outputs patient data to the screen
if (p == NULL || p->ID[0]==0)
{
cout << "\n No patient";
return;
}
else
cout << "\n Patient data:";
cout << "\n First name: " << p->FirstName;
cout << "\n Last name: " << p->LastName;
cout << "\n Phone number: " << p->ID;
}
int ReadNumber()
{
// this function reads an integer number from the keyboard.
// it is used because input with cin >> doesn’t work properly!
char buffer[20];

13
cin.getline(buffer, sizeof(buffer));
return atoi(buffer);
}
void DepartmentMenu (queue * q)
{
// this function defines the user interface with menu for one department
int choice = 0, success; patient p;
while (choice != 6)
{
// clear screen
clrscr();
// print menu
cout << "\n Welcome to department: " << q->DepartmentName;
cout << "\n Please enter your choice:";
cout << "\n 1: Add normal patient";
cout << "\n 2: Add critically ill patient";
cout << "\n 3: Take out patient for operation";
cout << "\n 4: Remove dead patient from queue";
cout << "\n 5: List queue";
cout << "\n 6: Change department or exit";
// get user choice
choice = ReadNumber();
// do indicated action
switch (choice)
{
case 1: // Add normal patient
p = InputPatient();
if (p.ID[0])
{
success = q->AddPatientAtEnd(p);
clrscr();
if (success)
{
cout << "\n Patient added:";
}
else
{
// error
cout << "\n Error: The queue is full. Cannot add
patient:";
}
OutputPatient(&p);
cout << "\n Press any key";

14
getch();
}
break;
case 2: // Add critically ill patient
p = InputPatient();
if (p.ID[0])
{
success = q->AddPatientAtBeginning(p);
clrscr();
if (success)
{
cout << "\n Patient added: ";
}
else
{
// error
cout << "\n Error: The queue is full.
Cannot add patient:";
}
OutputPatient(&p);
cout << "\n Press any key";
getch();
}
break;
case 3: // Take out patient for operation
p = q->GetNextPatient();
clrscr();
if (p.ID[0])
{
cout << "\n Patient to operate:";
OutputPatient(&p);
}
else
{
cout << "\n There is no patient to operate.";
}
cout << "\n Press any key";
getch();
break;
case 4: // Remove dead patient from queue
p = InputPatient();
if (p.ID[0])
{

15
success = q->RemoveDeadPatient(&p);
clrscr();
if (success)
{
cout << "\n Patient removed: ";
}
else
{
// error
cout << "\n Error: Cannot find patient: ";
}
OutputPatient(&p);
cout << "\n Press any key";
getch();
}
break;
case 5: // List queue
clrscr();
q->OutputList();
cout << "\n Press any key";
getch();
break;
}
}
}
// main function defining queues and main menu
void main ()
{
int i, MenuChoice = 0;
// define three queues
queue departments[3];
// set department names
strcpy (departments[0].DepartmentName, "Cardiology");
strcpy (departments[1].DepartmentName, "Pulmonary");
strcpy (departments[2].DepartmentName, "Plastic surgery");
while (MenuChoice != 4)
{
// clear screen
clrscr();
// print menu
cout << "\n Welcome to Bengaluru Hospital";
cout << "\n Please enter your choice:";
for (i = 0; i < 3; i++)

16
{
// write menu item for department i
cout << " " << (i+1) << " : "
<<departments[i].DepartmentName;
}
cout << "\n 4: Exit";
// get user choice
MenuChoice = ReadNumber();
// is it a department name?
if (MenuChoice >= 1 && MenuChoice <= 3)
{
// call submenu for department
// (using pointer arithmetics here:)
DepartmentMenu (departments + (MenuChoice-1));
}
}
}

17
Output

18
19
20
Limitations

The main limitation of the previous system of Hospital Management


System:

● The existing system only provides text-based interface, which is not


as user-friendly as Graphical user Interface.

● Since the system is implemented in Manual, so the response is very


slow.

● The transactions are executed in offline mode, hence online data


capture and modification is not possible.

● Off-line reports cannot be generated due to batch mode execution.


Hence, there is a need of reformation of the system with more
advantages and flexibility. The Library Management System
eliminates most of the limitations of the existing software.

It has the following objectives:

● Enhancement:

The main objective of Library Management System is to


enhance and upgrade the existing system by increasing its
efficiency and effectiveness. The software improves the
working methods by replacing the existing manual system
with the computer-based system.

21
● Automation:

The Library Management System automates each and every


activity of the manual system and increases its throughput.
Thus the response time of the system is very less and it
works very fast.

● Accuracy:

The Library Management System provides the uses a quick


response with very accurate information regarding the users
etc. Any details or system in an accurate manner, as and
when required.

● User-Friendly:

The software Library Management System has a very user-


friendly interface. Thus the users will feel very easy to work
on it. The software provides accuracy along with a pleasant
interface. Make the present manual system more interactive,
speedy and user friendly.

● Availability:

The transaction reports of the system can be retried as and


when required. Thus, there is no delay in the availability of
any information, whatever needed, can be captured very
quickly and easily.

22
Conclusion

C++ software can also be used to design numerous databases and

systems like the one above. These type of systems help increase the

efficiency of handling data. The C++ software is easier to use when

the user knows the language. Using a manual system ensure data entry

is more accurate, up to date and organised. Automation ensure smooth

running of tasks and processes in the hospital.

The C++ program also has many limitations related to response, online

availability and user-friendliness. Since it is a manual system, the

response is slow. There is no option for online availability, which is a

disadvantage in a hospital environment. C++ is not user-friendly as

there is no GUI (Graphical User Interface).

In this time and age of IoT, C++ may look like a dinosaur and feel

outdated. But it still plays a very integral part of development and IT

and is still considered a very good language to act as a foundation for

young aspiring students, allowing them to learn any language they want

very easily. So, C++ is one of the best languages that are out there.

Bibliography

23
http://cpp-project.blogspot.com/2011/12/hotel-management.html

http://cpp-project.blogspot.com/2013/03/c-project-ideas-for-class-12-

11-c.html

http://turbocbse.blogspot.com/2015/08/installation-guide-for-turbo-c-

with.html

http://cpp-project.blogspot.com/2013/01/hospital-management-

system-c-project.html

https://www.scribd.com/doc/288083775/Computer-Science-

Investigatory-Project-Class-11-12

https://www.slideshare.net/lokeshmeena28/computer-science-project-

for-class-11th-and-12th

24

You might also like