Minimizing error function -> sloving linear system of equations

Theraven1982
Messages
23
Reaction score
0

Homework Statement


I want to find certain coefficients \alpha_{uv} by minimizing a error function. In the end, I want to make a function of this, so iteration is not a problem. I want to estimate these coefficients to find the best estimate for f(x,y).



Homework Equations


The error function:
<br /> E(\alpha)=\sum_{x,y}w(x,y)\Big( f(x,y)-\sum_{u,v=-N}^{N}\alpha_{u,v}f(x+u, y+v)\Big)^{2}<br />
with
<br /> w(x,y)=P(f(x,y)\in M_1|f(x,y)),<br />
which in turn is equal to

<br /> \frac{1}{\sigma\sqrt{2\pi}} \frac{exp\Big[ -\frac{1}{2\sigma^2} \Big( f(x,y) - \sum_{u,v=-N}^{N}\alpha_{u,v}f(x+u, y+v)\Big)^2\Big]}{ \sum_{i=1}^{2}P(f(x,y)|f(x,y)\in M_{i}) }<br />

The Attempt at a Solution


<br /> \frac{\partial E}{\partial \alpha_{s,t}}=0<br />

eventually gives:

<br /> \sum_{u,v=-N}^{N}\alpha_{u,v}=\frac{ \sum_{x,y}w(x,y)f(x+s, y+t)f(x,y) }{ \sum_{x,y}w(x,y)f(x+s, y+t)f(x+u, y+v) }<br />

So, now we have a linear system of equations. I don't know how to solve this in a efficient way.
Thanks in advance,
 
Last edited:
Physics news on Phys.org
That's a very wide question! There are many different ways of solving a linear system- which is most efficient depends on the coefficients. Gaussian eliminaion with pivoting is probably the best general method.
 
I was afraid of that ;). I'll find my linear algebra book ;).
Is there anyone who has experience in solving these equations in Matlab? There are probably functions for this purpose ; again, any kick in the right direction is welcome ;)
 
There are two things I don't understand about this problem. First, when finding the nth root of a number, there should in theory be n solutions. However, the formula produces n+1 roots. Here is how. The first root is simply ##\left(r\right)^{\left(\frac{1}{n}\right)}##. Then you multiply this first root by n additional expressions given by the formula, as you go through k=0,1,...n-1. So you end up with n+1 roots, which cannot be correct. Let me illustrate what I mean. For this...
Back
Top