Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm running TeXworks and MikTeX on Microsoft Windows and within a document I have the code you see below. Compiling results in a pdf file in which I can see the text within this picture but I can't see the line or the circles. Nonetheless when I print it the line and the circles are there. Is there something I can do differently to make the line and the circles visible?

\setlength{\unitlength}{0.66mm}

\begin{picture}(100,100)(0,0)

\label{picture of bitangent plane}

\put(40,50){\circle{60}}      % left big circle

\put(140,50){\circle{60}}     % right big circle

\put(122,74){\circle*{2}}     % dot at e^{i\theta} on right circle

\put(122,26){\circle*{2}}     % dot at e^{-i\theta} on right circle

\put(58,26){\circle*{2}}      % dot at e^{-i\theta} on left circle

\put(70,50){\circle*{2}}      % dot at -1 on left circle

\put(38,11){\line(4,3){104}}  % line

\put(140,80){\circle*{2}}     % dot at i on right circle

\put(140,20){\circle*{2}}     % dot at -i on right circle

\put(170,50){\circle*{2}}     % dot at 1 on right circle

\put(110,50){\circle*{2}}     % dot at -1 on right circle

\put(10,50){\circle*{2}}      % dot at 1 on left circle

\put(40,80){\circle*{2}}      % dot at i on left circle

\put(40,20){\circle*{2}}      % dot at -i on left circle

\put(58,74){\circle*{2}}      % dot at e^{i\theta} on left circle

\put(116,76){$e^{i\theta}$}   % right

\put(115,19){$e^{-i\theta}$}  % right

\put(62,76){$e^{i\theta}$}

\put(59,19){$e^{-i\theta}$}   % left

\put(173,49){$1$}  \put(5,49){$1$}

\put(101,49){$-1$} \put(72,49){$-1$}

\put(140,83){$i$}  \put(40,83){$i$}

\put(137,14){$-i$} \put(35,14){$-i$}

\put(70,5){\text{The bitangent plane.}}

\end{picture}
share|improve this question

5 Answers 5

Your circles are too small and you get warnings:

LaTeX Warning: \oval, \circle, or \line size unavailable on input line 6.
LaTeX Warning: \oval, \circle, or \line size unavailable on input line 7.

Load the pict2e package.

I also fixed the bounding box and put the picture in a figure environment. Your \label command is out of place where you put it.

\documentclass{article}
\usepackage{pict2e}
\begin{document}

\begin{figure}
\centering
\setlength{\unitlength}{0.66mm}
\begin{picture}(180,100)(0,0)
\put(40,50){\circle{60}}      % left big circle
\put(140,50){\circle{60}}     % right big circle
\put(122,74){\circle*{2}}     % dot at e^{i\theta} on right circle
\put(122,26){\circle*{2}}     % dot at e^{-i\theta} on right circle
\put(58,26){\circle*{2}}      % dot at e^{-i\theta} on left circle
\put(70,50){\circle*{2}}      % dot at -1 on left circle
\put(38,11){\line(4,3){104}}  % line
\put(140,80){\circle*{2}}     % dot at i on right circle
\put(140,20){\circle*{2}}     % dot at -i on right circle
\put(170,50){\circle*{2}}     % dot at 1 on right circle
\put(110,50){\circle*{2}}     % dot at -1 on right circle
\put(10,50){\circle*{2}}      % dot at 1 on left circle
\put(40,80){\circle*{2}}      % dot at i on left circle
\put(40,20){\circle*{2}}      % dot at -i on left circle
\put(58,74){\circle*{2}}      % dot at e^{i\theta} on left circle
\put(116,76){$e^{i\theta}$}   % right
\put(115,19){$e^{-i\theta}$}  % right
\put(62,76){$e^{i\theta}$}
\put(59,19){$e^{-i\theta}$}   % left
\put(173,49){$1$}  \put(5,49){$1$}
\put(101,49){$-1$} \put(72,49){$-1$}
\put(140,83){$i$}  \put(40,83){$i$}
\put(137,14){$-i$} \put(35,14){$-i$}
\end{picture}
\caption{The bitangent plane}\label{fig:bitangentplane}
\end{figure}
\end{document}

enter image description here

share|improve this answer

With tikz:

\documentclass{article}
\usepackage{amsmath}
\usepackage{tikz}

\begin{document}
\begin{tikzpicture}
  \draw (0,0) circle [radius=2cm];
  \foreach \ang/\x in {0/$-1$,45/$e^{i\theta}$,90/$i$,180/$1$,270/$-i$,315/$e^{-i\theta}$}{%
   \node[circle,fill=black,inner sep=1.5pt,outer sep=0pt] (a\ang) at (\ang:2cm) {};
   \node  at (\ang:2.4cm) {\x};
  }
  \draw (5.7,0) circle [radius=2cm];
  \foreach \ang/\x in {0/$1$,135/$e^{i\theta}$,90/$i$,180/$-1$,270/$-i$,225/$e^{-i\theta}$}{%
   \node[circle,fill=black,inner sep=1.5pt,outer sep=0pt] (b\ang) at ([xshift=5.7cm]\ang:2cm) {};
   \node  at ([xshift=5.7cm]\ang:2.4cm) {\x};
  }
  \draw[shorten >=-2cm,shorten <=-2cm] (a315) -- (b135);
  \node at (3,-3) {The bitangent plane.};
\end{tikzpicture}

\end{document}

enter image description here

share|improve this answer
    
@TheLastError Do you have a counter? We don't compete with pstricks in this aspect ;) –  Harish Kumar Feb 22 at 12:24
    
charactercountonline.com is my counter. –  Oh my ghost Feb 22 at 12:25

A solution where only the center of the circles and the radius is defined:

\documentclass{article}
\usepackage{pstricks-add}

\begin{document}

\begin{figure}
\psset{unit=0.66mm} \def\CRadius{30 }
\begin{pspicture}(175,70)
\pnodes(40,35){M1}(140,35){M2}
\pscircle(M1){\CRadius}      % left big circle
\pscircle(M2){\CRadius}     % right big circle
\psCircleTangents(M1){\CRadius}(M2){\CRadius}%
\psdots(CircleTO1)(CircleTO2)(CircleTO3)(CircleTO4)%
       (CircleTI1)(CircleTI2)(CircleTI3)(CircleTI4)
\rput(M1){\psdots(\CRadius;180)(\CRadius;0)}
\rput(M2){\psdots(\CRadius;180)(\CRadius;0)}
\pcline[nodesep=-17,linecolor=red](CircleTI3)(CircleTI4)%
\uput[45](CircleTI1){$e^{i\theta}$}  \uput[135](CircleTI4){$e^{i\theta}$}
\uput[225](CircleTI2){$e^{-i\theta}$}\uput[-45](CircleTI3){$e^{-i\theta}$}
\uput[180](!\psGetNodeCenter{M1}M1.x \CRadius sub M1.y){1} 
\uput[0](!\psGetNodeCenter{M1}M1.x \CRadius add M1.y){-1} 
\uput[180](!\psGetNodeCenter{M2}M2.x \CRadius sub M2.y){-1} 
\uput[0](!\psGetNodeCenter{M2}M2.x \CRadius add M2.y){1} 
\uput[90](CircleTO1){$i$}  \uput[90](CircleTO2){$i$}
\uput[-90](CircleTO3){$-i$}\uput[-90](CircleTO4){$-i$}
\end{pspicture}
\caption{The bitangent plane}
\end{figure}

\end{document}

enter image description here

share|improve this answer

LaTeX's picture environment only supports a limited range of slopes and radii, because circles and lines are constructed using font glyphs:

LaTeX Warning: \oval, \circle, or \line size unavailable on input line 9.

Package pict2e circumvent these limitations by using graphics commands:

\documentclass{article}
\usepackage{amsmath}
\usepackage{pict2e}

\begin{document}
\setlength{\unitlength}{0.66mm}
\begin{picture}(175,90)(5,3)
\label{picture of bitangent plane}
\put(40,50){\circle{60}}      % left big circle
\put(140,50){\circle{60}}     % right big circle
\put(122,74){\circle*{2}}     % dot at e^{i\theta} on right circle
\put(122,26){\circle*{2}}     % dot at e^{-i\theta} on right circle
\put(58,26){\circle*{2}}      % dot at e^{-i\theta} on left circle
\put(70,50){\circle*{2}}      % dot at -1 on left circle
\put(38,11){\line(4,3){104}}  % line
\put(140,80){\circle*{2}}     % dot at i on right circle
\put(140,20){\circle*{2}}     % dot at -i on right circle
\put(170,50){\circle*{2}}     % dot at 1 on right circle
\put(110,50){\circle*{2}}     % dot at -1 on right circle
\put(10,50){\circle*{2}}      % dot at 1 on left circle
\put(40,80){\circle*{2}}      % dot at i on left circle
\put(40,20){\circle*{2}}      % dot at -i on left circle
\put(58,74){\circle*{2}}      % dot at e^{i\theta} on left circle
\put(116,76){$e^{i\theta}$}   % right
\put(115,19){$e^{-i\theta}$}  % right
\put(62,76){$e^{i\theta}$}
\put(59,19){$e^{-i\theta}$}   % left
\put(173,49){$1$}  \put(5,49){$1$}
\put(101,49){$-1$} \put(72,49){$-1$}
\put(140,83){$i$}  \put(40,83){$i$}
\put(137,14){$-i$} \put(35,14){$-i$}
\put(70,5){\text{The bitangent plane.}}
\end{picture}
\end{document}

Result

And for fun, a golfed version for The Last Error:

\documentclass{book}\usepackage{pict2e}\begin{document}\def~#1,#2
{\p#1,#2{\circle*{2}}}\def\p#1,#2#{\put(#1,#2)}\def\m#1,#2,#3 #4
{\p#1,#3{#4}\p#2,#3{#4}}\unitlength0.66mm\picture(170,87)~53,23
\m35,135,47 \circle{60} \p33,8{\line(4,3){104}}~117,71 ~117,23 ~65,47
~135,77 ~135,17 ~165,47 ~105,47 ~5,47 ~35,77 ~35,17 ~53,71 \m57,111,73
$e^{i\theta}$ \m54,110,16 $e^{-i\theta}$ \m0,168,46 $1$ \m67,96,46 $-1$
\m35,135,80 $i$ \m30,132,11 $-i$
\p65,2{The bitangent plane.}\endpicture\end{document}
share|improve this answer
2  
@TheLastError: 516 characters. –  Heiko Oberdiek Feb 22 at 13:44
1  
@TheLastError: Reduced to 495 characters. –  Heiko Oberdiek Feb 22 at 14:06

Reducing the number of used characters in the existing answers.

\documentclass[pstricks,border=12pt,12pt]{standalone}
\usepackage{pst-node,pst-plot}
\psset{plotpoints=9,unit=3}
\degrees[8]
\makeatletter
\newcommand\Right[2][1 1]{%
    \psscalebox{#1}{%
    \rput(!2 sqrt 0){\curvepnodes{0}{8}{1 t \pst@angleunit PtoC}{#2}\pscircle{1}}%
    \foreach \i/\t in {0/1,2/i,3/e^{i\theta},4/-1,5/e^{-i\theta},6/-i}{\qdisk(#2\i){2pt}\uput[\i](#2\i){\psscalebox{#1}{$\t$}}}%
}}
\makeatother

\begin{document}
\begin{pspicture}(-2.5,-1.5)(2.5,1.5)
    \Right{A}\Right[-1 1]{B}\pcline[nodesep=-1](A3)(B5)
\end{pspicture}
\end{document}

enter image description here

Golfed version (446 characters)

\documentclass[pstricks]{standalone}\usepackage{pstricks-add}\degrees[8]\makeatletter\def\R#1#2{\psscalebox{#1}{\rput(!2 sqrt 3 mul 0){\curvepnodes[plotpoints=9]{0}{8}{3 t \pst@angleunit PtoC}{#2}\pscircle{3}}\foreach \i/\t in {0/1,2/i,3/e^{i\theta},4/-1,5/e^{-i\theta},6/-i}{\qdisk(#2\i){.1}\uput[\i](#2\i){\psscalebox{#1}{$\t$}}}}}\begin{document}\pspicture(-9,-5)(9,5)\R{1 1}{A}\R{-1 1}{B}\pcline[nodesep=-1](A3)(B5)\endpspicture\end{document}
share|improve this answer
    
In search of less characters don't lose the code readability a good balance is imp. can you make the code with new line instead of single line. –  texenthusiast Feb 22 at 14:00
    
@texenthusiast: The golfed version is not for readability but for fun. It should be ignored by those who are not interested in golfing. –  Oh my ghost Feb 22 at 14:02

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.