Optimization of parameters for a calculated result having an experimental result
조회 수: 5 (최근 30일)
이전 댓글 표시
Hello everyone, I have a function
Hc=par1.*(x.^par2).*(y.^par3).*(z.^par4).*exp(par5.*w).*exp(par6.*v)
I have the inputs x, y, z, w and v (they are number arrays of equal quantity of elements) and the initial values for par1, par2... par6, so I have multiple outputs of Hc. I also have the experimental values of H. I have the relative deviation for each one and the average relative deviation as follows:
RD=(H-Hc)./H.*100;
ARD=100*(sum(RD))/q; %where q is the number of elements
Now, I need to optimize those 6 parameters so that the relative deviation is as close to zero (0) as possible. How could I do that?
댓글 수: 0
답변 (1개)
Alan Weiss
2018년 9월 4일
Perhaps along the lines of Curve Fitting via Optimization. Before fitting, you might want to take the logarithm of both sides of your equation in order to get a simpler expression to optimize.
Alan Weiss
MATLAB mathematical toolbox documentation
댓글 수: 2
Torsten
2018년 9월 5일
To get starting values for the parameters, you should try to fit
log(Hc)
against
log(par1)+par2*log(x)+par3*log(y)+par4*log(z)+par5*w+par6*v
That's a linear fit in the parameters - thus easily accomplished.
Best wishes
Torsten.
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!