# Finding an instance of a parametric equation that intersects given points

So I have this equation for a circle centered at the origin that has some orientation in 3D space.

rotatedCircle[t_, \[Alpha]_, \[Beta]_] :=
RollPitchYawMatrix[{\[Alpha], \[Beta], 0}, {1, 2, 3}].( {
{Cos[t]},
{Sin[t]},
{0}
} )


I'd like to find a circle that intersects two points on the surface of a sphere (also centered at the origin), solving for \[Alpha] and \[Beta] above (and I suppose I'd want to be able to tell it that t goes from 0 to 2 Pi). What can I use to solve this?

• What is the sphere of interest? What other constraints are there? As given, there is not enough information to offer guidance. Mar 26 '20 at 0:14
• Note that a circle is only uniquely determined by three conditions, and specifying just two points does not suffice. Mar 26 '20 at 0:30
• Everything is centered at the origin. I'll add that to the post Mar 26 '20 at 4:48

If both the sphere and the circle passing through two of the sphere's points have the same center, then the sphere is necessarily a great circle.

In the following example, I restrict myself to a unit sphere (scale up or down whenever appropriate):

(* two points on the sphere; one could also use RandomPoint[Sphere[], 2] *)
BlockRandom[SeedRandom["fp.monkey"];
sphrpts = RandomSample[RandomVariate[CircularRealMatrixDistribution[3]], 2]];

(* roll-pitch-yaw angles *)
ang = RollPitchYawAngles[RotationMatrix[{{0, 0, 1}, Cross @@ sphrpts}], {1, 2, 3}];

Show[Graphics3D[{{Opacity[1/2], Sphere[]}, {AbsolutePointSize[6], Point[sphrpts]}}],
ParametricPlot3D[RollPitchYawMatrix[ang, {1, 2, 3}].{Cos[t], Sin[t], 0} // Evaluate,
{t, -π, π}], Boxed -> False]


• So I had previously tried a solution like this that used the cross product to find the great circle, but it fails in the case of antipodal points where the cross product is the zero vector. My hope with finding an instance of a parametric equation that solved the problem is that in that in the case of antipodal points, I could set a rotation to an arbitrary angle to get a unique solution. Mar 27 '20 at 22:41
• This really is information that you should have added to your question. Indeed, infinitely many great circles pass through antipodal points, so you need another condition. What is that condition for you? Mar 28 '20 at 11:56