C1_Presentation.ppt

Download Report

Transcript C1_Presentation.ppt

C++ Implementation
( Version 1 – Text Interface )
Elimination of services of our system.
General Flow of the program.
Sample Output Results.
Programming Algorithm Analysis.
Presented by Peter
Elimination of services of the
system.
Functions that we will remain in our system:
A manageable of database system that stores about the patients
records.
Provide a neat and tidy prescription to patients.
Information system that provide lists of suggested nutrition recipe,
some details about the medical properties of the herbs, etc.
Functions that we have to modify:
A clear and detail described receipt to patients.
Functions that we have to eliminate:
A simple simulated query system about the registered patients.
A manageable database system that concerns about the storage.
An accounting system that calculates the income and expenditure of
the shop.
How we will present our program.
We have built two stage of C++ program
implementations. One is in text-mode version,
and the other one with GUI.
The difference between them is noticeable, but
they are still logical and acceptable.
we want to emphasize the problems in
implementation of the GUI from text mode and
the change in problem ideas
To show there is a linkage within the two
versions of the programs.
General flow of the program
Herb System
Patients Records and
Medical Records
Information System
Patients Records and
Medical Records
Management of
Patients’ Records
Management of
Medical Records
Information System
Herbs and Medicine
Properties
Nutrition Recipe
General flow of the program
Management of
Patients’ Records
List Records
Create Records
Delete Records
Search Records
Modify Records
General flow of the program
Management of
Medical Records
Search Records
List Past Medical
Records
Create New Medical
Records
Produce Prescription
Produce Receipt
The relationship between each
object inside the system.
Menu
Records
Inheritance
HerbsInfo
History
Inheritance
Herbs
HerbsOrder
Output Result
Herbs Info.
Output Result
Prescription
Receipt
The format of data files.
FileNameList.dat : Stores the sorted order of Patients ID of valid
patient records.
Patient’sID.dat ( e.g. 1536.dat ) : Stores the general information of
the particular patient. It has a particular format and it only consists of
a list of strings only.
Patients’sIDHistory.dat ( e.g. 1536History.dat ) : stores the past
medical information of that particular patient. This file can be
appended for new medical records but unable to be modified. ( but
not physically )
herb_noList.txt : stores the simplest information for all herbs. ( e.g.
Herb ID, Its Name, Its First Division and its second Division )
HerbsDetail.dat : stores the full information that will be used in the
information system for all herbs. It includes the medical function and
the main cure.
Output Screen
Output Screen – Create Records
Output Screen – Create Records
Output Screen – Delete Records
Output Screen – Delete Records
Output Screen – Search Records
Output Screen – Modify Records
Output Screen – Modify Records
Output Screen – View Past Medical
Records
Output Screen – Create New
Medical Records
Output Screen – Create New
Medical Records
Output Screen – Create New
Medical Records
Output Prescriptions and Receipt.
Noticeable Programming
Algorithm in the system.
In the first version of C++ Implementation of program, there
are some noticeable programming algorithms and
techniques that is necessary to be introduced. They are:
1. Binary Search.
2. Insertion Sort
3. Overloading of Constructors.
4. Inheritance of basic class.
Noticeable Programming
Algorithm in the system.
Binary Search
played a large role in the writing the program. For example, creation
of patient records, searching of a patient record through Patient’s ID
and Searching the Herb’s ID.
good advantage in its running time
great dependence in the order of the data structure
The program has a lot of searching processes when proceeding with
the above services
the running time is greatly reduced when the number of patient
records is increased
Insertion Sort.
this function has played a main role in the creation and deletion of
Patient Records and Herbs Records.
Insertion Sort has a great advantage in running time when the input
records are almost sorted.
Noticeable Programming
Algorithm in the system.
Overloading of Constructors
Widely used in creating objects. Foe example: the Herbs, the
Patient Records, the History records, etc.
reduce a lot of assignment and initialization task while there is a
reading of data from data files
It provides a convenience to programmers.
Inheritance of basic class
In our program, we have created a basic class “Herbs” and two
inherited classes “HerbsOrder” and “HerbsInfo”
They are a good example in implementation of inheritance.
to provide the overloading of functions from the basic class “Herb”
and provides some private functions that related to the new
objects.
everything will become very clear and easy to understand.