Abstract
There are several methods to perform rotations in space. That is, rotate a vector \({\vec{\text{v}}}\) and an angle θ around an axis in the direction of a vector \({\vec{\text{u}}}\), resulting in the rotated vector \({{\vec{v}^{\prime}}}\). Quaternions are generally used to solve rotation problems because they are considered to have the best computational complexity. However, this work shows that when the data is given in spherical coordinates, the use of spherical trigonometry formulas to solve a rotation, can offer better computational complexity than the quaternion method which is systematically used. Additionally, sometimes when the data is given in spherical coordinates, an abacus is used to solve the rotation problems. The use of abacus makes it possible to observe intermediate results as the rotation goes. Also, the use of spherical trigonometry formulas allows this, however it is not possible to do so using quaternions.
Similar content being viewed by others
Availability of data and material
Not applicable
Code Availability
Matlab.
References
Barrientos, A., Peñin, L., Balaguer, C., Aracil, R.: Fundamentos de Robótica. McGraw-Hill, New York (2007)
Sun, H.G., Zhang, Y., Baleanu, D., Chen, W., Chen, Y.Q.: A new collection of real-world applications of fractional calculus in science and engineering. Commun. Nonlinear Sci. Numer. Simul. 64, 213–231 (2018)
Abd El Salam M.A., Ramadan, M.A., Nassar, M.A., Agarwal, P., Chu, Y.-M.: Matrix computational collocation approach based on rational Chebyshev functions for nonlinear differential equations. Adv Differ Equ 1, 1–17 (2021)
Zelasco, J.F.: Resulting rotations in plate tectonics. (Rotaciones resultantes en tectónica de placas.) 17ª Meeting of Geodesy and Geophysics, Asociación Argentina de Geofísicos y Geodestas, University of Buenos Aires. October 1992.
Vince, J.: Quaternions for Computer Graphics. Springer, Cham (2011)
Lemonnier, H.: Fundamental formulas of spherical trigonometry and on torsion angles. (Formules fondamentales de la trigonométrie sphérique et sur les angles de torsion.) Nouvelles annales de mathématiques: journal des candidats aux écoles polytechnique et normale, 1(4), 606–616 (1845)
Mondal, S.R., Nisar, K.S., Abdeljawad, T.: On the study of trigonometric polynomials using strum sequence. J. Math. (2020)
Todhunter, I.: Spherical trigonometry for the use of colleges and schools (1858)
Funding
Not applicable.
Author information
Authors and Affiliations
Corresponding author
Ethics declarations
Conflict of interest
The authors declare that they have no known competing financial interests or personal relationships that could have appeared to influence the work reported in this paper.
Additional information
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Appendix: Obtaining angles ZUV′ and \({{\varvec{\lambda}}}_{\varvec{v}{^{\prime}}}\)
Appendix: Obtaining angles ZUV′ and \({{\varvec{\lambda}}}_{\varvec{v}{^{\prime}}}\)
The accounts to be made to obtain the angle \(ZUV\) from and of the angle \(ZUV\) depend on the location of the triangles formed by points \(Z, U\) and \(V\) and \(Z, U\) and V′. In particular, if divide the unit sphere into two hemispheres from the \(\overline{ZU }\) meridian, we can separate the cases depending on whether the triangle formed by \(Z, U\) and \(V\) is to the left or to the right of the meridian \(\overline{ZU }\), and in turn if the triangle formed by \(Z\), \(U\) and V′ is on the same side (it is saying, in the same hemisphere) or the other.
In the case where the triangle formed by \(Z, U\) and \(V\) is formed to the right of the \(\overline{ZU }\) meridian, the triangle formed by \(Z, U\) and V′ will form on the opposite side (as is the case in Fig. 2) if meets the condition
In this case you have:
If, on the contrary, the triangle formed by \(Z, U\) and \(V\) is formed on the same side as the formed by \(Z, U\) and V′ (that is, to the right of the \(\overline{ZU }\) meridian), which will happen if the condition is not met given by Eq. (16), you have the relationships:
The other possible case for the triangle formed by \(Z, U\) and \(V\) is that it forms to the left of the \(\overline{ZU }\) meridian. In that case, the triangle formed by \(Z, U\) and V′ will form a on the opposite side if complies that:
in which case we have:
If the condition given by Eq. (22) is not fulfilled (which implies that the triangle formed by \(Z, U\) and V′ it is formed on the left side of the \(\overline{ZU }\) meridian, just like the triangle formed by \(Z, U\) and \(V\)), the relationships are:
Rights and permissions
About this article
Cite this article
Suárez, M.D., Pavlov, L. & Zelasco, J.F. Efficiency Comparison of Quaternions and Spherical Trigonometry Formulas for 3D Rotations. Int. J. Appl. Comput. Math 8, 85 (2022). https://doi.org/10.1007/s40819-021-01238-5
Accepted:
Published:
DOI: https://doi.org/10.1007/s40819-021-01238-5