Rotation matrix for azimuth and zenith angles

In summary, the conversation discusses converting spherical coordinates to Cartesian and rotating a shape by incrementing theta and phi. The speaker shares a matrix for rotating the azimuth angle and asks for help finding one for the zenith angle. The expert suggests incrementing theta and phi before converting to Cartesian and warns against simply adding degrees. They also provide equations for rotating within a Cartesian system and explain the effects of incrementing theta and phi. The conversation ends with a question about interpreting mouse input.
  • #1
lightningbolt
2
0
I have a shape with spherical coordinate (r, theta, phi) which I can convert to Cartesian. I want to apply rotation to the shape by incrementing theta & phi.
I figured out the matrix for rotating azimuth angle is
{
{cos(theta), -sin(theta), 0}
{sin(theta), cos(theta), 0}
{ 0, 0, 1}
}
How to find the rotation matrix for Zenith angle?.
Thanks.
 
Physics news on Phys.org
  • #2
Why don't you increment θ and φ as you wish then convert to Cartesian?
 
  • #3
@SonyAD,
If you change θ and φ in spherical coordinates and convert to Cartesian, it won't result in the change you expect. It gives garbage values.
i.e I can't just add 5 degree to θ or φ, if i want to rotate the shape 5 degree.
Thanks.
 
  • #4
I don't think I understand what you're after.

If it is rotation equations inside a Cartesian system you're after:

v1 = calf*xi+salf*zi;
v2 = calf*zi-salf*xi;
v3 = cbet*yi+sbet*v2;

zr = cbet*v2-sbet*yi;
xr = cgam*v1+sgam*v3;
yr = cgam*v3-sgam*v1;

salf = [tex]\sin(\alpha)[/tex];
calf = [tex]\cos(\alpha)[/tex];

etc.

In case you're making a mistake converting to Cartesian, I've worked out how to do it and http://en.wikipedia.org/wiki/Spherical_coordinate_system#Cartesian_coordinates":

x = radius · sin(θ) · cos(φ)
y = radius · sin(θ) · sin(φ)
z = radius · cos(θ)


In case the spherical coordinate system isn't doing what you expect it to, when you increment θ and φ this is what actually happens:

You rotate the initial point around the absolute Y axis.
You rotate the transformed point around the absolute Z axis.

Are you trying to interpret mouse input?
 
Last edited by a moderator:
  • #5


I would like to commend you for taking the initiative to find the rotation matrix for your spherical coordinates. It is essential to have a solid understanding of coordinate systems and their transformations in order to accurately represent and manipulate data in various fields of science.

To answer your question, the rotation matrix for the zenith angle can be found by using the same approach as the azimuth angle. The zenith angle, also known as the polar angle, is the angle measured from the positive z-axis to the vector representing the point in spherical coordinates.

To rotate the shape by incrementing the zenith angle, we can use the following matrix:

{
{cos(phi), 0, sin(phi)}
{0, 1, 0}
{-sin(phi), 0, cos(phi)}
}

This matrix represents a rotation around the y-axis, which is perpendicular to the z-axis and passes through the origin. This rotation will change the value of the zenith angle while keeping the azimuth angle constant.

It is important to note that the order in which these rotations are applied matters. If you first apply the rotation for the azimuth angle and then the rotation for the zenith angle, the resulting shape will be different from if you apply the rotations in the opposite order. This is due to the fact that rotations are not commutative, meaning the order of operations affects the final outcome.

I hope this helps in your understanding of rotation matrices for spherical coordinates. Keep up the good work in exploring and understanding coordinate systems in your scientific endeavors.
 

1. What is a rotation matrix for azimuth and zenith angles?

A rotation matrix for azimuth and zenith angles is a mathematical tool used to describe the orientation of an object in three-dimensional space. It is commonly used in astronomy and geology to represent the position of celestial bodies or points on the Earth's surface.

2. How is a rotation matrix for azimuth and zenith angles calculated?

A rotation matrix for azimuth and zenith angles is calculated using trigonometric functions, specifically sine and cosine, based on the values of the azimuth and zenith angles. The resulting matrix can then be used to transform the coordinates of an object from one reference frame to another.

3. What do the entries in a rotation matrix for azimuth and zenith angles represent?

The entries in a rotation matrix for azimuth and zenith angles represent the direction cosines of the three axes of a three-dimensional coordinate system. These values determine the orientation of the reference frame and can be used to rotate and transform objects within that frame.

4. How is a rotation matrix for azimuth and zenith angles used in astronomy?

In astronomy, a rotation matrix for azimuth and zenith angles is used to represent the position of celestial objects such as stars, planets, and galaxies. It can also be used to calculate the position and movement of objects relative to each other, as well as to track the motion of objects in the night sky.

5. Can a rotation matrix for azimuth and zenith angles be used to describe the rotation of the Earth?

Yes, a rotation matrix for azimuth and zenith angles can be used to describe the rotation of the Earth. By using the Earth's rotation axis as one of the axes in the matrix, it is possible to represent the Earth's rotation and its orientation in space at any given time.

Similar threads

Replies
1
Views
1K
  • Differential Geometry
Replies
3
Views
2K
Replies
2
Views
975
  • Differential Geometry
Replies
7
Views
2K
  • Differential Geometry
Replies
12
Views
3K
  • Differential Geometry
Replies
7
Views
4K
  • Precalculus Mathematics Homework Help
Replies
31
Views
2K
  • Differential Geometry
Replies
8
Views
3K
  • Mechanical Engineering
Replies
3
Views
438
  • Advanced Physics Homework Help
Replies
4
Views
355
Back
Top