Cartesius Library
|
Collects functions devoted to rotations of Rˆ3 space. More...
Data Types | |
interface | assignment(=) |
interface | operator(*) |
interface | operator(.det.) |
interface | operator(.inv.) |
type | rotation |
@TODO Add ten more types of triples of angles to be used to define rotations, then one more type of triple of angles: rotation angle and two angles defining the rotation axis. This seems to be all... More... | |
type | xyzangles |
type | zyzangles |
Functions/Subroutines | |
complex function | harmonics_r_to_c_coef (l, mc, mr) |
Returns the coefficient of transformation from real (cubic) to complex (spherical) basis <j,mc(complex)|j,mr(real)> More... | |
complex function | harmonics_c_to_r_coef (l, mr, mc) |
Returns the coefficient of transformation from complex (spherical) to real (cubic) basis <j,mr(real)|j,mc(complex)> More... | |
subroutine | setmatricestotransformsphericaltocubic (sphericalToCubicMatrices) |
@TODO This should not be done in a subroutine. We need to define these matrices explicitly as a public variable (see above). More... | |
subroutine | xrot (angle, rm) |
subroutine | yrot (angle, rm) |
subroutine | zrot (angle, rm) |
type(rotation) function, private | r_mult_r (r1, r2) |
real function | det_r (rin) |
type(rotation) function, private | inv_r (rin) |
subroutine | r_to_r (r_result, r_source) |
subroutine | array_to_r (r_result, array_source) |
subroutine, private | xyz_to_r (rm, Angles) |
subroutine, private | zyz_to_r (rm, Angles) |
subroutine, private | q_to_r (rm, q) |
Returns an SO(3) rotation matrix corresponding to the given rotation quaternion. More... | |
subroutine | av_to_q (q, a, v) |
Returns a quaternion corresponding to a rotation around the given vector by the given angle. More... | |
subroutine | av_to_r (r, a, v) |
Returns an SO(3) rotation matrix corresponding to a rotation around the given vector by the given angle. More... | |
type(vector) function | rot_vec (rot, vin) |
type(point) function | rot_point (rot, pin) |
subroutine | wignermatrixelementforrealharmonics_cayleyklein (l, m1, m2, ck_a, ck_b, matrixElement) |
Subroutine calculates matrix elements (m1,m2) of the Wigner D-matrix (Dˆl) over cubic harmonics from the Cayley-Klein parameters, describing rotation. More... | |
subroutine | wignermatrixelementforrealharmonics_eulerangles (l, m1, m2, alpha, beta, gamma, matrixElement) |
Subroutine calculates matrix elements (m1,m2) of the Wigner D-matrix (Dˆl) over cubic harmonics from the Euler Angles, describing rotation. More... | |
real function | wignermatrixelementreal_eulerangles_fn (l, m1, m2, alpha, beta, gamma) |
Returns the value of the Wigner D-matrix element, describing rotation of a real (cubic) harmonic, in ZYZ convention. More... | |
subroutine | wignermatrixelement_cayleyklein (l, m1, m2, ck_a, ck_b, matrixElement) |
Subroutine calculates matrix elements (m1,m2) of the Wigner D-matrix (Dˆl) over spherical harmonics from the Cayley-Klein parameters, describing rotation. More... | |
subroutine | wignermatrixelement_eulerangles (l, m1, m2, alpha, beta, gamma, matrixElement) |
Subroutine calculates matrix elements (m1,m2) of the Wigner D-matrix (Dˆl) over spherical harmonics from the Euler angles, describing rotation. Used expression comes from eqs. (1) and (5) of chapter 4.3. from the book of Varshalovich book (in Russian) p.68. Please, note ZYZ convention for Euler angles is used in this book, thus we also use this convention when calculating Euler angles for the transformation of the laboratory frame to the local one (see module 'particles.f90'. More... | |
complex function | wignermatrixelement_eulerangles_fn (l, m1, m2, alpha, beta, gamma) |
real function | wignersmalldmatrixelement_eulerangles_fn (l, m1, m2, beta) |
Returns the value of the Wigner small d-matrix element, which specifies coefficients for rotation a complex (spherical) harmonic around the Y axis. More... | |
subroutine | geteuleranglesforrotation (somePoint, alpha, beta, gamma) |
subroutine | getcayleykleinforrotation (somePoint, a, b) |
subroutine | eulerangles_to_cayleyklein (alpha, beta, gamma, ck_a, ck_b) |
Variables | |
type(complex_matrix), dimension(0:3), public | sphericaltocubicmatrices |
complex, dimension(0:0, 0:0), public | harmonicstransform_s = cmplx(1.0, 0.0) |
Global variable containing matrices transforming spherical harmonics for l=0 to the cubic ones. More... | |
complex, dimension(-1:1,-1:1), public | harmonicstransform_p = reshape( [cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,sq0p5), cmplx(0.0,0.0),cmplx(1.0,0.0),cmplx(0.0,0.0), cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(-sq0p5,0.0)], [3,3]) |
Global variable containing matrices transforming spherical harmonics for l=1 to the cubic ones. More... | |
complex, dimension(-2:2,-2:2), public | harmonicstransform_d = reshape( [cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,-sq0p5), cmplx(0.0,0.0),cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,sq0p5),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(1.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(-sq0p5,0.0),cmplx(0.0,0.0), cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(sq0p5,0.0)], [5,5]) |
Global variable containing matrices transforming spherical harmonics for l=2 to the cubic ones. More... | |
complex, dimension(-3:3,-3:3), public | harmonicstransform_f = reshape( [cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,sq0p5), cmplx(0.0,0.0),cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,-sq0p5),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(1.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(-sq0p5,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(sq0p5,0.0),cmplx(0.0,0.0), cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(-sq0p5,0.0)], [7,7]) |
Global variable containing matrices transforming spherical harmonics for l=3 to the cubic ones. More... | |
Collects functions devoted to rotations of Rˆ3 space.
subroutine rotations::array_to_r | ( | type (rotation), intent(out) | r_result, |
real, dimension(1:3,1:3), intent(in) | array_source | ||
) |
subroutine rotations::av_to_q | ( | type(quaternion), intent(out) | q, |
real, intent(in) | a, | ||
type(vector), intent(in) | v | ||
) |
Returns a quaternion corresponding to a rotation around the given vector by the given angle.
subroutine rotations::av_to_r | ( | type(rotation), intent(out) | r, |
real, intent(in) | a, | ||
type(vector), intent(in) | v | ||
) |
Returns an SO(3) rotation matrix corresponding to a rotation around the given vector by the given angle.
real function rotations::det_r | ( | type(rotation), intent(in) | rin | ) |
subroutine rotations::eulerangles_to_cayleyklein | ( | real, intent(in) | alpha, |
real, intent(in) | beta, | ||
real, intent(in) | gamma, | ||
complex, intent(out) | ck_a, | ||
complex, intent(out) | ck_b | ||
) |
subroutine rotations::getcayleykleinforrotation | ( | type(point), intent(in) | somePoint, |
complex, intent(out) | a, | ||
complex, intent(out) | b | ||
) |
subroutine rotations::geteuleranglesforrotation | ( | type(point), intent(in) | somePoint, |
real, intent(out) | alpha, | ||
real, intent(out) | beta, | ||
real, intent(out) | gamma | ||
) |
complex function rotations::harmonics_c_to_r_coef | ( | integer, intent(in) | l, |
integer, intent(in) | mr, | ||
integer, intent(in) | mc | ||
) |
Returns the coefficient of transformation from complex (spherical) to real (cubic) basis <j,mr(real)|j,mc(complex)>
complex function rotations::harmonics_r_to_c_coef | ( | integer, intent(in) | l, |
integer, intent(in) | mc, | ||
integer, intent(in) | mr | ||
) |
Returns the coefficient of transformation from real (cubic) to complex (spherical) basis <j,mc(complex)|j,mr(real)>
|
private |
Returns an SO(3) rotation matrix corresponding to the given rotation quaternion.
|
private |
subroutine rotations::r_to_r | ( | type (rotation), intent(out) | r_result, |
type (rotation), intent(in) | r_source | ||
) |
type(point) function rotations::rot_point | ( | type(rotation), intent(in) | rot, |
type(point), intent(in) | pin | ||
) |
type(vector) function rotations::rot_vec | ( | type(rotation), intent(in) | rot, |
type(vector), intent(in) | vin | ||
) |
subroutine rotations::setmatricestotransformsphericaltocubic | ( | type(complex_matrix), dimension(0:3), intent(inout) | sphericalToCubicMatrices | ) |
@TODO This should not be done in a subroutine. We need to define these matrices explicitly as a public variable (see above).
subroutine rotations::wignermatrixelement_cayleyklein | ( | integer, intent(in) | l, |
integer, intent(in) | m1, | ||
integer, intent(in) | m2, | ||
complex, intent(in) | ck_a, | ||
complex, intent(in) | ck_b, | ||
complex, intent(out) | matrixElement | ||
) |
Subroutine calculates matrix elements (m1,m2) of the Wigner D-matrix (Dˆl) over spherical harmonics from the Cayley-Klein parameters, describing rotation.
subroutine rotations::wignermatrixelement_eulerangles | ( | integer, intent(in) | l, |
integer, intent(in) | m1, | ||
integer, intent(in) | m2, | ||
real, intent(in) | alpha, | ||
real, intent(in) | beta, | ||
real, intent(in) | gamma, | ||
complex, intent(out) | matrixElement | ||
) |
Subroutine calculates matrix elements (m1,m2) of the Wigner D-matrix (Dˆl) over spherical harmonics from the Euler angles, describing rotation. Used expression comes from eqs. (1) and (5) of chapter 4.3. from the book of Varshalovich book (in Russian) p.68. Please, note ZYZ convention for Euler angles is used in this book, thus we also use this convention when calculating Euler angles for the transformation of the laboratory frame to the local one (see module 'particles.f90'.
@attenion This calculates the matrix elements based on the assumption that we are rotating in reverse. Shouldn't we make the matrix by following the correct formula, and pass the reverse angles in other modules for clarity?
\[ D_{m'm}^{l}\left(\pi-\gamma,\beta,\pi-\alpha\right)=e^{im'\left(\pi-\gamma\right)}d_{m'm}\left(\beta\right) e^{im\left(\pi-\alpha\right)}=e^{-im'\gamma}d_{m'm}^{l}\left(\beta\right)e^{-im\alpha}\] \]
complex function rotations::wignermatrixelement_eulerangles_fn | ( | integer, intent(in) | l, |
integer, intent(in) | m1, | ||
integer, intent(in) | m2, | ||
real, intent(in) | alpha, | ||
real, intent(in) | beta, | ||
real, intent(in) | gamma | ||
) |
subroutine rotations::wignermatrixelementforrealharmonics_cayleyklein | ( | integer, intent(in) | l, |
integer, intent(in) | m1, | ||
integer, intent(in) | m2, | ||
complex, intent(in) | ck_a, | ||
complex, intent(in) | ck_b, | ||
real, intent(out) | matrixElement | ||
) |
Subroutine calculates matrix elements (m1,m2) of the Wigner D-matrix (Dˆl) over cubic harmonics from the Cayley-Klein parameters, describing rotation.
subroutine rotations::wignermatrixelementforrealharmonics_eulerangles | ( | integer, intent(in) | l, |
integer, intent(in) | m1, | ||
integer, intent(in) | m2, | ||
real, intent(in) | alpha, | ||
real, intent(in) | beta, | ||
real, intent(in) | gamma, | ||
real, intent(out) | matrixElement | ||
) |
Subroutine calculates matrix elements (m1,m2) of the Wigner D-matrix (Dˆl) over cubic harmonics from the Euler Angles, describing rotation.
real function rotations::wignermatrixelementreal_eulerangles_fn | ( | integer, intent(in) | l, |
integer, intent(in) | m1, | ||
integer, intent(in) | m2, | ||
real, intent(in) | alpha, | ||
real, intent(in) | beta, | ||
real, intent(in) | gamma | ||
) |
Returns the value of the Wigner D-matrix element, describing rotation of a real (cubic) harmonic, in ZYZ convention.
real function rotations::wignersmalldmatrixelement_eulerangles_fn | ( | integer, intent(in) | l, |
integer, intent(in) | m1, | ||
integer, intent(in) | m2, | ||
real, intent(in) | beta | ||
) |
Returns the value of the Wigner small d-matrix element, which specifies coefficients for rotation a complex (spherical) harmonic around the Y axis.
\[ d^{l}_{m_{1}m_{2}}\left(\beta\right)= \sqrt{\left(j-m_{1}\right)!\left(j+m_{1}\right)!\left(j-m_{2}\right)!\left(j+m_{2}\right)!} \sum_{h=h_{min}}^{h_{max}}\left(-1\right)^{m_{1}-m_{2}+h} \frac{\left(\cos\frac{\beta}{2}\right)^{2j+m_{2}-m_{1}-2h}\left(\sin\frac{\beta}{2}\right)^{m_{1}-m_{2}+2h}} {h!\left(m_{1}-m_{2}+h\right)!\left(j-m_{1}-h\right)!\left(j+m_{2}-h\right)!} \]
subroutine rotations::xrot | ( | real, intent(in) | angle, |
type(rotation), intent(out) | rm | ||
) |
|
private |
subroutine rotations::yrot | ( | real, intent(in) | angle, |
type(rotation), intent(out) | rm | ||
) |
subroutine rotations::zrot | ( | real, intent(in) | angle, |
type(rotation), intent(out) | rm | ||
) |
|
private |
complex, dimension(-2:2,-2:2), public rotations::harmonicstransform_d = reshape( [cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,-sq0p5), cmplx(0.0,0.0),cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,sq0p5),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(1.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(-sq0p5,0.0),cmplx(0.0,0.0), cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(sq0p5,0.0)], [5,5]) |
Global variable containing matrices transforming spherical harmonics for l=2 to the cubic ones.
complex, dimension(-3:3,-3:3), public rotations::harmonicstransform_f = reshape( [cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,sq0p5), cmplx(0.0,0.0),cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,-sq0p5),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(1.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(-sq0p5,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0), cmplx(0.0,0.0),cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(sq0p5,0.0),cmplx(0.0,0.0), cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(0.0,0.0),cmplx(-sq0p5,0.0)], [7,7]) |
Global variable containing matrices transforming spherical harmonics for l=3 to the cubic ones.
complex, dimension(-1:1,-1:1), public rotations::harmonicstransform_p = reshape( [cmplx(0.0,sq0p5),cmplx(0.0,0.0),cmplx(0.0,sq0p5), cmplx(0.0,0.0),cmplx(1.0,0.0),cmplx(0.0,0.0), cmplx(sq0p5,0.0),cmplx(0.0,0.0),cmplx(-sq0p5,0.0)], [3,3]) |
Global variable containing matrices transforming spherical harmonics for l=1 to the cubic ones.
complex, dimension(0:0,0:0), public rotations::harmonicstransform_s = cmplx(1.0, 0.0) |
Global variable containing matrices transforming spherical harmonics for l=0 to the cubic ones.
type(complex_matrix), dimension(0:3), public rotations::sphericaltocubicmatrices |