Question: I need this in a matlab script file, like an m file. This would help me to understand it a lot. We know a thermometer

I need this in a matlab script file, like an m file. This would help me to understand it a lot. We know a thermometer tells us the ambient temperature. However, we also know that depending
on other conditions, like humidity or wind velocity, the "feels like" temperature will be different.
The wind chill temperature, TWC(in F), is the temperature you feel on your exposed skin when it is
cold.
The equation for wind chill apparent temperature when T51F is given by:
Twc=35.74+0.6215*T-35.75*v0.16+0.4275*T*v0.16
Where Twc is the wind chill apparent temperature, T is the ambient temperature in F, and v is the
wind speed in miles/hour.
The equation for the heat index is determined as follows when T80F :
THI=c1+c2*T+c3*R+c4*T*R+c5*T2+c6*R2+c7*T2*R+c8*T*R2+c9*T2*R2
Where THI is Heat Index apparent temperature, T is ambient temperature (F),R is Relative Humidity
(%),c1=-42.379,c2=2.049015,c3=10.1433,c4=-0.224755,c5=-0.00683783,c6=-0.0548172,
c7=0.00122874,c8=0.00085282, and c9=-0.00000199. The function output should be rounded to
the nearest tenth degree.
If the temperature is between 51 and 79.99, the apparent temperature is the ambient temperature.
Write an m -file function with two inputs and one output for the "feels like temperature". The
function should be named "feels_like.m". The first input to the function needs to be
temperature (in F) and the second needs to be wind speed (in mph) if the temperature is less than
51F or humidity (in %) if the temperature is greater than 80F. The m -file should then calculate and
output the apparent temperature. Example output is shown in Figure 1 to test your function.
>T=feelslike (25,10)%25F and 10mph wind speed
T=
15.10
T=feelslike (75,10)%75F and 10is not used
T=
75.00
T=feelslike (95,10)%95F and 10% humidity
T=
90.20
Figure 1: Wind Chill Script Input and Output Format
I need this in a matlab script file, like an m

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!