Mathematica绘制曲面交线方法(方法二)
MeshFunction方式
Show[Graphics3D[{Opacity[0.5], Ball[{0, 0, 0}, 2]}],
ParametricPlot3D[{4 + (3 + Cos[v]) Sin[u], (3 + Cos[v]) Cos[u],
Sin[v]}, {u, 0, 2 \[Pi]}, {v, -\[Pi], \[Pi]},
MeshFunctions -> Function[{x, y, z}, (z^2 + x^2 + y^2)],
Mesh -> {{{4, Directive[Thick, Red]}}}, PlotPoints -> 50],
Boxed -> False]