CCL: Fractional to orthonormal converting matrix



Masoud, I am not an expert in maths, but this sounds similar to the shift in the laboratory and reference frames used in NMR spectroscopy. I am not sure in such cases whether the angle between the XY, XZ and YZ axes must be 90 degrees. You may want to look at that possibility before doing lots of hard work starting from the big bang. You may simply be able to expand on what exists in that area to define your own co-ordinate system. Just another crazy idea! David

On Sat, Sep 24, 2011 at 4:09 AM, Masoud m_nahali!A!alum.sharif.edu <owner-chemistry-#-ccl.net> wrote:
Dear Herbert

Thanks for your prompt reply. I fancy calculating the converting matrix considering no specific preferred direction. I meant if a, b, and c vectors were in any direction and certainly were not taken in X or XY plane I would like to calculate the converting matrix in this case. Actually I am writing a Fortran 90 program in which the a, b, and c vectors (every vectors may have different angles with respect to X Y Z coordination axes) are as input file and then the program would calculate converting matrix and it is a key point since through this matrix any atomic positions (orthonormal or fractional) could be converted to each other with no limitation on how and where the vectors or axes are.     

Best Wishes

 Masoud






On Fri, Sep 23, 2011 at 5:54 PM, Herbert Fruchtl herbert.fruchtl..st-andrews.ac.uk <owner-chemistry^^^ccl.net> wrote:

Sent to CCL by: Herbert Fruchtl [herbert.fruchtl::st-andrews.ac.uk]
Fractional coordinates, in connection with lattice parameters (lengths and angles rather than lattice vectors), don't contain any information about orientation in a Cartesian coordinate system, so you have to choose one. If you multiply the transformation matrix described in your link with a rotation matrix (rotating your coordinates around any axis by any angle), you get another valid transformation matrix. You don't say which orientation you want instead of the simplest one.

HTH,

  Herbert



On 23/09/11 15:50, Masoud Nahali m_nahali ~ alum.sharif.edu wrote:

Sent to CCL by: "Masoud  Nahali" [m_nahali=alum.sharif.edu]
Dear CCL Friends

There is a matrix that converts fractional coordinates to orthonormal ones and certainly the vice versa could be done by an inverted matrix. In the following link you can find this matrix and a brief justification.

http://www.angelfire.com/linux/myp/FracCor/fraccor.html

There are 2 limitations in this approach since we have to take one of the vectors on X axis and also another vector must be on X-Y plane.

I need a general form of such converting matrix without the 2 limitations. I mean that a, b, and c vectors shouldn't be limited to locate in/on a specific direction (plane) like X-axis or X-Y plane. I appreciate any suggestion in advance to find it.



Best Wishes
Masoud>


--
Herbert Fruchtl
Senior Scientific Computing Officer
School of Chemistry, School of Mathematics and Statistics
University of St Andrews
--
The University of St Andrews is a charity registered in Scotland:
No SC013532