Screenshot of the program: linearizeModel.m
Sample output:
Code to copy:
%Data : Initialize time vector
t = [0 0.5 1 1.5 2 3 4 5];
%Initialize concentrations vector at each time
c = [3.26 2.09 1.62 1.48 1.17 1.06 0.9 0.85];
X =t;
Y = 1./c.^2;
a = polyfit(X,Y,1);
a0 = a(2);
a1 = a(1);
k = a1/2;
c0 = 1/sqrt(a0);
fprintf('The value of k is %.4f L^2/(mg^2 d)', k);
fprintf('and the value of c0 is %.4f mg/L.\n', c0);
%find error
e = (Y-a0-a1.*X).^2;
%find sum of squares of error
sr = sum(e);
%find standard deviation
Sy = sqrt(sr/(28-1));
C =c0./(sqrt(1+2*k*c0^2*t));
C_e = polyval(a,X);
%plot the data
plot(t,c, 'o',t,C);
xlabel('Time (d)');
ylabel('Concentration');
legend('Data','Untransformed Model');
grid on
figure(2)
plot(X,Y,'o',X,C_e)
xlabel('Time (d)');
ylabel('Concentration');
legend('Transformed Data','Transformed Model');
grid on
use the linearize model to estimate k and C0 based on the following data using matlab...
Can you make matlab solve it? 2. An investigator has reported the data tabulated below for an experiment to determine the growth rate of bacteria k (per day) as a function of ox ygen concentration c (mg/L). It is known that such data can be modeled by the following equation: Where es and kmax are parameters 0.5 1.1 0.8 2.5 1.5 5.3 2.5 7.6 8.9 a) Use a transformation to linearize this equation. b) Then write a function m file...
Use matlab a) Create a simulated data set b) Create a set of plots to determine the best transformation to linearize the data c) Fit a first order polynomial (y mx + b) to the linearized data to find the constants m and b d) Reconstruct the original equation from m and b in the linear fitted polynomial e) Plot the fitted equation. Radioactive decay is modeled by the equation: rt where A the amount of mass as a function...
Fluoride ion selective electrodes obey the following equation: E(V) = K - (0.0592)log[F-] where the fluoride concentration is expressed as mol/L and the temperature coefficient is normally equal to 1. In a normal calibration procedure you dilute a standard fluoride solution to between 10 and 20 mg/L fluoride ion and then measure the response of the electrode. You then plot the data and do a linear regression to obtain the fitting coefficients K and . Use the plotting and linear...
Use the data below to answer questions 1 to 6. Use a multiple linear regression model with linear main effects only Show all calculations. No credit will be given for computer 7.2 9.8 12.3 12.9 Sum of Squares 31.19 3 5 6 8 9 Y U D F G J K L Calculate the fitted regression line. Write out the calculations using matrix format. Use the data below to answer questions 1 to 6. Use a multiple linear regression model...
Use nonlinear regression to estimate α4 and β4 based on the following data. y= α4Xe^(β4X) x 0.1 0.2 0.4 0.6 0.9 1.3 1.5 1.7 1.8 y 0.75 1.25 1.45 1.25 0.85 0.55 0.35 0.28 0.14 If you were to use linear regression to find α4 and β4, how would you make the model linear? Plot the data points, the fit to the data using linear and nonlinear regression. What method produces the better estimate
USING MATLAB. For given data, estimate the length when time is at 3.5 seconds and at 13 seconds by utilizing the maximum number of data given, and provide the equation for the best fit curve, and plot the curve against the data. (a) Linear regression method (b) Exponential Function (c) Power Function (d) Saturation Function (e) Polynomial regression (f) Lagrange polynomial (8) Newton's divided-difference polynomial Time (sec) Length (in) 10 17 18 25 28 30 30 10 15 36 38
2. Let the following data be given where X is the independent variable and Y is the dependent variable Find the correlation coefficient r a. a and B,onpfrom the sample for the model: b. Estimate +tx and the actual data Y where ε is the random error between the fitted model f by Y write the linear equation P=" dr-h Predict the value of P when x = 8 c. d. 2. Let the following data be given where X...
Fluoride ion selective electrodes obey the following equation: E(V) = K - B(0.0592)log[F] where the fluoride concentration is expressed as mol/L and the temperature coefficient B is normally equal to 1. In a normal calibration procedure you dilute a standard fluoride solution to between 10 and 20 mg/L fluoride ion and then measure the response of the electrode. You then plot the data and do a linear regression to obtain the fitting coefficients K and B. Use the plotting and...
matlab please TABLE P15.5 Dissolved oxygen concentration in water as a function of temperature (°C) and chloride concentration (O/L). Dissolved Oxygen (mg/L) for Temperature (C) and Concentration of Chloride (g/L) C=Og/L c=10 g/l c=20 g/L 14.6 12.9 11.4 12.8 11.3 10.3 11.3 10.1 8.96 10.1 9.03 8.08 9.09 8.17 7.35 8.26 7.46 6.73 6.85 6.20 1.56 the percent relative error for your prediction. Explain pos sible causes for the discrepancy. 15.7 As compared with the models from Probs. 15.5 and...
Only question 6 please, this is the model referred to in Question 6 from 5.c c) Estimate the linear model for a state's unemployment rate shown below (i.e. estimate Bo and β1) using OLS. Write the resulting regression equation. unemployment rate-β0 + β|minimum wage + ε 6. The following questions ask you to use the regression model you estimated to predict unemployment rates (ie, the model in 5.c). Use the unemployment and minimum wage data from the table above to...