summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/texdraw
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2019-05-06 22:06:13 +0000
committerKarl Berry <karl@freefriends.org>2019-05-06 22:06:13 +0000
commit8a185390c6e2c38df4c6fef045bd079b218353e1 (patch)
treece50f56a94b9e1a8feb0b42c27876b655fd60123 /Master/texmf-dist/tex/generic/texdraw
parent926e35dfc63afa701f76cdefd4d6a3aad4883df7 (diff)
texdraw (6may19)
git-svn-id: svn://tug.org/texlive/trunk@51030 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/generic/texdraw')
-rw-r--r--Master/texmf-dist/tex/generic/texdraw/blockdiagram.tex10
-rw-r--r--Master/texmf-dist/tex/generic/texdraw/texdraw.sty10
-rw-r--r--Master/texmf-dist/tex/generic/texdraw/texdraw.tex263
-rw-r--r--Master/texmf-dist/tex/generic/texdraw/txdexamp.latex514
-rw-r--r--Master/texmf-dist/tex/generic/texdraw/txdexamp.tex485
-rw-r--r--Master/texmf-dist/tex/generic/texdraw/txdps.tex10
-rw-r--r--Master/texmf-dist/tex/generic/texdraw/txdtools.tex10
7 files changed, 165 insertions, 1137 deletions
diff --git a/Master/texmf-dist/tex/generic/texdraw/blockdiagram.tex b/Master/texmf-dist/tex/generic/texdraw/blockdiagram.tex
index eb944f0db8b..d800513c15a 100644
--- a/Master/texmf-dist/tex/generic/texdraw/blockdiagram.tex
+++ b/Master/texmf-dist/tex/generic/texdraw/blockdiagram.tex
@@ -1,6 +1,6 @@
% Block diagrams in TeXdraw
-% $Id: blockdiagram.tex,v 1.12 2019/03/28 texdraw-V2R0a $
+% $Id: blockdiagram.tex 1.15 2019/04/18 TeXdraw-v2r3 $
% Copyright (C) 1993-2019 Peter Kabal
@@ -10,14 +10,12 @@
% Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
% Peter Kabal
-% Department of Electrical Engineering
+% Department of Electrical & Computer Engineering
% McGill University
-% 3480 University
-% Montreal, Quebec
-% Canada H3A 2A7
% peter dot kabal at mcgill dot ca
-
+% http://www-mmsp.ece.mcgill.ca/MMSP/Documents/Software/
+
% ===============================================================
\input txdtools
diff --git a/Master/texmf-dist/tex/generic/texdraw/texdraw.sty b/Master/texmf-dist/tex/generic/texdraw/texdraw.sty
index 2452991e81d..c91c6b5af08 100644
--- a/Master/texmf-dist/tex/generic/texdraw/texdraw.sty
+++ b/Master/texmf-dist/tex/generic/texdraw/texdraw.sty
@@ -1,6 +1,6 @@
% TeXdraw macros
-% $Id: texdraw.sty,v 2.4 2019/03/28 texdraw-V2R0a $
+% $Id: texdraw.sty 2.6 2019/04/18 TeXdraw-v2r3 $
% Copyright (C) 1991-2019 Peter Kabal
@@ -10,14 +10,12 @@
% Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
% Peter Kabal
-% Department of Electrical Engineering
+% Department of Electrical & Computer Engineering
% McGill University
-% 3480 University
-% Montreal, Quebec
-% Canada H3A 2A7
% peter dot kabal at mcgill dot ca
-
+% http://www-mmsp.ece.mcgill.ca/MMSP/Documents/Software/
+
% ===============================================================
\NeedsTeXFormat{LaTeX2e}
diff --git a/Master/texmf-dist/tex/generic/texdraw/texdraw.tex b/Master/texmf-dist/tex/generic/texdraw/texdraw.tex
index e55c754bc52..a326538bd6a 100644
--- a/Master/texmf-dist/tex/generic/texdraw/texdraw.tex
+++ b/Master/texmf-dist/tex/generic/texdraw/texdraw.tex
@@ -1,6 +1,6 @@
% TeXdraw macros
-% $Id: texdraw.tex,v 2.4 2019/03/28 texdraw-V2R0a $
+% $Id: texdraw.tex 2.7 2019/04/18 TeXdraw-v2r3 $
% Copyright (C) 1991-2019 Peter Kabal
@@ -10,16 +10,14 @@
% Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
% Peter Kabal
-% Department of Electrical Engineering
+% Department of Electrical & Computer Engineering
% McGill University
-% 3480 University
-% Montreal, Quebec
-% Canada H3A 2A7
% peter dot kabal at mcgill dot ca
-
+% http://www-mmsp.ece.mcgill.ca/MMSP/Documents/Software/
+
\def\setRevDate $#1 #2 #3${#2}
-\def\TeXdrawId{\setRevDate $Date: 2019/03/28 16:40:42 $ TeXdraw V2R0a}
+\def\TeXdrawId{\setRevDate $Date: 2019/04/18 14:10:45 $ TeXdraw V2R3}
% ===============================================================
@@ -29,7 +27,7 @@
% superimposed on the figure.
% (2) TeXdraw implements a \bsegment-\esegment environment which allows
% parameter changes and coordinate changes to be kept local. In
-% effect, these segments are self-contained relocatable procedures.
+% effect these segments are self-contained relocatable procedures.
% (3) TeX's macro facility can be used to modularize drawing units and
% produce more complex entities from simple elements.
% (4) The drawing can be positioned on the page like any other TeX box.
@@ -78,12 +76,12 @@
\def\btexdraw {\x@pix=0 \y@pix=0
\x@segoffpix=\x@pix \y@segoffpix=\y@pix
+ \let\p@sfile=\p@sundef
% Set the default values (define outside of the group so that \etexdraw can
% see the scaling parameters)
\t@exdrawdef
\setbox\t@xdbox=\vbox\bgroup\offinterlineskip
\global\d@bs=0 % pending segments
- \global\t@extonlytrue % no PS commands yet
\global\p@osinitfalse
\s@avemove \x@pix \y@pix % capture the initial position
\m@pendingfalse
@@ -93,34 +91,40 @@
% ====== End TeXdraw
% Write out a trailer, close the file, bring in the PostScript code as
-% a \special include file. The \special is offset to position on the page
-% to be (llx,ury) in PostScript coordinates.
+% a \special include file. The \special is offset on the page to be at
+% (llx,ury) in PostScript coordinates.
% The drawing is placed in a \vbox of appropriate size (zero depth). The
% temporary PostScript file is superimposed with offsets such that the
% lower lefthand corner of the drawing is aligned with the lower lefthand of
-% the box. Then, the position is temporarily offset to that corresponding
-% to (0 0) to place the TeX text. Note that TeX text goes on top of the
-% PostScript drawing.
-\def\etexdraw {\ift@extonly \else
- \t@drclose % close the PostScript file
- \fi
+% the box.
+\def\etexdraw {\p@sclose % close the PostScript file
\egroup % ends the \vbox \bgroup
- \ifdim \wd\t@xdbox>0pt
- \t@xderror {TeXdraw box non-zero size,
- possible extraneous text}%
- \fi
\vbox {\offinterlineskip
\pixtobp \xminpix \l@lxbp \pixtobp \yminpix \l@lybp
\pixtobp \xmaxpix \u@rxbp \pixtobp \ymaxpix \u@rybp
- \hbox{\t@xdinclude
- [{\l@lxbp},{\l@lybp}][{\u@rxbp},{\u@rybp}]{\p@sfile}}%
- \pixtodim \xminpix \t@xpos \pixtodim \yminpix \t@ypos
- \kern \t@ypos
- \hbox {\kern -\t@xpos
- \box\t@xdbox % TeX text
- \kern \t@xpos}%
- \kern -\t@ypos\relax}}
+ \ifx\p@sfile\p@sundef
+ \hbox{\t@xdempty
+ [{\l@lxbp},{\l@lybp}][{\u@rxbp},{\u@rybp}]}%
+ \else
+ \hbox{\t@xdinclude
+ [{\l@lxbp},{\l@lybp}][{\u@rxbp},{\u@rybp}]{\p@sfile}}%
+ \fi
+ \t@xdtext}%
+}
+% Superimpose TeX text. The position is temporarily offset to a position
+% corresponding to (0 0) to place the TeX text.
+\def\t@xdtext {
+ \ifdim \wd\t@xdbox>0pt
+ \t@xderror {TeXdraw box non-zero size, possible extraneous text}%
+ \fi
+ \pixtodim \xminpix \t@xpos \pixtodim \yminpix \t@ypos
+ \kern \t@ypos
+ \hbox {\kern -\t@xpos
+ \box\t@xdbox % TeX text
+ \kern \t@xpos}%
+ \kern -\t@ypos\relax
+}
% ===== Drawing scaling
% The units in any segment may be scaled arbitrarily. A unit scale is
@@ -161,10 +165,10 @@
\f@lushmove
\fi
\begingroup
- \x@segoffpix=\x@pix
- \y@segoffpix=\y@pix
- \setsegscale 1
- \global\advance \d@bs by 1\relax}
+ \x@segoffpix=\x@pix
+ \y@segoffpix=\y@pix
+ \setsegscale 1
+ \global\advance \d@bs by 1\relax}
\def\esegment {\endgroup
\ifnum \d@bs=0
\writetx {es}%
@@ -290,20 +294,20 @@
% Check if the argument starts with a left parenthesis
\def\htext #1{\def\testit {#1}%
\ifx \testit\l@paren
- \let\next=\h@move
+ \let\t@cmd=\h@move
\else
- \let\next=\h@text
+ \let\t@cmd=\h@text
\fi
- \next {#1}}
+ \t@cmd {#1}}
% Rotated text
\def\rtext td:#1 #2{\def\testit {#2}%
\ifx \testit\l@paren
- \let\next=\r@move
+ \let\t@cmd=\r@move
\else
- \let\next=\r@text
+ \let\t@cmd=\r@text
\fi
- \next td:#1 {#2}}
+ \t@cmd td:#1 {#2}}
% Vertical text
\def\vtext {\rtext td:90 }
@@ -626,7 +630,7 @@
% Need to be able to insert "%", "{" and "}" characters into the
% PostScript file.
% Define macros which have these characters with category "other".
-% We will assume, that these characters have the standard meanings --
+% We will assume that these characters have the standard meanings -
% after all, we use comments and braces in this code.
\catcode`\%=12
\def\p@b {%!} \def\p@p {%%}
@@ -693,8 +697,8 @@
\g@etargxy #2 #3 #4 \\#5#6% leading blank
\else
\def #6{#2}%
- \def\next {#3}%
- \ifx \next\empty \else
+ \def\a@rg {#3}%
+ \ifx \a@rg\empty \else
\t@xderror {TeXdraw: invalid coordinate}%
\fi
\fi}
@@ -725,8 +729,8 @@
% ===== Low level list decoding macros
% Pick off the first item -> #3, rest of string -> #4
\def\g@etitem #1 #2\\#3#4{\edef #4{#2}\edef #3{#1}}
-\def\a@pppix #1#2{\edef\next {#1}%
- \ifx \next\empty \else
+\def\a@pppix #1#2{\edef\a@rg {#1}%
+ \ifx \a@rg\empty \else
\coordtopix {#1}\t@pixa
\ifx #2\empty
\edef #2{\the\t@pixa}%
@@ -778,7 +782,7 @@
% Two flags are used. Both flags are local to a segment.
% - move pending: Set when a move has been invoked but the move command
-% has not been written out to the PostScript file
+% has not been written out to the PostScript file.
% - path in progress: Set when a PostScript path has been started but the
% path has not been terminated and stroked.
% (1) Moves are kept back. Using TeX's groups, a local flag and local
@@ -862,7 +866,7 @@
% \ifp@osinit indicates whether the next move should be captured as the
% initial values for \xminpix, \yminpix, \xmaxpix, and \ymaxpix. However,
% if a \f@lushmove is invoked, then we assume that the appropriate initial
-% values has already been set. The "mv" command in PostScript is defined
+% values have already been set. The "mv" command in PostScript is defined
% to stroke the current path (if any) and move to the pixel coordinates
% specified.
@@ -987,13 +991,26 @@
\advance \t@ypos by -#2 bp%
\t@xpos=#3 bp%
\advance \t@xpos by -#1 bp%
- \dp0=0pt \ht0=\t@ypos \wd0=\t@xpos
+ \dp0=0pt \ht0=\t@ypos \wd0=\t@xpos
\box0%
\endgroup}
\else
\let\t@xdinclude=\includegraphics
\fi
+% Leave space without including a PS file
+\def\t@xdempty [#1,#2][#3,#4]{%
+ \begingroup
+ \leavevmode
+ \setbox0=\hbox{}%
+ \t@ypos=#4 bp%
+ \advance \t@ypos by -#2 bp%
+ \t@xpos=#3 bp%
+ \advance \t@xpos by -#1 bp%
+ \dp0=0pt \ht0=\t@ypos \wd0=\t@xpos
+ \box0%
+ \endgroup}
+
% ===== Write to the PostScript file
% Macro to write PostScript commands to the temporary PostScript file
% To decrease the size of the PostScript file, moves are kept back to
@@ -1008,76 +1025,94 @@
% only for those commands which just change line parameters
% without drawing. This routine opens the file and writes the
% PS file header the first time it is called.
-% \w@rps : lowest level direct write to the PostScript file
+% \p@swr : lowest level direct write to the PostScript file
\def\writeps #1{\f@lushbs
\f@lushmove
\p@athtrue
\writetx {#1}}
-\def\writetx #1{\ift@extonly
- \global\t@extonlyfalse
- \t@xdpsfn \p@sfile
- \t@dropen \p@sfile
- \fi
- \w@rps {#1}}
-\def\w@rps #1{\immediate\write\drawfile {#1}}
-
-% ===== Open a PostScript file
+\def\writetx #1{\p@sopen
+ \ifx\p@sfile\p@sundef \else
+ \p@swr {#1}%
+ \fi}
+\def\p@swr #1{\immediate\write\drawfile {#1}}
+
+% ===== Open/Close a PostScript file
% Open a PostScript file, write the definitions used by TeXdraw.
-\def\t@xdpsfn #1{%
- \global\advance \t@xdnum by 1
- \ifnum \t@xdnum<10
- \xdef #1{\jobname.ps\the\t@xdnum}
- \else
- \xdef #1{\jobname.p\the\t@xdnum}
+\xdef\p@sundef{UnDeFiNeD}
+\def\p@sopen {%
+ \ifx\p@sfile\p@sundef
+ \p@sopenI
+ \fi
+}
+% The code has a hook to avoid generating the PS file under certain
+% circumstances. The amsmath package sometimes sets an expression twice,
+% once to measure it and again to actually typeset it. In the first case,
+% \ifmeasuring@ is set to true. For that setting, the PS file is not
+% generated.
+\def\p@sopenI {%
+ \ifx\ifmeasuring@\iftrue \else % \ifmeasuring@ undefined or false
+ \global\advance \t@xdnum by 1
+ \ifnum \t@xdnum<10
+ \xdef \p@sfile{\jobname.ps\the\t@xdnum}%
+ \else
+ \xdef \p@sfile{\jobname.p\the\t@xdnum}%
+ \fi
+ \t@xdopen \p@sfile
+ \fi
+}
+
+\def\p@sclose {
+ \ifx\p@sfile\p@sundef \else
+ \t@xdclose
\fi
}
-\def\t@dropen #1{%
+\def\t@xdopen #1{%
\immediate\openout\drawfile=#1%
- \w@rps {\p@b PS-Adobe-3.0 EPSF-3.0}%
- \w@rps {\p@p BoundingBox: (atend)}%
- \w@rps {\p@p Title: TeXdraw drawing: #1}%
- \w@rps {\p@p Pages: 1}%
- \w@rps {\p@p Creator: \TeXdrawId}%
- \w@rps {\p@p CreationDate: \the\year/\the\month/\the\day}%
- \w@rps {50 dict begin}%
- \w@rps {/mv {stroke moveto} def}%
- \w@rps {/lv {lineto} def}%
- \w@rps {/st {currentpoint stroke moveto} def}%
- \w@rps {/sl {st setlinewidth} def}%
- \w@rps {/sd {st 0 setdash} def}%
- \w@rps {/sg {st setgray} def}%
- \w@rps {/bs {gsave} def /es {stroke grestore} def}%
- \w@rps {/fl \l@br gsave setgray fill grestore}%
- \w@rps { currentpoint newpath moveto\r@br\space def}%
- \w@rps {/fp {gsave setgray fill grestore st} def}%
- \w@rps {/cv {curveto} def}%
- \w@rps {/cr \l@br gsave currentpoint newpath 3 -1 roll 0 360 arc}%
- \w@rps { stroke grestore\r@br\space def}%
- \w@rps {/fc \l@br gsave setgray currentpoint newpath}%
- \w@rps { 3 -1 roll 0 360 arc fill grestore\r@br\space def}%
- \w@rps {/ar {gsave currentpoint newpath 5 2 roll arc stroke grestore} def}%
- \w@rps {/el \l@br gsave /svm matrix currentmatrix def}%
- \w@rps { currentpoint translate scale newpath 0 0 1 0 360 arc}%
- \w@rps { svm setmatrix stroke grestore\r@br\space def}%
- \w@rps {/fe \l@br gsave setgray currentpoint translate scale newpath}%
- \w@rps { 0 0 1 0 360 arc fill grestore\r@br\space def}%
- \w@rps {/av \l@br /hhwid exch 2 div def /hlen exch def}%
- \w@rps { /ah exch def /tipy exch def /tipx exch def}%
- \w@rps { currentpoint /taily exch def /tailx exch def}%
- \w@rps { /dx tipx tailx sub def /dy tipy taily sub def}%
- \w@rps { /alen dx dx mul dy dy mul add sqrt def}%
- \w@rps { /blen alen hlen sub def}%
- \w@rps { gsave tailx taily translate dy dx atan rotate}%
- \w@rps { (V) ah ne {blen 0 gt {blen 0 lineto} if} {alen 0 lineto} ifelse}%
- \w@rps { stroke blen hhwid neg moveto alen 0 lineto blen hhwid lineto}%
- \w@rps { (T) ah eq {closepath} if}%
- \w@rps { (W) ah eq {gsave 1 setgray fill grestore closepath} if}%
- \w@rps { (F) ah eq {fill} {stroke} ifelse}%
- \w@rps { grestore tipx tipy moveto\r@br\space def}%
- \w@rps {\p@sfactor\space \p@sfactor\space scale}%
- \w@rps {1 setlinecap 1 setlinejoin}%
- \w@rps {3 setlinewidth [] 0 setdash}%
- \w@rps {0 0 moveto}%
+ \p@swr {\p@b PS-Adobe-3.0 EPSF-3.0}%
+ \p@swr {\p@p BoundingBox: (atend)}%
+ \p@swr {\p@p Title: TeXdraw drawing: #1}%
+ \p@swr {\p@p Pages: 1}%
+ \p@swr {\p@p Creator: \TeXdrawId}%
+ \p@swr {\p@p CreationDate: \the\year/\the\month/\the\day}%
+ \p@swr {50 dict begin}%
+ \p@swr {/mv {stroke moveto} def}%
+ \p@swr {/lv {lineto} def}%
+ \p@swr {/st {currentpoint stroke moveto} def}%
+ \p@swr {/sl {st setlinewidth} def}%
+ \p@swr {/sd {st 0 setdash} def}%
+ \p@swr {/sg {st setgray} def}%
+ \p@swr {/bs {gsave} def /es {stroke grestore} def}%
+ \p@swr {/fl \l@br gsave setgray fill grestore}%
+ \p@swr { currentpoint newpath moveto\r@br\space def}%
+ \p@swr {/fp {gsave setgray fill grestore st} def}%
+ \p@swr {/cv {curveto} def}%
+ \p@swr {/cr \l@br gsave currentpoint newpath 3 -1 roll 0 360 arc}%
+ \p@swr { stroke grestore\r@br\space def}%
+ \p@swr {/fc \l@br gsave setgray currentpoint newpath}%
+ \p@swr { 3 -1 roll 0 360 arc fill grestore\r@br\space def}%
+ \p@swr {/ar {gsave currentpoint newpath 5 2 roll arc stroke grestore} def}%
+ \p@swr {/el \l@br gsave /svm matrix currentmatrix def}%
+ \p@swr { currentpoint translate scale newpath 0 0 1 0 360 arc}%
+ \p@swr { svm setmatrix stroke grestore\r@br\space def}%
+ \p@swr {/fe \l@br gsave setgray currentpoint translate scale newpath}%
+ \p@swr { 0 0 1 0 360 arc fill grestore\r@br\space def}%
+ \p@swr {/av \l@br /hhwid exch 2 div def /hlen exch def}%
+ \p@swr { /ah exch def /tipy exch def /tipx exch def}%
+ \p@swr { currentpoint /taily exch def /tailx exch def}%
+ \p@swr { /dx tipx tailx sub def /dy tipy taily sub def}%
+ \p@swr { /alen dx dx mul dy dy mul add sqrt def}%
+ \p@swr { /blen alen hlen sub def}%
+ \p@swr { gsave tailx taily translate dy dx atan rotate}%
+ \p@swr { (V) ah ne {blen 0 gt {blen 0 lineto} if} {alen 0 lineto} ifelse}%
+ \p@swr { stroke blen hhwid neg moveto alen 0 lineto blen hhwid lineto}%
+ \p@swr { (T) ah eq {closepath} if}%
+ \p@swr { (W) ah eq {gsave 1 setgray fill grestore closepath} if}%
+ \p@swr { (F) ah eq {fill} {stroke} ifelse}%
+ \p@swr { grestore tipx tipy moveto\r@br\space def}%
+ \p@swr {\p@sfactor\space \p@sfactor\space scale}%
+ \p@swr {1 setlinecap 1 setlinejoin}%
+ \p@swr {3 setlinewidth [] 0 setdash}%
+ \p@swr {0 0 moveto}%
}
% Notes:
@@ -1116,15 +1151,15 @@
% indicate. This is due to the fact that multiple move commands in
% a row are collapsed into a single move. The BoundingBox information
% includes the effect of the moves which were expunged.
-\def\t@drclose {%
+\def\t@xdclose {%
\bgroup
- \w@rps {stroke end showpage}%
- \w@rps {\p@p Trailer:}%
+ \p@swr {stroke end showpage}%
+ \p@swr {\p@p Trailer:}%
\pixtobp \xminpix \l@lxbp \pixtobp \yminpix \l@lybp
\pixtobp \xmaxpix \u@rxbp \pixtobp \ymaxpix \u@rybp
- \w@rps {\p@p BoundingBox: \l@lxbp\space \l@lybp\space
+ \p@swr {\p@p BoundingBox: \l@lxbp\space \l@lybp\space
\u@rxbp\space \u@rybp}%
- \w@rps {\p@p EOF}%
+ \p@swr {\p@p EOF}%
\egroup
\immediate\closeout\drawfile
}
diff --git a/Master/texmf-dist/tex/generic/texdraw/txdexamp.latex b/Master/texmf-dist/tex/generic/texdraw/txdexamp.latex
deleted file mode 100644
index 434f82fe9be..00000000000
--- a/Master/texmf-dist/tex/generic/texdraw/txdexamp.latex
+++ /dev/null
@@ -1,514 +0,0 @@
-% TeXdraw examples for latex
-
-% $Id: txdexamp.latex,v 2.1 2019/03/28 texdraw-V2R0a $
-
-% These examples are taken from the TeXdraw manual.
-
-% Peter Kabal
-% Department of Electrical Engineering
-% McGill University
-% 3480 University
-% Montreal, Quebec
-% Canada H3A 2A7
-
-% peter dot kabal at mcgill dot ca
-
-\documentclass [11pt]{article}
-\usepackage {texdraw}
-
-\input txdtools
-\let\et=\etexdraw
-\def\etexdraw{\drawbb\et}
-
-\begin{document}
-
-\noindent
-TeXdraw examples using LaTeX.
-
-\bigskip
-\begin{center}
-\begin{texdraw}
- \avec (0 0.8) \textref h:C v:B \htext (0 0.9){\sl y}
- \move (0 0) \avec (0.8 0) \textref h:L v:C \htext(0.9 0){\sl x}
- \move (0 1.0)
-\end{texdraw}
-\end{center}
-
-\bigskip
-\begin{center}
-\begin{texdraw}
- \drawdim{cm} \linewd 0.02
- \move(2 2) \lvec(3 3) \lvec(2 4) \lvec(1 3) \lvec(2 2)
- \textref h:C v:C \htext(2 3){$\sum \rho_n$}
-\end{texdraw}
-\end{center}
-
-\bigskip
-\begin{center}
-\begin{texdraw}
- \drawdim in
- \linewd 0.03 \setgray 0.6 \arrowheadtype t:F \avec(0.5 0.5)
- \linewd 0.01 \setgray 0 \arrowheadtype t:V \avec(1.0 0.5)
- \linewd 0.015 \lpatt(0.067 0.1) \lvec (1.5 0)
- \linewd 0.02 \lpatt() \arrowheadtype t:T \avec(2.0 0.5)
- \arrowheadtype t:H \avec(2.5 0.5)
- \setgray 0.4 \arrowheadtype t:W \avec(3.0 0)
- \textref h:R v:T \htext (0.35 0.50){\tt t:F}
- \textref h:R v:T \htext (1.0 0.43){\tt t:V}
- \textref h:R v:T \htext (1.82 0.50){\tt t:T}
- \textref h:R v:T \htext (2.5 0.43){\tt t:H}
- \textref h:R v:B \htext (2.8 0){\tt t:W}
-\end{texdraw}
-\end{center}
-
-\bigskip
-\begin{center}
-\begin{texdraw}
- \newcommand{\bdot}{\bsegment
- \fcir f:0 r:0.02
- \esegment}
- \newcommand{\Ttext}[1]{\bsegment
- \textref h:C v:B \htext (0 +0.06){#1}
- \esegment}
- \newcommand{\Btext}[1]{\bsegment
- \textref h:C v:T \htext (0 -0.06){#1}
- \esegment}
- \newcommand{\Ltext}[1]{\bsegment
- \textref h:R v:C \htext (-0.08 0){#1}
- \esegment}
- \newcommand{\Rtext}[1]{\bsegment
- \textref h:L v:C \htext (+0.08 0){#1}
- \esegment}
- \move (-1.5 0)
- \bsegment
- \move (+1.55 +0.45) \move (-1.55 -0.45) \move (0 0)
- \Ttext{Horizontal Text}
- \bdot \Btext{\tt h:C v:C}
- \move (-0.9 0) \bdot \Ltext{\tt h:L v:C}
- \move (+0.9 0) \bdot \Rtext{\tt h:R v:C}
- \move (0 +0.3) \bdot \Ttext{\tt h:C v:T}
- \move (0 -0.3) \bdot \Btext{\tt h:C v:B}
- \move (-0.9 -0.3) \bdot \Ltext{\tt h:L v:B}
- \lvec (-0.9 +0.3) \bdot \Ltext{\tt h:L v:T}
- \lvec (+0.9 +0.3) \bdot \Rtext{\tt h:R v:T}
- \lvec (+0.9 -0.3) \bdot \Rtext{\tt h:R v:B}
- \lvec (-0.9 -0.3)
- \esegment
- \newcommand{\atext}{\rtext td:45 }
- \newcommand{\ATtext}[1]{\bsegment
- \setsegscale 0.707
- \textref h:C v:B \atext (-0.06 +0.06){#1}
- \esegment}
- \newcommand{\ABtext}[1]{\bsegment
- \setsegscale 0.707
- \textref h:C v:T \atext (+0.060 -0.06){#1}
- \esegment}
- \newcommand{\ALtext}[1]{\bsegment
- \setsegscale 0.707
- \textref h:R v:C \atext (-0.08 -0.08){#1}
- \esegment}
- \newcommand{\ARtext}[1]{\bsegment
- \setsegscale 0.707
- \textref h:L v:C \atext (+0.08 +0.08){#1}
- \esegment}
- \move (+1.5 0)
- \bsegment
- \move (+1.33 +1.33) \move (-1.33 -1.33) \move (0 0)
- \setsegscale 0.707
- \ATtext{Rotated Text}
- \bdot \ABtext{\tt h:C v:C}
- \move (-0.9 -0.9) \bdot \ALtext{\tt h:L v:C}
- \move (+0.9 +0.9) \bdot \ARtext{\tt h:R v:C}
- \move (-0.3 +0.3) \bdot \ATtext{\tt h:C v:T}
- \move (+0.3 -0.3) \bdot \ABtext{\tt h:C v:B}
- \move (-0.6 -1.2) \bdot \ALtext{\tt h:L v:B}
- \lvec (-1.2 -0.6) \bdot \ALtext{\tt h:L v:T}
- \lvec (+0.6 +1.2) \bdot \ARtext{\tt h:R v:T}
- \lvec (+1.2 +0.6) \bdot \ARtext{\tt h:R v:B}
- \lvec (-0.6 -1.2)
- \esegment
-\end{texdraw}
-\end{center}
-
-\vfill
-\newpage
-
-
-\bigskip
-\begin{center}
-\begin{texdraw}
- \move(-0.75 -0.25) \lvec (-0.75 +0.5) \lvec (+0.75 +0.5)
- \lvec(+0.75 -0.25) \ifill f:0.9 % fill the region
- \move(0 0)
- \avec(-0.75 -0.25) \textref h:R v:C \htext{H-text}
- \move(0 0) \avec(-0.75 +0.25) \textref h:R v:B \htext{H-text}
- \move(0 0) \avec(0 +0.5) \textref h:L v:T \vtext{V-text}
- \move(0 0) \avec(+0.75 +0.25) \textref h:L v:B \htext{H-text}
- \move(0 0) \avec(+0.75 -0.25) \textref h:L v:C \htext{H-text}
- \move (-1.15 -0.3) \move (+1.15 +0.92) % increase the size of the drawing
-\end{texdraw}
-\end{center}
-
-\bigskip
-\begin{center}
-\begin{texdraw}
- \linewd 0.02
- \fcir f:0.7 r:1
- \larc r:1 sd:45 ed:135
- \lvec ( 0.707 0.707) \move (0 0) \lvec (-0.707 +0.707)
-\end{texdraw}
-\end{center}
-
-\bigskip
-\begin{center}
-\begin{texdraw}
- \newcommand{\Ltext}[1]{\bsegment
- \textref h:R v:C \htext (-0.08 0){#1}
- \esegment}
- \newcommand{\Rtext}[1]{\bsegment
- \textref h:L v:C \htext (+0.08 0){#1}
- \esegment}
- \newcommand{\bdot}{\fcir f:0 r:0.02 }
- \newcommand{\Ldot}[1]{\bdot \Ltext{#1}}
- \newcommand{\Rdot}[1]{\bdot \Rtext{#1}}
- \move (-2 0)
- \bsegment
- \lpatt (0.033)
- \move (0 0) \Ldot{0} \lvec (0 1) \Ldot{1}
- \lvec (1 1) \Rdot{2} \lvec (1 0) \Rdot{3}
- \lpatt ()
- \move (0 0) \clvec (0 1)(1 1)(1 0)
- \esegment
- \move (0 0)
- \bsegment
- \lpatt (0.033)
- \move (0 0) \Ldot{0} \lvec (0.5 0.8) \Ldot{1}
- \lvec (1.5 0.8) \Rdot{2} \lvec (1 0) \Rdot{3}
- \lpatt ()
- \move (0 0) \clvec (0.5 1)(1.5 1)(1 0)
- \esegment
- \move ( 2 0)
- \bsegment
- \lpatt (0.033)
- \move (0 0) \Ldot{0} \lvec (0 1) \Ldot{1}
- \lvec (1 0) \Rdot{2} \lvec (1 1) \Rdot{3}
- \lpatt ()
- \move (0 0) \clvec (0 1)(1 0)(1 1)
- \esegment
-\end{texdraw}
-\end{center}
-
-\bigskip
-\begin{center}
-\begin{texdraw}
-\move (0.5 0)
-\lvec (0 0.5) \clvec (0.5 0.85)(1 0.65)(1.5 1)
-\lvec (2 0.5) \clvec (1.5 0.15)(1 0.35)(0.5 0)
-\lfill f:0.8
-\end{texdraw}
-\end{center}
-
-\vfill
-\newpage
-
-
-\bigskip
-\newcommand{\tbox}[1]{\bsegment
- \lvec (0 +0.25) \lvec (0.75 +0.25)
- \lvec (0.75 -0.25) \lvec (0 -0.25) \lvec (0 0)
- \textref h:C v:C \htext (0.375 0){#1}
- \savepos (0.75 0)(*ex *ey)
- \esegment
- \move (*ex *ey)}
-\begin{center}
-\begin{texdraw}
- \ravec (1 0) \tbox{$H(z)$} \ravec (1 0)
-\end{texdraw}
-\end{center}
-
-\bigskip
-\def\cavec (#1 #2)(#3 #4)(#5 #6){
- \clvec (#1 #2)(#3 #4)(#5 #6)
- \cossin (#3 #4)(#5 #6)\cosa\sina
- \rmove (0 0) % stroke the Bezier curve
- \bsegment
- \drawdim in \setsegscale 0.05
- \move ({-\cosa} -\sina) \avec (0 0)
- \esegment}
-
-\def\caw (#1 #2){
- \currentpos \xa\ya
- \cossin ({\xa} \ya)(#1 #2)\cosa\sina
-
-% The nominal wiggly curve is (0 0) (1+dx dy) (-dx -dy) (1 0)
-% Find the rotated offset (dx dy) -> (du dv)
- \rotatecoord (0.4 0.1)\cosa\sina \du\dv
-
-% calculate the length of the vector
- \vectlen ({\xa} \ya)(#1 #2)\len
-
-% draw the curve in normalized units
- \bsegment
- \setsegscale {\len}
- \realadd \cosa \du \tmpa \realadd \sina \dv \tmpb
- \cavec ({\tmpa} \tmpb)({-\du} -\dv)({\cosa} \sina)
- \esegment
-
- \move (#1 #2)}
-
-% rotate a coordinate (x y)
-% arguments: (x y) cosa sina x' y'
-% x' = cosa * x - sina * y; y' = sina * x + cosa * y
-\def\rotatecoord (#1 #2)#3#4#5#6{
- \getpos (#1 #2)\xarg\yarg
- \realmult \xarg {#3} \tmpa \realmult \yarg {#4} \tmpb
- \realadd \tmpa {-\tmpb} #5
- \realmult \xarg {#4} \tmpa \realmult \yarg {#3} \tmpb
- \realadd \tmpa \tmpb #6}
-
-\begin{center}
-\begin{texdraw}
- \arrowheadtype t:W
- \move (0 0)
- \cavec (1.4 0.1)(-0.4 -0.1)(1 0)
- \move (1 0) \caw (1 1) \htext{tip at \tt (1 1)}
- \move (1 0) \caw (2 1) \htext{tip at \tt (2 1)}
- \move (1 0) \caw (2 0) \htext{tip at \tt (2 0)}
- \move (0 1.13) \move (0 -0.04)
-\end{texdraw}
-\end{center}
-
-\vfill
-\newpage
-
-
-\bigskip
-\def\delay {\bsegment
- \setsegscale 0.3
- \lvec (0 +0.5) \lvec (1 +0.5) \lvec (1 -0.5)
- \lvec (0 -0.5) \lvec (0 0)
- \textref h:C v:C \htext (0.5 0){$z^{-1}$}
- \savepos (1 0)(*ex *ey)
- \esegment
- \move (*ex *ey)}
-\def\bdot {\fcir f:0 r:0.02 }
-\def\Ttext #1{\bsegment
- \textref h:C v:B \htext (0 +0.06){#1}
- \esegment}
-\def\Btext #1{\bsegment
- \textref h:C v:T \htext (0 -0.06){#1}
- \esegment}
-\def\Ltext #1{\bsegment
- \textref h:R v:C \htext (-0.06 0){#1}
- \esegment}
-\def\Rtext #1{\bsegment
- \textref h:L v:C \htext (+0.06 0){#1}
- \esegment}
-\def\cradius {0.08}
-\def\pluss {\bsegment
- \setsegscale {\cradius}
- \move (-0.5 0) \lvec (+0.5 0)
- \move (0 -0.5) \lvec (0 +0.5)
- \esegment}
-\def\pcir {\lcir r:{\cradius} \pluss}
-\def\puttext (#1 #2)#3{\bsegment
- \setsegscale {\cradius}
- \textref h:C v:C \htext (#1 #2){#3}
- \esegment}
-\def\putwnw #1{\puttext (-1.7 +1.2){#1}}
-\def\putwsw #1{\puttext (-1.7 -1.2){#1}}
-\def\putn #1{\puttext ( 0 +2 ){#1}}
-\def\puts #1{\puttext ( 0 -2 ){#1}}
-\def\avectoc (#1 #2){\currentpos \xa\ya
- \cossin ({\xa} \ya)(#1 #2)\cosa\sina
- \savepos (#1 #2)(*tx *ty)
- \bsegment
- \move (*tx *ty)
- \setsegscale {\cradius}
- \rmove ({-\cosa} -\sina)
- \savecurrpos (*ex *ey)
- \esegment
- \avec (*ex *ey)
- \move (#1 #2)}
-\def\avecfrc (#1 #2){\currentpos \xa\ya
- \cossin ({\xa} \ya)(#1 #2)\cosa\sina
- \bsegment
- \setsegscale {\cradius}
- \move ({\cosa} \sina)
- \savecurrpos (*ex *ey)
- \esegment
- \move (*ex *ey)
- \avec (#1 #2)}
-
-\begin{center}
-\begin{texdraw}
-\drawdim in
-\arrowheadtype t:F \arrowheadsize l:0.08 w:0.04
-\def\pl {$\scriptscriptstyle +$} \def\mn {$\scriptscriptstyle -$}
-
-\move (0 +0.63) \move (0 -0.60) \move (0 0) % compensate for the text size
-
-% Input to the first stage
-\bsegment
- \Ltext{$x(n)$}
- \lvec (0.3 0) \bdot \lvec (0.3 +0.4)
- \move (0.3 0) \lvec (0.3 -0.4)
- \savepos (0.3 0)(*ex *ey)
-\esegment
-\move (*ex *ey)
-
-% first lattice stage
-\bsegment
- \move (0 +0.4) \avectoc (1.7 +0.4)
- \pcir \putwnw{\pl} \puts{\mn}
- \avecfrc (2.1 +0.4)
- \move (0 -0.4) \avec (0.4 -0.4) \delay \avectoc (1.7 -0.4)
- \pcir \putwsw{\pl} \putn{\mn}
- \avecfrc (2.1 -0.4)
- \move (0.9 +0.4) \bdot \avectoc (1.7 -0.4)
- \move (0.9 -0.4) \bdot \avectoc (1.7 +0.4)
- \move (0.1 +0.42) \Ttext {$f_0(n)$}
- \move (2.0 +0.42) \Ttext {$f_1(n)$}
- \move (0.1 -0.4) \Btext {$b_0(n)$}
- \move (2.0 -0.4) \Btext {$b_1(n)$}
- \textref h:L v:B \htext (1.15 +0.2){$K_1$}
- \textref h:L v:T \htext (1.15 -0.2){$K_1$}
- \savepos (2.1 0)(*ex *ey)
-\esegment
-\move (*ex *ey)
-
-% center section
-\bsegment
- \textref h:C v:C
- \htext (0.3 +0.4){$\cdots$}
- \htext (0.3 -0.4){$\cdots$}
- \savepos (0.6 0)(*ex *ey)
-\esegment
-\move (*ex *ey)
-
-% last lattice stage
-\bsegment
- \move (0 +0.4) \avectoc (1.7 +0.4)
- \pcir \putwnw{\pl} \puts{\mn}
- \avecfrc (2.3 +0.4) \Rtext{$e(n)$}
- \move (0 -0.4) \avec (0.4 -0.4) \delay \avectoc (1.7 -0.4)
- \pcir \putwsw{\pl} \putn{\mn}
- \avecfrc (2.1 -0.4)
- \move (0.9 +0.4) \bdot \avectoc (1.7 -0.4)
- \move (0.9 -0.4) \bdot \avectoc (1.7 +0.4)
- \move (0.1 +0.42) \Ttext {$f_{P-1}(n)$}
- \move (2.0 +0.42) \Ttext {$f_P(n)$}
- \move (0.1 -0.4) \Btext {$b_{P-1}(n)$}
- \move (2.0 -0.4) \Btext {$b_P(n)$}
- \textref h:L v:B \htext (1.15 +0.2){$K_P$}
- \textref h:L v:T \htext (1.15 -0.2){$K_P$}
-\esegment
-\end{texdraw}
-\end{center}
-
-\bigskip
-\begin{center}
-\begin{texdraw}
-\arrowheadtype t:F \arrowheadsize l:0.08 w:0.04
-\def\ds {\displaystyle}
-\def\ticklab (#1 #2)#3{\move(#1 #2)
- \bsegment
- \lvec (0 0.05)
- \textref h:C v:T \htext (0 -0.05){#3}
- \esegment}
-\def\Rtext #1{\bsegment
- \textref h:L v:C \htext ( 0.08 0){#1}
- \esegment}
-
-\move (2.4 -0.32) % move to set the size
-
-\move (0 0)
-% Axes
-\avec (0 1.4)
-\move (0 0) \avec (2.2 0) \Rtext{$\omega$}
-\ticklab (0 0) {0}
-\ticklab (0.8 0) {$\ds {\pi \over 2N} $}
-\ticklab (1.2 0) {$\omega_s$}
-\ticklab (1.6 0) {$\ds {\pi \over N} $}
-
-\linewd 0.025
-\move (0 1)
-\lvec (0.4 1)
-\lvec (0.44 0.998)
-\lvec (0.48 0.988)
-\lvec (0.52 0.973)
-\lvec (0.56 0.951)
-\lvec (0.60 0.923)
-\lvec (0.64 0.891)
-\lvec (0.68 0.852)
-\lvec (0.72 0.809)
-\lvec (0.76 0.760)
-\lvec (0.80 0.707)
-\lvec (0.84 0.649)
-\lvec (0.88 0.587)
-\lvec (0.92 0.522)
-\lvec (0.96 0.454)
-\lvec (1.00 0.382)
-\lvec (1.04 0.309)
-\lvec (1.08 0.233)
-\lvec (1.12 0.156)
-\lvec (1.16 0.078)
-\lvec (1.20 0)
-\lvec (1.9 0)
-\end{texdraw}
-\end{center}
-
-\bigskip
-\begin{center}
-\begin{texdraw}
-\arrowheadtype t:V \arrowheadsize l:0.08 w:0.04
-\linewd 0.01
-\setunitscale 1.5 % circle will have radius 1.5 inches
-
-\def\Btext #1{\bsegment
- \textref h:C v:T \htext (0 -0.04){#1}
- \esegment}
-\def\Ttext #1{\bsegment
- \textref h:C v:B \htext (0 0.04){#1}
- \esegment}
-\def\Ltext #1{\bsegment
- \textref h:R v:C \htext (-0.04 0){#1}
- \esegment}
-\def\bdot {\fcir f:0 r:0.0133 }
-\def\vtick {\bsegment
- \move (0 -0.05) \lvec (0 0.05)
- \esegment}
-\def\htick {\bsegment
- \move (-0.05 0) \lvec ( 0.05 0)
- \esegment}
-\def\Hlen #1#2{\bsegment
- \vtick \avec ({#1} 0) \vtick \avec (0 0)
- \relsegscale 0.5
- \move ({#1} 0) \Ttext {#2}
- \esegment}
-\def\Vlen #1#2{\bsegment
- \htick \avec (0 {#1}) \htick \avec (0 0)
- \relsegscale 0.5
- \move (0 {#1}) \Ltext {#2}
- \esegment}
-
-\lcir r:1 % circle
-\move (-1.05 0) \lvec ( 1.05 0) % axes
-\move (0 -1.05) \lvec (0 1.05)
-
-\move (0 0) \lvec (0.707 0.707) \bdot
-\rmove (0.02 0.02) \textref h:L v:B \htext {X}
-\move (0.707 -0.707) \bdot
-\textref h:R v:T \htext(-0.02 -0.02){O}
-
-\move (0.5 0) % center of ellipse
-\bsegment
- \lellip rx:0.435 ry:0.804
- \bdot \Btext {$\beta_2$}
- \move (0 0.15) \Hlen {0.435}{$|\beta_1{+}\beta_3|$}
- \move (-0.7 0) \Vlen {0.804}{$|\beta_1{-}\beta_3|$}
-\esegment
-\end{texdraw}
-\end{center}
-
-\end{document}
diff --git a/Master/texmf-dist/tex/generic/texdraw/txdexamp.tex b/Master/texmf-dist/tex/generic/texdraw/txdexamp.tex
deleted file mode 100644
index 3ae3aee66dd..00000000000
--- a/Master/texmf-dist/tex/generic/texdraw/txdexamp.tex
+++ /dev/null
@@ -1,485 +0,0 @@
-% TeXdraw examples
-
-% $Id: txdexamp.tex,v 2.1 2019/03/28 texdraw-V2R0a $
-
-% These examples are taken from the TeXdraw manual. Note that the fonts
-% for text will be different from those in the manual -- here we use the
-% plain TeX defaults.
-
-% Peter Kabal
-% Department of Electrical Engineering
-% McGill University
-% 3480 University
-% Montreal, Quebec
-% Canada H3A 2A7
-
-% peter dot kabal at mcgill dot ca
-
-\input texdraw
-\input txdtools
-\let\et=\etexdraw
-\def\etexdraw{\drawbb\et}
-
-\noindent
-TeXdraw examples using plain TeX.
-
-\bigskip
-\centertexdraw{
- \avec (0 0.8) \textref h:C v:B \htext (0 0.9){\sl y}
- \move (0 0) \avec (0.8 0) \textref h:L v:C \htext(0.9 0){\sl x}
- \move (0 1.0)}
-
-\bigskip
-\centertexdraw{
- \drawdim{cm} \linewd 0.02
- \move(2 2) \lvec(3 3) \lvec(2 4) \lvec(1 3) \lvec(2 2)
- \textref h:C v:C \htext(2 3){$\sum \rho_n$}
-}
-
-\bigskip
-\centertexdraw{
- \drawdim in
- \linewd 0.03 \setgray 0.6 \arrowheadtype t:F \avec(0.5 0.5)
- \linewd 0.01 \setgray 0 \arrowheadtype t:V \avec(1.0 0.5)
- \linewd 0.015 \lpatt(0.067 0.1) \lvec (1.5 0)
- \linewd 0.02 \lpatt() \arrowheadtype t:T \avec(2.0 0.5)
- \arrowheadtype t:H \avec(2.5 0.5)
- \setgray 0.4 \arrowheadtype t:W \avec(3.0 0)
- \textref h:R v:T \htext (0.35 0.50){\tt t:F}
- \textref h:R v:T \htext (1.0 0.43){\tt t:V}
- \textref h:R v:T \htext (1.82 0.50){\tt t:T}
- \textref h:R v:T \htext (2.5 0.43){\tt t:H}
- \textref h:R v:B \htext (2.8 0){\tt t:W}
-}
-
-\bigskip
-\centertexdraw{
- \def\bdot {\bsegment
- \fcir f:0 r:0.02
- \esegment}
- \def\Ttext #1{\bsegment
- \textref h:C v:B \htext (0 +0.06){#1}
- \esegment}
- \def\Btext #1{\bsegment
- \textref h:C v:T \htext (0 -0.06){#1}
- \esegment}
- \def\Ltext #1{\bsegment
- \textref h:R v:C \htext (-0.08 0){#1}
- \esegment}
- \def\Rtext #1{\bsegment
- \textref h:L v:C \htext (+0.08 0){#1}
- \esegment}
- \move (-1.5 0)
- \bsegment
- \move (+1.55 +0.45) \move (-1.55 -0.45) \move (0 0)
- \Ttext{Horizontal Text}
- \bdot \Btext{\tt h:C v:C}
- \move (-0.9 0) \bdot \Ltext{\tt h:L v:C}
- \move (+0.9 0) \bdot \Rtext{\tt h:R v:C}
- \move (0 +0.3) \bdot \Ttext{\tt h:C v:T}
- \move (0 -0.3) \bdot \Btext{\tt h:C v:B}
- \move (-0.9 -0.3) \bdot \Ltext{\tt h:L v:B}
- \lvec (-0.9 +0.3) \bdot \Ltext{\tt h:L v:T}
- \lvec (+0.9 +0.3) \bdot \Rtext{\tt h:R v:T}
- \lvec (+0.9 -0.3) \bdot \Rtext{\tt h:R v:B}
- \lvec (-0.9 -0.3)
- \esegment
- \def\atext {\rtext td:45 }
- \def\ATtext #1{\bsegment
- \setsegscale 0.707
- \textref h:C v:B \atext (-0.06 +0.06){#1}
- \esegment}
- \def\ABtext #1{\bsegment
- \setsegscale 0.707
- \textref h:C v:T \atext (+0.060 -0.06){#1}
- \esegment}
- \def\ALtext #1{\bsegment
- \setsegscale 0.707
- \textref h:R v:C \atext (-0.08 -0.08){#1}
- \esegment}
- \def\ARtext #1{\bsegment
- \setsegscale 0.707
- \textref h:L v:C \atext (+0.08 +0.08){#1}
- \esegment}
- \move (+1.5 0)
- \bsegment
- \move (+1.33 +1.33) \move (-1.33 -1.33) \move (0 0)
- \setsegscale 0.707
- \ATtext{Rotated Text}
- \bdot \ABtext{\tt h:C v:C}
- \move (-0.9 -0.9) \bdot \ALtext{\tt h:L v:C}
- \move (+0.9 +0.9) \bdot \ARtext{\tt h:R v:C}
- \move (-0.3 +0.3) \bdot \ATtext{\tt h:C v:T}
- \move (+0.3 -0.3) \bdot \ABtext{\tt h:C v:B}
- \move (-0.6 -1.2) \bdot \ALtext{\tt h:L v:B}
- \lvec (-1.2 -0.6) \bdot \ALtext{\tt h:L v:T}
- \lvec (+0.6 +1.2) \bdot \ARtext{\tt h:R v:T}
- \lvec (+1.2 +0.6) \bdot \ARtext{\tt h:R v:B}
- \lvec (-0.6 -1.2)
- \esegment
-}
-
-\vfill
-\eject
-
-
-\bigskip
-\centertexdraw{
- \move(-0.75 -0.25) \lvec (-0.75 +0.5) \lvec (+0.75 +0.5)
- \lvec(+0.75 -0.25) \ifill f:0.9 % fill the region
- \move(0 0)
- \avec(-0.75 -0.25) \textref h:R v:C \htext{H-text}
- \move(0 0) \avec(-0.75 +0.25) \textref h:R v:B \htext{H-text}
- \move(0 0) \avec(0 +0.5) \textref h:L v:T \vtext{V-text}
- \move(0 0) \avec(+0.75 +0.25) \textref h:L v:B \htext{H-text}
- \move(0 0) \avec(+0.75 -0.25) \textref h:L v:C \htext{H-text}
- \move (-1.15 -0.3) \move (+1.15 +0.92) % increase the size of the drawing
-}
-
-\bigskip
-\centertexdraw{
- \linewd 0.02
- \fcir f:0.7 r:1
- \larc r:1 sd:45 ed:135
- \lvec ( 0.707 0.707) \move (0 0) \lvec (-0.707 +0.707)
-}
-
-\bigskip
-\centertexdraw{
- \def\Ltext #1{\bsegment
- \textref h:R v:C \htext (-0.08 0){#1}
- \esegment}
- \def\Rtext #1{\bsegment
- \textref h:L v:C \htext (+0.08 0){#1}
- \esegment}
- \def\bdot {\fcir f:0 r:0.02 }
- \def\Ldot #1{\bdot \Ltext{#1}}
- \def\Rdot #1{\bdot \Rtext{#1}}
- \move (-2 0)
- \bsegment
- \lpatt (0.033)
- \move (0 0) \Ldot{0} \lvec (0 1) \Ldot{1}
- \lvec (1 1) \Rdot{2} \lvec (1 0) \Rdot{3}
- \lpatt ()
- \move (0 0) \clvec (0 1)(1 1)(1 0)
- \esegment
- \move (0 0)
- \bsegment
- \lpatt (0.033)
- \move (0 0) \Ldot{0} \lvec (0.5 0.8) \Ldot{1}
- \lvec (1.5 0.8) \Rdot{2} \lvec (1 0) \Rdot{3}
- \lpatt ()
- \move (0 0) \clvec (0.5 1)(1.5 1)(1 0)
- \esegment
- \move ( 2 0)
- \bsegment
- \lpatt (0.033)
- \move (0 0) \Ldot{0} \lvec (0 1) \Ldot{1}
- \lvec (1 0) \Rdot{2} \lvec (1 1) \Rdot{3}
- \lpatt ()
- \move (0 0) \clvec (0 1)(1 0)(1 1)
- \esegment
-}
-
-\bigskip
-\centertexdraw{
-\move (0.5 0)
-\lvec (0 0.5) \clvec (0.5 0.85)(1 0.65)(1.5 1)
-\lvec (2 0.5) \clvec (1.5 0.15)(1 0.35)(0.5 0)
-\lfill f:0.8
-}
-
-\vfill
-\eject
-
-
-\bigskip
-\def\tbox #1{\bsegment
- \lvec (0 +0.25) \lvec (0.75 +0.25)
- \lvec (0.75 -0.25) \lvec (0 -0.25) \lvec (0 0)
- \textref h:C v:C \htext (0.375 0){#1}
- \savepos (0.75 0)(*ex *ey)
- \esegment
- \move (*ex *ey)}
-\centertexdraw{
- \ravec (1 0) \tbox{$H(z)$} \ravec (1 0)
-}
-
-\bigskip
-\def\cavec (#1 #2)(#3 #4)(#5 #6){
- \clvec (#1 #2)(#3 #4)(#5 #6)
- \cossin (#3 #4)(#5 #6)\cosa\sina
- \rmove (0 0) % stroke the Bezier curve
- \bsegment
- \drawdim in \setsegscale 0.05
- \move ({-\cosa} -\sina) \avec (0 0)
- \esegment}
-
-\def\caw (#1 #2){
- \currentpos \xa\ya
- \cossin ({\xa} \ya)(#1 #2)\cosa\sina
-
-% The nominal wiggly curve is (0 0) (1+dx dy) (-dx -dy) (1 0)
-% Find the rotated offset (dx dy) -> (du dv)
- \rotatecoord (0.4 0.1)\cosa\sina \du\dv
-
-% calculate the length of the vector
- \vectlen ({\xa} \ya)(#1 #2)\len
-
-% draw the curve in normalized units
- \bsegment
- \setsegscale {\len}
- \realadd \cosa \du \tmpa \realadd \sina \dv \tmpb
- \cavec ({\tmpa} \tmpb)({-\du} -\dv)({\cosa} \sina)
- \esegment
-
- \move (#1 #2)}
-
-% rotate a coordinate (x y)
-% arguments: (x y) cosa sina x' y'
-% x' = cosa * x - sina * y; y' = sina * x + cosa * y
-\def\rotatecoord (#1 #2)#3#4#5#6{
- \getpos (#1 #2)\xarg\yarg
- \realmult \xarg {#3} \tmpa \realmult \yarg {#4} \tmpb
- \realadd \tmpa {-\tmpb} #5
- \realmult \xarg {#4} \tmpa \realmult \yarg {#3} \tmpb
- \realadd \tmpa \tmpb #6}
-
-\centertexdraw{
- \arrowheadtype t:W
- \move (0 0)
- \cavec (1.4 0.1)(-0.4 -0.1)(1 0)
- \move (1 0) \caw (1 1) \htext{tip at \tt (1 1)}
- \move (1 0) \caw (2 1) \htext{tip at \tt (2 1)}
- \move (1 0) \caw (2 0) \htext{tip at \tt (2 0)}
- \move (0 1.13) \move (0 -0.04)
-}
-
-\vfill
-\eject
-
-
-\bigskip
-\def\delay {\bsegment
- \setsegscale 0.3
- \lvec (0 +0.5) \lvec (1 +0.5) \lvec (1 -0.5)
- \lvec (0 -0.5) \lvec (0 0)
- \textref h:C v:C \htext (0.5 0){$z^{-1}$}
- \savepos (1 0)(*ex *ey)
- \esegment
- \move (*ex *ey)}
-\def\bdot {\fcir f:0 r:0.02 }
-\def\Ttext #1{\bsegment
- \textref h:C v:B \htext (0 +0.06){#1}
- \esegment}
-\def\Btext #1{\bsegment
- \textref h:C v:T \htext (0 -0.06){#1}
- \esegment}
-\def\Ltext #1{\bsegment
- \textref h:R v:C \htext (-0.06 0){#1}
- \esegment}
-\def\Rtext #1{\bsegment
- \textref h:L v:C \htext (+0.06 0){#1}
- \esegment}
-\def\cradius {0.08}
-\def\pluss {\bsegment
- \setsegscale {\cradius}
- \move (-0.5 0) \lvec (+0.5 0)
- \move (0 -0.5) \lvec (0 +0.5)
- \esegment}
-\def\pcir {\lcir r:{\cradius} \pluss}
-\def\puttext (#1 #2)#3{\bsegment
- \setsegscale {\cradius}
- \textref h:C v:C \htext (#1 #2){#3}
- \esegment}
-\def\putwnw #1{\puttext (-1.7 +1.2){#1}}
-\def\putwsw #1{\puttext (-1.7 -1.2){#1}}
-\def\putn #1{\puttext ( 0 +2 ){#1}}
-\def\puts #1{\puttext ( 0 -2 ){#1}}
-\def\avectoc (#1 #2){\currentpos \xa\ya
- \cossin ({\xa} \ya)(#1 #2)\cosa\sina
- \savepos (#1 #2)(*tx *ty)
- \bsegment
- \move (*tx *ty)
- \setsegscale {\cradius}
- \rmove ({-\cosa} -\sina)
- \savecurrpos (*ex *ey)
- \esegment
- \avec (*ex *ey)
- \move (#1 #2)}
-\def\avecfrc (#1 #2){\currentpos \xa\ya
- \cossin ({\xa} \ya)(#1 #2)\cosa\sina
- \bsegment
- \setsegscale {\cradius}
- \move ({\cosa} \sina)
- \savecurrpos (*ex *ey)
- \esegment
- \move (*ex *ey)
- \avec (#1 #2)}
-
-\centertexdraw{
-\drawdim in
-\arrowheadtype t:F \arrowheadsize l:0.08 w:0.04
-\def\pl {$\scriptscriptstyle +$} \def\mn {$\scriptscriptstyle -$}
-
-\move (0 +0.63) \move (0 -0.60) \move (0 0) % compensate for the text size
-
-% Input to the first stage
-\bsegment
- \Ltext{$x(n)$}
- \lvec (0.3 0) \bdot \lvec (0.3 +0.4)
- \move (0.3 0) \lvec (0.3 -0.4)
- \savepos (0.3 0)(*ex *ey)
-\esegment
-\move (*ex *ey)
-
-% first lattice stage
-\bsegment
- \move (0 +0.4) \avectoc (1.7 +0.4)
- \pcir \putwnw{\pl} \puts{\mn}
- \avecfrc (2.1 +0.4)
- \move (0 -0.4) \avec (0.4 -0.4) \delay \avectoc (1.7 -0.4)
- \pcir \putwsw{\pl} \putn{\mn}
- \avecfrc (2.1 -0.4)
- \move (0.9 +0.4) \bdot \avectoc (1.7 -0.4)
- \move (0.9 -0.4) \bdot \avectoc (1.7 +0.4)
- \move (0.1 +0.42) \Ttext {$f_0(n)$}
- \move (2.0 +0.42) \Ttext {$f_1(n)$}
- \move (0.1 -0.4) \Btext {$b_0(n)$}
- \move (2.0 -0.4) \Btext {$b_1(n)$}
- \textref h:L v:B \htext (1.15 +0.2){$K_1$}
- \textref h:L v:T \htext (1.15 -0.2){$K_1$}
- \savepos (2.1 0)(*ex *ey)
-\esegment
-\move (*ex *ey)
-
-% center section
-\bsegment
- \textref h:C v:C
- \htext (0.3 +0.4){$\cdots$}
- \htext (0.3 -0.4){$\cdots$}
- \savepos (0.6 0)(*ex *ey)
-\esegment
-\move (*ex *ey)
-
-% last lattice stage
-\bsegment
- \move (0 +0.4) \avectoc (1.7 +0.4)
- \pcir \putwnw{\pl} \puts{\mn}
- \avecfrc (2.3 +0.4) \Rtext{$e(n)$}
- \move (0 -0.4) \avec (0.4 -0.4) \delay \avectoc (1.7 -0.4)
- \pcir \putwsw{\pl} \putn{\mn}
- \avecfrc (2.1 -0.4)
- \move (0.9 +0.4) \bdot \avectoc (1.7 -0.4)
- \move (0.9 -0.4) \bdot \avectoc (1.7 +0.4)
- \move (0.1 +0.42) \Ttext {$f_{P-1}(n)$}
- \move (2.0 +0.42) \Ttext {$f_P(n)$}
- \move (0.1 -0.4) \Btext {$b_{P-1}(n)$}
- \move (2.0 -0.4) \Btext {$b_P(n)$}
- \textref h:L v:B \htext (1.15 +0.2){$K_P$}
- \textref h:L v:T \htext (1.15 -0.2){$K_P$}
-\esegment
-}
-
-\bigskip
-\centertexdraw{
-\arrowheadtype t:F \arrowheadsize l:0.08 w:0.04
-\def\ds {\displaystyle}
-\def\ticklab (#1 #2)#3{\move(#1 #2)
- \bsegment
- \lvec (0 0.05)
- \textref h:C v:T \htext (0 -0.05){#3}
- \esegment}
-\def\Rtext #1{\bsegment
- \textref h:L v:C \htext ( 0.08 0){#1}
- \esegment}
-
-\move (2.4 -0.32) % move to set the size
-
-\move (0 0)
-% Axes
-\avec (0 1.4)
-\move (0 0) \avec (2.2 0) \Rtext{$\omega$}
-\ticklab (0 0) {0}
-\ticklab (0.8 0) {$\ds {\pi \over 2N} $}
-\ticklab (1.2 0) {$\omega_s$}
-\ticklab (1.6 0) {$\ds {\pi \over N} $}
-
-\linewd 0.025
-\move (0 1)
-\lvec (0.4 1)
-\lvec (0.44 0.998)
-\lvec (0.48 0.988)
-\lvec (0.52 0.973)
-\lvec (0.56 0.951)
-\lvec (0.60 0.923)
-\lvec (0.64 0.891)
-\lvec (0.68 0.852)
-\lvec (0.72 0.809)
-\lvec (0.76 0.760)
-\lvec (0.80 0.707)
-\lvec (0.84 0.649)
-\lvec (0.88 0.587)
-\lvec (0.92 0.522)
-\lvec (0.96 0.454)
-\lvec (1.00 0.382)
-\lvec (1.04 0.309)
-\lvec (1.08 0.233)
-\lvec (1.12 0.156)
-\lvec (1.16 0.078)
-\lvec (1.20 0)
-\lvec (1.9 0)
-}
-
-\bigskip
-\centertexdraw{
-\arrowheadtype t:V \arrowheadsize l:0.08 w:0.04
-\linewd 0.01
-\setunitscale 1.5 % circle will have radius 1.5 inches
-
-\def\Btext #1{\bsegment
- \textref h:C v:T \htext (0 -0.04){#1}
- \esegment}
-\def\Ttext #1{\bsegment
- \textref h:C v:B \htext (0 0.04){#1}
- \esegment}
-\def\Ltext #1{\bsegment
- \textref h:R v:C \htext (-0.04 0){#1}
- \esegment}
-\def\bdot {\fcir f:0 r:0.0133 }
-\def\vtick {\bsegment
- \move (0 -0.05) \lvec (0 0.05)
- \esegment}
-\def\htick {\bsegment
- \move (-0.05 0) \lvec ( 0.05 0)
- \esegment}
-\def\Hlen #1#2{\bsegment
- \vtick \avec ({#1} 0) \vtick \avec (0 0)
- \relsegscale 0.5
- \move ({#1} 0) \Ttext {#2}
- \esegment}
-\def\Vlen #1#2{\bsegment
- \htick \avec (0 {#1}) \htick \avec (0 0)
- \relsegscale 0.5
- \move (0 {#1}) \Ltext {#2}
- \esegment}
-
-\lcir r:1 % circle
-\move (-1.05 0) \lvec ( 1.05 0) % axes
-\move (0 -1.05) \lvec (0 1.05)
-
-\move (0 0) \lvec (0.707 0.707) \bdot
-\rmove (0.02 0.02) \textref h:L v:B \htext {X}
-\move (0.707 -0.707) \bdot
-\textref h:R v:T \htext(-0.02 -0.02){O}
-
-\move (0.5 0) % center of ellipse
-\bsegment
- \lellip rx:0.435 ry:0.804
- \bdot \Btext {$\beta_2$}
- \move (0 0.15) \Hlen {0.435}{$|\beta_1{+}\beta_3|$}
- \move (-0.7 0) \Vlen {0.804}{$|\beta_1{-}\beta_3|$}
-\esegment
-}
-
-\bye
diff --git a/Master/texmf-dist/tex/generic/texdraw/txdps.tex b/Master/texmf-dist/tex/generic/texdraw/txdps.tex
index 4779145231a..482e3faf408 100644
--- a/Master/texmf-dist/tex/generic/texdraw/txdps.tex
+++ b/Master/texmf-dist/tex/generic/texdraw/txdps.tex
@@ -1,6 +1,6 @@
% TeXdraw macros to access PostScript builtins
-% $Id: txdps.tex,v 1.8 2019/03/28 texdraw-V2R0a $
+% $Id: txdps.tex 1.10 2019/04/18 TeXdraw-v2r3 $
% Copyright (C) 1991-2019 Peter Kabal
@@ -10,14 +10,12 @@
% Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
% Peter Kabal
-% Department of Electrical Engineering
+% Department of Electrical & Computer Engineering
% McGill University
-% 3480 University
-% Montreal, Quebec
-% Canada H3A 2A7
% peter dot kabal at mcgill dot ca
-
+% http://www-mmsp.ece.mcgill.ca/MMSP/Documents/Software/
+
% ===============================================================
\chardef\catamp=\the\catcode`\@
diff --git a/Master/texmf-dist/tex/generic/texdraw/txdtools.tex b/Master/texmf-dist/tex/generic/texdraw/txdtools.tex
index a7fe26dc363..eea68fbd0c8 100644
--- a/Master/texmf-dist/tex/generic/texdraw/txdtools.tex
+++ b/Master/texmf-dist/tex/generic/texdraw/txdtools.tex
@@ -1,6 +1,6 @@
% TeXdraw toolbox macros, useful for extended TeXdraw commands
-% $Id: txdtools.tex,v 1.9 2019/03/28 texdraw-V2R0a $
+% $Id: txdtools.tex 1.11 2019/04/18 TeXdraw-v2r3 $
% Copyright (C) 1991-2019 Peter Kabal
@@ -10,14 +10,12 @@
% Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
% Peter Kabal
-% Department of Electrical Engineering
+% Department of Electrical & Computer Engineering
% McGill University
-% 3480 University
-% Montreal, Quebec
-% Canada H3A 2A7
% peter dot kabal at mcgill dot ca
-
+% http://www-mmsp.ece.mcgill.ca/MMSP/Documents/Software/
+
% ===============================================================
% These macros use temporary count registers defined by TeXdraw