Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

To maintain one’s body weight,an adult human needs to consume enough calories da

ID: 3629959 • Letter: T

Question

To maintain one’s body weight,an adult human needs to consume enough calories daily to (1) meet the basal metabolic rate (energy required to breathe,maintain body temperature,etc),(2) account for physical activity such as exercise,and (3) account for energy required to digest the food that is eaten.For an adult that weighs P pounds ,we can estimate these caloric requirements using the following formulas:


1)basal metabolic rate :Calories required=70*(p/2.2)^0.756

2)Physical activity:Calories required=0.0385*Intensity*P*Minutes

Here ,Minutes is the number of minutes spent during the physical activity,and Intensity is a number that estimates the intensity of the activity.Here are some sample numbers for the range of values:

Activity intensity
Running 10 mph 17
Running 6 mph 10
basketball 8
Walking 1 mph 1

3)Energy to digest food:Calories required=TotalCaloriesConsumed*o.1

in other words,10% of the calories we consume goes to digestion.

Write a function that computes the calories required for the basal metabolic rate,taking as input a parameter for the person’s weight.Write another function that computes the calories required for physical activity,taking as input parameters for the intensity,weight ,and minutes spent exercising.

Use these functions in a program that inputs a person’s weight ,and estimate for the intensity of physical activity,the number of minutes spent performing the physical activity,and the number of calories in one serving of your favorite food.The program should the calculate and output how many servings of the food should be eaten per day to maintain the person’s current weight at the specified level.The computation should include the energy that is required to digest food.

You can find estimates of the caloric content of many food on the web.For example ,a double cheese has approximately 1000 calories.

Explanation / Answer

please rate - thanks



#include <iostream>
#include <cmath>
using namespace std;
double BMR(double );
double required(int,int, double);
int main()
{int intense,min,cal;
double wt,needed,servings,digest;
cout<<"Enter weight: ";
cin>>wt;
cout<<"Enter excersize intensity: sample values ";
cout<<"Running 10 MPH:   17 ";
cout<<"Running 6 MPH:    10 ";
cout<<"Basketball:       8 ";
cout<<"Walking 1 MPH:     1 ";
cout<<"Enter: ";
cin>>intense;
cout<<"Enter how many minutes will you do this: ";
cin>>min;
cout<<"Enter number of calories in 1 serving of your favorite food: ";
cin>>cal;
needed=BMR(wt)+required(intense,min,wt);
digest=needed*.1;
servings=(needed-digest)/cal;
cout<<"Serving needed to maintain weight:"<<servings<<endl;
system("pause");
return 0;
}
double BMR(double p)
{return pow((70.0*(p/2.2)),0.756);
}
double required(int in,int min,double p )
{return 0.0385*in*p*min;
}


Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote