Rotating vector x around vector z

  • Context: Undergrad 
  • Thread starter Thread starter ddr
  • Start date Start date
  • Tags Tags
    Rotating Vector
Click For Summary
SUMMARY

The discussion focuses on the mathematical process of rotating vector x around vector z by a specified angle alpha. The initial formula provided involves calculating the projection of vector x onto vector z, denoted as xonz, and then determining the orthogonal component y. The final rotation formula is expressed as answer = xonz + y cos[alpha] + (z/|z|) × y sin[alpha], where × represents the vector product. The participants suggest that a simpler form of this rotation could exist and encourage further exploration.

PREREQUISITES
  • Understanding of vector mathematics
  • Familiarity with scalar and vector products
  • Knowledge of trigonometric functions (cosine and sine)
  • Ability to manipulate vector components in three-dimensional space
NEXT STEPS
  • Research vector rotation techniques in 3D graphics
  • Learn about quaternion representations for rotations
  • Explore the application of rotation matrices in computer graphics
  • Investigate simplifications in vector mathematics for efficiency
USEFUL FOR

Mathematicians, computer graphics developers, and anyone involved in physics simulations or 3D modeling who needs to understand vector rotations in three-dimensional space.

ddr
Is this how it should be done (rotating vector x around vector z for alpha degrees):
assumes |x|*|z|<>0
xonz=(scalar_product(z,x)/(|x|*|z|))*z;
y=x-xonz;
assumes |x|<>0
result=cos(alpha)*x+sin(aplha)*(|y|/|x|)*y;
 
Physics news on Phys.org
correction

actually y=croos_vector(z,(x-xonz))/|x-xonz|^2
 
Not quite. I should say:

answer = xonz + y cos [alpha] + z/|z| X y sin [alpha].

Where X means vector product. And y = x - xonz.

Note: There should be a simpler form to this. Try yourself, please!
 
Last edited:

Similar threads

  • · Replies 7 ·
Replies
7
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 3 ·
Replies
3
Views
3K
Replies
7
Views
4K
  • · Replies 7 ·
Replies
7
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 9 ·
Replies
9
Views
2K
  • · Replies 12 ·
Replies
12
Views
5K