# How to draw spherical figures?

I need to input in my document this kind of images. How to 1. draw this image? 2. set its position to text? 3. enumerate and give name, to refer to its number?

• For spherical drawings (and 3d in general) Asymptote is probably the drawing language of choice. There's a well written manual and plenty of examples. You will get more advice and help here, if you have a specific problem once you get started. – Thruston Feb 27 '15 at 16:33
• 1.: tex.stackexchange.com/q/53445 tex.stackexchange.com/q/159445 2. and 3. are really basics and can be found in each introduction to TeX or on this site. – LaRiFaRi Feb 27 '15 at 16:33
• You have the image already---why draw it again? Just do this: \begin{figure}\includegraphics[width=\linewidth,height=0.75\textheight,keepaspectratio]{sphereimagefile}\caption{Sphere}\label{fig:sphere}\end{figure} – musarithmia Feb 27 '15 at 16:49
• If you don't know how to do labels and cross-references in LaTeX, I would not advise trying to draw a sphere. – musarithmia Feb 27 '15 at 16:50
• I would like to put them by code, because the quality of image will be better. I'm aware of Asymptote, but I don't want to use it in LaTeX documment. – Giorgi Feb 27 '15 at 17:02

This is a possible solution via tikz-3dplot, to serve as a starting point.

code

\documentclass[border=10pt]{standalone}
\usepackage{tikz,amsmath}
\usepackage{tikz-3dplot}
\usetikzlibrary{shapes,calc,positioning}
\usetikzlibrary{calc,intersections}
\begin{document}

\tdplotsetmaincoords{90}{90}

\begin{tikzpicture}[scale=5,tdplot_main_coords]

% draw various ellipses
\tdplotsetthetaplanecoords{90}
\tdplotdrawarc[tdplot_rotated_coords,thick]{(0,0,0)}{0.8}{0}{360}{}{}
%
\tdplotsetrotatedcoords{60}{70}{0}
\tdplotdrawarc[dashed,tdplot_rotated_coords,name path=blue]{(0,0,0)}{0.8}{0}{360}{below}{$\alpha_2$}
\tdplotdrawarc[tdplot_rotated_coords]{(0,0,0)}{0.8}{0}{180}{above right}{$\alpha_1$}
%
\tdplotsetrotatedcoords{120}{110}{0}
\tdplotdrawarc[dashed,tdplot_rotated_coords,name path=green]{(0,0,0)}{0.8}{0}{360}{below}{$\beta$}
\tdplotdrawarc[tdplot_rotated_coords]{(0,0,0)}{0.8}{0}{180}{left}{$\mathcal A_2$}
%
\tdplotsetrotatedcoords{180}{16}{0}
\tdplotdrawarc[dashed,tdplot_rotated_coords,name path=red]{(0,0,0)}{0.8}{0}{360}{above left}{$\zeta$}
\tdplotdrawarc[tdplot_rotated_coords]{(0,0,0)}{0.8}{-90}{90}{below left}{$\gamma$}

% find intersections

\path [name intersections={of={green and blue}, total=\n}]
\foreach \i in {1,...,\n}{(intersection-\i) circle [radius=0.5pt] coordinate(gb\i){}};

\path [name intersections={of={green and red}, total=\n}]
\foreach \i in {1,...,\n} {(intersection-\i) circle [radius=0.5pt]coordinate(gc\i){}};

\path[name intersections={of={red and blue}, total=\n}]
\foreach \i in {1,...,\n}{(intersection-\i) circle [radius=0.5pt]coordinate(cb\i){}};

(cb4) to[bend left=7] (gc1) to[bend left=15] (gb2) to[bend left=15] cycle;

% label
\draw (gb2) node[below]{$\mathcal C$};
\draw (gc1) node[above right]{$\mathcal A_1$};
\draw (cb4) node[above left]{$\mathcal B$};
\draw[] (gc1) to[bend left=30] ++(1,0.71,0.5)node(a){};
\draw[thick,->] (0,0,0) -- (1,0,0) node[anchor=north east]{$X$};
\draw[thick,->] (0,0,0) -- (0,1,0) node[anchor=north west]{$Y$};
\draw[thick,->] (0,0,0) -- (0,0,1) node[anchor=south]{$Z$};

• For triangle, just replace to[bend left=xx] with --. For complex surface (3D), clip are often used, but usually not an easy task. – Jesse Feb 28 '15 at 15:06