Hello, my name is Victor Assis and I am a student from Brazil. I have been working hard on a problem that I could not quite get myself, and I need your help. This is the deal:
I have to fit an equation to a data set. But my equation does have linear and nonlinear parameters. My idea is to simply use OLS, with a slightly difference: I am gonna anchor the value of my linear parameters on the value of the nonlinears. To do this I just set up the OLS classical problem, and computed the partial derivatives of the linear parameters. Once I got those, I am using this as a constraint (but I just substituted it for the values in the sum of the squared residuals).
the problem that i am facing is that I don't seem to understand how to set up this problem in Matlab. When I am trying to set up an objective function I don't understand how to define what is parameters and what is the dataset that i am gonna use.
I don't know if i made myself clear, but i will print the equation i am trying to fit to my dataset here just in case:
y= A + B*(tc-t)^(z)+C*(tc-t)^(z)*cos(w*log(tc-t)+phi)
Linear parameters that will be anchored : A,B, C Parameters estimated by the Genetic algorithm : tc,z,w,phi Dataset used: y,t (both are column vectors Nx1
I appreciate your help. Thank you very much.
Best Answer