Page 1 of 1

Euler to polar angles for levelsplot

Posted: Fri Apr 17, 2020 2:39 am
by thanasis
Hello,

Whereas curry and pepper use the Euler angles of Exp.CrystalOrientation to calculate properties along specific orientations, levelsplot uses polar angles in Ori.

In the simple case of Exp.MolFrame = [0 0 0], to transform the Euler angles of Exp.CrystalOrientation to polar angles, I am using the following transformations:

Code: Select all

Rp = erot(Exp.CrystalOrientation)
v = Rp*[0; 0; 1]
[phi,theta] = vec2ang(v)
Ori=[phi,theta]
Would that be correct?
What if Exp.MolFrame is not zero?

Maybe levelsplot could use the same Euler angles as curry and pepper in a future version, for better integration with the other functions?

Re: Euler to polar angles for levelsplot

Posted: Fri Apr 17, 2020 6:30 am
by katarkon
I don't completely shure, but You should use active rotation matrix Ra=Rp.' in this case as it's described in the erot documrntation.

Re: Euler to polar angles for levelsplot

Posted: Fri Apr 17, 2020 6:40 am
by thanasis
From some numerical tests I believe Rp does seem to give correct results.

However, I found that there is a snag, as the use of a vector (v) means it can only work for axial systems.

The information on the third Euler angle (required in the case of rhombic systems) is lost. So, using vec2ang is not a good approach.

Re: Euler to polar angles for levelsplot

Posted: Fri Apr 17, 2020 10:46 am
by Stefan Stoll
For levelsplot, Exp.MolFrame is disregarded, since the magnetic-field orientation for levelsplot is defined relative to the molecular frame, whereas Exp.MolFrame defines the orientation of the molecular frame relative to the crystal frame.

Re: Euler to polar angles for levelsplot

Posted: Fri Apr 17, 2020 10:53 am
by thanasis
Thanks Stefan.

Is there any way to define a third angle, i.e. the "twist" of a rhombic system around the polar vector?

Re: Euler to polar angles for levelsplot

Posted: Fri Apr 17, 2020 11:00 am
by Stefan Stoll
You can supply levelsplot with the three Euler angles in Ori. This is documented.