# [GRASS5] TODOs for 5.0.0

Glynn Clements glynn.clements at virgin.net
Sat Sep 1 04:08:43 EDT 2001

```Markus Neteler wrote:

> > + jacobi - Used by i.cca
> >
> > I have a description of Jacobi iteration in one of my mathematics
> > textbooks, but I haven't been able to figure out how that correlates
> > with the existing code. Can anyone provide a precise description of
> > the intended semantics?
>
> I don't know much about the intended semantics, but the jacobi() is
> described here:
> http://www.ulib.org/webRoot/Books/Numerical_Recipes/bookcpdf/c11-1.pdf

That indicates that jacobi() is finding eigenvalues and eigenvectors.
In which case, doesn't eigen() do that?

Changing jacobi() to call eigen() instead is trivial:

int
jacobi (double a[MX][MX], long n, double d[MX], double v[MX][MX])
{
double *aa[MX], *vv[MX], *dd;
int i;
for (i = 0; i < n; i++) {
aa[i] = &a[i+1][1];
vv[i] = &v[i+1][1];
}
dd = &d[1];
eigen(aa, vv, dd, n);
}

However, I don't enough about i.cca (or the imagery programs
generally) to be able to test it.

--
Glynn Clements <glynn.clements at virgin.net>

```

More information about the grass-dev mailing list