How to get circle points in 3d given a radius and a vector orthogonal to the circle area? I already know how to get a point on a circle (here), but I need a circle in 3d which should be the orthogonal to a given vector.
I got:


*

*Angle in degree/radians

*Circle radius

*Orthogonal vector


I think, I need to rotate the 2d circle positions to be orthogonal to the given vector, but I do not how how to do that.
 A: Let $\newcommand{n}{\mathbf n}\newcommand{u}{\mathbf u}\newcommand{v}{\mathbf v}\n$ be the given vector orthogonal to the circle. 
You can use two vectors of length $1$ orthogonal to $\n$ and to each other. One way to get these is to choose two other vectors that form a basis together with $\n$ and apply Gram-Schmidt. (Vectors along two axes will be OK as long as $\n$ is not in the plane of those two axes.)
Alternatively, if $\n$ is not along the $z$ axis, project it onto the $x,y$ plane, rotate $90$ degrees, and make a unit length vector in that direction. Then take the cross product with $\n$ and set the result to unit length to get the third vector. 
In any case, once you have your two new vectors $\u$ and $\v,$
a point on the circle is given by 
$$ (\cos\theta)\u + (\sin\theta)\v.$$
A: Let us denote the angle by $\theta$, the radius by $r$ and the orthogonal vector by $\vec a$ ("axis"); furthermore let us assume the length of $\vec a$ is 1.
First you must define which point is defined by $\theta=0$. If $\vec a$ is not parallel to the $xy$-plane then there is a unique vector $\vec v_0 = (x_0\, 0\, z_0)$ orthogonal to $\vec a$ with length $r$ and $x_0 > 0$. (Otherwise you need a different choice for $\vec v_0$. In 3D there is no obvious way to define such a $\vec v_0$ for any $\vec a$.)
Then all you need to do is rotate the vector $\vec v_0$ around $\vec a$ by the angle $\theta$. The formula is:
$$ \cos \theta\ \vec v_0 + (1-\cos \theta)(\vec a \cdot \vec v_0)\vec a + \sin \theta\ \vec a \times \vec v_0$$
