On a windy day, a temperature of 15 degrees may feel colder, perhaps 7 degrees. The formula below calculates the "wind chill," indicating the temperature that is felt based on the actual temperature (T, in Fahrenheit) and wind speed (W, in miles per hour):
windChill = 35.7 + 0.6T - 35.7W^0.16 + 0.43TW^0.16 In a previous problem you wrote a function to return the wind chill for a single temperature T and wind speed W. In this problem the function is given a single temperature T but a vector of wind speeds WV; your job is to return a vector of wind chills, one for each temperature and wind speed pair. For example, if T is 32 and WV is [1:5], then the function returns the vector [32.9600, 30.3867, 28.7437, 27.5116, 26.5161].
Here is the code given
function windChills = ComputeWindChills(T, WV) windChills = ... ; end
finish the code.
0 Comments
Sign in to comment.