Quadrupoles - représentation

(P Reinhardt, LCT, UPMC)

Input - a given quadrupole

Qpole={{1.,2.,3.},{2.,2.,2.},{3.,2.,3.}};
MatrixForm[Qpole1]

Transformation to a traceless tensor

RR=Qpole[[1,1]]+Qpole[[2,2]]+Qpole[[3,3]];
Qpole[[1,1]]=Qpole[[1,1]]-RR/3.;
Qpole[[2,2]]=Qpole[[2,2]]-RR/3.;
Qpole[[3,3]]=Qpole[[3,3]]-RR/3.;
MatrixForm[Qpole]

Eigenvalues and eigenvectors

eval=Eigenvalues[Qpole]
A=Eigenvectors[Qpole]
Eigenvectors[Qpole,1]

vec1=Sqrt[Abs[eval[[1]]]]/2*{A[[1,1]],A[[1,2]],A[[1,3]]}
vec2=Sqrt[Abs[eval[[2]]]]/2*{A[[2,1]],A[[2,2]],A[[2,3]]}
vec3=Sqrt[Abs[eval[[3]]]]/2*{A[[3,1]],A[[3,2]],A[[3,3]]}

CentralPole=-Sign[eval[[1]]]-Sign[eval[[2]]]-Sign[eval[[3]]]

Graphical representation

Show[Graphics3D[{{ColorData[8,Sign[eval[[1]]]+1],Sphere[vec1,0.1],Sphere[-vec1,0.1]},{ColorData[8,Sign[eval[[2]]]+1],Sphere[vec2,0.1],Sphere[-vec2,0.1]},{ColorData[8,Sign[eval[[3]]]+1],Sphere[vec3,0.1],Sphere[-vec3,0.1]},{ColorData[8,Sign[CentralPole]+1],Sphere[{0,0,0},0.2]}}],Axes->True]