[vtkusers] Computing eigenvalues for asymmetric matrices & detecting complex conjugate

Alexis Chan alexisc at cs.unc.edu
Wed Apr 6 15:32:10 EDT 2011


Hi
I am trying to compute the eigenvalue of S^2 + Omega^2 where S: strain-rate
tensor and Omega:spin tensor [1]

*Question 1:*

Since vtkMath::Jacobi computes the eigenvalues for a symmetric matrix, does
that mean that I have compute the eigenvalues for S separately from the
eigenvalues of Omega?

Is there a way to compute eigenvalues of asymmetric matrices in VTK ?
Should I run the Matlab eig function using vtkMatlabEngineInterface
instead?

Here's how I compute S^2+Omega^2 in my modification of vtkCellDerivatives:

else if(this->TensorMode == VTK_TENSOR_MODE_COMPUTE_LAMBDA2)// This is not
actually Lambda2, but the tensor used for calculating lambda2
          {
          tens->SetComponent(0,0, derivs[0]*derivs[0] + 0.25*derivs[1]*
derivs[1] + 0.25*derivs[3]*derivs[3] + 0.25*derivs[2]*derivs[2] + 0.25*
derivs[6]*derivs[6]);
 tens->SetComponent(0,1, 0.5*derivs[0]*derivs[1] + 0.5*derivs[4]*derivs[1] +
0.25*derivs[2]*derivs[5] + 0.25*derivs[6]*derivs[7]);
          tens->SetComponent(0,2, 0.5*derivs[0]*derivs[2] + 0.25*derivs[1]*
derivs[5] + 0.25*derivs[3]*derivs[7] + 0.5*derivs[8]*derivs[1]);
          tens->SetComponent(1,0, 0.5*derivs[0]*derivs[1] + 0.5*derivs[4]*
derivs[1] + 0.25*derivs[5]*derivs[2] + 0.25*derivs[7]*derivs[6]);
          tens->SetComponent(1,1, 0.25*derivs[1]*derivs[1] + 0.25*derivs[3]*
derivs[3] + 1*derivs[4]*derivs[4] + 0.25*derivs[5]*derivs[5] + 0.25*derivs[7
]*derivs[7]);
          tens->SetComponent(1,2, 0.25*derivs[1]*derivs[2] + 0.25*derivs[3]*
derivs[6] + 0.5*derivs[4]*derivs[5] + 0.5*derivs[8]*derivs[5]);
          tens->SetComponent(2,0, 0.5*derivs[1]*derivs[2] + 0.25*derivs[5]*
derivs[1] + 0.25*derivs[7]*derivs[5] + 0.5*derivs[8]*derivs[2]);
          tens->SetComponent(2,1, 0.25*derivs[2]*derivs[1] + 0.25*derivs[6]*
derivs[5] + 0.5*derivs[4]*derivs[5] + 0.5*derivs[8]*derivs[5]);
          tens->SetComponent(2,2, 0.25*derivs[2]*derivs[2] + 0.25*derivs[6]*
derivs[6] + 0.25*derivs[5]*derivs[5] + 0.25*derivs[7]*derivs[7] + 1*derivs[8
]*derivs[8]);

          outTensors->InsertTuple(cellId, tens->T);
          }

full file here:
https://github.com/alexisylchan/VTK/blob/master/Graphics/myVTKCellDerivatives.cxx

*Question2:*

How do I determine if the eigenvalue returned by vtkMath::Jacobi is a real
or complex-conjugate value?

I would appreciate any help! Thanks.

[1] Jinhee Jeong and Fazle Hussain. On the Identification of a Vortex.
Journal of Fluid Mechanics, pages 69-94, 285
1995<http://journals.cambridge.org/download.php?file=%2FFLM%2FFLM285%2FS0022112095000462a.pdf&code=b89c005d1fed041d4786ecfec8f757c2>
[2] Sujudi,D., and Haines,R., “Identification of Swirling Flow in 3-D Vector
Fields”, Proc. AIAA (Am. Inst. of Aeronautics and Astronautics)
Computational Fluid Dynamics Conf., American Institute of Aeronautics and
Astronautics, (Reston, Va., June 1995, pp.
151-158.<http://citeseer.ist.psu.edu/viewdoc/summary?cid=543964>
-- 
Regards,
Alexis
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20110406/d4db85d7/attachment.htm>


More information about the vtkusers mailing list