[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[leasqr] help with parameters
From: |
Pascal A. Dupuis |
Subject: |
[leasqr] help with parameters |
Date: |
Tue, 18 Jan 2005 01:37:19 -0600 |
User-agent: |
Mutt/1.5.6+20040907i |
Hello,
I use leasqr to fit a complex frequency response to measurered points.
Could someone please help fit the parameters ?
Context: there are a number of frequencies contained in f, the vector
to be optimised is Xok = [Rse Rpe 1e9*Cce Rce], where the scaling on
the third parameter ensure it has more or less the same order of
magnitude as the others.
The target is an impedance, obtained as Rs+ (Cce // (Rpe + Rce)),
where Rce has a special frequency response.
Then I have:
# fitting func
F = "leasqr_warburg_func";
# Jacobian
dFdp = "leasqr_warburg_dfdp";
#scalar tolerance and number of iter
stol=0.001; niter=250;
#desired fractional precision in parameter estimates
minstep = [0.01; 0.01];
# weight vector
wt1 = ones(2*length(f), 1);
# for the numerical derivative.
dp = .001*ones(size(Xok));
[f1, p1, kvg1, iter1, corp1, covp1, covr1, stdresid1, Z1, r21] = ...
leasqr ([f;f], [real(Zr); imag(Zr)], 1.01*Xok, F, stol, niter,
wt1, dp, dFdp, [minstep]);
The problem is that this always stop after 3 iterations.
If a compute:
%# at solution
f0=leasqr_warburg_func([f;f], Xok);
norm(f0-[real(Zr); imag(Zr)])
ans = 3.7211e-10
%# move 1% away
f01=leasqr_warburg_func([f;f], 1.01*Xok);
norm(f01-[real(Zr); imag(Zr)])
ans = 407.35
%# solution from leasqr
norm(f1-[real(Zr); imag(Zr)])
ans = 404.61
So, there was a progress, but I would expect further reduction of the
error norm! Which parameter should I change to force the convergence
to better values ? In particular, are stol absolute or relative ?
TIA
Pascal
--
Dr. ir. Pascal Dupuis
K. U. Leuven, ESAT/ELECTA (formerly ELEN): http://www.esat.kuleuven.ac.be/
Kasteelpark Arenberg, 10; B-3001 Leuven-Heverlee, Belgium
Tel. +32-16-32 10 21 -- Fax +32-16-32 19 85
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [leasqr] help with parameters,
Pascal A. Dupuis <=