Coding language: Matlab
I am unable to comment from answers; the issue I havebeen running into is the code for the function (fn_psi2atm.m). Ican not run the script w/o its function. So, can I please just havethe code for the function, to make the script work. Although I wasalready responded with the script's code, I would like to see thefigures for 2d.
Normal atmospheric pressure is defined as 1 atmosphere [atm]. 1[atm] = 14.6956 [psi] = 760 [torr] = 101.325 [kPa*].
1) Write a function, fn_psi2atm.m, to convertpsi to atm, torr and kPa. Set the output as 3 different unit withinput of pressure in psi.
2) Write a script, final.m, to do the followingwork.
a. Read an external data Time Pressure.txt. by using fgetl, andtextscan.
b. Convert the pressure unit by using fn_psi2atm.
c. Use the pressure unit of [atm]. Fit the data with linear anda third-degree polynomial by using polyfit. Use sprintf to storethe fitted result.
d. Use subplot. In the first plotting area, plot time vspressure in kPA unit. In the second plotting area, plot the datapoints in atm.
time(sec) 12345678910 Pressure(psi) 25.927.028.229.029.830.631.131.531.030.5
Coding language: Matlab I am unable to comment from answers; the issue I have been running into is the code for the functi
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am