need help for my assignment

You are working for a Bio-pharmaceutical company that is in the process of running trials on a new drug. The drug is to be used to help people combat severe pain. One of the important parameters for determining dose amount and frequency is the length of time the drug stays active in the bloodstream of the patient. Like many drugs an estimate of the concentration of the drug in the patient's bloodstream can be determined by the following equations:
𝐢𝑑 = 𝐢0𝑒^βˆ’π‘˜π‘‘
𝑑1/2 = 𝑙𝑛2 / π‘˜

where: Ct is the concentration in ug/L at time t
C0 is the initial concentration in ug/L and t is the time in hours.
k is the time constant (1/hrs)
t1/2 is the half-life in hrs

Some experimental data has been collected on a few patients as shown below:

Patient# C0(ug/L) Ct(ug/L) t(hrs)
1 325 160 2.0
1 600 100 6.2
2 325 220 1.0
3 600 200 4.4
4 325 100 3.0
4 325 88 3.2
2 600 200 3.3
2 325 100 3.3
4 600 210 3.4
5 325 105 3.5
1 600 110 6.0
3 325 100 3.1
2 600 120 5.5
2 600 125 5.5
5 120 60 2.2
2 325 100 3.4

You are to develop a menu-driven program that will allow the analyses of this data. The data shown above must be placed into a data file. The program must be designed using functions. The user of the program must be able to obtain the average tΒ½ along with the number of measurements used to calculate the average for any of the 5 patients for which data has been collected. The program must also be able to display the 2 patient numbers and averages of the patients that have the highest tΒ½ average values. A menu must be used to select the different options with an additional option for Exit. The program must run until exit is selected by the user. When reporting the average tΒ½ to the screen it must be reported to two decimal places. A function called analyzeData must take as input the patient number and must return both the average tΒ½ and the number of measurements in the average for the input patient number. A separate function called halfLife is to be used for calculating the tΒ½ based on C0, Ct and t that
are in the data file. A third function must also be used to determine the two patients with the longest average tΒ½ from the five different patients. All four values (patient1, half life 1, patient 2, half life 2) must be returned to the main function. Select an appropriate name for this function.


Last edited on
@qq83482260
Welcome to CPlusPlus forum.

You are working for a Bio-pharmaceutical company that is in the process of running trials on a new drug. The drug is to be used to help people combat severe pain. One of the important parameters for determining dose amount and frequency is the length of time the drug stays active in the bloodstream of the patient. Like many drugs an estimate of the concentration of the drug in the patient's bloodstream can be determined by the following equations.

What is the problem you are having? Do you need help with your whole task?
Last edited on
Topic archived. No new replies allowed.