
ゴール
使用tikz-3dplot
、私は描きたい大圏これは、固定された視点 (つまり、視線方向を表すベクトルに垂直な平面) から見た半径 1 の球の輪郭を描き、他の大円がその球から「出ている」という印象を与えないようにするためのものです (下の図の紫色の輪郭で、他のどの大円とも重なり合っていません)。
ムウェ
\documentclass[a4paper]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{amsmath,amssymb}
\usepackage[english]{babel}
\usepackage{float}
\usepackage{tikz}
\usepackage{tikz-3dplot}
%%%%%%%%
\begin{document}
\pgfmathsetmacro{\rvec}{1}
\pgfmathsetmacro{\thetavec}{54}
\pgfmathsetmacro{\phivec}{54}
\pgfmathsetmacro{\view}{135}
\tdplotsetmaincoords{75}{\view}
\definecolor{darkgreen}{rgb}{0.1,0.9,0.1}
\begin{tikzpicture}[scale=5,tdplot_main_coords]
\coordinate (O) at (0,0,0);
% Axes
\draw[thick,->] (O) -- (2.0,0,0) node[anchor=north east]{$X$};
\draw[thick,->] (O) -- (0,2.0,0) node[anchor=north west]{$Y$};
\draw[thick,->] (O) -- (0,0,1.4) node[anchor=south]{$Z$};
% Great circle in the OXZ plane
\tdplotsetthetaplanecoords{0}
\tdplotdrawarc[tdplot_rotated_coords]{(O)}{\rvec}{0}{180}{}{}
\tdplotdrawarc[tdplot_rotated_coords,loosely dashed,gray]{(O)}{\rvec}
{180}{360}{}{}
% Great circle in the OYZ plane
\tdplotsetthetaplanecoords{90}
\tdplotdrawarc[tdplot_rotated_coords]{(O)}{\rvec}{0}{180}{}{}
\tdplotdrawarc[tdplot_rotated_coords,losely dashed,gray]{(O)}{\rvec}
{180}{360}{}{}
% Great circle in the OXY plane
\tdplotdrawarc[blue]{(O)}{\rvec}{-55}{125}{}{}
\tdplotdrawarc[loosely dashed,blue]{(O)}{\rvec}{125}{305}{}{}
%% Testing great circles
% Rotated Great circle around Z-axis, this is the first wanted rotation
% to bring it in the original, non rotated "O-Y_ori-Z" plane.
\tdplotsetthetaplanecoords{\view}
\tdplotdrawarc[tdplot_rotated_coords,cyan]{(O)}{\rvec}{0}{360}{}{}
% Rotated big circle around Y-axis, this second rotation should be applied
% just after the previous one, i.e. on the great circle colored in cyan.
% How to do that ?
\tdplotsetrotatedthetaplanecoords{15}
\tdplotdrawarc[tdplot_rotated_coords,darkgreen]{(O)}{\rvec}{0}{360}{}{}
\end{tikzpicture}
\end{document}
現在のコードの結果:
私が望んでいるのは、パーツ内の最初の回転、次に 2 番目の回転 (この順序で) の合成の結果を取得することですTesting
が、それを tikz に伝える方法がわかりません。
答え1
tikzpicture
これを説明した問題に追加して解決します。
\tdplotsetrotatedcoords{\azimuth-90}{75}{0}
\begin{scope}[tdplot_rotated_coords]
\tdplotdrawarc[red]{(O)}{\radius}{0}{360}{}{}
\end{scope}
視覚効果を高めるために、極角を 75 度ではなく 55 度にした場合の結果の円 (赤) を以下に示します。
関数を使用すると魔法が現れます\tdplotsetrotatedcoords
: