I have an equation of the form t=X^TD^-1X(1), whereXis a 3D vectorX=[X Y Z] andD^-1is the inverse of a 3x3 diffusion tensorD=[Dxx Dxy Dxz; Dxy Dyy Dyz; Dxz Dyz Dzz].X^Tmeans that the vector is transposed.

The 3D vector ofXis the 3D distance for a set of points from the origin andtis the time for a pulse to get there.

Assuming that one of the eigenvectors is vertical (Dxz and Dyz are zero), equation (1) becomes

t=Dxx^-1 X^2+Dyy^-1 Y^2+Dzz^-1 Z^2+2 Dxy^-1 X Y (2)

The problem is to find the eigenvectors ofD-1.

The principal horizontal axes ofDwill be those where the non-diagonal term Dxy approaches zero. The principal horizontal axes (x, y) are derived from the geographical system (xg, yg) by a rotation of θ about the z axis (θ is expressed counterclockwise in degrees between x axis and xg axis).

KnowingtandXfor a set of points, a linear regression can be applied to equation (2).

My problem is that I assume that a multiple linear regression will be efficient, but I don't know how the angle θ is expressed in equation (2) so as to perform the multiple linear regression for each angle θ and see where Dxy approaches zero.

I would be grateful if anyone can help me with this.