The UB Health Services is a medium size hospital capable of handling few tens of patients. The hospital is to develop diet control software for the patients who are recovering from their illness. In the current scenario, the hospital does have software, capable of finding the diet requirement for a given patient. However, the existing software is poorly designed and developed by the previous IT team. You have joined this hospital as multifaceted IT person who has capacity to play dual roles — as a system analyst and as a developer.

In UB Health Services, you are given an application for calculating the recommended daily intake of calories. The application has the following general requirements:

  • The application has the formula for calculating daily recommended calories and the calculation is based on the patient’s personal data and it varies according to the patient’s gender. Here are the formulas:
Male: 66 + (6.3 × body weight in lbs.) + (12.9 × height in inches) − (6.8 × age in years)
Female: 655 + (4.3 × weight in lbs.) + (4.7 × height in inches) − (4.7 × age in years)
  • The application is also required to calculate an ideal-weight. The idea was for the application to be able to calculate a patient’s ideal weight based on height, along with calculating daily calories. As before, the calculation depends on gender, so there are separate formulas for men and women. Here are the formulas:
Male: 50 + 2.3 kg per inch over 5 feet
Female: 45.5 + 2.3 kg per inch over 5 feet
  • The next requirement is to save patient historical data so that doctors could easily track his patients’ progress. Therefore, for this requirement, application needed to capture some data that could be used to identify the patient.
  • Identification of the patient by using Medicare number.
  • Separation of the calculation operation and the operation of persisting patient data: These two actions should be separated to be able to perform some ad hoc calculations without having to input a patient’s name and Medicare number. In addition, users could save the data only when they were sure that all the entries were correct.
  • For implementing persistence of a patient’s history, a few alternatives are available, such as a flat file, a database (e.g., Access), or even a spreadsheet. In the given application, a flat file was used. You are required to change this to a database or XML file.

The system analyst role is to design and analysis the requirements by drawing a use case diagram, class diagram and sequence diagram for finding the correct diet intake in calories for a given patient. While the developer role is to produce the code, however, in this scenario, you have given the written code for the application developed by the previous IT team. This application is badly in need of refactoring and even a casual viewing of the source code reveals many examples of the “code smells” (talked about in Fowler’s book). You are only required to refactor the written code and test them based on the analysis and design produced by you as a system analyst. Finally, a report is given to the management about the defects in the design of the existing software by identifying the bad smells etc.

Your report should be written in the same manner as Fowler has done in the prescribed text - small refactoring’s with code comparisons and UML diagrams (refer Fowler pp.1-65). Ask your tutor if you have any doubts.

Academic Honesty!
It is not our intention to break the school's academic policy. Projects posted are only used as a reference and should not be submitted as is. We are not held liable for any misuse of the solutions. Please see the frequently asked questions page for further questions and inquiries.
Kindly fill out the form. Please provide a valid email address and we'll get back to you in less than 24 hours. We will be sending an invoice through PayPal upon confirmation. We are a non profit organization however we need an amount to keep this organization running, and to be able to complete our research and development.