Question: Develop a function called h 2 0 rho _ SI . m that accepts temperature in degrees Celsius and outputs density in kg / m
Develop a function called hrhoSIm that accepts temperature in
degrees Celsius and outputs density in kgm Do this by interpolating
the data in table A The output of the function should be the same size
as the input. If the user inputs a single temperature, the function should
return a single density. If the user inputs a matrix of temperatures, the
function returns a matrix of densities at those temperatures. Submit your
commented code and a command line call to the function for temperatures
and deg C to show the function works.
EXAMPLE FUNCTION:
function yout blahxin
Blah accepts an x input and provide the interpolated y
output
INPUTS:
xin nxn matrix of request x point
OUTPUT
yout nxn matrix of interpolated data at xin points
Author:
Date:
Version:
Change log:
xdata ;
ydata ;
yout interpxdata,ydata,xin;
end
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
