diff options
-rw-r--r-- | Master/texmf-dist/doc/latex/bropd/README | 30 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/bropd/bropd.pdf | bin | 0 -> 98255 bytes | |||
-rw-r--r-- | Master/texmf-dist/source/latex/bropd/bropd.dtx | 258 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/bropd/bropd.sty | 123 | ||||
-rwxr-xr-x | Master/tlpkg/bin/tlpkg-ctan-check | 2 | ||||
-rwxr-xr-x | Master/tlpkg/libexec/ctan2tds | 2 | ||||
-rw-r--r-- | Master/tlpkg/tlpsrc/bropd.tlpsrc | 0 | ||||
-rw-r--r-- | Master/tlpkg/tlpsrc/collection-mathextra.tlpsrc | 2 |
8 files changed, 414 insertions, 3 deletions
diff --git a/Master/texmf-dist/doc/latex/bropd/README b/Master/texmf-dist/doc/latex/bropd/README new file mode 100644 index 00000000000..79c3a19eb1a --- /dev/null +++ b/Master/texmf-dist/doc/latex/bropd/README @@ -0,0 +1,30 @@ +bropd package + +Version: 1.0 2012/11/04 + +by Benjamin Tatlock + +The bropd package simplifies the process of writing differential operators and +brackets in LaTeX. The commands facilitate the easy manipulation of equations +involving brackets and allow partial differentials to be expressed in an +alternate form. + + +The "bropd" package is copyright 2012 by Benjamin Tatlock + +It comprises this README file, as well as files +bropd.dtx +bropd.pdf +bropd.sty + +Run LaTeX on the documented source file bropd.dtx to install the package and +generate the accompanying documentation. + +"bropd" may be distributed and/or modified under the conditions of the LaTeX +Project Public License, either version 1.3 of this license or (at your option) +any later version. The latest version of this license is in + http://www.latex-project.org/lppl.txt +and version 1.3 or later is part of all distributions of LaTeX version +2005/12/01 or later. + +This work has the LPPL maintenance status "author-maintained". diff --git a/Master/texmf-dist/doc/latex/bropd/bropd.pdf b/Master/texmf-dist/doc/latex/bropd/bropd.pdf Binary files differnew file mode 100644 index 00000000000..d90afc955ed --- /dev/null +++ b/Master/texmf-dist/doc/latex/bropd/bropd.pdf diff --git a/Master/texmf-dist/source/latex/bropd/bropd.dtx b/Master/texmf-dist/source/latex/bropd/bropd.dtx new file mode 100644 index 00000000000..0d809486e86 --- /dev/null +++ b/Master/texmf-dist/source/latex/bropd/bropd.dtx @@ -0,0 +1,258 @@ +% \iffalse The license starting on line four applies to this file +%<*batchfile> +{\obeylines\obeyspaces \gdef\thepreamble{ + +Copyright 2012 by Benjamin Tatlock + +This work may be distributed and/or modified under the conditions of the +LaTeX Project Public License, either version 1.3 of this license or (at your +option) any later version. The latest version of this license is in + http://www.latex-project.org/lppl.txt +and version 1.3 or later is part of all distributions of LaTeX version +2005/12/01 or later. + +This work has the LPPL maintenance status `maintained'. + +The Current Maintainer of this work is Benjamin Tatlock. + +This work consists of the file bropd.dtx and the derived files bropd.sty and +bropd.pdf. +}} +\begingroup +\input docstrip +\keepsilent +\expandafter\preamble\thepreamble\endpreamble +\generate{\file{bropd.sty}{\from{bropd.dtx}{}}} +\endgroup +\documentclass{ltxdoc} +\usepackage{bropd,ifpdf} +\GetFileInfo{bropd.sty} +\title{The \textsf{bropd} package\thanks{This documentation corresponds to +\textsf{bropd}~v\fileversion, dated \filedate.}} +\author{Benjamin Tatlock} +\newenvironment{verba}{\begin{verbatim}}{\end{verbatim}} +\begin{document} +\maketitle +\begin{abstract} +The \textsf{bropd} package simplifies the process of writing differential +operators and brackets in \LaTeX. The commands facilitate the easy manipulation +of equations involving brackets and allow partial differentials to be expressed +in an alternate form. +\end{abstract} +\section{Introduction} +The \textsf{bropd} package introduces a bracket command that automatically +selects parentheses, square brackets or braces as appropriate based on the +number of brackets. As such, brackets can be freely added and removed without +alterations to the rest an equation. A command for writing ordinary and partial +differentials is also created with an optional concise form for typesetting +partial derivatives. This allows equations to be typed in a standard form and +their style altered globally at a later date. +\section{Usage} +This section outlines the use of the three commands provided by the +\textsf{bropd} package. +\subsection{Brackets} +The bracket command replaces \verb|\left(| and \verb|\right)| with the single +command, \verb|\br| to produce brackets in a math environment. The input +\verb|\br{x}| produces\[\br{x}.\]When nested, the type of bracket is determined +automatically, for example, \verb|r=\br{\br{x-a}^2+\br{y-b}^2}^{\frac{1}{2}}| +results in\[r=\br{\br{x-a}^2+\br{y-b}^2}^{\frac{1}{2}}.\] +\subsection{Differential operators} +\subsubsection{Ordinary differential} +The \verb|\od| command produces ordinary differentials, such as \verb|\od{y}{x}| +which is displayed as\[\od{y}{x}.\]The order of the differential can be +specified as an optional argument, illustrated here with the command +\verb|\od[2]{u}{x}=-\omega^2u| which results in\[\od[2]{u}{x}=-\omega^2u.\]When +using \verb|\od| with a sans-serif font, the package should be loaded with the +optional argument \verb|sans|.\subsubsection{Partial differential}The command +\verb|\pd| follows the same form as \verb|\od|, but instead produces partial +differentials. By default \verb|\pd{u}{t}=6u\pd{u}{x}-\pd[3]{u}{x}| +produces\[\pd{u}{t}=6u\pd{u}{x}-\pd[3]{u}{x}.\]Loading the package with the +option \verb|pdshort| results in an alternative format for partial +differentials:\[u_t=6uu_x-u_{xxx}\]Note that when using this form, the +\verb|\br| function \emph{must} follow \verb|\pd| when the first argument is +left empty, as demonstrated by \verb|\pd{}{z}\br{x+y}| which results +in\[\br{x+y}_z.\]If the optional argument is not a positive integer, the default +form is reverted to, as with \verb|\pd[n]xy|:\[\pd[n]xy\]The syntax for partial +differentials is extended to allow the second order term such +as\[\pd{u}{x,t}\]to be easily typeset with \verb|\pd{u}{x,t}|. +\subsection{Further examples} +Combining the commands provided by this package allows more complex terms to be +written concisely. The \verb|\br| allows equations with multiple brackets to be +constructed and manipulated quickly and easily. An example of this is +\verb|\br{x-y}\br{Q-\frac12\br{P+\br{x-1}\br{\br{A+B}\br{u+c}-t}}}|, which +results in\[\br{x-y}\br{Q-\frac12\br{P+\br{x-1}\br{\br{A+B}\br{u+c}-t}}}.\] +The form of the partial differentials written with the \verb|\pd| command can be +changed at any time.\verb|\pd Et+\sum_{i=1}^3\pd{}{x_i}\br{\br{E+p}u_i}| +produces\[\pd Et+\sum_{i=1}^3\pd{}{x_i}\br{\br{E+p}u_i}\] +or, with \verb|pdshort|,\[E_t+\sum_{i=1}^3\br{\br{E+p}u_i}_{x_i}.\] +\StopEventually{\typeout{**************************************************} +\typeout{*} +\typeout{* To finish the installation, you have to move the} +\typeout{* following file into a directory searched by TeX:} +\typeout{*} +\typeout{* \space\space bropd.sty} +\typeout{*} +\typeout{* Documentation is in bropd.\ifpdf pdf\else dvi\fi.} +\typeout{*} +\typeout{**************************************************}\end{document}} +\clearpage +\DocInput{bropd.dtx} +\clearpage +\Finale +%</batchfile> +% \fi +% \section{Implementation} +% Announce the name, package version and \LaTeXe\ requirement +% \begin{macrocode} +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{bropd} +[2012/11/04 1.0 automated typing of brackets and differential operators] +% \end{macrocode} +% Initiate conditionals and counters +% \begin{macrocode} +\newif\if@bropd@a\newif\if@bropd@b\newif\if@bropd@s +\newcounter{@bropd@c}\newcounter{@bropd@d} +\newcounter{@bropd@e}\newcounter{@bropd@f} +% \end{macrocode} +% Provide optional arguments for alternative form partial differential and +% sans-serif fonts +% \begin{macrocode} +\DeclareOption{pdshort}{\@bropd@atrue} +\DeclareOption{sans}{\@bropd@strue}\ProcessOptions +% \end{macrocode} +% Internal command for default partial differential form +% \begin{macrocode} +\newcommand\@bropd@g[4]{\def\@bropd@h{#1} +\ifx\@bropd@h\empty +\setcounter{@bropd@c}0\setcounter{@bropd@d}1 +\let\@bropd@h\empty +% \end{macrocode} +% Determine order of partial derivative and display as power of partial if +% greater than one +% \begin{macrocode} +\@for\@bropd@i:=#3\do{\stepcounter{@bropd@c}} +\frac{#4\ifnum\value{@bropd@c}>1 +^{\arabic{@bropd@c}}\fi#2} +% \end{macrocode} +% Cycle through each term for the denominator. If a term is the same as the +% previous, add to counter, otherwise print along with counter value +% \begin{macrocode} +{\@for\@bropd@i:=#3\do{ +\ifx\@bropd@i\@bropd@h +\stepcounter{@bropd@d} +\else +\@bropd@h +\ifnum\value{@bropd@d}>1 +^{\arabic{@bropd@d}} +\fi +#4\setcounter{@bropd@d}1 +\fi +\let\@bropd@h\@bropd@i} +\@bropd@h +\ifnum\value{@bropd@d}>1 +^{\arabic{@bropd@d}}\fi} +\else +% \end{macrocode} +% If optional argument provided, display partial differential to stated order +% \begin{macrocode} +\frac{#4^{#1}#2}{#4#3^{#1}} +\fi} +% \end{macrocode} +% Internal command for brackets. Evaluate terms within brackets to determine +% the highest bracket level +% \begin{macrocode} +\newcommand\@bropd@j[1]{\setcounter{@bropd@f}0 +{\renewcommand{\br}[1]{\stepcounter{@bropd@e}{##1} +\ifnum\value{@bropd@e}>\value{@bropd@f} +\setcounter{@bropd@f}{\value{@bropd@e}} +\fi +\addtocounter{@bropd@e}{-1}}\sbox0{$#1$}} +\loop +\ifnum\value{@bropd@f}>2 +\addtocounter{@bropd@f}{-3} +\repeat +% \end{macrocode} +% Detemine bracket type for current level +% \begin{macrocode} +\ifnum\value{@bropd@f}>0 +\ifnum\value{@bropd@f}>1 +\def\@bropd@k{\left\lbrace#1\right\rbrace} +\else +\def\@bropd@k{\left[#1\right]} +\fi +\else +\def\@bropd@k{\left(#1\right)} +\fi} +\if@bropd@a +\let\@bropd@l\empty +% \end{macrocode} +% External bracket command +% \begin{macrocode} +\newcommand\br[1]{\let\@bropd@m\@bropd@l +\@bropd@j{\let\@bropd@l\empty#1\let\@bropd@l\@bropd@m} +\ifx\@bropd@l\empty +\def\@bropd@n{\@bropd@k} +\else +\let\@bropd@m\@bropd@l +\def\@bropd@n{\@bropd@k_{\@bropd@m}} +\fi +\let\@bropd@l\empty +\@bropd@n} +% \end{macrocode} +% External command for alternative partial differential command +% \begin{macrocode} +\newcommand\pd[3][]{\def\@bropd@h{#1} +\ifx\@bropd@h\empty +\@bropd@bfalse +\else +% \end{macrocode} +% Default partial differential if character provided as optional argument +% \begin{macrocode} +\if!\ifnum9<1#1!\else_\fi +\@bropd@bfalse +\else +\@bropd@btrue +\fi +\fi +\if@bropd@b\@bropd@g{#1}{#2}{\noexpand#3}\partial +\else +% \end{macrocode} +% Construct alternate form partial differential +% \begin{macrocode} +\def\@bropd@o{#2} +\def\@bropd@p{\ifx\@bropd@h\empty +\@for\@bropd@i:=#3\do\@bropd@i\else\setcounter{@bropd@c}0 +\loop +\ifnum\value{@bropd@c}<#1 +#3\stepcounter{@bropd@c} +\repeat +\fi} +\ifx\@bropd@o\empty +\let\@bropd@l\@bropd@p\else{#2}{_{\@bropd@p}}\fi\fi} +\else +% \end{macrocode} +% External command for default partial differentials +% \begin{macrocode} +\newcommand\pd[3][]{\@bropd@g{#1}{#2}{\noexpand#3}\partial} +% \end{macrocode} +% External command for brackets +% \begin{macrocode} +\newcommand\br[1]{\@bropd@j{#1}\@bropd@k} +\fi +% \end{macrocode} +% Format ordinary differential based on font type +% \begin{macrocode} +\if@bropd@s +\newcommand\@bropd@r{\mathsf{d}} +\else +\newcommand\@bropd@r{\mathrm{d}} +\fi +% \end{macrocode} +% External command for ordinary differentials +% \begin{macrocode} +\newcommand\od[3][]{\def\@bropd@h{#1} +\frac{\@bropd@r\ifx\@bropd@h\empty\else^{#1}\fi#2} +{\@bropd@r#3\ifx\@bropd@h\empty\else^{#1}\fi}} +\endinput +% \end{macrocode} +% \endinput diff --git a/Master/texmf-dist/tex/latex/bropd/bropd.sty b/Master/texmf-dist/tex/latex/bropd/bropd.sty new file mode 100644 index 00000000000..5f16b74b052 --- /dev/null +++ b/Master/texmf-dist/tex/latex/bropd/bropd.sty @@ -0,0 +1,123 @@ +%% +%% This is file `bropd.sty', +%% generated with the docstrip utility. +%% +%% The original source files were: +%% +%% bropd.dtx +%% +%% Copyright 2012 by Benjamin Tatlock +%% +%% This work may be distributed and/or modified under the conditions of the +%% LaTeX Project Public License, either version 1.3 of this license or (at your +%% option) any later version. The latest version of this license is in +%% http://www.latex-project.org/lppl.txt +%% and version 1.3 or later is part of all distributions of LaTeX version +%% 2005/12/01 or later. +%% +%% This work has the LPPL maintenance status `maintained'. +%% +%% The Current Maintainer of this work is Benjamin Tatlock. +%% +%% This work consists of the file bropd.dtx and the derived files bropd.sty and +%% bropd.pdf. +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{bropd} +[2012/11/04 1.0 automated typing of brackets and differential operators] +\newif\if@bropd@a\newif\if@bropd@b\newif\if@bropd@s +\newcounter{@bropd@c}\newcounter{@bropd@d} +\newcounter{@bropd@e}\newcounter{@bropd@f} +\DeclareOption{pdshort}{\@bropd@atrue} +\DeclareOption{sans}{\@bropd@strue}\ProcessOptions +\newcommand\@bropd@g[4]{\def\@bropd@h{#1} +\ifx\@bropd@h\empty +\setcounter{@bropd@c}0\setcounter{@bropd@d}1 +\let\@bropd@h\empty +\@for\@bropd@i:=#3\do{\stepcounter{@bropd@c}} +\frac{#4\ifnum\value{@bropd@c}>1 +^{\arabic{@bropd@c}}\fi#2} +{\@for\@bropd@i:=#3\do{ +\ifx\@bropd@i\@bropd@h +\stepcounter{@bropd@d} +\else +\@bropd@h +\ifnum\value{@bropd@d}>1 +^{\arabic{@bropd@d}} +\fi +#4\setcounter{@bropd@d}1 +\fi +\let\@bropd@h\@bropd@i} +\@bropd@h +\ifnum\value{@bropd@d}>1 +^{\arabic{@bropd@d}}\fi} +\else +\frac{#4^{#1}#2}{#4#3^{#1}} +\fi} +\newcommand\@bropd@j[1]{\setcounter{@bropd@f}0 +{\renewcommand{\br}[1]{\stepcounter{@bropd@e}{##1} +\ifnum\value{@bropd@e}>\value{@bropd@f} +\setcounter{@bropd@f}{\value{@bropd@e}} +\fi +\addtocounter{@bropd@e}{-1}}\sbox0{$#1$}} +\loop +\ifnum\value{@bropd@f}>2 +\addtocounter{@bropd@f}{-3} +\repeat +\ifnum\value{@bropd@f}>0 +\ifnum\value{@bropd@f}>1 +\def\@bropd@k{\left\lbrace#1\right\rbrace} +\else +\def\@bropd@k{\left[#1\right]} +\fi +\else +\def\@bropd@k{\left(#1\right)} +\fi} +\if@bropd@a +\let\@bropd@l\empty +\newcommand\br[1]{\let\@bropd@m\@bropd@l +\@bropd@j{\let\@bropd@l\empty#1\let\@bropd@l\@bropd@m} +\ifx\@bropd@l\empty +\def\@bropd@n{\@bropd@k} +\else +\let\@bropd@m\@bropd@l +\def\@bropd@n{\@bropd@k_{\@bropd@m}} +\fi +\let\@bropd@l\empty +\@bropd@n} +\newcommand\pd[3][]{\def\@bropd@h{#1} +\ifx\@bropd@h\empty +\@bropd@bfalse +\else +\if!\ifnum9<1#1!\else_\fi +\@bropd@bfalse +\else +\@bropd@btrue +\fi +\fi +\if@bropd@b\@bropd@g{#1}{#2}{\noexpand#3}\partial +\else +\def\@bropd@o{#2} +\def\@bropd@p{\ifx\@bropd@h\empty +\@for\@bropd@i:=#3\do\@bropd@i\else\setcounter{@bropd@c}0 +\loop +\ifnum\value{@bropd@c}<#1 +#3\stepcounter{@bropd@c} +\repeat +\fi} +\ifx\@bropd@o\empty +\let\@bropd@l\@bropd@p\else{#2}{_{\@bropd@p}}\fi\fi} +\else +\newcommand\pd[3][]{\@bropd@g{#1}{#2}{\noexpand#3}\partial} +\newcommand\br[1]{\@bropd@j{#1}\@bropd@k} +\fi +\if@bropd@s +\newcommand\@bropd@r{\mathsf{d}} +\else +\newcommand\@bropd@r{\mathrm{d}} +\fi +\newcommand\od[3][]{\def\@bropd@h{#1} +\frac{\@bropd@r\ifx\@bropd@h\empty\else^{#1}\fi#2} +{\@bropd@r#3\ifx\@bropd@h\empty\else^{#1}\fi}} +\endinput +%% +%% End of file `bropd.sty'. diff --git a/Master/tlpkg/bin/tlpkg-ctan-check b/Master/tlpkg/bin/tlpkg-ctan-check index 24cae32f1b8..f56843469e0 100755 --- a/Master/tlpkg/bin/tlpkg-ctan-check +++ b/Master/tlpkg/bin/tlpkg-ctan-check @@ -77,7 +77,7 @@ my @TLP_working = qw( booktabs booktabs-de booktabs-fr boolexpr boondox bophook borceux bosisio boxedminipage boxhandler bpchem bpolynomial - bracketkey braids braille braket breakcites breakurl brodp + bracketkey braids braille braket breakcites breakurl bropd bullcntr bundledoc burmese bussproofs bytefield c-pascal cabin cachepic calcage calctab calculator calligra calligra-type1 calrsfs cals calxxxx-yyyy cancel diff --git a/Master/tlpkg/libexec/ctan2tds b/Master/tlpkg/libexec/ctan2tds index 9b030d9b322..80a7e5ed493 100755 --- a/Master/tlpkg/libexec/ctan2tds +++ b/Master/tlpkg/libexec/ctan2tds @@ -1885,7 +1885,7 @@ $standardsource='\.(bat|c|drv|dtx|fea|fdd|ins|sfd)$|configure.*|install-sh'; 'booktabs-de', 'NULL', # doc, no need to build 'blacklettert1','NULL', # don't try to do fontinst 'bosisio', '.*\.dtx', - 'brodp', "$package.dtx", + 'bropd', "$package.dtx", 'calculator', "$package.dtx", 'canoniclayout','.*\.dtx', 'carlisle', '\.ins|ltxtable.tex', diff --git a/Master/tlpkg/tlpsrc/bropd.tlpsrc b/Master/tlpkg/tlpsrc/bropd.tlpsrc new file mode 100644 index 00000000000..e69de29bb2d --- /dev/null +++ b/Master/tlpkg/tlpsrc/bropd.tlpsrc diff --git a/Master/tlpkg/tlpsrc/collection-mathextra.tlpsrc b/Master/tlpkg/tlpsrc/collection-mathextra.tlpsrc index 195f2f91c11..187e3ff8211 100644 --- a/Master/tlpkg/tlpsrc/collection-mathextra.tlpsrc +++ b/Master/tlpkg/tlpsrc/collection-mathextra.tlpsrc @@ -6,7 +6,7 @@ depend amstex depend binomexp depend boldtensors depend bosisio -depend brodp +depend bropd depend ccfonts depend commath depend concmath |