Rotate a vector around another vector?

If I have vector A, and I want to rotate it n degrees around vector B, what is the equation for this?

Ax#,Ay#,Az# is pointing somewhere.

Bx#,By#,Bz# is an axis I want to rotate vector A around by n degrees.

this is more something for the maths subforum here…

but at http://skal.planet-d.net/demo/matrixfaq.htm
you will find how to construct rotation matrix for angle,axis and then transform the vector A with that matrix

Didn’t realize there was a math forum.

I’d like to do this without a matrix. I’m sure it’s possible.

well you can always “compress” the operations that are done to turn the angle axis to matrix and those which transform the vector with that matrix to just one operation.