Question
Biomedical Research A research institute specializing in physiology is conducting a study on the strain and effects of commuting trips done on a bicycle or
Biomedical Research
A research institute specializing in physiology is conducting a study on the strain and effects of commuting trips done on a bicycle or walking. When the physiological strain of commuting trips has been studied, the results will be used in exercise prescriptions, which can then use commuting as part of an exercise regimen.
In this program you will write a C++ program to analyze a small subset of the data that has been collected.
INPUT: Redirect the input from the file HR.txt.
The file consists of three columns, with six lines of data for each person. The first line stores each persons ID number (integer), clinically measured maximum heart rate (integer), and age (integer). The following five lines contain the days average commuting heart rate, maximum commuting heart rate, and exercise heart rate for five consecutive working days. Then, the six line sequence is repeated for the next person. At times the heart rate monitors reacted to nearby power lines or other objects, and gave false readings. These incorrect measurements were rejected and show up in the data file as -1. On the days the person did not exercise, the exercise heart rate value is zero.
PROCESSING; Use precisely six parallel arrays: one for subject numbers and five for the calculated values as described below.
Using this information, calculate
1. Average of the average commuting heart rates for each person.
2. Number of days that the person exercised on his/her own.
3. Estimated maximum heart rate = 220 age.
4. Ratio (%) of measured maximum heart rate to estimated maximum heart rate. The maximum heart rate for each person has been measured during a maximum oxygen uptake test in the laboratory. During the test, the person exercised with increasing intensity until exhaustion, and then the maximum heart rate was measured close to the end of the test. Using this measured maximum heart rate and the estimated maximum heart rate, calculate the percentage of the measured maximum heart rate with respect to the estimated maximum heart rate. Note that this percentage can exceed 100%.
5. Ratio (%) of highest commuting heart rate to measured maximum heart rate. Find the highest maximum commuting heart rate for each person, and then calculate the percentage of this value with respect to the measured maximum heart rate.
-----------------------------------------------------
This is data: file HR.txt.
6231 181 28 140.1 170 101.8 128.4 156 0.0 145.2 171 106.2 131.3 165 0.0 144.8 170 0.0 1124 178 36 122.8 139 138.4 119.6 142 0.0 117.8 134 133.4 115.3 145 134.2 87.2 109 120.5 7345 195 36 128.4 151 104.6 120.5 153 0.0 134.5 166 140.4 127.4 156 0.0 150.3 169 158.5 9439 197 21 121.5 143 112.2 128.9 145 0.0 126.1 159 134.5 123.0 152 0.0 131.5 147 0.0 4545 190 52 114.8 130 113.1 102.6 131 0.0 117.4 129 149.1 -1 -1 114.0 114.1 123 119.5 2438 200 26 123.0 165 105.4 118.2 130 122.0 121.7 136 124.5 116.1 130 0.0 111.0 152 103.5 2776 178 45 110.3 120 129.1 107.8 132 0.0 111.5 145 135.0 -1 -1 0.0 95.5 119 0.0 8762 186 28 122.7 146 151.9 116.0 137 0.0 119.9 145 0.0 123.3 148 150.0 121.0 142 156.3 4915 185 27 120.3 169 0.0 130.2 150 0.0 123.0 158 0.0 133.4 152 0.0 131.6 159 0.0 3521 181 51 108.3 133 119.3 -1 -1 0.0 117.6 147 125.3 106.7 131 0.0 122.7 159 0.0
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started