diff options
author | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
---|---|---|
committer | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
commit | e0c6872cf40896c7be36b11dcc744620f10adf1d (patch) | |
tree | 60335e10d2f4354b0674ec22d7b53f0f8abee672 /macros/latex/contrib/bosisio |
Initial commit
Diffstat (limited to 'macros/latex/contrib/bosisio')
27 files changed, 5532 insertions, 0 deletions
diff --git a/macros/latex/contrib/bosisio/README b/macros/latex/contrib/bosisio/README new file mode 100644 index 0000000000..0772d5f3de --- /dev/null +++ b/macros/latex/contrib/bosisio/README @@ -0,0 +1,91 @@ +#=======================================================================# +# Bosisio's LaTeX packages # +#=======================================================================# + + ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +| Copyright(C) 1997-2010 by F. Bosisio | +| | +| This program can be redistributed and/or modified under | +| the terms 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 LaTeX distributions | +| version 2005/12/01 or later. | +| | +| This work has the LPPL maintenance status `maintained'. | +| The Current Maintainer of this work is F. Bosisio. | +| | +| This work consists of files README and index.html. | +| | +| E-mail: fbosisio@bigfoot.com | +| CTAN location: macros/latex/contrib/bosisio/ | ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + +This file describes the LaTeX packages developed and mantained +by F. Bosisio at the "Politecnico di Milano", Italy. +See file "index.html" for a more detailed description of each package. + +For information on the whole LaTeX packages visit the CTAN archive +(http://www.ctan.org) or search the CTAN Catalogue online +(http://www.ctan.org/Catalogue). + +At now the available packages are: + * envmath: + - Extended and more powerful math-environments + - The new math environments are used to make multi-line formulas and + systems of equations, both numbered or unnumbered. + + * mathenv: + - Old name for the "envmath" package + - Package "mathenv" has been renamed to "envmath", in order to avoid + conflicts with another package with the same name: if you were using + the "old" "mathenv" package, you need to change your LaTeX files in + order to include the new one. + + * mathcmd: + - Extended math-mode commands + - New commands include derivatives, vectors operators, arrow-limits, + integrals and sums. + + * sobolev: + - Commands to deal with Sobolev and Hilbert spaces + - The new commands include norm, semi-norm, scalar products, crochet + symbols, besides the various Sobolev spaces. + + * graphfig: + - Simple and powerful way of using graphics files inside figures + - It provides a new "Figure" environment and a "\graphfile" command: + the combined use of these authomatically produce a correct centering + of the graph(s) with respect to the page. + Moreover, subfigures can be handled in the same way and hard-to-discover + errors (such as a "\label" preceding a "\caption") are eliminated. + + * dblfont: + - An easy way to define blackboard-bold letters + + * accenti: + - This package is obsolete and its only aim is to simplify the usage + of accents in the Italian language. + - The declaration "\usepackage[latin1]{inputenc}" is a better alternative, + as it directly allows the use of the accented characters in the document, + which is extremly useful with an italian keyboard. + + * quotes: + - Use double-quote character for both opening and closing quotes. + + * evenpage: + - Ensure that the number of pages generated by "LaTeX" is an even number. + +Besides the packages themselves, also the "makedoc" utility is available: +it is a UNIX shell-script that takes a ".dtx" file and extracts both the +".sty" file and the documentation (which is automatically compiled with LaTeX). +The script only works for ".dtx" files that are structured like my packages, +i.e. they must directly produce the style-file and a documentation-driver +(".drv") when simply run through LaTeX. + +If you have any suggestions, find any bugs or make any improvment on any of +my packages, please let me know about it by sending an E-mail at the following +address: fbosisio@bigfoot.com diff --git a/macros/latex/contrib/bosisio/accenti.dtx b/macros/latex/contrib/bosisio/accenti.dtx new file mode 100644 index 0000000000..6f6ab9a78d --- /dev/null +++ b/macros/latex/contrib/bosisio/accenti.dtx @@ -0,0 +1,327 @@ +%\iffalse % MetaComment +%% +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% | Copyright(C) 1997-2010 by F. Bosisio | +%% | | +%% | This program can be redistributed and/or modified under | +%% | the terms 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 LaTeX distributions | +%% | version 2005/12/01 or later. | +%% | | +%% | This work has the LPPL maintenance status `maintained'. | +%% | The Current Maintainer of this work is F. Bosisio. | +%% | | +%% | This work consists of files accenti.dtx and accenti.html | +%% | and of the derived files accenti.sty and accenti.pdf. | +%% | | +%% | E-mail: fbosisio@bigfoot.com | +%% | CTAN location: macros/latex/contrib/bosisio/ | +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% +%% If you make any improvment, find any bug or have +%% any suggestion, please let me know about it. +%% +%<*package,driver> +%\fi +% +\def\FileName{accenti} +%\iffalse % MetaComment +%</package,driver> +%<*package> +%\fi +\def\fileversion{2.3} +\def\filedate{2005/04/02} +\def\docdate{2005/04/09} +\def\filedescr{Commands to make accents (FB)} +% +%\iffalse % MetaComment +%</package> +%<*dtx> +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +% This section is the installation driver +% +\def\batchfile{\FileName.dtx} +% +\input docstrip +% +\keepsilent +% \askforoverwritefalse +% +\generateFile{\FileName.sty}{f}{\from{\FileName.dtx}{package}} +% +\generateFile{\FileName.drv}{f}{\from{\FileName.dtx}{driver}} +% +\Msg{******************************************************} +\Msg{*} +\Msg{* To produce the documentation run the} +\Msg{* file `\FileName.drv' through LaTeX.} +\Msg{*} +\Msg{******************************************************} +% +\endbatchfile +% +% End of the installation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%</dtx> +% +% This section is the documentation driver +% +%<+driver>\documentclass[12pt,a4paper]{ltxdoc} +%<+driver> \EnableCrossrefs +%<+driver> \CodelineIndex +%<+driver> \RecordChanges +%<+driver> %\OnlyDescription % Uncomment not to see the implementation +%<+driver>\begin{document} +%<+driver> \DocInput{\FileName.dtx} +%<+driver> \PrintIndex +%<+driver> \PrintChanges +%<+driver>\end{document} +% +% End of the documentation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%<*package> +%\fi +% +% \changes{v0.1}{4 May 1997}{First release (basic accents-command)} +% \changes{v0.2}{20 August 1997}{Added extended-chars handling} +% \changes{v1.0}{5 September 1997}{Documentation added} +% \changes{v1.1}{7 November 1997}{Fixed a bug in the options} +% \changes{v2.0}{20 December 1997}{Separated from package ``quotes''} +% \changes{v2.1}{5 March 1999}{Added copyright notice and changed addresses} +% \changes{v2.2}{2 April 2005}{All commands made robust} +%\iffalse % MetaComment +% The previous change was requested by Robin Fairbains (robin.fairbains@cl.cam.ac.uk) +%\fi +% \changes{v2.3}{9 April 2005}{Usage of the double-quote character (") avoided} +% +% \MakeShortVerb{\|} +% +% \title{Package \texttt{\FileName}\thanks{This is version \fileversion, +% last revised \filedate; documentation date \docdate}} +% \author{F. Bosisio\\\normalsize E-mail: \texttt{fbosisio@bigfoot.com}} +% \date{\filedate} +% \maketitle +% +% \begin{abstract} +% Documentation for the package \texttt{\FileName}. +% \end{abstract} +% +% \section{Introduction} +% This package provides a shorter version of some accents-making +% commands, particularly suited for italian language. +% +% In particular some commands are redefined, so care should be +% taken, expecially when including this package in an already +% existent \LaTeX{} file. +% +% \noindent +% The redefined commands are:\\ +% ``|\a|'', ``|\i|'', ``|\o|'' and ``|\u|'',\\ +% whose job can now be done by the commands\\ +% ``|\oFinnick|'' (finnick ``o'' bar), +% ``|\DotlessI|'' (dotless ``i'', for accents), +% ``|\aAccent|'' (for accents in |tabbing| environment) +% and ``|\uAccent|'' (upsidedown ``hat'' accent). +% +% \section{Obsolete package} +% +% This package is \emph{obsolete}, as it has been superseeded by +% the standard ``|inputenc|'' package: indeed, the declaration\\ +% \mbox{}\qquad |\usepackage[latin1]{inputenc}|\\ +% directly allows the use of the characters ``\`a'', ``\`e'', +% ``\`\i'', ``\`o'', ``\`u'' and ``\'e'' in the document, which +% is extremly useful with an italian keyboard. +% +% \section{Required packages} +% +% This package requires the ``|\xspace|'' command provided by +% the ``|xspace|'' package. +% +% \section{Options} +% +% This package provides the options ``|ExtdChar|'' and +% ``|ExtdCharOnly|'' which allow the use of the special +% characters ``\`a'', ``\`e'', ``\`\i'', ``\`o'', ``\`u'' and ``\'e'' +% as accents-making commands. +% The second option also inhibits the definitions of +% ``|\a|'', ``|\e|'', ``|\i|'', ``|\o|'', ``|\u|'', ``|\ee|'' +% and ``|\che|'' as short forms of the accent-commands +% (it is particularly useful for non-Italian documents). +% +% \section{Accents} +% +% Unless you specify the ``|ExtdCharOnly|'' option, the +% commands ``|\a|'', ``|\e|'', ``|\i|'', ``|\o|'', ``|\u|'' and ``|\E|'' +% prints the corresponding letter with a grave accent; +% the commands ``|\ee|'' and ``|\che|'' print the letter ``|e|'' +% or the three letters ``|che|'' with an acute accent (i.e. ``\'e'' +% and ``ch\'e''). +% +% Moreover, if the ``|ExtdChar|'' or ``|ExtdCharOnly|'' option was +% used, the chars ``\`a'', ``\`e'', ``\`\i'', ``\`o'', ``\`u'' and ``\'e'' +% are equivalent to the commands ``|\`a|'', ``|\`e|'', ``|\`\i|'', +% ``|\`o|'', ``|\`u|'' and ``|\'e|''. +% +% \StopEventually{} +% \newpage +% \section{Implementation} +% +% \begin{macrocode} +%% +\NeedsTeXFormat{LaTeX2e}[1995/12/01] +\ProvidesPackage{\FileName}[\filedate\space v\fileversion\space\filedescr] +\RequirePackage{xspace}[1996/12/06 v1.05] +%% +\newif\if@ExtendedAccChar\@ExtendedAccCharfalse +\DeclareOption{ExtdChar}{\@ExtendedAccChartrue} +%% +\newif\if@NotOnlyExtended@\@NotOnlyExtended@true +\DeclareOption{ExtdCharOnly}{\@NotOnlyExtended@false} +%% +\ProcessOptions +%% +% \end{macrocode} +% +% \begin{macro}{\a,\e,\i,\o,\u,\ee,\che,\E} +% +% The original commands ``|\a|'', ``|\i|'', ``|\o|'' and ``|\u|'' are +% saved before being redefined. +% The combined use of an intermediate internal command and of +% ``|\DeclareRobustCommand*|'', allow for all the commands of the +% package to be robust (even the saved original ones). +% +% \begin{macrocode} +%% +\let\a@RIGINAL=\a +\let\i@RIGINAL=\i +\let\o@RIGINAL=\o +\let\u@RIGINAL=\u +%% +\DeclareRobustCommand*\aAccent{\a@RIGINAL} +\DeclareRobustCommand*\DotlessI{\i@RIGINAL} +\DeclareRobustCommand*\oFinnick{\o@RIGINAL} +\DeclareRobustCommand*\uAccent{\u@RIGINAL} +% \end{macrocode} +% +% The commands ``|\a|'', ``|\e|'', ``|\i|'', ``|\o|'', ``|\u|'' and ``|\E|'' +% prints the corresponding letter with a grave accent; +% the commands ``|\ee|'' and ``|\che|'' print the letter ``|e|'' +% or the three letters ``|che|'' with an acute accent (i.e. ``\'e'' +% and ``ch\'e''). +% The definitions are deferred at the ``|\begin{document}|'' +% in order to avoid conflicts with other packages. +% +% \begin{macrocode} +%% +\if@NotOnlyExtended@ %-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\ + \AtBeginDocument{% + \renewcommand*\a{\`a\xspace}% + \newcommand*\e{\`e\xspace}% + \renewcommand*\i{\`\DotlessI\xspace}% + \renewcommand*\o{\`o\xspace}% + \renewcommand*\u{\`u\xspace}% + \newcommand*\E{\`E\xspace}% + \newcommand*\ee{\'e\xspace}% + \newcommand*\che{ch\'e\xspace}% + } +\fi %-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/ +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{Accents} +% A trick adapted from the |doc| package (which, perhaps, may be +% done in a better way) is used (if the ``|ExtdChar|'' option was +% selected) to associate the extended-ASCII chars which represents +% accents with the corresponding accent-making commands. +% +% \begin{macrocode} +%% +\if@ExtendedAccChar %-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\ +%% +%% %%%%%%%%%% +%% % à = \a % +%% %%%%%%%%%% +\begingroup + \catcode`\~\active \lccode`\~`\à% + \lowercase{% + \global\expandafter\let + \csname ac\string\à\endcsname~% + \gdef~{\`a}}% +\endgroup +\global\catcode`\à\active +%% +%% %%%%%%%%%% +%% % è = \e % +%% %%%%%%%%%% +\begingroup + \catcode`\~\active \lccode`\~`\è% + \lowercase{% + \global\expandafter\let + \csname ac\string\è\endcsname~% + \gdef~{\`e}}% +\endgroup +\global\catcode`\è\active +%% +%% %%%%%%%%%%% +%% % é = \ee % +%% %%%%%%%%%%% +\begingroup + \catcode`\~\active \lccode`\~`\é% + \lowercase{% + \global\expandafter\let + \csname ac\string\è\endcsname~% + \gdef~{\'e}}% +\endgroup +\global\catcode`\é\active +%% +%% %%%%%%%%%% +%% % ì = \i % +%% %%%%%%%%%% +\begingroup + \catcode`\~\active \lccode`\~`\ì% + \lowercase{% + \global\expandafter\let + \csname ac\string\ì\endcsname~% + \gdef~{\`\DotlessI}}% +\endgroup +\global\catcode`\ì\active +%% +%% %%%%%%%%%% +%% % ò = \o % +%% %%%%%%%%%% +\begingroup + \catcode`\~\active \lccode`\~`\ò% + \lowercase{% + \global\expandafter\let + \csname ac\string\ò\endcsname~% + \gdef~{\`o}}% +\endgroup +\global\catcode`\ò\active +%% +%% %%%%%%%%%% +%% % ù = \u % +%% %%%%%%%%%% +\begingroup + \catcode`\~\active \lccode`\~`\ù% + \lowercase{% + \global\expandafter\let + \csname ac\string\ù\endcsname~% + \gdef~{\`u}}% +\endgroup +\global\catcode`\ù\active +%% +\fi %-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/-/ +% \end{macrocode} +% \end{macro} +% +%\iffalse % MetaComment +%<*package> +%\fi +% +% \CheckSum{271} +% \Finale +% +\endinput diff --git a/macros/latex/contrib/bosisio/accenti.html b/macros/latex/contrib/bosisio/accenti.html new file mode 100644 index 0000000000..24fec226d8 --- /dev/null +++ b/macros/latex/contrib/bosisio/accenti.html @@ -0,0 +1,162 @@ +<html> +<!-- ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +| Copyright(C) 1997-2010 by F. Bosisio | +| | +| This program can be redistributed and/or modified under | +| the terms 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 LaTeX distributions | +| version 2005/12/01 or later. | +| | +| This work has the LPPL maintenance status `maintained'. | +| The Current Maintainer of this work is F. Bosisio. | +| | +| This work consists of files accenti.dtx and accenti.html | +| and of the derived files accenti.sty and accenti.pdf. | +| | +| E-mail: fbosisio@bigfoot.com | +| CTAN location: macros/latex/contrib/bosisio/ | ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +--> +<head> + <title>Package accenti</title> +</head> +<body> + +<h1 align="center"> + Package <tt>accenti</tt><br /> + <small> + This is version 2.3, last revised 2005/04/02; documentation date 2005/04/09. + </small> +</h1> + +<p align="center"> + <strong> + Author: <i>F. Bosisio</i><br /> + <small> + E-mail: <a href="mailto:fbosisio@bigfoot.com"> + <tt>fbosisio@bigfoot.com</tt> + </a><br /> + CTAN location: <a href="http://mirror.ctan.org/macros/latex/contrib/bosisio"> + <tt>macros/latex/contrib/bosisio</tt> + </a> + </small> + </strong> +</p> + +<!------------------------------------------------------------------------> + +<h3>Abstract:</h3> + +<div> + Documentation for the package <tt>accenti</tt>. +</div> + +<br /><hr /> +<!------------------------------------------------------------------------> + +<h2>Table of contents</h2> + +<ul> + <li><a href="#SECTION01">Introduction</a></li> + <li><a href="#SECTION02">Obsolete package</a></li> + <li><a href="#SECTION03">Required packages</a></li> + <li><a href="#SECTION04">The options</a></li> + <li><a href="#SECTION05">Accents</a></li> +</ul> + +<br /><hr /> +<!------------------------------------------------------------------------> + +<h2><a name="SECTION01">Introduction</a></h2> + +<p> + This package provides a shorter version of some accents-making + commands, particularly suited for italian language. +</p> + +<p> + In particular some commands are redefined, so care should be + taken, expecially when including this package in an already + existent LaTeX file. +</p> + +<p> + The redefined commands are: + ``<tt>\a</tt>'', ``<tt>\i</tt>'', ``<tt>\o</tt>'' and ``<tt>\u</tt>'',<br /> + whose job can now be done by the commands<br /> + ``<tt>\oFinnick</tt>'' (finnick ``o'' bar), + ``<tt>\DotlessI</tt>'' (dotless ``i'', for accents), + ``<tt>\aAccent</tt>'' (for accents in <tt>tabbing</tt> environment) + and ``<tt>\uAccent</tt>'' (upsidedown ``hat'' accent). +</p> + +<h2><a name="SECTION02">Obsolete package</a></h2> + +<p> + This package is <em>obsolete</em>, as it has been superseeded by the + standard ``<tt>inputenc</tt>'' package: indeed, the declaration + <pre> + \usepackage[latin1]{inputenc} + </pre> + directly allows the use of the characters ``à'', ``è'', + ``ì'', ``ò'', ``ù'' and ``é'' in the + document, which is extremly useful with an italian keyboard. +</p> + + +<h2><a name="SECTION03">Required packages</a></h2> + +<p> + This package requires the ``<tt>\xspace</tt>'' command provided by + the ``<tt>xspace</tt>'' package. +</p> + +<h2><a name="SECTION04">The options</a></h2> + +<p> + This package provides the options ``<tt>ExtdChar</tt>'' and + ``<tt>ExtdCharOnly</tt>'' which allow the use of the special + characters ``à'', ``è'', ``ì'', ``ò'', + ``ù'' and ``é'' as accents-making commands. + The second option also inhibits the definitions of + ``<tt>\a</tt>'', ``<tt>\e</tt>'', ``<tt>\i</tt>'', ``<tt>\o</tt>'', + ``<tt>\u</tt>'', ``<tt>\ee</tt>'' and ``<tt>\che</tt>'' as short forms + of the accent-commands (it can be expecially useful for non-Italian + documents). +</p> + +<h2><a name="SECTION05">Accents</a></h2> + +<p> + Unless you specify the ``<tt>ExtdCharOnly</tt>'' option, the + commands ``<tt>\a</tt>'', ``<tt>\e</tt>'', ``<tt>\i</tt>'', + ``<tt>\o</tt>'', ``<tt>\u</tt>'' and ``<tt>\E</tt>'' + prints the corresponding letter with a grave accent, whilst + the commands ``<tt>\ee</tt>'' and ``<tt>\che</tt>'' print the letter + ``</tt>e</tt>'' or the three letters ``</tt>che</tt>'' with an acute + accent (i.e. ``é'' and ``ché''). +</p> + +<p> + Moreover, if the ``<tt>ExtdChar</tt>'' or ``<tt>ExtdCharOnly</tt>'' + option was used, the characters``à'', ``è'', ``ì'', + ``ò'', ``ù'' and ``é'' are equivalent to the + commands ``</tt>\`a</tt>'', ``</tt>\`e</tt>'', ``</tt>\`\i</tt>'', + ``</tt>\`o</tt>'', ``</tt>\`u</tt>'' and ``</tt>\'e</tt>''. +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<address> + <i>F. Bosisio</i><br /> + E-mail: <a href="mailto:fbosisio@bigfoot.com"><tt>fbosisio@bigfoot.com</tt></a> +</address> + +<!------------------------------------------------------------------------> +</body> +</html> diff --git a/macros/latex/contrib/bosisio/accenti.pdf b/macros/latex/contrib/bosisio/accenti.pdf Binary files differnew file mode 100644 index 0000000000..0ed4ae7e35 --- /dev/null +++ b/macros/latex/contrib/bosisio/accenti.pdf diff --git a/macros/latex/contrib/bosisio/dblfont.dtx b/macros/latex/contrib/bosisio/dblfont.dtx new file mode 100644 index 0000000000..0598e5b3ef --- /dev/null +++ b/macros/latex/contrib/bosisio/dblfont.dtx @@ -0,0 +1,264 @@ +%\iffalse % MetaComment +%% +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% | Copyright(C) 1997-2010 by F. Bosisio | +%% | | +%% | This program can be redistributed and/or modified under | +%% | the terms 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 LaTeX distributions | +%% | version 2005/12/01 or later. | +%% | | +%% | This work has the LPPL maintenance status `maintained'. | +%% | The Current Maintainer of this work is F. Bosisio. | +%% | | +%% | This work consists of files dblfont.dtx and dblfont.html | +%% | and of the derived files dblfont.sty and dblfont.pdf. | +%% | | +%% | E-mail: fbosisio@bigfoot.com | +%% | CTAN location: macros/latex/contrib/bosisio/ | +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% +%% If you make any improvment, find any bug or have +%% any suggestion, please let me know about it. +%% +%<*package,driver> +%\fi +% +\def\FileName{dblfont} +%\iffalse % MetaComment +%</package,driver> +%<*package> +%\fi +\def\fileversion{2.2} +\def\filedate{1997/12/13} +\def\docdate{2005/04/09} +\def\filedescr{Blackboard-bold symbols (FB)} +% +%\iffalse % MetaComment +%</package> +%<*dtx> +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +% This section is the installation driver +% +\def\batchfile{\FileName.dtx} +% +\input docstrip +% +\keepsilent +% \askforoverwritefalse +% +\generateFile{\FileName.sty}{f}{\from{\FileName.dtx}{package}} +% +\generateFile{\FileName.drv}{f}{\from{\FileName.dtx}{driver}} +% +\Msg{******************************************************} +\Msg{*} +\Msg{* To produce the documentation run the} +\Msg{* file `\FileName.drv' through LaTeX.} +\Msg{*} +\Msg{******************************************************} +% +\endbatchfile +% +% End of the installation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%</dtx> +% +% This section is the documentation driver +% +%<+driver>\documentclass[12pt,a4paper]{ltxdoc} +%<+driver> \EnableCrossrefs +%<+driver> \CodelineIndex +%<+driver> \RecordChanges +%<+driver> %\OnlyDescription % Uncomment not to see the implementation +%<+driver>\begin{document} +%<+driver> \DocInput{\FileName.dtx} +%<+driver> \PrintIndex +%<+driver> \PrintChanges +%<+driver>\end{document} +% +% End of the documentation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%<*package> +%\fi +% +% \changes{v0.1}{1 November 1997}{First release} +% \changes{v1.0}{7 November 1997}{Documentation added} +% \changes{v1.1}{17 November 1997}{Added options in ``XX'' format} +% \changes{v2.0}{13 December 1997}{Used ``newcommand*'' instead of ``def''} +% \changes{v2.1}{5 March 1999}{Added copyright notice and changed addresses} +% \changes{v2.2}{9 April 2005}{Usage of the double-quote character (") avoided} +% +% \MakeShortVerb{\|} +% +% \title{Package \texttt{\FileName}\thanks{This is version \fileversion, +% last revised \filedate; documentation date \docdate}} +% \author{F. Bosisio\\\normalsize E-mail: \texttt{fbosisio@bigfoot.com}} +% \date{\filedate} +% \maketitle +% +% \begin{abstract} +% Documentation for the package \texttt{\FileName}. +% \end{abstract} +% +% \section{Introduction} +% This package provides the font ``|\DblFont|'' (font |msbm10|), which +% corresponds to the so called blackdoard-bold symbols. +% +% \section{The options} +% For each uppercase letter ``|X|'' a corresponding ``|X|'' and ``|XX|'' +% options exist: they declare the commands ``|\X|'' and ``|\XX|'' which +% both generate the letter |X| in |DblFont|. +% If a command named ``|\X|'' or ``|\XX|'' already exists in \LaTeX{}, +% its definition is first saved in ``|\BackDoubleX|'' or +% ``|\BackDoubleXX|'', respectively. +% +% \noindent +% Also a ``|RT|'' option exists: it declares the ``|\RT|'' command, +% which generates the two letters |RT| in |DblFont| (used for the +% Raviart-Thomas spaces). +% +% \StopEventually{} +% \newpage +% \section{Implementation} +% +% \begin{macrocode} +%% +\NeedsTeXFormat{LaTeX2e}[1995/12/01] +\ProvidesPackage{\FileName}[\filedate\space v\fileversion\space\filedescr] +% \end{macrocode} +% +% The font ``|\DblFont|'' is loaded, if not already done. +% \begin{macrocode} +%% +\newfont{\DblFont}{msbm10 scaled \magstep1} +% \end{macrocode} +% +% The ``|\DeclareDblFontSymbol|'' has one argument which is used +% both as the command name to define and as the output it should +% generate (in |\DblFont|). +% The ``|\csname #1 \endcsname|'' sequence adds a backslash in front +% of the argument, to get the command name. +% \begin{macrocode} +%% +\newcommand*\DeclareDblFontSymbol[1]{% +\expandafter\newcommand*\csname #1\endcsname{\ensuremath{\mathbb{#1}}}% +} +% \end{macrocode} +% The ``|\dECL@REdBLfONTsYMBOL|'' has one argument which is used +% both as the command name to define (doubled) and as the output +% it should generate (in |\DblFont|). +% The ``|\csname #1#1 \endcsname|'' sequence adds a backslash in front +% of the argument and doubles it, to get the command name. +% \begin{macrocode} +\newcommand*\dECL@REdBLfONTsYMBOL[1]{% +\expandafter\newcommand*\csname #1#1\endcsname{\ensuremath{\mathbb{#1}}}% +} +% \end{macrocode} +% +% The command ``|\BackUpL@texCmd{<X>}|'' saves the command ``|\<X>|'' in +% the macro ``|\BackDouble<X>|'' and then undefines ``|\<X>|'', so that a +% ``|\newcommand*\<X>{..}|'' can be used to redefine it. +% \begin{macrocode} +%% +\newcommand*\BackUpL@texCmd[1]{% +\expandafter\let\csname BackDouble#1\endcsname=\csname #1\endcsname% +\expandafter\let\csname #1\endcsname\undefined% +\typeout{*** Command name ``#1'' has been replaced by ``BackDouble#1''! ***}% +} +% \end{macrocode} +% +% An option exists for each uppercase letter: it declares the +% command ``|\X|'' which generates the letter |X| in |DblFont|, +% where |X| denotes the letter under consideration. +% If a command named ``|\X|'' already exists in \LaTeX{}, its definition +% is saved in ``|\BackDoubleX|'', before being redefined. +% \begin{macrocode} +%% +\DeclareOption{A}{\DeclareDblFontSymbol{A}} +\DeclareOption{B}{\DeclareDblFontSymbol{B}} +\DeclareOption{C}{\DeclareDblFontSymbol{C}} +\DeclareOption{D}{\DeclareDblFontSymbol{D}} +\DeclareOption{E}{\DeclareDblFontSymbol{E}} +\DeclareOption{F}{\DeclareDblFontSymbol{F}} +\DeclareOption{G}{\DeclareDblFontSymbol{G}} +\DeclareOption{H}{\BackUpL@texCmd{H} \DeclareDblFontSymbol{H}} +\DeclareOption{I}{\DeclareDblFontSymbol{I}} +\DeclareOption{J}{\DeclareDblFontSymbol{J}} +\DeclareOption{K}{\DeclareDblFontSymbol{K}} +\DeclareOption{L}{\BackUpL@texCmd{L} \DeclareDblFontSymbol{L}} +\DeclareOption{M}{\DeclareDblFontSymbol{M}} +\DeclareOption{N}{\DeclareDblFontSymbol{N}} +\DeclareOption{O}{\BackUpL@texCmd{O} \DeclareDblFontSymbol{O}} +\DeclareOption{P}{\BackUpL@texCmd{P} \DeclareDblFontSymbol{P}} +\DeclareOption{Q}{\DeclareDblFontSymbol{Q}} +\DeclareOption{R}{\DeclareDblFontSymbol{R}} +\DeclareOption{S}{\BackUpL@texCmd{S} \DeclareDblFontSymbol{S}} +\DeclareOption{T}{\DeclareDblFontSymbol{T}} +\DeclareOption{U}{\DeclareDblFontSymbol{U}} +\DeclareOption{V}{\DeclareDblFontSymbol{V}} +\DeclareOption{W}{\DeclareDblFontSymbol{W}} +\DeclareOption{X}{\DeclareDblFontSymbol{X}} +\DeclareOption{Y}{\DeclareDblFontSymbol{Y}} +\DeclareOption{Z}{\DeclareDblFontSymbol{Z}} +% \end{macrocode} +% +% An option ``|XX|'' exists for each uppercase letter ``|X|'': it declares +% the command ``|\XX|'' which generates the letter |X| in |DblFont|. +% If a command named ``|\XX|'' already exists in \LaTeX{}, its +% definition is saved in ``|\BackDoubleXX|'', before being redefined. +% \begin{macrocode} +%% +\DeclareOption{AA}{\dECL@REdBLfONTsYMBOL{A}} +\DeclareOption{BB}{\dECL@REdBLfONTsYMBOL{B}} +\DeclareOption{CC}{\dECL@REdBLfONTsYMBOL{C}} +\DeclareOption{DD}{\dECL@REdBLfONTsYMBOL{D}} +\DeclareOption{EE}{\dECL@REdBLfONTsYMBOL{E}} +\DeclareOption{FF}{\dECL@REdBLfONTsYMBOL{F}} +\DeclareOption{GG}{\dECL@REdBLfONTsYMBOL{G}} +\DeclareOption{HH}{\dECL@REdBLfONTsYMBOL{H}} +\DeclareOption{II}{\dECL@REdBLfONTsYMBOL{I}} +\DeclareOption{JJ}{\dECL@REdBLfONTsYMBOL{J}} +\DeclareOption{KK}{\dECL@REdBLfONTsYMBOL{K}} +\DeclareOption{LL}{\dECL@REdBLfONTsYMBOL{L}} +\DeclareOption{MM}{\dECL@REdBLfONTsYMBOL{M}} +\DeclareOption{NN}{\dECL@REdBLfONTsYMBOL{N}} +\DeclareOption{OO}{\dECL@REdBLfONTsYMBOL{O}} +\DeclareOption{PP}{\dECL@REdBLfONTsYMBOL{P}} +\DeclareOption{QQ}{\dECL@REdBLfONTsYMBOL{Q}} +\DeclareOption{RR}{\dECL@REdBLfONTsYMBOL{R}} +\DeclareOption{SS}{\BackUpL@texCmd{SS} \dECL@REdBLfONTsYMBOL{S}} +\DeclareOption{TT}{\dECL@REdBLfONTsYMBOL{T}} +\DeclareOption{UU}{\dECL@REdBLfONTsYMBOL{U}} +\DeclareOption{VV}{\dECL@REdBLfONTsYMBOL{V}} +\DeclareOption{WW}{\dECL@REdBLfONTsYMBOL{W}} +\DeclareOption{XX}{\dECL@REdBLfONTsYMBOL{X}} +\DeclareOption{YY}{\dECL@REdBLfONTsYMBOL{Y}} +\DeclareOption{ZZ}{\dECL@REdBLfONTsYMBOL{Z}} +% \end{macrocode} +% +% A further option is for Raviart-Thomas spaces: it declares the +% command ``|\RT|'' which generates the two letters |RT| in |DblFont| +% \begin{macrocode} +% +\DeclareOption{RT}{\DeclareDblFontSymbol{RT}} +% \end{macrocode} +% +% Finally, the user option are parsed, thereby defining the +% corresponding commands. +% \begin{macrocode} +% +\ProcessOptions +% \end{macrocode} +% +%\iffalse % MetaComment +%<*package> +%\fi +% +% \CheckSum{154} +% \Finale +% +\endinput diff --git a/macros/latex/contrib/bosisio/dblfont.html b/macros/latex/contrib/bosisio/dblfont.html new file mode 100644 index 0000000000..ccedddc5a4 --- /dev/null +++ b/macros/latex/contrib/bosisio/dblfont.html @@ -0,0 +1,108 @@ +<html> +<!-- ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +| Copyright(C) 1997-2010 by F. Bosisio | +| | +| This program can be redistributed and/or modified under | +| the terms 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 LaTeX distributions | +| version 2005/12/01 or later. | +| | +| This work has the LPPL maintenance status `maintained'. | +| The Current Maintainer of this work is F. Bosisio. | +| | +| This work consists of files dblfont.dtx and dblfont.html | +| and of the derived files dblfont.sty and dblfont.pdf. | +| | +| E-mail: fbosisio@bigfoot.com | +| CTAN location: macros/latex/contrib/bosisio/ | ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +--> +<head> + <title>Package dblfont</title> +</head> +<body> + +<h1 align="center"> + Package <tt>dblfont</tt><br /> + <small> + This is version 2.2, last revised 1997/12/13; documentation date 2005/04/09. + </small> +</h1> + +<p align="center"> + <strong> + Author: <i>F. Bosisio</i><br /> + <small> + E-mail: <a href="mailto:fbosisio@bigfoot.com"> + <tt>fbosisio@bigfoot.com</tt> + </a><br /> + CTAN location: <a href="http://mirror.ctan.org/macros/latex/contrib/bosisio"> + <tt>macros/latex/contrib/bosisio</tt> + </a> + </small> + </strong> +</p> + +<!------------------------------------------------------------------------> + +<h3>Abstract:</h3> + +<div> + Documentation for the package <tt>dblfont</tt>. +</div> + +<br /><hr /> +<!------------------------------------------------------------------------> + +<h2>Table of contents</h2> + +<ul> + <li><a href="#SECTION01">Introduction</a></li> + <li><a href="#SECTION02">The options</a></li> +</ul> + +<br /><hr /> +<!------------------------------------------------------------------------> + +<h2><a name="SECTION01">Introduction</a></h2> + +<p> + This package provides the font ``<tt>\DblFont</tt>'' (font + <tt>msbm10</tt>), which corresponds to the so called blackdoard-bold + symbols. +</p> + +<h2><a name="SECTION02">The options</a></h2> + +<p> + For each uppercase letter ``<tt>X</tt>'' a corresponding ``<tt>X</tt>'' + and ``<tt>XX</tt>'' options exist: they declare the commands + ``<tt>\X</tt>'' and ``<tt>\XX</tt>'' respectively, which both generate + the letter <tt>X</tt> in <tt>DblFont</tt>. + <br /> + If a command named ``<tt>\X</tt>'' or ``<tt>\XX</tt>'' already exists in + LaTeX, its definition is first saved in ``<tt>\BackDoubleX</tt>'' or + ``<tt>\BackDoubleXX</tt>'' respectively. +</p> + +<p> + Also a ``<tt>RT</tt>'' option exists: it declares the ``<tt>\RT</tt>'' + command, which generates the two letters <tt>RT</tt> in <tt>DblFont</tt> + (useful for the <em>Raviart-Thomas</em> spaces). +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<address> + <i>F. Bosisio</i><br /> + E-mail: <a href="mailto:fbosisio@bigfoot.com"><tt>fbosisio@bigfoot.com</tt></a> +</address> + +<!------------------------------------------------------------------------> +</body> +</html> diff --git a/macros/latex/contrib/bosisio/dblfont.pdf b/macros/latex/contrib/bosisio/dblfont.pdf Binary files differnew file mode 100644 index 0000000000..93b56cea31 --- /dev/null +++ b/macros/latex/contrib/bosisio/dblfont.pdf diff --git a/macros/latex/contrib/bosisio/envmath.dtx b/macros/latex/contrib/bosisio/envmath.dtx new file mode 100644 index 0000000000..e1f74afc03 --- /dev/null +++ b/macros/latex/contrib/bosisio/envmath.dtx @@ -0,0 +1,975 @@ +%\iffalse % MetaComment +%% +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% | Copyright(C) 1997-2010 by F. Bosisio | +%% | | +%% | This program can be redistributed and/or modified under | +%% | the terms 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 LaTeX distributions | +%% | version 2005/12/01 or later. | +%% | | +%% | This work has the LPPL maintenance status `maintained'. | +%% | The Current Maintainer of this work is F. Bosisio. | +%% | | +%% | This work consists of files envmath.dtx and envmath.html | +%% | and of the derived files envmath.sty and envmath.pdf. | +%% | | +%% | E-mail: fbosisio@bigfoot.com | +%% | CTAN location: macros/latex/contrib/bosisio/ | +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% +%% If you make any improvment, find any bug or have +%% any suggestion, please let me know about it. +%% +%<*package,driver> +%\fi +% +\def\FileName{envmath} +%\iffalse % MetaComment +%</package,driver> +%<*package> +%\fi +\def\fileversion{2.5} +\def\filedate{2010/02/10} +\def\docdate{2005/04/09} +\def\filedescr{Extended math environments (FB)} +% +%\iffalse % MetaComment +%</package> +%<*dtx> +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +% This section is the installation driver +% +\def\batchfile{\FileName.dtx} +% +\input docstrip +% +\keepsilent +% \askforoverwritefalse +% +\generateFile{\FileName.sty}{f}{\from{\FileName.dtx}{package}} +% +\generateFile{\FileName.drv}{f}{\from{\FileName.dtx}{driver}} +% +\Msg{******************************************************} +\Msg{*} +\Msg{* To produce the documentation run the} +\Msg{* file `\FileName.drv' through LaTeX.} +\Msg{*} +\Msg{******************************************************} +% +\endbatchfile +% +% End of the installation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%</dtx> +% +% This section is the documentation driver +% +%<+driver>\documentclass[12pt,a4paper]{ltxdoc} +%<+driver> \EnableCrossrefs +%<+driver> \CodelineIndex +%<+driver> \RecordChanges +%<+driver> %\OnlyDescription % Uncomment not to see the implementation +%<+driver>\begin{document} +%<+driver> \DocInput{\FileName.dtx} +%<+driver> \PrintIndex +%<+driver> \PrintChanges +%<+driver>\end{document} +% +% End of the documentation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%<*package> +%\fi +% +% \changes{v0.1}{20 April 1997}{First release (basic environments)} +% \changes{v0.2}{10 May 1997}{Added the ``*-form'' of environments} +% \changes{v1.0}{24 May 1997}{Documentation added} +% \changes{v1.1}{18 October 1997}{``EQNarray'' and ``EqSystem'' environments} +% \changes{v1.2}{5 November 1997}{Options to behave like ``Standard'' LateX} +% \changes{v1.3}{8 November 1997}{Documentation updated} +% \changes{v2.0}{20 December 1997}{Separated from package ``mathcmd''} +% \changes{v2.1}{4 February 1998}{``MultiLine'' and ``EqSystem'' environments +% reimplemented; ``EQNarray'' environment and +% ``CONTINUE'' command made obsolete} +% \changes{v2.2}{6 February 1998}{``@StandartEquation'' deferred +% ``AtBeginDocument''; some ``def'' replaced +% by ``newcommand*''; documentation updated} +% \changes{v2.3}{5 March 1999}{Added copyright notice and changed addresses} +% \changes{v2.4}{9 April 2005}{Usage of the double-quote character (") avoided} +% \changes{v2.5}{10 February 2010}{Package renamed from ``mathenv'' to +% ``envmath'' to avoid name conflicts} +%\iffalse % MetaComment +% The previous change was requested by Karl Berry (karl@freefriends.org) +%\fi +% +% \MakeShortVerb{\|} +% +% \title{Package \texttt{\FileName}\thanks{This is version \fileversion, +% last revised \filedate; documentation date \docdate}} +% \author{F. Bosisio\\\normalsize E-mail: \texttt{fbosisio@bigfoot.com}} +% \date{\filedate} +% \maketitle +% +% \begin{abstract} +% Documentation for the package \texttt{\FileName}. +% \end{abstract} +% +% \section{Introduction} +% This package provides some useful math-commands and enviroments, +% which are simpler to use and prettier then their standard \LaTeX{} +% counterpart. +% +% In particular some commands are redefined\footnote{See the options +% in next section if you don't want these comand to be redefined}, so +% care should be taken, expecially when including this package in an +% already existent \LaTeX{} file. +% +% \noindent +% The redefined commands are:\\ +% |\(|, |\)|, |\[|, |\]|, |\{| and |\}| \\ +% The effect of ``|\(| \dots |\)|'' can still be achieved by the +% \LaTeX{} equivalent commands ``|\begin{math}| \dots |\end{math}|'' +% or ``|$| \dots |$|''. +% +% \noindent +% Similarly, the effect of ``|\[| \dots |\]|'' can be achieved by +% the \LaTeX{} equivalent commands +% ``|\begin{displaymath}| \ldots |\end{displaymath}|'' +% or ``|$$| \dots |$$|''. +% +% \noindent +% The ``|\{|'' and ``|\}|'' commands are the more error-prone, since +% one may try to use ``|\left\{|'', which now is incorrect, because +% the ``|\{|'' command already contains a ``|\left|'' declaration. +% In the rare occasions where a brace of normal size is needed, one +% can use the \LaTeX{} commands ``|\lbrace|'' and ``|\rbrace|'' +% +% \noindent +% Also the ``|equation|'' environment has been changed, but it is +% completly compatible with the original definition, so it should +% be safe, perhaps except when the first character of the equation +% is an open square bracket or it is placed in a moving argument: +% in fact, the new version of this command is fragile, and this is +% true also for most of the commands defined by this package. +% +% \section{Backward compatibility} +% The package has been renamed from ``|mathenv|'' to ``|envmath|'', +% in order to avoid conflicts with another package with the same name: +% if you were using the ``old'' package, you need to change your \LaTeX{} +% files in order to include the new ones.\\ +% Alternatively, you can also rename the package to give it the ``old'' +% name (you need to change also the ``|\def\FileName{...}|'' line inside +% the ``|sty|''-file), but you must take care not to have another package +% with the same name installed on your system. +% +% \section{The options} +% At now, five options are available with the \texttt{\FileName} +% package. +% +% \noindent +% The ``|RedefEquation|''/``|StdEquation|'' and +% ``|RedefBrackets|''/``|StdBrackets|'' options control +% whether the ``|equation|'' environment and the brace commands +% ``|\(|'', ``|\(|'', ``|\)|'', ``|\[|'', ``|\]|'', ``|\{|'' and ``|\}| +% should be redefined or retain their original \LaTeX{} meaning. +% More precisely, ``|RedefEquation|'' (default) redefines the +% ``equation'' environment to have an optional argument (used as a +% label), while ``|StdEquation|'' leaves it unchanged. In the first +% case, the ``equation'' environment will be equivalent to the +% ``Equation'' environment (capitalized!) described below, whereas in +% the second case they will be different. +% Similarly, the ``|RedefBrackets|'' option (default) makes the +% brackets command to be redefined, whilst ``|StdBrackets|'' leave +% them their original meaning. +% Also a ``|Standard|'' option exists, which amounts to specify both +% the ``|StdEquation|'' and ``|StdBrackets|'' options, thus making the +% package fully standard, which may be useful when sending your +% \LaTeX{} files to someone else. +% +% \section{Math-mode environments} +% This package provides three math-mode environments, each with a +% ``*-form'' which does not generates numbers. +% +% \subsection{The \texttt{Equation} environment} +% The ``|Equation|'' environment has an optional argument +% which is used as a label to reference it. +% \begin{verbatim} +% \begin{Equation}[label] +% ... +% \end{Equation} +% \end{verbatim} +% If the ``|RedefEquation|'' option is in effect (default), +% then the ``|equation|'' environment is redefined to have +% the same optional argument as ``|Equation|''. +% +% There is also a *-form, which does not generate a number +% (so this *-form is really a ``displaymath'' and not an +% equation, but it has been added for simmetry and for making +% it easier to add or remove the number to a formula). +% +% \noindent +% The *-form has an optional argument like the non-* form, +% which is disregarded by the environment and is added only +% for simmetry reasons. +% \begin{verbatim} +% \begin{equation*}[disregarded-label] +% ... +% \end{equation*} +% \end{verbatim} +% +% \subsection{The \texttt{MultiLine} equation environment} +% The ``|MultiLine|'' environment is intended for formulas +% that don't fit on a single line, and so must be broken +% across lines. +% +% \noindent +% As for the |Equation| environment above, it has an optional +% argument which is used as a label. +% +% \noindent +% All the lines but the first are automatically indented by +% the lenght ``|\MultiLineIndent|'', which is rougthly what +% one expects, but can be changed at any time by the user +% with ``|\setlenght{\MultiLineIndent}{...}|''. +% You can also control the alignment of the continuation rows +% by placing an optional |&| in the first row: is such a case +% all the others line will \emph{not} be indented +% by ``|\MultiLineIndent|'' but wil behave \emph{as if} there +% there were an ampersand in front of them (i.e. they will be +% left-aligned at the right of the \& in the first row). +% +% \noindent +% Each line but the last must end with a ``|\\|'' command +% (which can have an optional argument to add some vertical +% space between lines). +% When the line is broken in the middle (e.g. after a ``+'' +% sign) and not at the end (i.e. after a ``='' or similar), the +% *-form ``|\\*|'' may be used to indicate the line-break, the +% difference being in an extra space added at the beginning of +% the next line. +% The width of a thise space defaults to 1em and can be changed +% by the user with ``|\setlenght{\MultiLineStarIndent}{...}|''. +% +% \begin{verbatim} +% \begin{MultiLine}[label] +% ... [&]= ... = \\ +% = ... + \\* +% + ... = \\ +% = ... +% \end{MultiLine} +% \end{verbatim} +% +% Also this environment has a *-form which differs only in that +% it does not generate an equation number. +% \begin{verbatim} +% \begin{MultiLine*}[disregarded-label] +% ... [&]= ... = \\ +% = ... + \\* +% + ... = \\ +% = ... +% \end{MultiLine*} +% \end{verbatim} +% +% \subsection{The \texttt{System} environment} +% The ``|System|'' environment is used for grouping a set of +% equations together inside a left brace, with one only +% equation number. +% +% \noindent +% Again there is an optional argument to indicate a label and +% each equation is separated by a ``|\\|'' or ``|\\*|'' command, +% as for the ``|MultiLine|'' environment. +% +% \noindent +% The rows (except the ones ended with the *-form ``|\\*|'') +% may optionally contain one ``|&|'', which is usually used +% when some text should be added to the equation. +% \begin{verbatim} +% \begin{System}[label] +% ... = ... [& ...] \\ +% ... = ... + \\* +% + ... [& ...] \\ +% ... = ... [& ...] +% \end{System} +% \end{verbatim} +% +% A *-form which does not generate any number is also provided. +% \begin{verbatim} +% \begin{System*}[disregarded-label] +% ... = ... [& ...] \\ +% ... = ... + \\* +% + ... [& ...] \\ +% ... = ... [& ...] +% \end{System*} +% \end{verbatim} +% +% \subsection{The \texttt{EqSystem} environment} +% The ``|EqSystem|'' environment is used for grouping a set of +% equations together inside a left brace, each with its own +% equation number. +% +% \noindent +% Again there is an optional argument to indicate a label and +% each equation is separated by a ``|\\|'' or ``|\\*|'' command. +% +% \noindent +% The rows may optionally contain one ``|&|'', which is +% usually used when some text should be added to the equation. +% \begin{verbatim} +% \begin{EqSystem}[label] +% ... = ... [& ...] \\ % (1.1) +% ... = ... + \\* % (1.2) +% + ... [& ...] \\ % (1.3) +% ... = ... [& ...] % (1.4) +% \end{EqSystem} +% \end{verbatim} +% +% A *-form is also provided: it differs in that each equation +% is numbered with the same number but with a lowercase letter +% added, i.e. like (1.1a), (1.1b), etc. instead of (1.1), +% (1.2) and so on. +% \begin{verbatim} +% \begin{EqSystem*}[label] +% ... = ... [& ...] \\ % (1.5a) +% ... = ... + \\* % (1.5b) +% + ... [& ...] \\ % (1.5c) +% ... = ... [& ...] % (1.5d) +% \end{EqSystem*} +% \end{verbatim} +% In both cases, if the optional argument is present, each +% equation can be referenced by |\ref{<label>:a}|, +% |\ref{<label>:b}|, \dots, where |<label>|, stands for +% the string used as optional argument. +% In the case of the *-form, a reference of the kind +% |\ref{<label>}| will print the equation number without +% any letter, thus referring to the system as a whole, +% whereas such a reference is meaningless (and indeed does +% not exists) when dealing with the non *-form. +% +% +% \section{Math-mode commands} +% In addition to the previously mentioned environments, the +% \texttt{\FileName} package defines also some of math-mode +% commands which considerably simplify the use of adjustable-size +% parentheses. +% +% \noindent +% The ``|\(|'', ``|\[|'', ``|\{|'', ``|\)|'', ``|\]|'' +% and ``|\}|'' generates the corresponding parenthesis but +% with a ``|\left|'' or ``|\right|'' declaration +% (respectively) added, so they must come in matched pairs or +% coupled with a ``|\left.|'' or ``|\rigtht.|'' or another +% adjustable-size delimiter. +% +% \StopEventually{} +% \newpage +% \section{Implementation} +% +% \begin{macrocode} +%% +\NeedsTeXFormat{LaTeX2e}[1995/12/01] +\ProvidesPackage{\FileName}[\filedate\space v\fileversion\space\filedescr] +%% +\newif\if@Redefine@Equation@ +\DeclareOption{RedefEquation}{\@Redefine@Equation@true} +\DeclareOption{StdEquation}{\@Redefine@Equation@false} +%% +\newif\if@Redefine@Brackets@ +\DeclareOption{RedefBrackets}{\@Redefine@Brackets@true} +\DeclareOption{StdBrackets}{\@Redefine@Brackets@false} +%% +\DeclareOption{Standard}{\@Redefine@Equation@false\@Redefine@Brackets@false} +%% +\ExecuteOptions{RedefEquation,RedefBrackets} +% \end{macrocode} +% +% The ``|\ProcessOptions*|'' command was used here instead of +% ``|\ProcessOptions*|'' in order to process the options in the +% ``|\usepackage|'' order, rather than in the declaration order +% \begin{macrocode} +%% +\ProcessOptions* +% \end{macrocode} +% +% \begin{macro}{\StartMath@Err} +% The ``|\StartMath@Err|'' prints an error message if used in math-mode +% (saying that you can't use the command passed to it as an argument in +% math-mode); otherwise it just enters math-mode through a |$$|. +% It is used by the *-form of the math-environments to prevent +% their use in math-mode. +% \begin{macrocode} +%% +\newcommand*\StartMath@Err[1]{% +\ifmmode\PackageError{\FileName}{% +You can't use environment ``#1'' in math mode}{% +You probably used ``\string\end{#1}'' without a previous ``\string\begin{#1}''.}% +\else$$\fi% +} +% \end{macrocode} +% \end{macro} +% +% \begin{environment}{Equation} +% The definition of the original ``|equation|'' environment is first saved +% in the ``|\@StandardEquation|'' command. +% Then the ``|\@LabelledEquation|'' command is defined as an |equation| +% with a label. +% The |Equation| command simply calls ``|\@LabelledEquation|'' or +% ``|\@StandardEquation|'', depending on the presence or absence of the +% optional argument (indicated by the square bracket). +% \begin{macrocode} +%% +\AtBeginDocument{% +\let\@StandardEquation=\equation +} +\def\@LabelledEquation[#1]{\@StandardEquation\label{#1}} +\newenvironment{Equation}{% +\@ifnextchar[{\@LabelledEquation}{\@StandardEquation}% +}{% +\endequation% +} +% \end{macrocode} +% +% If the ``|RedefEquation|'' option is in effect, |equation| is defined +% to be the same as |Equation|. +% The actual definition of the |equation| environment is deferred at the +% ``|\begin{document}|'' in order to minimize the possibility of +% conflicts with other packages. +% \begin{macrocode} +\if@Redefine@Equation@ + \AtBeginDocument{\let\equation=\Equation} +\fi +% \end{macrocode} +% \end{environment} +% +% \begin{environment}{equation*} +% The command ``|\Equation@Star|'' simply enters math-mode (via the +% ``|\StartMath@Err|'' command). +% The definition of ``|equation*|'' is deferred at the +% ``|\begin{document}|'' so that this definition takes precedence over +% the analogue one from the ``|amsmath|'' package, if both are included. +% The command ``|\global\@ignoretrue|'' in the definition of +% ``|\end{equation*}|'' prevents spurious spaces at the beginning of next +% line. +% \begin{macrocode} +%% +\def\Equation@Star[#1]{\StartMath@Err{equation*}} +\AtBeginDocument{% +\@namedef{equation*}{\@ifnextchar[{\Equation@Star}{\Equation@Star[]}}% +\@namedef{endequation*}{$$\global\@ignoretrue}% +} +% \end{macrocode} +% \end{environment} +% +% \begin{macro}{\ARRAY@CR} +% The original definition of ``|\@arraycr|'' is saved in the command +% ``|\@ArrayCR|''. +% Then ``|\ARRAY@CR|'' is defined to do the same job of ``|\@arraycr|'' +% and add a ``|\displaystyle|'' declation at the beginning of next row. +% \begin{macrocode} +%% +\let\@ArrayCR=\@arraycr +\def\@ArrayCR@quadra[#1]{\@ArrayCR[#1]\displaystyle} +\def\@ArrayCR@star@quadra[#1]{% +\@ArrayCR[#1]\displaystyle\mbox{\hspace{\SystemStarIndent}}% +} +\def\@ArrayCR@star*{% +\@ifnextchar[{\@ArrayCR@star@quadra}{% +\@ArrayCR\displaystyle\mbox{\hspace{\SystemStarIndent}}}}% +\newcommand*{\ARRAY@CR}{\@ifnextchar*{\@ArrayCR@star}{% +\@ifnextchar[{\@ArrayCR@quadra}{\@ArrayCR\displaystyle}}% +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\MakeAmper@Active} +% Makes ``\&'' active (instead of a tab marker), giving +% it the meaning specified by the argument. +% \begin{macrocode} +%% +\newcommand*\MakeAmper@Active[1]{ +\global\def\@AMPERSAND{#1}% +\begingroup% + \catcode`\~\active \lccode`\~`\&% + \lowercase{% + \global\expandafter\let + \csname ac\string\&\endcsname~% + \gdef~{\@AMPERSAND}}% +\endgroup% +\global\catcode`\&\active% +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\MakeAmper@Tab} +% Restores ``\&'' to its original meaning (a tab marker). +% \begin{macrocode} +%% +\newcommand*\MakeAmper@Tab{\global\catcode`\&=4} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\OneShot@Amper} +% Makes ``\&'' active for one occurrence only: when encountered, the +% code in the first argument is executed, then ``\&'' is restored to +% its original meaning, a tab marker is inserted, and finally the +% code in the second argument is executed. +% \begin{macrocode} +%% +\newcommand*\OneShot@Amper[2]{% +\MakeAmper@Active{#1\expandafter\MakeAmper@Tab}% +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\MultiLineIndent} +% The length ``|\MultiLineIndent|'' represents the amount of spece by +% which each line but the first of a ``|MultiLine|'' environment is +% indented. It defaults to 1.7em, which is roughtly equal to the width +% of a character followed by an equal sign (e.g.: ``|A = |'' ). +% \begin{macrocode} +%% +\newlength\MultiLineIndent +\setlength{\MultiLineIndent}{1.7em} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\MultiLineStarIndent} +% The length ``|\MultiLineStarIndent|'' represents the amount of spece by +% which each line following a ``|\\*|'' in a ``|MultiLine|'' environment is +% indented. It defaults to 1em, which is roughtly equal to the width +% of a an equal sign (e.g.: ``|=|'' ). +% \begin{macrocode} +%% +\newlength\MultiLineStarIndent +\setlength\MultiLineStarIndent{1em} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\@MultiLineCR} +% The ``|\@MultiLineCR|'' command does the original job of ``|\@arrycr|'' +% (saved in ``|\ArrayCR|'') and then executes the ``|\ML@EveryRow|'' +% command. +% In the *-form it also adds a space equal to ``|\MultiLineStarIndent|''. +% The splitting in subcommands is required in order to pass the optional +% argument to ``|\@ArrayCR|'' and not to the last executed command. +% \begin{macrocode} +%% +\newcommand*\@MultiLineCR{% +\@ifnextchar*{\MLineCR@star}{% +\@ifnextchar[{\MLineCR@quadra}{\@ArrayCR\ML@EveryRow}}% +} +\def\MLineCR@star*{% +\@ifnextchar[{\MLineCR@star@quadra}{% +\@ArrayCR\ML@EveryRow\hspace{\MultiLineStarIndent}}% +} +\def\MLineCR@star@quadra[#1]{% +\@ArrayCR[#1]% +\ML@EveryRow% +\hspace{\MultiLineStarIndent}% +} +\def\MLineCR@quadra[#1]{\@ArrayCR[#1]\ML@EveryRow} +% \end{macrocode} +% +% The ``|MultiLine|'' environment starts by setting ``|\ML@EveryRow|'' +% to be equivalent to ``|\@MultiLINEcr|'', so that this command is +% executed at the end of the first row. +% It checks the |\catcode| of \& and redefines ``|\ML@EveryRow|'' +% accordingly: if \& is a tab marker (|\catcode|=4), an ampersand has +% occurred in the first row, so that each row must begin itself with +% an ampersand; otherwise (i.e. if the |\catcode| of \& is \emph{active}) +% no ampersand were found in the first row, so that each line must begin +% with a space equal to ``|\MultiLineStarIndent|''. +% \begin{macrocode} +\newcommand*\@MultiLINEcr{% +\ifnum\catcode`\&=4% +\global\def\ML@EveryRow{&\displaystyle\mbox{}}% +\else% +\MakeAmper@Tab% +\global\def\ML@EveryRow{\displaystyle\mbox{\hspace{\MultiLineIndent}}}% +\fi% +\ML@EveryRow% +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\CONTINUE} +% The command ``|\CONTINUE|'' is obsolete: you should use ``|\\*|'' instead. +% \begin{macrocode} +%% +\newcommand*{\CONTINUE}{% +\PackageError{\FileName}{% +Command ``\string\CONTINUE'' is obsolete: use ``\string\\*'' instead}{% +You'd better correct your input file as stated above,\MessageBreak% +but if you press ENTER everything will work for the moment.}% +\MLineCR@star*% +} +% \end{macrocode} +% \end{macro} +% +% \begin{environment}{MultiLine} +% The internal commad ``|\Start@MultiLine|'' is used by the ``|MultiLine|'' +% and ``|MultiLine*|'' environments. +% It makes \& add a ``|\displaystyle|'' declaration. +% It also changes the meaning of ``|\\|'' to ``|\@MultiLineCR|'', sets +% ``|\ML@EveryRow|'' to its default value ``|\@MultiLINEcr|'' and then +% starts an ``|array|'' environment (we already are in math-mode +% here) with one only column which is left aligned. +% Finally, if there is an optional argument it is used as a ``|\label|'' +% or ignored, depending on the current meaning of ``|\@LABEL|'' (which +% is the same as ``|\label|'' in the standard form and does nothing in +% the *-form). +% \begin{macrocode} +%% +\newcommand*\Start@MultiLine{% +\@ifnextchar[{\Start@MultiLine@quadra}{\Start@MultiLine@no}% +} +%% +\def\Start@MultiLine@quadra[#1]{\@LABEL{#1}\Start@MultiLine@no} +%% +\newcommand*\Start@MultiLine@no{% +\OneShot@Amper{}{\displaystyle}% +\let\@arraycr=\@MultiLineCR% +\let\ML@EveryRow=\@MultiLINEcr% +\begin{array}{l@{\hspace{0.3em}}l}% +\displaystyle% +} +% \end{macrocode} +% +% The internal command ``|\Stop@MultiLine|'' is used by the ``|MultiLine|'' +% and ``|MultiLine*|'' environments. +% It simply closes the ``|array|'' environment anr restores ``|\@arrycr|'' +% to its original meaning. +% \begin{macrocode} +%% +\newcommand*\Stop@MultiLine{% +\end{array}% +\let\@arraycr=\@ArrayCR% +\MakeAmper@Tab% % For the case no ``\\'' is used +} +% \end{macrocode} +% +% The ``|MultiLine|'' environment invokes ``|\Start@MultiLine|'' and +% ``|\Stop@MultiLine|'' inside an ``|equation|'' environment. +% \begin{macrocode} +%% +\newenvironment{MultiLine}{% +\let\@LABEL=\label% +\@StandardEquation% +\Start@MultiLine% +}{% +\Stop@MultiLine% +\endequation% +\global\@ignoretrue% +} +% \end{macrocode} +% \end{environment} +% +% \begin{environment}{MultiLine*} +% The ``|\MultiLine@Star|'' command issues an error message if used inside +% math mode, while when in text mode starts a ``|displaymath|'' environment +% (throught the ``|$$|'' command) in which a ``|\Start@MultiLineEq|'' command +% is issued (so it is the same as ``|\Label@MultiLineEq|'', but with +% ``|\equation|'' substituted by ``|$$|''). +% \begin{macrocode} +%% +\@namedef{MultiLine*}{\ifmmode\Not@MathErr{MultiLine*}\else$$\fi% +\def\@LABEL##1{}% +\Start@MultiLine% +} +\@namedef{endMultiLine*}{\Stop@MultiLine$$\global\@ignoretrue} +% \end{macrocode} +% \end{environment} +% +% \begin{environment}{System} +% The ``|\@System@Def|'' command is the kernel of the ``|System|'' and +% ``|System*|'' environments. +% It redefines ``|\@arraycr|'' so that ``|\\|'' not only ends the +% line but also adds a ``|\displaystyle|'' declaration. +% Then it draws an adjustable-size left brace, which will be as big as +% the system requires. +% Finally, a two-column array environment with a ``|\qquad|'' space +% between the columns is started and a ``|\displaystyle|'' declaration +% is added to the first row. +% \begin{macrocode} +%% +\newcommand*\@System@Def{% +\let\@arraycr=\ARRAY@CR% +\left\lbrace% +\begin{array}{l@{\qquad}l@{}}% +\displaystyle% +} +% \end{macrocode} +% The ``|\Label@System|'' commands opens an equation environment, issues +% a ``|\label|'' command for cross-referencing, and then calls the +% command ``|\@System@Def|'' defind above. +% \begin{macrocode} +\def\Label@System[#1]{\@StandardEquation\label{#1}\@System@Def} +% \end{macrocode} +% The ``|\begin{System}|'' command does the same things, skipping the +% ``|\label|'' command if there isn't the optional parameter. +% The ``|\end{System}|'' command closes the array, puts an invisible +% delimiter (``|\right.|'') which pairs with the left brace of the +% ``|\@System@Def|'' command, restores ``|\@arraycr|'' to its original +% meaning, ends the equation, and prevents spurious spaces by issuing +% the command ``|\global\@ignoretrue|''. +% \begin{macrocode} +\newenvironment{System}{% +\@ifnextchar[{\Label@System}{\@StandardEquation\@System@Def}% +}{% +\end{array}% +\right.% +\endequation% +\let\@arraycr=\@ArrayCR% +\global\@ignoretrue% +} +% \end{macrocode} +% \end{environment} +% +% \begin{environment}{System*} +% The ``|\System@Star|'' command generates en error message when used in +% math-mode, and calls ``|\@System@Def|'' inside a ``|displaymath|'' +% environment (the ``|$$|'') when used in text-mode. +% \begin{macrocode} +%% +\def\System@Star[#1]{\StartMath@Err{System*}\@System@Def} +% \end{macrocode} +% The ``|System*|'' environment is the same as ``|System|'', but with +% ``|\begin{equation}|$\ldots$|\end{equation}|'' substituted by +% ``|$$|\ldots|$$|''. +% \begin{macrocode} +\@namedef{System*}{\@ifnextchar[{\System@Star}{\System@Star[]}} +\@namedef{endSystem*}{\end{array}\right. $$\let\@arraycr=\@ArrayCR \global\@ignoretrue} +% \end{macrocode} +% \end{environment} +% +% \begin{environment}{EQNarray} +% The |EQNarray| environment is only for backward compatibility: +% use the |equationarry| environment from package |eqnarray| if +% you need more control than an |eqnarray| environment allows. +% \begin{macrocode} +%% +\newenvironment{EQNarray}{% +\PackageError{\FileName}{Environment ``EQNarray'' is obsolete}{% +Use the ``equationarry'' environment from the ``eqnarray'' package instead!}% +\eqnarray% +}{% +\endeqnarray% +} +% \end{macrocode} +% \end{environment} +% \begin{macro}{\SystemColSep,\SystemBraceSep,\SystemStarIndent} +% \begin{macrocode} +%% +\newlength\SystemColSep +\setlength\SystemColSep{2em} +%% +\newlength\SystemBraceSep +\setlength\SystemBraceSep{3pt} +%% +\newlength\SystemStarIndent +\setlength\SystemStarIndent{2em} +% \end{macrocode} +% \end{macro} +% +% \begin{environment}{EqSystem} +% \begin{macrocode} +%% +\newsavebox{\SysRow@Box} +\newlength\ColOne@Width +\newlength\ColTwo@Width +\newlength\SysCol@TmpWidth +%% +\newcommand*\Start@EqSysRow{% +\OneShot@Amper{% +$\end{lrbox}% +\settowidth\SysCol@TmpWidth{\usebox{\SysRow@Box}}% +\ifnum\SysCol@TmpWidth>\ColOne@Width\global\setlength\ColOne@Width\SysCol@TmpWidth\fi% +\usebox{\SysRow@Box}% +}{% +\begin{lrbox}{\SysRow@Box}$\displaystyle% +}% +\begin{lrbox}{\SysRow@Box}$\displaystyle% +} +%% +\newcommand*\Stop@EqSysRow{% +$\end{lrbox}% +\settowidth\SysCol@TmpWidth{\usebox{\SysRow@Box}}% +\ifnum\catcode`\&=4% +\ifnum\SysCol@TmpWidth>\ColTwo@Width\global\setlength\ColTwo@Width\SysCol@TmpWidth\fi% +\else% +\MakeAmper@Tab% +\ifnum\SysCol@TmpWidth>\ColOne@Width\global\setlength\ColOne@Width\SysCol@TmpWidth\fi% +\fi% +\usebox{\SysRow@Box}% +} +%% +\def\@EqSystCR@star@quadra[#1]{% +\Sys@@eqncr% +\noalign{\penalty\@eqpen\vskip #1\relax}% +\Start@EqSysRow% +\mbox{\hspace{\SystemStarIndent}}% +} +%% +\def\@EqSystCR@star*{% +\global\@eqnswfalse% +\@ifnextchar[{\@EqSystCR@star@quadra}{% +\Sys@@eqncr\Start@EqSysRow\mbox{\hspace{\SystemStarIndent}}}% +} +%% +\def\@EqSystCR@quadra[#1]{% +\Sys@@eqncr% +\noalign{\penalty\@eqpen\vskip #1\relax}% +\Start@EqSysRow% +} +%% +\newcommand*\EqSyst@CR{% +\Stop@EqSysRow% +\@ifnextchar*{\@EqSystCR@star}{% +\@ifnextchar[{\@EqSystCR@quadra}{\Sys@@eqncr\Start@EqSysRow}}% +} +%% +\let\Label@EqSystem=\relax +%% +\newcommand*\Sys@@eqncr{% +\let\reserved@a\relax% +\ifcase\@eqcnt\def\reserved@a{& &}% %% \@eqcnt = 0 +\or\def\reserved@a{&}% %% \@eqcnt = 1 +\else% %% \@eqcnt > 1 +\let\reserved@a\@empty% +\PackageError{\FileName}{Too many columns in EqSystem environment}{% +You can use at most one ``&'' in each row of an ``EqSystem'' environment.}% +\fi% +\reserved@a% +\if@eqnsw\Label@EqSystem\@eqnnum\stepcounter{equation}\fi% +\global\@eqnswtrue% +\global\@eqcnt\z@% +\cr% +} +%% +\newenvironment{EqSystem}[1][\relax]{% +\setcounter{EqSys@counter}{0}% +\def\Label@EqSystem{#1}% +\def\@tempa{\relax}% +\ifx\Label@EqSystem\@tempa\else% +\def\Label@EqSystem{\stepcounter{EqSys@counter}\label{#1:\alph{EqSys@counter}}}% +\fi% +\BEGIN@EqSystem% +}{% +\Stop@EqSysRow% +%%%-------------------- \endEQNarr@y ----------------------% +\Sys@@eqncr% +\egroup% +\global\advance\c@equation\m@ne% +$$% +%%%--------------------------------------------------------% +\vspace*{-\belowdisplayskip}% +\end{minipage}% +\advance\ColTwo@Width\ColOne@Width% +\advance\ColTwo@Width\SystemColSep% +\setlength\SysCol@TmpWidth\displaywidth% +\global\advance\SysCol@TmpWidth-\ColTwo@Width% +\global\divide\SysCol@TmpWidth\tw@% +\global\advance\SysCol@TmpWidth\ColTwo@Width% +\global\advance\SysCol@TmpWidth\SystemBraceSep% %% Space around left-brace +\global\advance\SysCol@TmpWidth 1em% %% ~= Left-brace size +\hspace{-\SysCol@TmpWidth}% +\right\lbrace% +\advance\SysCol@TmpWidth-1em% %% ~= Left-brace size +\hspace*{\SysCol@TmpWidth}% +$$\global\@ignoretrue% +} +%% +\newcommand*\BEGIN@EqSystem{% +\setlength\ColOne@Width\z@% +\setlength\ColTwo@Width\z@% +$$\left.% +\begin{minipage}{\displaywidth}% +\vspace*{-\abovedisplayskip}% +%%%-------------------------- \EQNarr@y -------------------% +\stepcounter{equation}% +\let\@currentlabel=\theequation% +\global\@eqnswtrue% +\global\@eqcnt\z@% +\tabskip\@centering% +\let\\=\EqSyst@CR% +$$\halign to \displaywidth\bgroup% +\tabskip\z@{##}\hfil% +&\global\@eqcnt\@ne% +\hspace{\SystemColSep}{##}\hfil% +\tabskip\@centering% +&\llap{##}\tabskip\z@\cr% +%%%--------------------------------------------------------% +\Start@EqSysRow% +} +% \end{macrocode} +% \end{environment} +% +% \begin{environment}{EqSystem*} +% \begin{macrocode} +%% +\newcounter{EqSys@counter} +%% +\newcommand*\EqSystem@Star[1][\relax]{% +\stepcounter{equation}% +\setcounter{EqSys@counter}{\value{equation}}% +\def\Label@EqSystem{#1}% +\def\@tempa{\relax}% +\ifx\Label@EqSystem\@tempa\else% +\let\@currentlabel=\theequation% +\label{#1}% +\def\Label@EqSystem{\label{#1:\alph{equation}}}% +\fi% +\let\INNER@theEQUATION=\theequation% +\xdef\inner@theEQUATION{\theequation}% +\def\theequation{\inner@theEQUATION\alph{equation}}% +\setcounter{equation}{0}% +\BEGIN@EqSystem% +} +%% +\@namedef{EqSystem*}{\EqSystem@Star} +%% +\@namedef{endEqSystem*}{% +\endEqSystem% +\setcounter{equation}{\value{EqSys@counter}}% +\global\let\theequation=\INNER@theEQUATION% +} +% \end{macrocode} +% \end{environment} +% +% The \LaTeX{} environments \texttt{math} and \texttt{displaymath} +% are redefined so that they will not be affected by the subsequent +% redefinition of the brackets commands. +% The redefinition of the brackets commands is deferred at the +% |\begin{document}|, so that other packages may use the original +% definitions and cannot override the new ones. +% It only takes place if the ``|RedefBrackets|'' option is in effect. +% \begin{macrocode} +\if@Redefine@Brackets@ + \AtBeginDocument{% + \let\math=\( + \let\endmath=\) + \let\displaymath=\[ + \let\enddisplaymath=\] + \renewcommand*{\(}{\left(}% + \renewcommand*{\)}{\right)}% + \renewcommand*{\[}{\left[}% + \renewcommand*{\]}{\right]}% + \renewcommand*{\{}{\left\lbrace}% + \renewcommand*{\}}{\right\rbrace}% + } +\fi +% \end{macrocode} +% +%\iffalse % MetaComment +%<*package> +%\fi +% +% \CheckSum{653} +% \Finale +% +\endinput + diff --git a/macros/latex/contrib/bosisio/envmath.html b/macros/latex/contrib/bosisio/envmath.html new file mode 100644 index 0000000000..73862b4425 --- /dev/null +++ b/macros/latex/contrib/bosisio/envmath.html @@ -0,0 +1,419 @@ +<html> +<!-- ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +| Copyright(C) 1997-2010 by F. Bosisio | +| | +| This program can be redistributed and/or modified under | +| the terms 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 LaTeX distributions | +| version 2005/12/01 or later. | +| | +| This work has the LPPL maintenance status `maintained'. | +| The Current Maintainer of this work is F. Bosisio. | +| | +| This work consists of files envmath.dtx and envmath.html | +| and of the derived files envmath.sty and envmath.pdf. | +| | +| E-mail: fbosisio@bigfoot.com | +| CTAN location: macros/latex/contrib/bosisio/ | ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +--> +<head> + <title>Package envmath</title> +</head> +<body> + +<h1 align="CENTER"> +Package <tt>envmath</tt><br /> +<small> +This is version 2.5, last revised 2010/02/10; documentation date 2005/04/09. +</small> +</h1> + +<p align="CENTER"> +<strong> +Author: <i>F. Bosisio</i><br /> +<small> +E-mail: <a href="mailto:fbosisio@bigfoot.com"> + <tt>fbosisio@bigfoot.com</tt> + </a><br /> +CTAN location: <a href="http://mirror.ctan.org/macros/latex/contrib/bosisio"> + <tt>macros/latex/contrib/bosisio</tt> + </a> +</small> +</strong> +</p> + +<p align="LEFT"></p> + +<!------------------------------------------------------------------------> +<p> + +<h3>Abstract</h3> +<div> +Documentation for the package <tt>envmath</tt>. +</div> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2>Table of contents</h2> + +<ul> + <li><a href="#SECTION01">Introduction</a></li> + <li><a href="#SECTION02">The options</a></li> + <li><a href="#SECTION03">Math-mode environments</a> + <ul> + <li><a href="#SECTION03a">The <tt>Equation</tt> environment</a></li> + <li><a href="#SECTION03b">The <tt>MultiLine</tt> equation environment</a></li> + <li><a href="#SECTION03c">The <tt>System</tt> environment</a></li> + <li><a href="#SECTION03d">The <tt>EqSystem</tt> environment</a></li> + </ul></li> + <li><a href="#SECTION04">Math-mode commands</a></li> +</ul> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2> +<a name="SECTION01">Introduction</a> +</h2> + +<p> +This package provides some useful math-commands and enviroments, which +are simpler to use and prettier then their standard LaTeX counterpart. +</p> + +<p> +In particular some commands are redefined +(see <a href="#SECTION02">next section</a> if you don't want them to be +redefined), so care should be taken, expecially when including this package +in an already existent LaTeX file. + +<p> +The <a href="#SECTION04">redefined commands</a> are:<br /> +<tt>\(</tt>, <tt>\)</tt>, +<tt>\[</tt>, <tt>\]</tt>, +<tt>\{</tt> and <tt>\}</tt>.<br /> +The effect of ``<tt>\(</tt> ...<tt>\)</tt>'' can still be achieved by +the LaTeX equivalent commands ``<tt>\begin{math} ... \end{math}</tt>'' +or ``<tt>$...$</tt>''. +</p> + +<p> +Similarly, the effect of ``<tt>\[...\]</tt>'' can be achieved by the +LaTeX equivalent commands +``<tt>\begin{displaymath}...\end{displaymath}</tt>'' or +``<tt>$$...$$</tt>''. +</p> + +<p> +The ``<tt>\{</tt>'' and ``<tt>\}</tt>'' commands are the more +error-prone, since one may try to use ``<tt>\left\{</tt>'', which now +is incorrect, because the ``<tt>\{</tt>'' command already contains a +``<tt>\left</tt>'' declaration. +In the rare occasions where a brace of normal size is needed, one can use +the LaTeX commands ``<tt>\lbrace</tt>'' and ``<tt>\rbrace</tt>''. +</p> + +<p> +Also the <a href="#SECTION03a">``<tt>equation</tt>'' environment</a> has been +changed, but it is completly compatible with the original definition, so it +should be safe, perhaps except when the first character of the equation is +an open square bracket or it is placed in a moving argument: +in fact, the new version of this command is fragile, and this is true also +for most of the commands defined by this package. +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2> +<a name="SECTION02">The options</a> +</h2> + +<p> +At now, five options are available with the <tt>envmath</tt> package. +</p> + +<p> +The ``<tt>RedefEquation</tt>''/``<tt>StdEquation</tt>'' and +``<tt>RedefBrackets</tt>''/``<tt>StdBrackets</tt>'' options control +whether the ``<tt>equation</tt>'' environment and the brace commands +``<tt>\(</tt>'', ``<tt>\)</tt>'', ``<tt>\[</tt>'', +``<tt>\]</tt>'', ``<tt>\{</tt>'' and ``<tt>\}</tt>'' should +be redefined or retain their original LaTeX meaning. +</p> + +<p> +More precisely, ``<tt>RedefEquation</tt>'' (default) redefines the +``equation'' environment to have an optional argument (used as a label), +while ``<tt>StdEquation</tt>'' leaves it unchanged. +In the first case, the ``equation'' environment will be equivalent to the +<a href="#SECTION03a">``Equation'' environment</a> (capitalized!) described +below, whereas in the second case they will be different. +</p> + +<p> +Similarly, the ``<tt>RedefBrackets</tt>'' option (default) makes the +<a href="#SECTION04"> bracket commands</a> to be redefined, whilst +``<tt>StdBrackets</tt>'' leave them their original meaning. +</p> + +<p> +Also a ``<tt>Standard</tt>'' option exists, which amounts to specify both +the ``<tt>StdEquation</tt>'' and ``<tt>StdBrackets</tt>'' options, thus making +the package fully standard, which may be useful when sending your +LaTeX files to someone else. +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2> +<a name="SECTION03">Math-mode environments</a> +</h2> + +<p> +This package provides some math-mode environments, each with a ``*-form'' +which does not generates numbers (or produce sub-numbering). +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h3> +<a name="SECTION03a">The <tt>Equation</tt> environment</a> +</h3> + +<p> +The ``<tt>Equation</tt>'' environment has an optional argument which is used +as a label to reference it. +<pre> + \begin{Equation}[<label>] + ... + \end{Equation} +</pre> +</p> + +<p> +If the ``<tt>RedefEquation</tt>'' option is in effect (default), then +the ``<tt>equation</tt>'' environment is redefined to have the same optional +argument as ``<tt>Equation</tt>''. +</p> + +<p> +There is also a *-form, which does not generate a number (so this *-form is +really a ``displaymath'' and not an equation, but it has been added for +simmetry and for making it easier to add or remove the number to a formula). +</p> + +<p> +The *-form has an optional argument like the non-* form, which is +disregarded by the environment and is added only for simmetry reasons. +<pre> + \begin{equation*}[<disregarded-label>] + ... + \end{equation*} +</pre> +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h3> +<a name="SECTION03b">The <tt>MultiLine</tt> equation environment</a> +</h3> + +<p> +The ``<tt>MultiLine</tt>'' environment is intended for formulas that don't +fit on a single line, and so must be broken across lines. +</p> + +<p> +As for the <a href="#SECTION03a"><tt>Equation</tt> environment</a> above, +it has an optional argument which is used as a label. +</p> + +<p> +All the lines but the first are automatically indented by the lenght +``<tt>\MultiLineIndent</tt>'', which is rougthly what one expects, but +can be changed at any time by the user with +``<tt>\setlenght\MultiLineIndent{...}</tt>''. +You can also control the alignment of the continuation rows by placing an +optional <tt>&</tt> in the first row: is such a case all the others line +will <em>not</em> be indented by ``<tt>\MultiLineIndent</tt>'' but wil behave +<em>as if</em> there were an ampersand in front of them (i.e. they will be +left-aligned at the right of the & in the first row). +</p> + +<p> +Each line but the last must end with a ``<tt>\\</tt>'' command +(which can have an optional argument to add some vertical space between +lines). +When the line is broken in the middle (e.g. after a ``+'' sign) and not at +the end (i.e. after a ``='' or similar), the *-form ``<tt>\\*</tt>'' +may be used to indicate the line-break, the difference being in an extra +space added at the beginning of the next line. +The width of a this space defaults to 1em and can be changed by the user +with ``<tt>\setlenght\MultiLineStarIndent{...}</tt>''. +</p> + +<p> +<pre> + \begin{MultiLine}[<label>] + ... [&]= ... = \\ + = ... + \\* + + ... = \\ + = ... + \end{MultiLine} +</pre> +</p> + +<p> +Also this environment has a *-form which differs only in that it does not +generate an equation number. +<pre> + \begin{MultiLine*}[<disregarded-label>] + ... [&]= ... = \\ + = ... + \\* + + ... = \\ + = ... + \end{MultiLine*} +</pre> +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h3> +<a name="SECTION03c">The <tt>System</tt> environment</a> +</h3> + +<p> +The ``<tt>System</tt>'' environment is used for grouping a set of equations +together inside a left brace, with one only equation number. +</p> + +<p> +Again there is an optional argument to indicate a label and each equation +is separated by a ``<tt>\\</tt>'' or ``<tt>\\*</tt>'' command, +as for the <a href="#SECTION03b">``<tt>MultiLine</tt>'' environment</a>. +</p> + +<p> +The rows (except the ones ended with the *-form ``<tt>\\*</tt>'') +may optionally contain one ``<tt>&</tt>'', which is usually used when +some text should be added to the equation. +<pre> + \begin{System}[<label>] + ... = ... [& ...] \\ + ... = ... + \\* + + ... [& ...] \\ + ... = ... [& ...] + \end{System} +</pre> +</p> + +<p> +A *-form which does not generate any number is also provided. +<pre> + \begin{System*}[<disregarded-label>] + ... = ... [& ...] \\ + ... = ... + \\* + + ... [& ...] \\ + ... = ... [& ...] + \end{System*} +</pre> +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h3> +<a name="SECTION03d">The <tt>EqSystem</tt> environment</a> +</h3> + +<p> +The ``<tt>EqSystem</tt>'' environment is used for grouping a set of equations +together inside a left brace, each with its own equation number. +</p> + +<p> +Again there is an optional argument to indicate a label and each equation is +separated by a ``<tt>\\</tt>'' or ``<tt>\\*</tt>'' command. +</p> + +<p> +The rows may optionally contain one ``<tt>&</tt>'', which is usually used +when some text should be added to the equation. +<pre> + \begin{EqSystem}[<label>] + ... = ... [& ...] \\ % (1.1) + ... = ... + \\* % + + ... [& ...] \\ % (1.2) + ... = ... [& ...] % (1.3) + \end{EqSystem} +</pre> +</p> + +<p> +A *-form is also provided: it differs in that each equation is numbered with +the same number but with a lowercase letter added, i.e. like (1.1a), (1.1b), +etc. instead of (1.1), (1.2) and so on. +<pre> + \begin{EqSystem*}[<label>] + ... = ... [& ...] \\ % (1.5a) + ... = ... + \\* % + + ... [& ...] \\ % (1.5b) + ... = ... [& ...] % (1.5c) + \end{EqSystem*} +</pre> +In both cases, if the optional argument is present, each equation can be +referenced by <tt>\ref{<label>:a}</tt>, +<tt>\ref{<label>:b}</tt>, ..., where <tt><label></tt>, +stands for the string used as optional argument. +In the case of the *-form, a reference of the kind +<tt>\ref{<label>}</tt> will print the equation number without +any letter, thus referring to the system as a whole, whereas such a +reference is meaningless (and indeed does not exists) when dealing with +the non *-form. +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2> +<a name="SECTION04">Math-mode commands</a> +</h2> + +<p> +In addition to the previously mentioned environments, the <tt>envmath</tt> +package defines also some of math-mode commands which considerably simplify +the use of adjustable-size parentheses. +</p> + +<p> +The ``<tt>\(</tt>'', ``<tt>\[</tt>'', ``<tt>\{</tt>'', +``<tt>\)</tt>'', ``<tt>\]</tt>'' and ``<tt>\}</tt>'' generates +the corresponding parenthesis but with a ``<tt>\left</tt>'' or +``<tt>\right</tt>'' declaration (respectively) added, so they must come +in matched pairs or coupled with a ``<tt>\left.</tt>'' or +``<tt>\rigtht.</tt>'' or another adjustable-size delimiter. +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<address> + <i>F. Bosisio</i><br /> + E-mail: <a href="mailto:fbosisio@bigfoot.com"><tt>fbosisio@bigfoot.com</tt></a> +</address> + +<!------------------------------------------------------------------------> + +</body> +</html> diff --git a/macros/latex/contrib/bosisio/envmath.pdf b/macros/latex/contrib/bosisio/envmath.pdf Binary files differnew file mode 100644 index 0000000000..e8d3525d5d --- /dev/null +++ b/macros/latex/contrib/bosisio/envmath.pdf diff --git a/macros/latex/contrib/bosisio/evenpage.dtx b/macros/latex/contrib/bosisio/evenpage.dtx new file mode 100644 index 0000000000..9beb363f3b --- /dev/null +++ b/macros/latex/contrib/bosisio/evenpage.dtx @@ -0,0 +1,143 @@ +%\iffalse % MetaComment +%% +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% | Copyright(C) 1997-2010 by F. Bosisio | +%% | | +%% | This program can be redistributed and/or modified under | +%% | the terms 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 LaTeX distributions | +%% | version 2005/12/01 or later. | +%% | | +%% | This work has the LPPL maintenance status `maintained'. | +%% | The Current Maintainer of this work is F. Bosisio. | +%% | | +%% | This work consists of files evenpage.dtx and evenpage.html | +%% | and of the derived files evenpage.sty and evenpage.pdf. | +%% | | +%% | E-mail: fbosisio@bigfoot.com | +%% | CTAN location: macros/latex/contrib/bosisio/ | +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% +%% If you make any improvment, find any bug or have +%% any suggestion, please let me know about it. +%% +%<*package,driver> +%\fi +% +\def\FileName{evenpage} +%\iffalse % MetaComment +%</package,driver> +%<*package> +%\fi +\def\fileversion{1.0} +\def\filedate{1998/01/21} +\def\docdate{2005/04/09} +\def\filedescr{Ensures the number of pages to be even (FB)} +% +%\iffalse % MetaComment +%</package> +%<*dtx> +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +% This section is the installation driver +% +\def\batchfile{\FileName.dtx} +% +\input docstrip +% +\keepsilent +% \askforoverwritefalse +% +\generateFile{\FileName.sty}{f}{\from{\FileName.dtx}{package}} +% +\generateFile{\FileName.drv}{f}{\from{\FileName.dtx}{driver}} +% +\Msg{******************************************************} +\Msg{*} +\Msg{* To produce the documentation run the} +\Msg{* file `\FileName.drv' through LaTeX.} +\Msg{*} +\Msg{******************************************************} +% +%\endbatchfile +% +% End of the installation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%</dtx> +% +% This section is the documentation driver +% +%<+driver>\documentclass[12pt,a4paper]{ltxdoc} +%<+driver> \EnableCrossrefs +%<+driver> \CodelineIndex +%<+driver> \RecordChanges +%<+driver> %\OnlyDescription % Uncomment not to see the implementation +%<+driver>\begin{document} +%<+driver> \DocInput{\FileName.dtx} +%<+driver> \PrintIndex +%<+driver> \PrintChanges +%<+driver>\end{document} +% +% End of the documentation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%<*package> +%\fi +% +% \changes{v0.1}{21 January 1998}{First release} +% \changes{v0.1}{9 April 2005}{Added copyright notice and changed addresses} +% +% \title{Package \texttt{\FileName}\thanks{This is version \fileversion, +% last revised \filedate; documentation date \docdate}} +% \author{F. Bosisio\\\normalsize E-mail: \texttt{fbosisio@bigfoot.com}} +% \date{\filedate} +% \maketitle +% +% \begin{abstract} +% Documentation for the package \texttt{\FileName}. +% \end{abstract} +% +% \section{Introduction} +% This package ensures that the number of pages generated by \LaTeX{} +% is an even number: if it is odd, an empty page is added at the +% end, with nothing on it (neither page number, headers or footers). +% +% \section{Commands} +% No command is provided by this package: just include it in order +% to obtain the scope. +% +% \StopEventually{} +% +% \newpage +% \section{Implementation} +% +% \begin{macrocode} +%% +\NeedsTeXFormat{LaTeX2e}[1995/12/01] +\ProvidesPackage{\FileName}[\filedate\space v\fileversion\space\filedescr] +% \end{macrocode} +% +% The code simply checks if the current page number is odd, in +% which case a new page is generated with |\clearpage\mbox{}| +% (the |\mbox{}| is needed, otherwise the page will be empty +% and \TeX{} will remove it). +% The use of |\thispagestyle{empty}| ensures that nothing +% (headings, page numbers, footers, etc.) will appear on that page. +% All this code must be esecuted at the end of the document +% (when the last page is being proceddes) and this is provided +% by the |\AtEndDocument| command. +% \begin{macrocode} +%% +\AtEndDocument{\ifodd\value{page}\clearpage\mbox{}\thispagestyle{empty}\fi} +%% +% \end{macrocode} +% +% \CheckSum{15} +% \Finale +% +%\iffalse % MetaComment +%<*package> +%\fi +% +\endinput diff --git a/macros/latex/contrib/bosisio/evenpage.html b/macros/latex/contrib/bosisio/evenpage.html new file mode 100644 index 0000000000..d328f937ab --- /dev/null +++ b/macros/latex/contrib/bosisio/evenpage.html @@ -0,0 +1,71 @@ +<html> +<!-- ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +| Copyright(C) 1997-2010 by F. Bosisio | +| | +| This program can be redistributed and/or modified under | +| the terms 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 LaTeX distributions | +| version 2005/12/01 or later. | +| | +| This work has the LPPL maintenance status `maintained'. | +| The Current Maintainer of this work is F. Bosisio. | +| | +| This work consists of files evenpage.dtx and evenpage.html | +| and of the derived files evenpage.sty and evenpage.pdf. | +| | +| E-mail: fbosisio@bigfoot.com | +| CTAN location: macros/latex/contrib/bosisio/ | ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +--> +<head> + <title>Package evenpage</title> +</head> +<body> + +<h1 align="center"> + Package <tt>evenpage</tt><br /> + <small> + This is version 1.0, last revised 1998/01/21; documentation date 2005/04/09. + </small> +</h1> + +<p align="center"> + <strong> + Author: <i>F. Bosisio</i><br /> + <small> + E-mail: <a href="mailto:fbosisio@bigfoot.com"> + <tt>fbosisio@bigfoot.com</tt> + </a><br /> + CTAN location: <a href="http://mirror.ctan.org/macros/latex/contrib/bosisio"> + <tt>macros/latex/contrib/bosisio</tt> + </a> + </small> + </strong> +</p> + +<p> + This package ensures that the number of pages generated by LaTeX is an + even number: if it is odd, an empty page is added at the end, with + nothing on it (neither page number, headers or footers). +</p> + +<p> + No command is provided by this package: just include it in order to reach + the scope. +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<address> + <i>F. Bosisio</i><br /> + E-mail: <a href="mailto:fbosisio@bigfoot.com"><tt>fbosisio@bigfoot.com</tt></a> +</address> + +<!------------------------------------------------------------------------> +</body> +</html> diff --git a/macros/latex/contrib/bosisio/evenpage.pdf b/macros/latex/contrib/bosisio/evenpage.pdf Binary files differnew file mode 100644 index 0000000000..04402eea01 --- /dev/null +++ b/macros/latex/contrib/bosisio/evenpage.pdf diff --git a/macros/latex/contrib/bosisio/graphfig.dtx b/macros/latex/contrib/bosisio/graphfig.dtx new file mode 100644 index 0000000000..b9d7334cf0 --- /dev/null +++ b/macros/latex/contrib/bosisio/graphfig.dtx @@ -0,0 +1,485 @@ +%\iffalse % MetaComment +%% +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% | Copyright(C) 1997-2010 by F. Bosisio | +%% | | +%% | This program can be redistributed and/or modified under | +%% | the terms 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 LaTeX distributions | +%% | version 2005/12/01 or later. | +%% | | +%% | This work has the LPPL maintenance status `maintained'. | +%% | The Current Maintainer of this work is F. Bosisio. | +%% | | +%% | This work consists of files graphfig.dtx and graphfig.html | +%% | and of the derived files graphfig.sty and graphfig.pdf. | +%% | | +%% | E-mail: fbosisio@bigfoot.com | +%% | CTAN location: macros/latex/contrib/bosisio/ | +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% +%% If you make any improvment, find any bug or have +%% any suggestion, please let me know about it. +%% +%<*package,driver> +%\fi +% +\def\FileName{graphfig} +%\iffalse % MetaComment +%</package,driver> +%<*package> +%\fi +\def\fileversion{2.2} +\def\filedate{1997/12/15} +\def\docdate{2005/04/09} +\def\filedescr{Commands to include graphics files (FB)} +% +%\iffalse % MetaComment +%</package> +%<*dtx> +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +% This section is the installation driver +% +\def\batchfile{\FileName.dtx} +% +\input docstrip +% +\keepsilent +% \askforoverwritefalse +% +\generateFile{\FileName.sty}{f}{\from{\FileName.dtx}{package}} +% +\generateFile{\FileName.drv}{f}{\from{\FileName.dtx}{driver}} +% +\Msg{******************************************************} +\Msg{*} +\Msg{* To produce the documentation run the} +\Msg{* file `\FileName.drv' through LaTeX.} +\Msg{*} +\Msg{******************************************************} +% +\endbatchfile +% +% End of the installation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%</dtx> +% +% This section is the documentation driver +% +%<+driver>\documentclass[12pt,a4paper]{article} +%<+driver>\usepackage{doc} +%<+driver> \EnableCrossrefs +%<+driver> \CodelineIndex +%<+driver> \RecordChanges +%<+driver> %\OnlyDescription % Uncomment not to see the implementation +%<+driver>\begin{document} +%<+driver> \DocInput{\FileName.dtx} +%<+driver> \PrintIndex +%<+driver> \PrintChanges +%<+driver>\end{document} +% +% End of the documentation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%<*package> +%\fi +% +% \changes{v0.1}{21 April 1997}{First release} +% \changes{v0.2}{5 July 1997}{Added the ``\texttt{clip}'' option to ``\texttt{psfig}''} +% \changes{v0.3}{29 August 1997}{Modified the ``\texttt{@PS@Figure}'' command} +% \changes{v1.0}{8 September 1997}{Documentation added} +% \changes{v1.1}{19 November 1997}{Improved the ``SubFigure'' command} +% \changes{v1.2}{11 December 1997}{Fixed a bug in ``SubFigure'' references} +% \changes{v1.3}{12 December 1997}{Standard ``graphics'' package instead of ``psfig''} +%\iffalse % MetaComment +% The previous change has been suggested by Sebastian Rahtz (spqr@ftp.tex.ac.uk) +%\fi +% \changes{v2.0}{15 December 1997}{``graphfile'' instead of ``PSFigure/SubFigure''} +% \changes{v2.1}{5 March 1999}{Added copyright notice and changed addresses} +% \changes{v2.2}{9 April 2005}{Usage of the double-quote character (") avoided} +% +% \MakeShortVerb{\|} +% +% \title{Package \texttt{\FileName}\thanks{This is version \fileversion, +% last revised \filedate; documentation date \docdate}} +% \author{F. Bosisio\\\normalsize E-mail: \texttt{fbosisio@bigfoot.com}} +% \date{\filedate} +% \maketitle +% +% \begin{abstract} +% Documentation for the package \texttt{\FileName}. +% \end{abstract} +% +% \section{Introduction} +% This package provides some commands to make the use of graphic +% files in \LaTeX{} simpler. +% +% \noindent +% It declares the ``|Figure|'' environment (capitalized!) and +% the two commands ``|\graphfile|'' and ``|\graphfile*|''. +% Combining this commands, it it possible to include graphic +% files in a \LaTeX{} document very simply. +% +% \section{Required packages} +% This package uses the ``|\includegraphics*|'' command defined in the +% standard |graphics| package. +% Moreover, it uses the package |subfigure| when the |subfigure| +% option is specified, and the |float| package if the |AllowH| +% option is used. +% +% \section{The options} +% At now, two options are available: ``|subfigure|'' and ``|AllowH|''. +% +% \noindent +% The ``|subfigure|'' option allow the use of sub-figures +% inside a |Figure| environment, in order to place multiple +% pictures in a single \LaTeX{} figure (cfr. the |subfigure| +% standard package). +% +% \noindent +% The ``|AllowH|'' option allow the use of the ``|H|'' float specifier +% for the |Figure| environment, in order to place the figure exaclty +% where the command is placed (cfr. the |float| standard package). +% +% \section{The \texttt{Figure} environment and its relatives} +% The ``|Figure|'' environment (capitalized!) is somewhat different +% from the standard \LaTeX{} ``|figure|'' environment: besides an +% optional argument used to specify the placement parameters (which +% now defaults to ``|[htbp]|''), it has a mandatory argument specifying +% the ``caption'' and another optional argument, used as a ``label'' for +% cross-referencies: +% +% \begin{verbatim} +% \begin{Figure}[<htbpH>]{<caption>}[<label>] +% ... +% \end{Figure} +% \end{verbatim} +% +% \noindent +% The use of the ``|H|'' specifier (i.e. ``I want my float here!'') is +% possible only if the ``|AllowH|'' option has been specified. +% +% \subsection{The \texttt{graphfile} command} +% Inside the ``|Figure|'' environment, are available the commands: +% +% \begin{verbatim} +% \graphfile[<width>]{<file>}[<sub-caption>] +% \graphfile*[<heigth>]{<file>}[<sub-caption>] +% \end{verbatim} +% +% \noindent +% which are a simplified version of the ``|\includegraphics*|'' +% command (which is automatically included by this package; see the +% |graphics| package for reference), since you don't have to worry +% about scaling: the mandatory argument is the name of the graphic file to +% include, whereas the first optional argument specifies the desired +% width (in the non *-form) or heigth (in the *-form) of the figure as +% a fraction of ``|\linewidth|'' (e.g. ``|50|'' means ``|.50\linewidth|'', +% i.e. half a line! ), so no unit of measure (as ``|cm|'' or ``|pt|'') +% is required. +% Moreover, since the ``*-form'' of ``|\includegraphics|'' is used, the +% regions outside the bounding-box are not drawn. +% Another advantage of the combined use of the ``|Figure|'' environment +% and the ``|\graphfile|'' commands is that the picture is automatically +% centered horizontally, so no ``|\centering|'' or similar declartion +% is required. +% +% \begin{verbatim} +% \begin{Figure}[<htbpH>]{<caption>}[<label>] +% \graphfile[<width>]{<file>} +% \end{Figure} +% \end{verbatim} +% +% \subsection{Sub-figures} +% +% If you want to include more than one file in a single figure, +% you need to specify the ``|subfigure|'' option, which includes the +% |subfigure| package and provides the authomatic placement of a +% sub-caption below each picture. +% +% \begin{verbatim} +% \graphfile[<width_1>]{<file_1>}[<sub-caption_1>] +% ... +% \graphfile[<width_N>]{<file_N>}[<sub-caption_N>] +% \end{verbatim} +% +% \noindent +% which is a combined version of ``|\subfigure|'' and ``|\includegraphics*|'' +% (see the |subfigure| and |graphics| packages for reference): +% the last optional argument specify a ``caption'' for the sub-figure under +% consideration, while the first two arguments work exactly like as +% described above in the case of one only picture (indeed, you can +% use the last optional argument even if the |subfigure| option was +% not specified, in which case it is simply ignored). +% Each individual caption is printed preceded by a bracketed letter, +% which is the sub-figure counter and is printed even if no caption is +% specified. +% Using only a series of ``|\graphfile[|$\dots$|]{|$\dots$|}[|$\dots$|]|'' +% commands inside a ``|Figure|'' environment provides an equal spacing +% beetween the pictures and around them, without the need for any +% extra command. +% Finally, if a ``|<label>|'' was specified as the last optional argument +% to the ``|Figure|'' environment, you can reference to each individual +% sub-figure by the labels ``|<label>:a|'', ``|<label>:b|'', and so on, +% without the need for declaring them. +% +% \begin{verbatim} +% \begin{Figure}[<htbpH>]{<caption>}[<label>] +% \graphfile[<width_1>]{<file_1>}[<sub-caption_1>] +% \graphfile[<width_2>]{<file_2>}[<sub-caption_2>] +% : +% : +% \end{Figure} +% \end{verbatim} +% +% \subsection{The \texttt{FigureDefaultPlacement} command} +% +% The command ``|FigureDefaultPlacement{|$\dots$|}|'' can be used to +% specify the default value for the placement argument of the ``|Figure|'' +% environment. +% This is useful to change the default placement from the standard +% value ``htbp''. +% +% \StopEventually{} +% \newpage +% \section{Implementation} +% We start defining the options and including the required packages. +% \begin{macrocode} +%% +\NeedsTeXFormat{LaTeX2e}[1995/12/01] +\ProvidesPackage{\FileName}[\filedate\space v\fileversion\space\filedescr] +\RequirePackage{graphics} +%% +\newif\if@AllowSubFigure\@AllowSubFigurefalse +\newif\if@AllowHfloat\@AllowHfloatfalse +%% +\DeclareOption{subfigure}{\@AllowSubFiguretrue} +\DeclareOption{AllowH}{\@AllowHfloattrue} +%% +\ProcessOptions +%% +\if@AllowSubFigure + \RequirePackage{subfigure}[1995/03/06 v2.0] +% \end{macrocode} +% +% These redefinitions are needed in order to obtain the right form +% of the references (i.e. like ``Fig. 1a'' and not ``Fig. 1(a)'') +% \begin{macrocode} + \def\thesubfigure{\alph{subfigure}} +% \end{macrocode} +% +% We use ``|\renewcommand|'' instead of ``|\def|'' in order to realize +% possible changes in the |subfigure| package which may eliminate the +% inner command ``|\@thesubfigure|''. +% \begin{macrocode} + \renewcommand*\@thesubfigure{{\subcaplabelfont(\thesubfigure)}\space} + \let\SubGR@PH=\subfigure +\else +% \end{macrocode} +% +% If the ``subfigure'' option is not present, we let the internal +% command ``|\SubGR@PH|'' to simply execute its mandatory argument +% \begin{macrocode} + \newcommand*\SubGR@PH[2][]{#2} +\fi +\if@AllowHfloat + \RequirePackage{float}[1995/03/29 v1.2c] + \restylefloat{figure} +\fi +%% +\newif\if@FirstPicture\@FirstPicturetrue +\let\SubFig@Label=\relax +% \end{macrocode} +% +% \begin{macro}{\@Graph@Figure} +% This is the core command which includes and scales the graphic file +% using the commands provided by the |graphic| package. +% \begin{macrocode} +%% +\newcommand*\@Graph@Figure[3]{\resizebox{#1}{#2}{\includegraphics*{#3}}} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\graphfile} +% The command ``|\graphfile''| and its *-version simply calls one +% of the forthcoming commands. +% \begin{macrocode} +\newcommand*\graphfile{\@ifnextchar*{\graphfile@star}{% +\@ifnextchar[{\GraphFile@width}{\GraphFile@noSize}}% +} +\def\graphfile@star*{\@ifnextchar[{\GraphFile@heigth}{\GraphFile@noSize}} +% \end{macrocode} +% These commands, in turns, calls ``|\@GraphFile@Draw|'' with suitable +% arguments (i.e. the lengths are turned into fractions of ``|\linewidth|'' +% and an exclamation mark ``|!|'' is used where the scaling factor has +% to be the same as the other direction; furthermore the actual size +% of the graphic image is used [throught the ``|\width|'' command] if +% no scaling parameter is given). +% \begin{macrocode} +%% +\def\GraphFile@width[#1]{% +\@ifnextchar[{\@GraphFile@width@heigth{#1}}{\@GraphFile@widthNOheigth{#1}}% +} +\def\@GraphFile@width@heigth#1[#2]#3{% +\@ifnextchar[{\@GraphFile@Draw{.#1\linewidth}{.#2\linewidth}{#3}}{% +\@GraphFile@Draw{.#1\linewidth}{.#2\linewidth}{#3}[]}% +} +\def\@GraphFile@widthNOheigth#1#2{% +\@ifnextchar[{\@GraphFile@Draw{.#1\linewidth}{!}{#2}}{% +\@GraphFile@Draw{.#1\linewidth}{!}{#2}[]}% +} +\def\GraphFile@heigth[#1]#2{% +\@ifnextchar[{\@GraphFile@Draw{!}{.#1\linewidth}{#2}}{% +\@GraphFile@Draw{!}{.#1\linewidth}{#2}[]}% +} +\newcommand*\GraphFile@noSize[1]{% +\@ifnextchar[{\@GraphFile@Draw{\expandafter\width}{!}{#1}}{% +\@GraphFile@Draw{\expandafter\width}{!}{#1}[]}% +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\@GraphFile@Draw} +% This command has three mandatory arguments and an optional one, +% which represent, respectively, the width, heigth, file-name and +% sub-caption of the current picture. +% \begin{macrocode} +%% +\def\@GraphFile@Draw#1#2#3[#4]{% +\if@FirstPicture% +% \end{macrocode} +% If it is the first call to this command in the current |Figure| +% environment, we simply store it in ``|\TMP@Graph|''. +% We also set ``|@FirstPicture|'' to false for the next call. +% \begin{macrocode} + \@FirstPicturefalse% + \def\TMP@Graph{\SubGR@PH[#4\SubFig@Label]{\@Graph@Figure{#1}{#2}{#3}}}% +\else% + \ifx\TMP@Graph\undefined% +% \end{macrocode} +% If ``|\TMP@Graph|'' is not defined, this is the third call (or more). +% So we invoke the ``|\SubGR@PH|'' command (which may be ``|\subfigure|'' +% or simply its second argument depending on the options) with a +% ``|\@Graph@Figure|'' command inside and followed by an ``|\hfill|'' +% command for centering purposes. +% \begin{macrocode} + \SubGR@PH[#4\SubFig@Label]{\@Graph@Figure{#1}{#2}{#3}}\hspace*{\fill}% + \else% +% \end{macrocode} +% If we arrive at this point it is the second call to ``|\graphfile|'' +% inside the current |Figure| environment: before plotting the +% current figure (as above) we must call ``|\TMP@Graph|'' to plot +% the first one (which was only saved). +% We also undefine ``|\TMP@Graph|'' for the next time. +% \begin{macrocode} + \hspace*{-4pt}\TMP@Graph\hspace*{\fill}% + \let\TMP@Graph\undefined% + \SubGR@PH[#4\SubFig@Label]{\@Graph@Figure{#1}{#2}{#3}}\hspace*{\fill}% + \fi% +\fi% +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\FigureDefaultPlacement} +% The ``|\FigureDefaultPlacement|'' macro is defined to set the value of +% the ``|\Default@FigurePlacement|'' to its argument. +% Also ``|\Default@FigurePlacement|'' is initialized to ``|htbp|''. +% \begin{macrocode} +%% +\newcommand*\FigureDefaultPlacement[1]{\def\Default@FigurePlacement{#1}} +\def\Default@FigurePlacement{htbp} +% \end{macrocode} +% \end{macro} +% +% \begin{environment}{Figure} +% \begin{macrocode} +%% +\newenvironment{Figure}[2][\Default@FigurePlacement]{% +% \end{macrocode} +% The code for ``|\begin{Figure}|'' starts by setting ``|@FirstPicture|'' +% to true. +% \begin{macrocode} +\@FirstPicturetrue% +% \end{macrocode} +% Then we start a standard ``|figure|'' environment followed by an +% ``|\hfill|'' command (for centering purposes). +% \begin{macrocode} +\figure[#1]% +\hspace*{\fill}% +% \end{macrocode} +% We change the definition of ``|\\|'' so that an ``|\hfill|'' command +% is added at the beginning of next line. +% \begin{macrocode} +\let\@Figure@CR=\\% +\def\\{\par\hspace*{\fill}}% +% \end{macrocode} +% If there is the last optional argument, ``|\@Figure@quadra|'' is +% invoked, otherwise ``|\MK@Figure@Caption|'' is directly defined +% to print the specified caption. +% \begin{macrocode} +\@ifnextchar[{\@Figure@quadra{#2}}{\def\MK@Figure@Caption{\caption{#2}}}% +}{% +% \end{macrocode} +% The code for ``|\end{Figure}|'' starts by checking that ``|\TMP@Graph|'' +% is undefined, otherwise this means that there was one only picture: +% in such a case we have to print it out before continuing. +% \begin{macrocode} +\ifx\TMP@Graph\undefined\else% + \if@AllowSubFigure% + \renewcommand*\SubGR@PH[2][]{##2}% + \TMP@Graph\hspace*{\fill}% + \let\SubGR@PH=\subfigure% + \else% + \TMP@Graph\hspace*{\fill}% + \fi% + \global\let\TMP@Graph\undefined% +\fi% +% \end{macrocode} +% The ``|\MK@Figure@Caption|'' prints the previously saved caption. +% \begin{macrocode} +\MK@Figure@Caption% +% \end{macrocode} +% All local commands are undefined in order to save \TeX{} memory. +% \begin{macrocode} +\let\Mk@Figure@Caption\undefined% +\let\SubFig@Label=\relax% +\let\\=\@Figure@CR% +\let\@Figure@CR\undefined% +% \end{macrocode} +% The standard ``|figure|'' environment is closed. +% \begin{macrocode} +\endfigure% +% \end{macrocode} +% The command ``|\thesubfigure|'' is redefined so that it correctly +% prints the figure number, too. +% \begin{macrocode} +\def\thesubfigure{\thefigure\alph{subfigure}}% +} +% \end{macrocode} +% \end{environment} +% +% \begin{macro}{\@Figure@quadra} +% The ``|\MK@Figure@Caption|'' is defined to print the specified +% caption with an added label. +% Also ``|\SubFig@Label|'' generates a label in the form ``|<label>:a|''. +% \begin{macrocode} +%% +\def\@Figure@quadra#1[#2]{% +\def\MK@Figure@Caption{\caption{#1}\label{#2}}% +\def\SubFig@Label{\expandafter\label{#2:\expandafter\alph{subfigure}}}% +} +% \end{macrocode} +% \end{macro} +% +%\iffalse % MetaComment +%<*package> +%\fi +% +% \CheckSum{214} +% \Finale +% +\endinput + diff --git a/macros/latex/contrib/bosisio/graphfig.html b/macros/latex/contrib/bosisio/graphfig.html new file mode 100644 index 0000000000..23f985da8d --- /dev/null +++ b/macros/latex/contrib/bosisio/graphfig.html @@ -0,0 +1,273 @@ +<html> +<!-- ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +| Copyright(C) 1997-2010 by F. Bosisio | +| | +| This program can be redistributed and/or modified under | +| the terms 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 LaTeX distributions | +| version 2005/12/01 or later. | +| | +| This work has the LPPL maintenance status `maintained'. | +| The Current Maintainer of this work is F. Bosisio. | +| | +| This work consists of files graphfig.dtx and graphfig.html | +| and of the derived files graphfig.sty and graphfig.pdf. | +| | +| E-mail: fbosisio@bigfoot.com | +| CTAN location: macros/latex/contrib/bosisio/ | ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +--> +<head> + <title>Package graphfig</title> +</head> +<body> + +<h1 align="CENTER"> +Package <tt>graphfig</tt><br /> +<small> +This is version 2.2, last revised 1997/12/15; documentation date 2005/04/09. +</small> +</h1> + +<p align="CENTER"> +<strong> +Author: <i>F. Bosisio</i><br /> +<small> +E-mail: <a href="mailto:fbosisio@bigfoot.com"> + <tt>fbosisio@bigfoot.com</tt> + </a><br /> +CTAN location: <a href="http://mirror.ctan.org/macros/latex/contrib/bosisio"> + <tt>macros/latex/contrib/bosisio</tt> + </a> +</small> +</strong> +</p> + +<p align="LEFT"></p> + +<!------------------------------------------------------------------------> +<p> + +<h3>Abstract</h3> +<div> +Documentation for the package <tt>graphfig</tt>. +</div> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2>Table of contents</h2> + +<ul> + <li><a href="#SECTION01">Introduction</a></li> + <li><a href="#SECTION02">Required packages</a></li> + <li><a href="#SECTION03">The options</a></li> + <li><a href="#SECTION04">The <tt>Figure</tt> environment and its relatives</a> + <ul> + <li><a href="#SECTION04a">The <tt>graphfile</tt> command</a></li> + <li><a href="#SECTION04b">Sub-figures</a></li> + </ul></li> +</ul> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2> +<a name="SECTION01">Introduction</a> +</h2> + +<p> +This package provides some commands to make the use of graphic files +in LaTeX simpler. +</p> + +<p> +It declares the ``<tt>Figure</tt>'' environment (capitalized!) and the two +commands ``<tt>\graphfile</tt>'' and ``<tt>\graphfile*</tt>''. +Combining this commands, it is possible to include graphic files in a +LaTeX document very simply. +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2> +<a name="SECTION02">Required packages</a> +</h2> + +<p> +This package uses the ``<tt>\includegraphics*</tt>'' command defined in +the standard <tt>graphics</tt> package. +Moreover, it uses the package <tt>subfigure</tt> when the +<a href="#SECTION03"><tt>subfigure</tt> option</a> is specified, and the +<tt>float</tt> package if the <a href="#SECTION03"><tt>AllowH</tt> option</a> +is used. +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2> +<a name="SECTION03">The options</a> +</h2> + +<p> +At now, two options are available: ``<tt>subfigure</tt>'' and +``<tt>AllowH</tt>''. +</p> + +<p> +The ``<tt>subfigure</tt>'' option allow the use of sub-figures inside a +<a href="#SECTION04"><tt>Figure</tt> environment</a>, in order to place +multiple pictures in a single LaTeX figure (cfr. the <tt>subfigure</tt> +standard package). +</p> + +<p> +The ``<tt>AllowH</tt>'' option allow the use of the ``<tt>H</tt>'' float +specifier for the <a href="#SECTION04"><tt>Figure</tt> environment</a>, +in order to place the figure exaclty where the command is placed +(cfr. the <tt>float</tt> standard package). +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2> +<a name="SECTION04">The <tt>Figure</tt> environment and its relatives</a> +</h2> + +<p> +The ``<tt>Figure</tt>'' environment (capitalized!) is somewhat different from +the standard LaTeX ``<tt>figure</tt>'' environment: besides an optional +argument used to specify the placement parameters (which now defaults to +``<tt>[htbp]</tt>''), it has a mandatory agrument specifying the ``caption'' +and another optional argument, used as a ``label'' for cross-referencies: +<pre> + \begin{Figure}[<htbpH>]{<caption>}[<label>] + ... + \end{Figure} +</pre> +</p> + +<p> +The use of the ``<tt>H</tt>'' specifier (i.e. ``I want my float here!'') is +possible only if the <a href="#SECTION03">``<tt>AllowH</tt>'' option</a> has +been specified. +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h3> +<a name="SECTION04a">The <tt>graphfile</tt> command</a> +</h3> + +<p> +Inside the ``<tt>Figure</tt>'' environment, are available the commands: +<pre> + \graphfile[<width>]{<file>}[<sub-caption>] + \graphfile*[<heigth>]{<file>}[<sub-caption>] +</pre><br /> +which are a simplified version of the ``<tt>\includegraphics*</tt>'' +command (which is automatically included by this package; see the +<tt>graphics</tt> package for reference), since you don't have to worry +about scaling: the mandatory argument is the name of the graphic file to +include, whereas the first optional argument specifies the desired width +(in the non *-form) or heigth (in the *-form) of the figure as a fraction +of ``<tt>\linewidth</tt>'' (e.g. ``|50|'' means +``<tt>.50\linewidth</tt>'', i.e. half a line! ), so no unit of measure +(as ``<tt>cm</tt>'' or ``<tt>pt</tt>'') is required. +</p> + +<p> +Moreover, since the ``*-form'' of ``<tt>\includegraphics</tt>'' is used, +the regions outside the bounding-box of postscript files are not drawn. +</p> + +<p> +Another advantage of the combined use of the +<a href="#SECTION04">``<tt>Figure</tt>'' environment</a> and the +``<tt>\graphfile</tt>'' commands is that the picture is automatically +centered horizontally, so no ``<tt>\centering</tt>'' or similar +declartion is required. +<pre> + \begin{Figure}[<htbpH>]{<caption>}[<label>] + \graphfile[<width>]{<file>} + \end{Figure} +</pre> +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h3> +<a name="SECTION04b">Sub-figures</a> +</h3> + +<p> +If you want to include more than one file in a single figure, you may +specify <a href="#SECTION03">the ``<tt>subfigure</tt>'' option</a>, which +includes the <tt>subfigure</tt> package and provides the authomatic +placement of a sub-caption below each picture. +</p> + +<p> +If the ``<tt>subfigure</tt>'' option is not specified, multiple graphs are +still allowed but no sub-caption will appear. +<pre> + \graphfile[<width_1>]{<file_1>}[<sub-caption_1>] + ... + \graphfile[<width_N>]{<file_N>}[<sub-caption_N>] +</pre><br /> +This is a combined version of ``<tt>\subfigure</tt>'' and +``<tt>\includegraphics*</tt>'' (see the <tt>subfigure</tt> and +<tt>graphics</tt> packages for reference): +the last optional argument specify a ``caption'' for the sub-figure under +consideration, while the first two arguments work exactly like as described +above in the case of one only picture (indeed, you can use the last optional +argument even if the <tt>subfigure</tt> option was not specified, in which +case it is simply ignored). +</p> + +<p> +Each individual caption is printed preceded by a bracketed letter, which is +the sub-figure counter and is printed even if no caption is specified. +Using only a series of ``<tt>\graphfile[...]{...}[...]</tt>'' commands +inside a ``<tt>Figure</tt>'' environment provides an equal spacing beetween +the pictures and around them, without the need for any extra command. +</p> + +<p> +Finally, if a ``<tt><label></tt>'' was specified as the last optional +argument to the <a href="#SECTION04">``<tt>Figure</tt>'' environment</a>, +you can reference to each individual sub-figure by the labels +``<tt><label>:a</tt>'', ``<tt><label>:b</tt>'', and so on, without +the need for declaring them. +<pre> + \begin{Figure}[<htbpH>]{<caption>}[<label>] + \graphfile[<width_1>]{<file_1>}[<sub-caption_1>] + \graphfile[<width_2>]{<file_2>}[<sub-caption_2>] + : + : + \end{Figure} +</pre> +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<address> + <i>F. Bosisio</i><br /> + E-mail: <a href="mailto:fbosisio@bigfoot.com"><tt>fbosisio@bigfoot.com</tt></a> +</address> + +<!------------------------------------------------------------------------> + +</body> +</html> + diff --git a/macros/latex/contrib/bosisio/graphfig.pdf b/macros/latex/contrib/bosisio/graphfig.pdf Binary files differnew file mode 100644 index 0000000000..a232116d20 --- /dev/null +++ b/macros/latex/contrib/bosisio/graphfig.pdf diff --git a/macros/latex/contrib/bosisio/index.html b/macros/latex/contrib/bosisio/index.html new file mode 100644 index 0000000000..4ec6b16a87 --- /dev/null +++ b/macros/latex/contrib/bosisio/index.html @@ -0,0 +1,338 @@ +<html> +<!-- ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +| Copyright(C) 1997-2010 by F. Bosisio | +| | +| This program can be redistributed and/or modified under | +| the terms 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 LaTeX distributions | +| version 2005/12/01 or later. | +| | +| This work has the LPPL maintenance status `maintained'. | +| The Current Maintainer of this work is F. Bosisio. | +| | +| This work consists of files README and index.html. | +| | +| E-mail: fbosisio@bigfoot.com | +| CTAN location: macros/latex/contrib/bosisio/ | ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +--> +<head> + <title>LaTeX packages by F. Bosisio</title> +</head> +<body bgcolor="white"> + +<h1 align="center">Bosisio's LaTeX packages</h1> + +<p> + This page describes the LaTeX packages developed and mantained + by F. Bosisio at the "Politecnico di Milano", Italy. +</p> + +<p> + For information on the whole LaTeX packages visit the + <a href="http://www.ctan.org">CTAN archive</a> or search the + <a href="http://www.ctan.org/Catalogue">CTAN Catalogue</a> online. +</p> + +<p> + At now the available packages are + <dl compact="1"> + <dt><a href="#envmath">envmath</a></dt> + <dd>Extended and more powerful math-environments</dd> + <dt><a href="#mathenv">mathenv</a></dt> + <dd>Old name for the "envmath" package</dd> + <dt><a href="#mathcmd">mathcmd</a></dt> + <dd>Extended math-mode commands</dd> + <dt><a href="#sobolev">sobolev</a></dt> + <dd>Commands to deal with Sobolev and Hilbert spaces</dd> + <dt><a href="#graphfig">graphfig</a></dt> + <dd>Simple and powerful way of using graphics files inside figures</dd> + <dt><a href="#dblfont">dblfont</a></dt> + <dd>An easy way to define blackboard-bold letters</dd> + <dt><a href="#accenti">accenti</a></dt> + <dd>This package is <em>obsolete</em> and its only aim is to simplify + the usage of accents in the Italian language.</dd> + <dt><a href="#quotes">quotes</a></dt> + <dd>Use double-quote character for both opening and closing quotes.</dd> + <dt><a href="#evenpage">evenpage</a></dt> + <dd>Ensure that the number of pages generated by "LaTeX" is an even + number.</dd> + </dl> +</p> + +<p> + Besides the packages themselves, also the + ``<a href="makedoc"><tt>makedoc</tt></a>'' utility is available: + it is a <tt>UNIX</tt> shell-script that takes a ``<tt>.dtx</tt>'' file and + extracts both the ``<tt>.sty</tt>'' file and the documentation (which is + automatically compiled with LaTeX). + The script only works for ``<tt>.dtx</tt>'' files that are structured like + my packages, i.e. they must directly produce the style-file and a + documentation-driver (``<tt>.drv</tt>'') when simply run through LaTeX. +</p> + +<p> + <em>If you have any suggestions, find any bugs or make any improvment + on any of my packages, please let me know about it</em> + by sending an E-mail at the following address: + <a href="mailto:fbosisio@bigfoot.com">fbosisio@bigfoot.com</a> +</p> + +<hr /> + +<h1><a name="envmath">The "envmath" package</h1> + +<p> + This package provides some environments and commands which I found very + useful in math-mode. +</p> + +<p> + The new math environments are used to make multi-line formulas and systems + of equations, both numbered or unnumbered. + Also the standard <em>equation</em> environment may be redefined so that + it has the same optional argument as the other ones (this optional argument + is simply a label for cross-referencies). +</p> + +<p> + Also a very simple way of making adjustable-size matching braces is + available. +</p> + +<p> + For more informations, see the <a href="envmath.html">on-line documentation</a> + or download the <a href="envmath.pdf">documentation file</a>. +</p> + +<p> + The source file is <a href="envmath.dtx">envmath.dtx</a>, which also + deserves as an installation driver: simply run it through LaTeX in order + to get the corresponding <samp>envmath.sty</samp> file and also the + documentation driver <samp>envmath.drv</samp> (which you must run throught + LaTeX to get the documentation). +</p> + +<hr /> + +<h1><a name="mathenv">The <em>obsolete</em> "mathenv" package</h1> + +<p> + The package "<tt>mathenv</tt>" has been renamed to + "<tt><a href="#envmath">envmath</a></tt>", in order to avoid conflicts with + another package with the same name: if you were using the "old" + "<tt>mathenv</tt>" package, you need to change your LaTeX files in order to + include the new one.<br /> + Alternatively, you can also rename the "new" package to give it the "old" + name (you need to change also the "<tt>\def\FileName{...}</tt>" line inside + the "<tt>sty</tt>"-file), but you must take care not to have another package + with the same name installed on your system. +</p> + +<hr /> + +<h1><a name="mathcmd">The "mathcmd" package</h1> + +<p> + This package provides some commands which I found very useful in math-mode. +</p> + +<p> + The new commands include derivatives, vectors operators, arrow-limits, + integrals and sums. +</p> + +<p> + For more informations, see the <a href="mathcmd.html">on-line documentation</a> + or download the <a href="mathcmd.pdf">documentation file</a>. +</p> + +<p> + The source file is <a href="mathcmd.dtx">mathcmd.dtx</a>, which also + deserves as an installation driver: simply run it through LaTeX in order + to get the corresponding <samp>mathcmd.sty</samp> file and also the + documentation driver <samp>mathcmd.drv</samp> (which you must run throught + LaTeX to get the documentation). +</p> + +<hr /> + +<h1><a name="sobolev">The "sobolev" package</h1> + +<p> + This package provides some commands which I found very useful when + dealing with higher Mathematics that envolves the use of Hilbert and + Sobolev spaces. +</p> + +<p> + The new commands include norm, semi-norm, scalar products, crochet symbols, + besides the various Sobolev spaces. +</p> + +<p> + For more informations, see the <a href="sobolev.html">on-line documentation</a> + or download the <a href="sobolev.pdf">documentation file</a>. +</p> + +<p> + The source file is <a href="sobolev.dtx">sobolev.dtx</a>, which also + deserves as an installation driver: simply run it through LaTeX in order + to get the corresponding <samp>sobolev.sty</samp> file and also the + documentation driver <samp>sobolev.drv</samp> (which you must run throught + LaTeX to get the documentation). +</p> + +<hr /> + +<h1><a name="graphfig">The "graphfig" package</h1> + +<p> + This package provides some very powerful commands to deal with figures + and graphics files in LaTeX. +</p> + +<p> + It provides a new <samp>Figure</samp> environment and a + <samp>\graphfile</samp> command: the combined use of these authomatically + produce a correct centering of the graph(s) with respect to the page. + Moreover, subfigures can be handled in the same way and hard-to-discover + errors (such as a <samp>\label</samp> preceding a <samp>\caption</samp>) + are eliminated. +</p> + +<p> + For more informations, see the <a href="graphfig.html">on-line documentation</a> + or download the <a href="graphfig.pdf">documentation file</a>. +</p> + +<p> + The source file is <a href="graphfig.dtx">graphfig.dtx</a>, which also + deserves as an installation driver: simply run it through LaTeX in order + to get the corresponding <samp>graphfig.sty</samp> file and also the + documentation driver <samp>graphfig.drv</samp> (which you must run throught + LaTeX to get the documentation). +</p> + +<hr /> + +<h1><a name="dblfont">The "dblfont" package</h1> + +<p> + This package provides a simple way to define new commands whose goal + is to print a letter in the blackboard-bold font. +</p> + +<p> + For more informations, see the <a href="dblfont.html">on-line documentation</a> + or download the <a href="dblfont.pdf">documentation file</a>. +</p> + +<p> + The source file is <a href="dblfont.dtx">dblfont.dtx</a>, which also + deserves as an installation driver: simply run it through LaTeX in order + to get the corresponding <samp>dblfont.sty</samp> file and also the + documentation driver <samp>dblfont.drv</samp> (which you must run throught + LaTeX to get the documentation). +</p> + +<hr /> + +<h1><a name="accenti">The package "accenti"</h1> + +<p> + This package provides a shorter version of the accents-making commands + of LaTeX. + They were explicitly build for Italian language, so that only the accents + that occurr in it are handled (the standard LaTeX accents commands still + remains available, though). +</p> + +<p> + I developed this package several years ago, when I was still dealing with + <tt>LaTeX2.09</tt>: now this package is <em>obsolete</em>, as it has been superseeded + by the standard ``<tt>inputenc</tt>'' package of <tt>LaTeX2e</tt>. + Indeed, the declaration + <pre> + \usepackage[latin1]{inputenc} + </pre><br /> + directly allows the use of the characters ``à'', ``è'', + ``ì'', ``ò'', ``ù'' and ``é'' in the document, + which is extremly useful with an italian keyboard. +</p> + +<p> + For more informations, see the <a href="accenti.html">on-line documentation</a> + or download the <a href="accenti.pdf">documentation file</a>. +</p> + +<p> + The source file is <a href="accenti.dtx">accenti.dtx</a>, which also + deserves as an installation driver: simply run it through LaTeX in order + to get the corresponding <samp>accenti.sty</samp> file and also the + documentation driver <samp>accenti.drv</samp> (which you must run throught + LaTeX to get the documentation). +</p> + +<hr /> + +<h1><a name="quotes">The "quotes" package</h1> + +<p> + This package allows to use the double-quote character for both opening and + closing quotes: provided it is <em>always</em> used, it automatically switches + between opening and closing duoble-quotes. +</p> + +<p> + For more informations, see the <a href="quotes.html">on-line documentation</a> + or download the <a href="quotes.pdf">documentation file</a>. +</p> + +<p> + The source file is <a href="quotes.dtx">quotes.dtx</a>, which also + deserves as an installation driver: simply run it through LaTeX in order + to get the corresponding <samp>quotes.sty</samp> file and also the + documentation driver <samp>quotes.drv</samp> (which you must run throught + LaTeX to get the documentation). +</p> + +<hr /> + +<h1><a name="evenpage">The "evenpage" package</h1> + +<p> + This package ensures that the number of pages generated by "LaTeX" is an even + number: if it is odd, an empty page is added at the end, with nothing on it + (neither page number, headers or footers). +</p> + +<p> + For more informations, see the <a href="evenpage.html">on-line documentation</a> + or download the <a href="evenpage.pdf">documentation file</a>. +</p> + +<p> + The source file is <a href="evenpage.dtx">evenpage.dtx</a>, which also + deserves as an installation driver: simply run it through LaTeX in order + to get the corresponding <samp>evenpage.sty</samp> file and also the + documentation driver <samp>evenpage.drv</samp> (which you must run throught + LaTeX to get the documentation). +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<address> + <i>F. Bosisio</i><br /> + E-mail: <a href="mailto:fbosisio@bigfoot.com"><tt>fbosisio@bigfoot.com</tt></a> +</address> + +<!------------------------------------------------------------------------> + +</body> +</html> diff --git a/macros/latex/contrib/bosisio/makedoc b/macros/latex/contrib/bosisio/makedoc new file mode 100644 index 0000000000..c0df879392 --- /dev/null +++ b/macros/latex/contrib/bosisio/makedoc @@ -0,0 +1,97 @@ +#!/bin/sh + +# + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +# | Copyright(C) 1997-2005 by F. Bosisio | +# | | +# | This program can be redistributed and/or modified under | +# | the terms of the LaTeX Project Public License, distributed | +# | from CTAN archives in directory macros/latex/base/lppl.txt; | +# | either version 1 of the License, or any later version. | +# | | +# | E-mail: fbosisio@bigfoot.com | +# | CTAN location: macros/latex/contrib/bosisio/ | +# + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + +# +# If there isn't a command-line parameter, ask for a filename +# +if test $1 +then + FILE=$1 +else + printf '\tInsert the filename you want to process with makedoc\n' + read FILE +fi +# +# Strip the ".dtx" extension (if present) and check that the file exists +# +FILE=`basename ${FILE} .dtx` +test -f ${FILE}.dtx || exit 1 +# +# Run LaTeX on the ".dtx" file to generate the ".sty" and ".drv" files +# +printf '\n\t\tRunning LaTeX on %s.dtx ...\n\n' "${FILE}" +latex ${FILE}.dtx || exit 2 +# +# Run LaTeX once to generate the ".aux", ".idx" and ".glo" files +# +printf '\n\t\tRunning LaTeX on %s.drv ...\n\n' "${FILE}" +latex ${FILE}.drv || exit 3 +# +# Run BibTeX to generate the bibliography file (".bbl") +# +if grep -q bibdata ${FILE}.aux +then + printf '\n\t\tRunning BibTeX on %s.aux ...\n\n' "${FILE}" + bibtex ${FILE} || exit 4 + rm ${FILE}.blg +fi +# +# Run MakeIndex on the index file +# +if test ${FILE}.idx +then + printf '\n\t\tRunning MakeIndex on %s.idx ...\n\n' "${FILE}" + makeindex -s gind.ist -o ${FILE}.ind ${FILE}.idx || exit 5 + rm ${FILE}.ilg +fi +# +# Run MakeIndex on the glossary file +# +if test ${FILE}.glo +then + printf '\n\t\tRunning MakeIndex on %s.glo ...\n\n' "${FILE}" + makeindex -s gglo.ist -o ${FILE}.gls ${FILE}.glo || exit 6 + rm ${FILE}.ilg +fi +# +# Rerun LaTeX to read the ".bbl", ".ind" and ".gls" files +# +printf '\n\t\tRe-running LaTeX on %s.drv ...\n\n' "${FILE}" +latex ${FILE}.drv +# +# Rerun LaTeX again to get the cross-references right +# +if grep -q 'Rerun to get cross-references right' ${FILE}.log +then + printf '\n\t\tRe-running LaTeX again on %s.drv ...\n\n' "${FILE}" + latex ${FILE}.drv +fi +# +# Remove temporary files +# +rm -f ${FILE}.drv ${FILE}.log ${FILE}.aux ${FILE}.ind ${FILE}.glo \ + ${FILE}.bbl ${FILE}.idx ${FILE}.gls +# +# Show the generated output +# +xdvi ${FILE}.dvi +# +# Run DviPdf to produce the PDF file +# +printf '\n\t\tRunning DviPdf ...\n\n' +dvipdf ${FILE}.dvi +# +# Remove DVI file +# +rm ${FILE}.dvi diff --git a/macros/latex/contrib/bosisio/mathcmd.dtx b/macros/latex/contrib/bosisio/mathcmd.dtx new file mode 100644 index 0000000000..57efb18447 --- /dev/null +++ b/macros/latex/contrib/bosisio/mathcmd.dtx @@ -0,0 +1,410 @@ +%\iffalse % MetaComment +%% +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% | Copyright(C) 1997-2010 by F. Bosisio | +%% | | +%% | This program can be redistributed and/or modified under | +%% | the terms 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 LaTeX distributions | +%% | version 2005/12/01 or later. | +%% | | +%% | This work has the LPPL maintenance status `maintained'. | +%% | The Current Maintainer of this work is F. Bosisio. | +%% | | +%% | This work consists of files mathcmd.dtx and mathcmd.html | +%% | and of the derived files mathcmd.sty and mathcmd.pdf. | +%% | | +%% | E-mail: fbosisio@bigfoot.com | +%% | CTAN location: macros/latex/contrib/bosisio/ | +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% +%% If you make any improvment, find any bug or have +%% any suggestion, please let me know about it. +%% +%<*package,driver> +%\fi +% +\def\FileName{mathcmd} +%\iffalse % MetaComment +%</package,driver> +%<*package> +%\fi +\def\fileversion{2.2} +\def\filedate{1997/12/20} +\def\docdate{2005/04/09} +\def\filedescr{Extensions to math environments (FB)} +% +%\iffalse % MetaComment +%</package> +%<*dtx> +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +% This section is the installation driver +% +\def\batchfile{\FileName.dtx} +% +\input docstrip +% +\keepsilent +% \askforoverwritefalse +% +\generateFile{\FileName.sty}{f}{\from{\FileName.dtx}{package}} +% +\generateFile{\FileName.drv}{f}{\from{\FileName.dtx}{driver}} +% +\Msg{******************************************************} +\Msg{*} +\Msg{* To produce the documentation run the} +\Msg{* file `\FileName.drv' through LaTeX.} +\Msg{*} +\Msg{******************************************************} +% +\endbatchfile +% +% End of the installation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%</dtx> +% +% This section is the documentation driver +% +%<+driver>\documentclass[12pt,a4paper]{ltxdoc} +%<+driver> \EnableCrossrefs +%<+driver> \CodelineIndex +%<+driver> \RecordChanges +%<+driver> %\OnlyDescription % Uncomment not to see the implementation +%<+driver>\begin{document} +%<+driver> \DocInput{\FileName.dtx} +%<+driver> \PrintIndex +%<+driver> \PrintChanges +%<+driver>\end{document} +% +% End of the documentation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%<*package> +%\fi +% +% \changes{v0.1}{20 April 1997}{First release (basic environments)} +% \changes{v0.2}{3 May 1997}{Added package options} +% \changes{v1.0}{24 May 1997}{Documentation added} +% \changes{v2.0}{20 December 1997}{Separated from package ``mathenv''} +% \changes{v2.1}{5 March 1999}{Added copyright notice and changed addresses} +% \changes{v2.2}{9 April 2005}{Usage of the double-quote character (") avoided} +% +% \MakeShortVerb{\|} +% +% \title{Package \texttt{\FileName}\thanks{This is version \fileversion, +% last revised \filedate; documentation date \docdate}} +% \author{F. Bosisio\\\normalsize E-mail: \texttt{fbosisio@bigfoot.com}} +% \date{\filedate} +% \maketitle +% +% \begin{abstract} +% Documentation for the package \texttt{\FileName}. +% \end{abstract} +% +% \section{Introduction} +% This package provides some useful math-commands which are simpler +% to use and prettier then their standard \LaTeX{} counterpart. +% +% In particular the ``|\d|'' command is redefined, so +% care should be taken, expecially when including this package in an +% already existent \LaTeX{} file. +% +% \noindent +% The original work of ``|\d|'' (i.e. place a dot under its argument) +% is now done by the ``|\UnderDot|'' command. +% +% \section{The options} +% At now, six options are available with the \texttt{\FileName} +% package, which comes out in matched pairs. +% +% \noindent +% The ``|ThreeSubscrSum|'' and ``|TwoSubscrSum|'' options control the +% placement of subscripts for the ``|\Sum|'' command: the latter +% (which is the default) puts the index under the simbol toghether +% with the starting point, while the former puts the index on the +% lower right corner. +% +% \noindent +% The ``|ProdVettWedge|'' and ``|ProdVettTimes|'' options select +% which symbol is to be used for the \emph{vector product}: the first +% one uses a ``|\wedge|'' (default), whilst the second uses a +% ``|\times|''. +% +% \noindent +% Finally, the ``|VectOpStr|'' and ``|VectOpSymb|'' options controls +% whether the vector-operator commands ``|\Grad|'', ``|\Div|'' and +% ``|\Rot|'' should produce a roman string (default) or a +% ``|\nabla|'' symbol followed by an operator, respectively. +% +% \section{Math-mode commands} +% The \texttt{\FileName} package defines a number of math-mode +% commands. +% +% \subsection{The \texttt{text} command} +% The ``|\text{|\ldots|}|'' command is defined to be +% equivalent to ``|\mbox|'' (except when the ``|amstext|'' +% package is also used, since this package already defines +% this command in a better way). +% +% \noindent +% It is intended for inserting pieces of text in a formula. +% +% \subsection{Commands for doing integrals} +% The ``|\Int|'' (capitalized) differs from the \LaTeX{} +% command ``|\int|'' in that it is always printed in +% |displaystyle| and if it has only a subscript, this is +% somewhat lowered so that it looks better. +% \begin{verbatim} +% \Int_{...}^{...} ... \d{...} +% \end{verbatim} +% +% The ``|\d{|\ldots|}|'' command is for making the +% differential symbol at the end of integrals: it simply +% prints a ``|d|'' followed by its argument and preceded by +% a little space, which seems prettier. +% +% \subsection{Commands for making sums} +% The ``|\Sum{|$\cdots=\cdots,\cdots$|}|'' command works +% differently, depending on which option between +% ``|TwoSubscrSum|'' (default) and ``|ThreeSubscrSum|'' has +% been specified. +% +% \noindent +% In the first case, it expands to +% ``|\displaystyle\sum_{...=...}^{...}|'', whereas in the +% second case the second and third argument are treated +% in the same way as before (i.e. as a subscript and +% superscript, respectively), but the first argument +% (the one before the ``='') is placed near +% the lower-left edge of the ``|\sum|'' symbol and the ``='' +% is not printed. +% +% There is also a ``|\SUM{|\ldots|}|'' command which is useful +% when only a subscript is desired, irrespectively of the +% option specified: in fact, is is equivalent to +% ``|\displaystyle\sum_{|\ldots|}|''. +% +% \subsection{Derivatives symbols} +% The commands ``|\DerTot{|\ldots|}{|\ldots|}|'', +% ``|\DerPar{|\ldots|}{|\ldots|}|'' and ``|\DerNorm{|\ldots|}|'' +% generate the symbols of total derivative, partial derivative +% and normal derivative, respectively. +% +% \noindent +% In other words, they are the same as: +% \begin{verbatim} +% \displaystyle\frac{d...}{d...} +% \displaystyle\frac{\partial ...}{\partial ...} +% \displaystyle\frac{\partial ...}{\partial n} +% \end{verbatim} +% +% \subsection{Arrow-limits commands} +% The command ``|\TendsTo|[$\cdots,\cdots$]'' generates a +% right-arrow with optionally an underscript wich is another +% smaller right-arrow between the two comma-separeted +% arguments inside the square brackets. +% +% \noindent +% For example, the command ``|f(x) \TendsTo[x,0] 1|'' generates +% the following output: +% $f(x) \mathop{\longrightarrow}\limits_{x \rightarrow 0} 1$. +% +% \subsection{Vector-operators commands} +% Finally, the commands ``|\Grad|'', ``|\Div|'' and +% ``|\Rot|'' generates the strings ``grad'', ``div'' and ``rot'' +% in roman type and with small spaces added before and after, +% if the ``VectOpStr'' option is in effect (default). +% If, instead, the option ``VectOpSymb'' was specified, they +% generate ``|\nabla|'', ``|\nabla\cdot|'' and +% ``|\nabla\ProdVett|'' respectively. +% +% The command ``|\ProdVett|'' is intended for making the +% symbol of vector product, and evaluates to ``|\times|'' +% with the option ``ProdVettTimes'' and to ``|\wedge|'' with +% the (default) option ``ProdVettWedge''. +% +% \begin{tabular}{lcccc} +% & & |VectOpStr| & \multicolumn{2}{c}{|VectOpSymb|} \\ +% & & &|ProdVettWedge|&|ProdVettTimes|\\ +% |\Grad|& $\Rightarrow$ & $\mathrm{grad}$& $\nabla$ & $\nabla$ \\ +% |\Div| & $\Rightarrow$ & $\mathrm{div}$& $\nabla\cdot$ & $\nabla\cdot$ \\ +% |\Rot| & $\Rightarrow$ & $\mathrm{rot}$& $\nabla\wedge$& $\nabla\times$ +% \end{tabular} +% +% +% \StopEventually{} +% \newpage +% \section{Implementation} +% +% \begin{macrocode} +%% +\NeedsTeXFormat{LaTeX2e}[1995/12/01] +\ProvidesPackage{\FileName}[\filedate\space v\fileversion\space\filedescr] +%% +\newif\if@ThreeSubscrSum +\DeclareOption{ThreeSubscrSum}{\@ThreeSubscrSumtrue} +\DeclareOption{TwoSubscrSum}{\@ThreeSubscrSumfalse} +%% +\DeclareOption{ProdVettWedge}{\let\ProdVett=\wedge} +\DeclareOption{ProdVettTimes}{\let\ProdVett=\times} +%% +\newif\if@VectOper@Symbol +\DeclareOption{VectOpStr}{\@VectOper@Symbolfalse} +\DeclareOption{VectOpSymb}{\@VectOper@Symboltrue} +%% +\ExecuteOptions{TwoSubscrSum,ProdVettWedge,VectOpStr} +% \end{macrocode} +% +% The ``|\ProcessOptions*|'' command was used here instead of +% ``|\ProcessOptions*|'' in order to process the options in the +% ``|\usepackage|'' order, rather than in the declaration order +% \begin{macrocode} +%% +\ProcessOptions* +% \end{macrocode} +% +% \begin{macro}{\text} +% The definition of |\text| is deferred at the |\begin{document}|, +% so that if the \texttt{amstext} package is loaded (even after this +% package), its definition of text will be used, since it seems +% better. +% \begin{macrocode} +%% +\AtBeginDocument{\ifx\undefined\text \def\text#1{\ \mbox{#1}\ } \fi} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\Int} +% The command |\@INT@sub@SUP| has one argument and then a mandatory +% superscript: il typesets an integral symbol (in |\displaystyle|) +% with the argument as a lower-bound and the superscript as an +% upper-bound. +% \begin{macrocode} +%% +\def\@INT@sub@SUP#1^#2{{\displaystyle\int_{#1}^{#2}}} +% \end{macrocode} +% The command |\@INT@subONLY| has only an argument, which is used as +% as a subscript for a |displaystyle| |\int|, but lowered of |0.2ex|. +% \begin{macrocode} +\def\@INT@subONLY#1{{\displaystyle\int_{\raisebox{-0.2ex}{$_{#1}$}}}} +% \end{macrocode} +% The command |\@INT@sub| must have a subscript and may optionally be +% followed by a superscript. +% \begin{macrocode} +\def\@INT@sub_#1{\@ifnextchar^{\@INT@sub@SUP{#1}}{\@INT@subONLY{#1}}} +% \end{macrocode} +% The command |\@INT@SUP@sub| must have a superscript and a subscript, +% in that order: they are passed to a |displaystyle| |\int| command. +% \begin{macrocode} +\def\@INT@SUP@sub^#1_#2{{\displaystyle\int_{#2}^{#1}}} +% \end{macrocode} +% The |\Int| command invokes |\@INT@SUP@sub| or |\@INT@sub| or simply +% expands to |\displaystyle\int| depending on what follows (|^|, |_| +% or neither of them). +% \begin{macrocode} +\newcommand{\Int}{\@ifnextchar^{\@INT@SUP@sub}{\@ifnextchar_{\@INT@sub}{\displaystyle\int}}} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\d} +% The original |\d| command is saved in |\UnderDot|, then (at the +% |\begin{document}| to avoid conflicts with other packages) it is +% redefined as a ``|d|'' preceeded by some space an followed by its +% argument (it is intended for printing the differential symbol at +% the end of an integral). +% \begin{macrocode} +%% +\AtBeginDocument{ \let\UnderDot=\d \renewcommand{\d}[1]{\:\:d#1} } +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\Sum} +% The command |\INNER@SUM| is defined differently depending on the +% selected option. It has 3 or 2 orguments, ended by an exclamation +% mark and separated by an equal sign and a comma. +% The two last arguments are passed as a subscrit and as a superscript +% to a |displaystyle| |\sum|, whereas the first argument (if they are +% 3) is typeset in |scriptstyle| and lowered so that it occours at the +% lower right corner of the |sum| symbol. +% \begin{macrocode} +%% +\if@ThreeSubscrSum + \def\INNER@SUM#1=#2,#3!{{\displaystyle\sum_{#2}^{#3}\raisebox{-0.6ex}{$_{\!#1}$}}} +\else + \def\INNER@SUM#1,#2!{{\displaystyle\sum_{#1}^{#2}}} +\fi +% \end{macrocode} +% The |\Sum| command is then simply a call to |\INNER@SUM|, with a +% question mark added to denote the end of the argument. +% \begin{macrocode} +\newcommand{\Sum}[1]{\INNER@SUM#1!} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\SUM} +% The |\SUM| command has one only argument which is used as a +% subscript and, again, is always printed in |\displaystyle|. +% \begin{macrocode} +\newcommand{\SUM}[1]{{\displaystyle\sum_{#1}}} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\DerPar} +% The commands ``|\DerPar|'', ``|\DerTot|'' and ``|\DerNorm|'' generate a +% |displaystyle| |\frac| command, with a ``|\partial|'' or ``|d|'' or +% ``|\partial n|'' added to its arguments and followed by a little space. +% \begin{macrocode} +%% +\newcommand\DerPar[2]{{\displaystyle\frac{\partial #1}{\partial #2}\:}} +\newcommand\DerTot[2]{{\displaystyle\frac{d#1}{d#2}\:}} +\newcommand\DerNorm[1]{{\displaystyle\frac{\partial #1}{\partial n}\:}} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\TendsTo} +% The command |\@TendeQuando| must be followed by a pair of square +% brackets, which enclose two arguments separated by a comma. +% It place a |\rightarrow| command between them and puts the whole +% under a bigger |\rightarrow|. +% The |\mathop| allows the |\limits| command, which, in turn, place +% the subscript \emph{under} the symbol. +% \begin{macrocode} +%% +\def\@TendeQuando[#1,#2]{ \mathop{\longrightarrow}\limits_{#1 \rightarrow #2} } +% \end{macrocode} +% The |\TendsTo| command invokes |\@TendeQuando| if followed by +% a ``['', or |\longrightarrow| otherwise. +% \begin{macrocode} +\def\TendsTo{\@ifnextchar[{\@TendeQuando}{\longrightarrow}} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\Grad} +% The |\Grad|, |\Div| and |\Rot| commands generates a symbol or a +% roman word, depending on the selected option. +% \begin{macrocode} +%% +\if@VectOper@Symbol + \newcommand\Grad{\nabla} + \newcommand\Div{\nabla\cdot} + \newcommand\Rot{\nabla\ProdVett} +\else + \newcommand\Grad{\:\mathrm{grad}\,} + \newcommand\Div{\:\mathrm{div}\,} + \newcommand\Rot{\:\mathrm{rot}\,} +\fi +% \end{macrocode} +% \end{macro} +% +%\iffalse % MetaComment +%<*package> +%\fi +% +% \CheckSum{153} +% \Finale +% +\endinput + diff --git a/macros/latex/contrib/bosisio/mathcmd.html b/macros/latex/contrib/bosisio/mathcmd.html new file mode 100644 index 0000000000..2aff926574 --- /dev/null +++ b/macros/latex/contrib/bosisio/mathcmd.html @@ -0,0 +1,248 @@ +<html> +<!-- ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +| Copyright(C) 1997-2010 by F. Bosisio | +| | +| This program can be redistributed and/or modified under | +| the terms 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 LaTeX distributions | +| version 2005/12/01 or later. | +| | +| This work has the LPPL maintenance status `maintained'. | +| The Current Maintainer of this work is F. Bosisio. | +| | +| This work consists of files mathcmd.dtx and mathcmd.html | +| and of the derived files mathcmd.sty and mathcmd.pdf. | +| | +| E-mail: fbosisio@bigfoot.com | +| CTAN location: macros/latex/contrib/bosisio/ | ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +--> +<head> + <title>Package mathcmd</title> +</head> +<body> + +<h1 align="CENTER"> +Package <tt>mathcmd</tt><br /> +<small> +This is version 2.2, last revised 1997/12/20; documentation date 2005/04/09. +</small> +</h1> + +<p align="CENTER"> +<strong> +Author: <i>F. Bosisio</i><br /> +<small> +E-mail: <a href="mailto:fbosisio@bigfoot.com"> + <tt>fbosisio@bigfoot.com</tt> + </a><br /> +CTAN location: <a href="http://mirror.ctan.org/macros/latex/contrib/bosisio"> + <tt>macros/latex/contrib/bosisio</tt> + </a> +</small> +</strong> +</p> + +<p align="LEFT"> +<!------------------------------------------------------------------------> +<p> + +<h3>Abstract:</h3> +<div> +Documentation for the package <tt>mathcmd</tt>. +</div> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2>Table of contents</h2> + +<ul> + <li><a href="#SECTION01">Introduction</a></li> + <li><a href="#SECTION02">The options</a></li> + <li><a href="#SECTION03">Math-mode commands</a> + <ul> + <li><a href="#SECTION03a">The <tt>text</tt> command</a></li> + <li><a href="#SECTION03b">Commands for doing integrals</a></li> + <li><a href="#SECTION03c">Commands for making sums</a></li> + <li><a href="#SECTION03d">Derivatives symbols</a></li> + <li><a href="#SECTION03e">Arrow-limits commands</a></li> + <li><a href="#SECTION03f">Vector-operators commands</a></li> + </ul></li> +</ul> + +<hr /><br /> +<!------------------------------------------------------------------------> +<p> + +<h2> +<a name="SECTION01">Introduction</a> +</h2> +This package provides some useful math-commands which are simpler to use and +prettier then their standard LaTeX counterpart. + +<p> +In particular <a href="#SECTION03b">the ``<tt>\d</tt>'' command</a> is +redefined, so care should be taken, expecially when including this package +in an already existent LaTeX file. + +<p> +The original work of ``<tt>\d</tt>'' (i.e. place a dot under its argument) +is now done by the ``<tt>\UnderDot</tt>'' command. + +<h2> +<a name="SECTION02">The options</a> +</h2> + +<p> +At now, six options are available with the <tt>mathcmd</tt> package, which +comes out in matched pairs. + +<p> +The ``<tt>ThreeSubscrSum</tt>'' and ``<tt>TwoSubscrSum</tt>'' options control +the placement of subscripts for +<a href="#SECTION03c">the ``<tt>\Sum</tt>'' command</a>: the latter +(which is the default) puts the index under the simbol toghether with the +starting point, while the former puts the index on the lower right corner. + +<p> +The ``<tt>ProdVettWedge</tt>'' and ``<tt>ProdVettTimes</tt>'' options +select which symbol is to be used for the +<a href="#SECTION03f"><em>vector product</em></a>: the first one uses +a ``<tt>\wedge</tt>'' (default), whilst the second uses a ``<tt>\times</tt>". + +<p> +Finally, the ``<tt>VectOpStr</tt>'' and ``<tt>VectOpSymb</tt>'' options +controls whether the <a href="#SECTION03f">vector-operator commands</a> +``<tt>\Grad</tt>'', ``<tt>\Div</tt>'' and ``<tt>\Rot</tt>'' should produce +a roman string (default) or a ``<tt>\nabla</tt>" symbol followed by an +operator, respectively. + +<h2> +<a name="SECTION03">Math-mode commands</a> +</h2> + +<p> +The <tt>mathcmd</tt> package defines a number of math-mode commands. + +<h3> +<a name="SECTION03a">The <tt>text</tt> command</a> +</h3> + +<p> +The ``<tt>\text...</tt>'' command is defined to be equivalent to +``<tt>\mbox</tt>'' (except when the ``<tt>amstext</tt>" package is also used, +since this package already defines this command in a better way). + +<p> +It is intended for inserting pieces of text in a formula. + +<h3> +<a name="SECTION03b">Commands for doing integrals</a> +</h3> + +<p> +The ``<tt>\Int</tt>'' (capitalized) differs from the LaTeX command +``<tt>\int</tt>'' in that it is always printed in <tt>displaystyle</tt> and +if it has only a subscript, this is somewhat lowered so that it looks better. +<pre> + \Int_{...}^{...} ... \d{...} +</pre> + +<p> +The <a href="#SECTION01">``<tt>\d...</tt>'' command</a> is for making the +differential symbol at the end of integrals: it simply prints a ``<tt>d</tt>'' +followed by its argument and preceded by a little space, which seems prettier. + +<h3> +<a name="SECTION03c">Commands for making sums</a> +</h3> + +<p> +The ``<tt>\Sum{...=...,...}</tt>'' command works differently, depending on +which option between ``<a href="#SECTION02"><tt>TwoSubscrSum</tt></a>'' +(default) and ``<a href="#SECTION02"><tt>ThreeSubscrSum</tt></a>'' has been +specified. + +<p> +In the first case, it expands to +``<tt>\displaystyle\sum_{...}={...}^{...}</tt>'', whereas in the second +case the second and third argument are treated in the same way as before +(i.e. as a subscript and superscript, respectively), but the first argument +(the one before the ``='') is placed near the lower-left edge of the +``<tt>\sum</tt>'' symbol and the ``='' is not printed. + +<p> +There is also a ``<tt>\SUM...</tt>'' command which is useful when only a +subscript is desired, irrespectively of the option specified: in fact, it +is equivalent to ``<tt>\displaystyle\sum_...</tt>". + +<h3> +<a name="SECTION03d">Derivatives symbols</a> +</h3> + +<p> +The commands ``<tt>\DerTot{...}{...}</tt>'', ``<tt>\DerPar{...}{...}</tt>'' and +``<tt>\DerNorm{...}</tt>'' generate the symbols of total derivative, partial +derivative and normal derivative, respectively. + +<p> +In other words, they are the same as: +<pre> + \displaystyle\frac{d...}{d...} + \displaystyle\frac{\partial ...}{\partial ...} + \displaystyle\frac{\partial ...}{\partial n} +</pre> + +<h3> +<a name="SECTION03e">Arrow-limits commands</a> +</h3> + +<p> +The command ``<tt>\TendsTo[...,...]</tt>'' generates a right-arrow with +optionally an underscript wich is another smaller right-arrow between the +two comma-separeted arguments inside the square brackets. + +<p> +For example, the command ``<tt>f(x) \TendsTo[x,0] 1</tt>'' generates +the following output: +<pre> + f(x) ----------> 1 + x --> 0 +</pre> + +<h3> +<a name="SECTION03f">Vector-operators commands</a> +</h3> + +<p> +Finally, the commands ``<tt>\Grad</tt>'', ``<tt>\Div</tt>'' and +``<tt>\Rot</tt>'' generates the strings ``grad'', ``div'' and ``rot'' +in roman type and with small spaces added before and after, if the +``<a href="#SECTION02">VectOpStr</a>'' option is in effect (default). +If, instead, the option ``<a href="#SECTION02">VectOpSymb</a>'' was specified, +they generate ``<tt>\nabla</tt>", ``<tt>\nabla\cdot</tt>'' and +``<tt>\nabla\ProdVett</tt>'' respectively. + +<p> +The command ``<tt>\ProdVett</tt>'' is intended for making the symbol of +vector product, and evaluates to ``<tt>\times</tt>'' with the option +``<a href="#SECTION02">ProdVettTimes</a>'' and to ``<tt>\wedge</tt>'' +with the (default) option ``<a href="#SECTION02">ProdVettWedge</a>''. + +<hr /><br /> +<!------------------------------------------------------------------------> + +<address> + <i>F. Bosisio</i><br /> + E-mail: <a href="mailto:fbosisio@bigfoot.com"><tt>fbosisio@bigfoot.com</tt></a> +</address> + +<!------------------------------------------------------------------------> + +</body> +</html> diff --git a/macros/latex/contrib/bosisio/mathcmd.pdf b/macros/latex/contrib/bosisio/mathcmd.pdf Binary files differnew file mode 100644 index 0000000000..19aa03a4dc --- /dev/null +++ b/macros/latex/contrib/bosisio/mathcmd.pdf diff --git a/macros/latex/contrib/bosisio/quotes.dtx b/macros/latex/contrib/bosisio/quotes.dtx new file mode 100644 index 0000000000..da76efd32b --- /dev/null +++ b/macros/latex/contrib/bosisio/quotes.dtx @@ -0,0 +1,177 @@ +%\iffalse % MetaComment +%% +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% | Copyright(C) 1997-2010 by F. Bosisio | +%% | | +%% | This program can be redistributed and/or modified under | +%% | the terms 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 LaTeX distributions | +%% | version 2005/12/01 or later. | +%% | | +%% | This work has the LPPL maintenance status `maintained'. | +%% | The Current Maintainer of this work is F. Bosisio. | +%% | | +%% | This work consists of files quotes.dtx and quotes.html | +%% | and of the derived files quotes.sty and quotes.pdf. | +%% | | +%% | E-mail: fbosisio@bigfoot.com | +%% | CTAN location: macros/latex/contrib/bosisio/ | +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% +%% If you make any improvment, find any bug or have +%% any suggestion, please let me know about it. +%% +%<*package,driver> +%\fi +% +\def\FileName{quotes} +%\iffalse % MetaComment +%</package,driver> +%<*package> +%\fi +\def\fileversion{2.2} +\def\filedate{1997/12/20} +\def\docdate{2005/04/09} +\def\filedescr{Commands to use double quotes (FB)} +% +%\iffalse % MetaComment +%</package> +%<*dtx> +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +% This section is the installation driver +% +\def\batchfile{\FileName.dtx} +% +\input docstrip +% +\keepsilent +% \askforoverwritefalse +% +\generateFile{\FileName.sty}{f}{\from{\FileName.dtx}{package}} +% +\generateFile{\FileName.drv}{f}{\from{\FileName.dtx}{driver}} +% +\Msg{******************************************************} +\Msg{*} +\Msg{* To produce the documentation run the} +\Msg{* file `\FileName.drv' through LaTeX.} +\Msg{*} +\Msg{******************************************************} +% +\endbatchfile +% +% End of the installation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%</dtx> +% +% This section is the documentation driver +% +%<+driver>\documentclass[12pt,a4paper]{ltxdoc} +%<+driver> \EnableCrossrefs +%<+driver> \CodelineIndex +%<+driver> \RecordChanges +%<+driver> %\OnlyDescription % Uncomment not to see the implementation +%<+driver>\begin{document} +%<+driver> \DocInput{\FileName.dtx} +%<+driver> \newpage +%<+driver> \PrintIndex +%<+driver> \PrintChanges +%<+driver>\end{document} +% +% End of the documentation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%<*package> +%\fi +% +% \changes{v0.1}{4 May 1997}{First release (basic accents-command)} +% \changes{v0.2}{20 August 1997}{Added double-quotes and extended-chars} +% \changes{v1.0}{5 September 1997}{Documentation added} +% \changes{v1.1}{7 November 1997}{Fixed a bug in the options} +% \changes{v2.0}{20 December 1997}{Separated from package ``quotes''} +% \changes{v2.1}{5 March 1999}{Added copyright notice and changed addresses} +% \changes{v2.2}{9 April 2005}{Usage of the double-quote character (") avoided} +% +% \MakeShortVerb{\|} +% +% \title{Package \texttt{\FileName}\thanks{This is version \fileversion, +% last revised \filedate; documentation date \docdate}} +% \author{F. Bosisio\\\normalsize E-mail: \texttt{fbosisio@bigfoot.com}} +% \date{\filedate} +% \maketitle +% +% \begin{abstract} +% Documentation for the package \texttt{\FileName}. +% \end{abstract} +% +% \section{Introduction} +% This package simplifies the use of double-quotes. +% +% \section{Double quotes} +% +% With this package, the character `` |"| '' generates the correct +% double-quote, i.e. the sequence $<<$| " text " |$>>$ +% generates $<<$ `` |text| '' $>>$, so that this character +% can be used both for opening and closing the double-quotes +% (provided that it is \emph{always} used). +% +% \StopEventually{} +% \newpage +% \section{Implementation} +% +% \begin{macrocode} +%% +\NeedsTeXFormat{LaTeX2e}[1995/12/01] +\ProvidesPackage{\FileName}[\filedate\space v\fileversion\space\filedescr] +% \end{macrocode} +% +% \begin{macro}{Quotes} +% The command ``|\@VIRGOLETTE|'' is defined to print an open or close +% double-quotes alternatively, so that they are always right. +% Moreover, the double-quotes are always printed in upright-shape, +% since they looks better. +% +% \begin{macrocode} +%% +\newif\if@virgolette\@virgolettefalse +%% +\newcommand{\@VIRGOLETTE}{% +\if@virgolette% + \@virgolettefalse% + \textup{''}% +\else% + \@virgolettetrue% + \textup{``}% +\fi% +} +% \end{macrocode} +% Then the character `` |"| '' is associated to the command +% ``|\@VIRGOLETTE|'' just defined, so that you just have to type +% this character in order to get the right double-quotes. +% This trick has been adapted from the |doc| package, but +% perhaps it may be done in a better way. +% \begin{macrocode} +\@makeother " %% Can this command be eliminated ? +\begingroup + \catcode`\~\active \lccode`\~`\"% + \lowercase{% + \global\expandafter\let + \csname ac\string\"\endcsname~% + \gdef~{\@VIRGOLETTE}}% +\endgroup +\global\catcode`\"\active +% +% \end{macrocode} +% \end{macro} +% +%\iffalse % MetaComment +%<*package> +%\fi +% +% \CheckSum{43} +% \Finale +% +\endinput + diff --git a/macros/latex/contrib/bosisio/quotes.html b/macros/latex/contrib/bosisio/quotes.html new file mode 100644 index 0000000000..21f2e05f53 --- /dev/null +++ b/macros/latex/contrib/bosisio/quotes.html @@ -0,0 +1,84 @@ +<html> +<!-- ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +| Copyright(C) 1997-2010 by F. Bosisio | +| | +| This program can be redistributed and/or modified under | +| the terms 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 LaTeX distributions | +| version 2005/12/01 or later. | +| | +| This work has the LPPL maintenance status `maintained'. | +| The Current Maintainer of this work is F. Bosisio. | +| | +| This work consists of files quotes.dtx and quotes.html | +| and of the derived files quotes.sty and quotes.pdf. | +| | +| E-mail: fbosisio@bigfoot.com | +| CTAN location: macros/latex/contrib/bosisio/ | ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +--> +<head> + <title>Package quotes</title> +</head> +<body> + +<h1 align="center"> + Package <tt>quotes</tt><br /> + <small> + This is version 2.2, last revised 1997/12/20; documentation date 2005/04/09. + </small> +</h1> + +<p align="center"> + <strong> + Author: <i>F. Bosisio</i><br /> + <small> + E-mail: <a href="mailto:fbosisio@bigfoot.com"> + <tt>fbosisio@bigfoot.com</tt> + </a><br /> + CTAN location: <a href="http://mirror.ctan.org/macros/latex/contrib/bosisio"> + <tt>macros/latex/contrib/bosisio</tt> + </a> + </small> + </strong> +</p> + +<p> + This package simplifies the usage of double-quotes. +</p> + +<p> + With this package, the character ``<tt>"</tt>'' generates the correct + double-quotes, so that it can be used both for opening and closing + quoted text (provided that it is <em>always</em> used). + <br /> + In other words, the input sequence + <pre> + "text" + </pre> + becomes equivalent to + <pre> + ``text'' + </pre> + and thus generates + <br /> + + + ``text'' +</p> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<address> + <i>F. Bosisio</i><br /> + E-mail: <a href="mailto:fbosisio@bigfoot.com"><tt>fbosisio@bigfoot.com</tt></a> +</address> + +<!------------------------------------------------------------------------> +</body> +</html> diff --git a/macros/latex/contrib/bosisio/quotes.pdf b/macros/latex/contrib/bosisio/quotes.pdf Binary files differnew file mode 100644 index 0000000000..5800b5a466 --- /dev/null +++ b/macros/latex/contrib/bosisio/quotes.pdf diff --git a/macros/latex/contrib/bosisio/sobolev.dtx b/macros/latex/contrib/bosisio/sobolev.dtx new file mode 100644 index 0000000000..e7b524e4fe --- /dev/null +++ b/macros/latex/contrib/bosisio/sobolev.dtx @@ -0,0 +1,543 @@ +%\iffalse % MetaComment +%% +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% | Copyright(C) 1997-2010 by F. Bosisio | +%% | | +%% | This program can be redistributed and/or modified under | +%% | the terms 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 LaTeX distributions | +%% | version 2005/12/01 or later. | +%% | | +%% | This work has the LPPL maintenance status `maintained'. | +%% | The Current Maintainer of this work is F. Bosisio. | +%% | | +%% | This work consists of files sobolev.dtx and sobolev.html | +%% | and of the derived files sobolev.sty and sobolev.pdf. | +%% | | +%% | E-mail: fbosisio@bigfoot.com | +%% | CTAN location: macros/latex/contrib/bosisio/ | +%% + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +%% +%% If you make any improvment, find any bug or have +%% any suggestion, please let me know about it. +%% +%<*package,driver> +%\fi +% +\def\FileName{sobolev} +%\iffalse % MetaComment +%</package,driver> +%<*package> +%\fi +\def\fileversion{2.2} +\def\filedate{1997/11/14} +\def\docdate{2005/04/09} +\def\filedescr{Commands to print the Sobolev spaces (FB)} +% +%\iffalse % MetaComment +%</package> +%<*dtx> +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +% This section is the installation driver +% +\def\batchfile{\FileName.dtx} +% +\input docstrip +% +\keepsilent +% \askforoverwritefalse +% +\generateFile{\FileName.sty}{f}{\from{\FileName.dtx}{package}} +% +\generateFile{\FileName.drv}{f}{\from{\FileName.dtx}{driver}} +% +\Msg{******************************************************} +\Msg{*} +\Msg{* To produce the documentation run the} +\Msg{* file `\FileName.drv' through LaTeX.} +\Msg{*} +\Msg{******************************************************} +% +\endbatchfile +% +% End of the installation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%</dtx> +% +% This section is the documentation driver +% +%<+driver>\documentclass[12pt,a4paper]{ltxdoc} +%<+driver> \EnableCrossrefs +%<+driver> \CodelineIndex +%<+driver> \RecordChanges +%<+driver> %\OnlyDescription % Uncomment not to see the implementation +%<+driver>\begin{document} +%<+driver> \DocInput{\FileName.dtx} +%<+driver> \PrintIndex +%<+driver> \PrintChanges +%<+driver>\end{document} +% +% End of the documentation driver +%- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +%<*package> +%\fi +% +% \changes{v0.1}{28 March 1997}{First release (basic commands)} +% \changes{v0.2}{3 April 1997}{Added package options} +% \changes{v0.3}{7 July 1997}{Fixed a bug in the command ``Scalar''} +% \changes{v0.4}{4 August 1997}{Fixed a bug in the options} +% \changes{v1.0}{5 August 1997}{Documentation added} +% \changes{v1.1}{4 November 1997}{Fixed a bug in the ``Hdiv'' command} +% \changes{v1.2}{5 November 1997}{Superscripts for ``Norm'' and ``SemiNorm''} +% \changes{v2.0}{14 November 1997}{Changed ``Scalar'' sintax; added ``Crochet''} +% \changes{v2.1}{5 March 1999}{Added copyright notice and changed addresses} +% \changes{v2.2}{9 April 2005}{Usage of the double-quote character (") avoided} +% +% \MakeShortVerb{\|} +% +% \title{Package \texttt{\FileName}\thanks{This is version \fileversion, +% last revised \filedate; documentation date \docdate}} +% \author{F. Bosisio\\\normalsize E-mail: \texttt{fbosisio@bigfoot.com}} +% \date{\filedate} +% \maketitle +% +% \begin{abstract} +% Documentation for the package \texttt{\FileName}. +% \end{abstract} +% +% \section{Introduction} +% This package provides some commands which are useful when dealing +% with Sobolev spaces and their relatives. +% +% In particular some commands are redefined, so care should be +% taken, expecially when including this package in an already +% existent \LaTeX{} file. +% +% \noindent +% The redefined commands are |\H| and |\L|. +% The effect of ``|\H|'' (which is a type of accent) can now be +% achieved by the command ``|\HAccent|'', whilst the job of ``|\L|'' +% (i.e. print an ``L'' with a superimposed bar) is now done by the +% command ``|\Lbar|''. +% +% \section{The options} +% Two options are available at the moment: \texttt{DivInBrackets} +% and \texttt{DivAsExponent}. +% They only affect the output of the ``|\Hdiv|'' command. +% +% \noindent +% The firt options (\texttt{DivInBrackets}, which is the default) +% makes |\Hdiv| behave like ``|H(div;|\dots|)|'', while the second +% one (\texttt{DivAsExponent}) makes |\Hdiv| expand to +% ``|H^{div}(|\dots|)|''. +% +% \section{The commands} +% Most of the subsequent space-generating commands have mandatory +% arguments to indicate the type of the space. +% Often this argument consists of a single digit: in this case it +% is \emph{not} necessary to enclose it in brackets, since in \LaTeX{} +% the names of commands consists of letters only, and so a digit +% following it is certainly an argument. +% This saves a lot of typing and is the only reason that makes these +% commans useful (if you always had to type the brackets, then it +% would have been simpler to type the expansion of the command than +% the command itself !). +% In other words, you can think as if several commands exist (like +% |\H|, |\H1|, |\H10|, etc.), the ones with the digit beeing a sort of +% abbreviation for the general one. +% +% \subsection{The \texttt{H} command} +% The |\H| command is used to generate the symbol of sobolev +% spaces. +% It takes a mandatory argument, which is used as a +% superscript, and an optional argument, which is used as a +% subscript. +% +% \noindent +% As explained above, if the mandatory argument is a digit, +% it need not be enclosed in brackets. +% Moreover, if the optional argument is the digit ``0'', it +% can be typed without the square brackets. +% +% \noindent +% Here are some examples (whith the |\DefaultSet| set to its +% default value |\Omega|): +% +% \begin{tabular}{lll} +% |\H2| & $\Longrightarrow$ & $H^2(\Omega)$ \\ +% |\H10| & $\Longrightarrow$ & $H^1_0(\Omega)$ \\ +% |\H1[\Gamma_D]| & $\Longrightarrow$ & $H^1_{\Gamma_D}(\Omega)$ \\ +% |\H{-1/2}| & $\Longrightarrow$ & $H^{-1/2}(\Omega)$ +% \end{tabular} +% +% \subsection{The \texttt{Hdiv} command} +% The |\Hdiv| command is used to generate the sobolev space +% called ``H div''. +% It takes only an optional argument, which is used as a +% subscript and which need not to be surrounded by the square +% brackets if it is the digit ``0''. +% +% \noindent +% If the (default) option \texttt{DivInBrackets} is in effect, +% it differs from the command |\H| in that the word ``div'' is +% printed (in roman type) inside brackets, before the set. +% If, instead, the option \texttt{DivAsExponent} is active, +% then it is simply an abbreviation for |\H{\mathrm{div}}|. +% +% \noindent +% Here are some examples:\\ +% \hfill \begin{tabular}{llcc} +% & & |DivInBrackets| & |DivAsExponent| \\ +% |\Hdiv| & $\Longrightarrow$ & $H(\mathrm{div};\Omega)$ & $H^{\mathrm{div}}(\Omega)$ \\ +% |\Hdiv0| & $\Longrightarrow$ & $H_0(\mathrm{div};\Omega)$ & $H^{\mathrm{div}}_0(\Omega)$ \\ +% |\Hdiv[\Gamma_D]| & $\Longrightarrow$ & $H_{\Gamma_D}(\mathrm{div};\Omega)$ & $H^{\mathrm{div}}_{\Gamma_D}(\Omega)$ +% \end{tabular} \hfill +% +% \subsection{The \texttt{L} command} +% The |\L| command is used to generate the symbol of +% Lebesgue-measurable functions. +% It has one argument which is the exponent of the L-space. +% Again, if this argument is a digit (or a single symbol, +% like ``|\infty|'') the surrounding braces are optional. +% Like for the |\H| command, the output of |\DefaultSet| is +% appended. +% +% \noindent +% Here are some examples: \hspace{2cm} +% \begin{tabular}{lll} +% |\L2| & $\Longrightarrow$ & $L^2(\Omega)$ \\ +% |\L{10}| & $\Longrightarrow$ & $L^{10}(\Omega)$ \\ +% |\L\infty| & $\Longrightarrow$ & $L^\infty(\Omega)$ +% \end{tabular} +% +% \subsection{The \texttt{W} command} +% The |\W| command is completly analogous, except that it +% prints a ``W'' insted af an ``L'' and that it has two +% argument, both printed as a supercript, separated by a comma. +% It is used for the generalized Sobolev spaces. +% +% \noindent +% Here is an example of how it is used: \hspace{1cm} +% \begin{tabular}{lll} +% |\W{k}{p}| & $\Longrightarrow$ & $W^{k,p}(\Omega)$ \\ +% |\W1\infty| & $\Longrightarrow$ & $W^{1,\infty}(\Omega)$ +% \end{tabular} +% +% \subsection{The \texttt{D} command} +% The |\D| command is used in the theory of distributions: +% it prints the space of distributions over the |\DefaultSet| +% if followed by a prime symbol, or its dual space, otherwise. +% \hfill \begin{tabular}{lll} +% |\D| & $\Longrightarrow$ & $\mathcal{D}(\Omega)$ \\ +% |\D'| & $\Longrightarrow$ & $\mathcal{D}'(\Omega)$ +% \end{tabular} \hfill +% +% \subsection{The \texttt{Norm} command} +% The |\Norm| command has a mandatory and an optional argument; +% it generates the norm of the mandatory argument, with the +% optional argument, if present, as a whole subscript, to +% denote the space within which the norm is taken. +% +% \noindent +% Some examples: \hspace{3cm} +% \begin{tabular}{lll} +% |\Norm{f(x)}| & $\Longrightarrow$ & $\left\|f(x)\right\|$ \\ +% |\Norm{g}[L^2]| & $\Longrightarrow$ & $\left\|g\right\|_{L^2}$ +% \end{tabular} +% +% \subsection{The \texttt{SemiNorm} command} +% The |\SemiNorm| command is completly analoguos, but +% generates the semi-norm instead of the norm. +% +% \noindent +% Some examples: \hspace{2cm} +% \DeleteShortVerb{\|} +% \MakeShortVerb{\!} +% \begin{tabular}{lll} +% !\SemiNorm{f(x)}! & $\Longrightarrow$ & $\left|f(x)\right|$ \\ +% !\SemiNorm{g}[H^1]! & $\Longrightarrow$ & $\left|g\right|_{H^1}$ +% \end{tabular} +% \DeleteShortVerb{\!} +% \MakeShortVerb{\|} +% +% \subsection{The \texttt{Scalar} command} +% The |\Scalar| command has two arguments; a third optional +% argument (which is used as a whole subscript) may follow +% inside square brackets. +% The output consists of the two arguments separated by a +% comma and enclosed in a pair of adjustable-size brackets, +% with the optional argument placed as a subscript (to denote +% the space inside which the scalr product is taken). +% +% \noindent +% Some examples: +% \begin{tabular}{lll} +% |\Scalar{f}{g}| &$\Longrightarrow$& $\left(f,g\right)$ \\ +% |\Scalar{u}{v}[L^2]| &$\Longrightarrow$& $\left(u,v\right)_{L^2}$\\ +% \end{tabular} +% +% \subsection{The \texttt{Crochet} command} +% The |\Crochet| command has two arguments; a third optional +% argument (which is used as a whole subscript) may follow +% inside square brackets. +% The output consists of the two arguments separated by a +% comma and enclosed in a pair of adjustable-size +% angular-parenthesys, with the optional argument placed as +% a subscript (to denote the space inside which the duality +% is taken). +% +% \noindent +% Some examples: +% \begin{tabular}{lll} +% |\Crochet{f}{g}| &$\Longrightarrow$& $\left\langle f,g\right\rangle$ \\ +% |\Crochet{u}{v}[D]| &$\Longrightarrow$& $\left\langle u,v\right\rangle_D$\\ +% \end{tabular} +% +% \StopEventually{} +% \newpage +% \section{Implementation} +% +% \begin{macrocode} +%% +\NeedsTeXFormat{LaTeX2e}[1995/12/01] +\ProvidesPackage{\FileName}[\filedate\space v\fileversion\space\filedescr] +% \end{macrocode} +% +% The options set the flag for the |\Hdiv| command. +% \begin{macrocode} +%% +\newif\if@DivAsExp +\DeclareOption{DivAsExponent}{\@DivAsExptrue} +\DeclareOption{DivInBrackets}{\@DivAsExpfalse} +%% +\ExecuteOptions{DivInBrackets} +% \end{macrocode} +% +% The ``|\ProcessOptions*|'' command was used here instead of +% ``|\ProcessOptions*|'' in order to process the options in the +% ``|\usepackage|'' order, rather than in the declaration order +% \begin{macrocode} +%% +\ProcessOptions* +% \end{macrocode} +% +% \begin{macro}{\DefaultSet} +% The command |\DefaultSet| makes |\@DefaultSet| to print the +% given argument enclosed in brackets. +% It also let |\@DefaultSet@Div| to be the same, but with the +% word ``div'' inside the brackets, before the argument. +% \begin{macrocode} +%% +\newcommand{\DefaultSet}[1]{\def\@DefaultSet{(#1)}% + \def\@DefaultSet@Div{(\mathrm{div};#1)}} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\NoDefaultSet} +% The command |\NoDefaultSet| deletes the content of the two macros +% |\@DefaultSet| and |\@DefaultSet@Div|, so that the first prints +% nothing, whilst the second only prints ``(div)''. +% \begin{macrocode} +\newcommand{\NoDefaultSet}{\let\@DefaultSet=\relax% + \def\@DefaultSet@Div{(\mathrm{div})}} +% \end{macrocode} +% +% \noindent +% Set the default value for |\DefualtSet| to be $\Omega$. +% \begin{macrocode} +%% +\DefaultSet{\Omega} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\DoNothing@zero} +% This command does nothing, but strips the character ``0'' (which +% \emph{must} immediately follow it, otherwise an error occour) +% from the input, since it is defined with a ``0'' attached to its +% name. +% \begin{macrocode} +%% +\def\DoNothing@zero0{\relax} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\H} +% The commands ``|\@HSobolev|< and``|\HSobolev@quadra|'' prints +% an ``H'' in math-mode (via the |\ensuremath| command) with the +% argument as a superscript, and, respectively, without subscripts +% and wiht the second argument as a subscript. +% Then they call |\@DefaultSet| in order to print the name of a set +% inside brackets, or nothing depending on which of the commands +% |\DefaultSet| and |\NoDefaultSet| has previously been invoked. +% \begin{macrocode} +%% +\newcommand{\@HSobolev}[1]{\ensuremath{H^{#1}\@DefaultSet}} +\def\HSobolev@quadra#1[#2]{\ensuremath{H^{#1}_{#2}\@DefaultSet}} +% \end{macrocode} +% The original command ``|\H|'' (used to make a type of accent) is +% saved in |\HAccent|; then |\H| is redefined so that it calls one +% of the previous two commands, depending on which character +% follows the command name. +% If this character is a ``0'', then it also invokes the command +% |\DoNothing@zero|, in order to strip that zero from the input. +% All this is deferred at the ``|\begin{document}|'' in order to +% avoid conflicts with other packages. +% \begin{macrocode} +\AtBeginDocument{% +\let\HAccent=\H +\renewcommand{\H}[1]{% +\@ifnextchar0{\HSobolev@quadra{#1}[0]\DoNothing@zero}{% +\@ifnextchar[{\HSobolev@quadra{#1}}{\@HSobolev{#1}}}% +}} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\Hdiv} +% The command |\@Hdiv@quadra| is used if the command |\Hdiv| is +% followed by a square bracket: it simply types ``H'' (in math mode) +% with a subscript. +% It also prints ``div'' (in roman) as an exponent and calls +% |\@DefaultSet| (with the ``DivAsExponent'' option) or calls +% |\@DefaultSet@Div| (with the ``DivInBraces'' option). +% \begin{macrocode} +%% +\def\@Hdiv@quadra[#1]{% +\if@DivAsExp \ensuremath{H^{\mathrm{div}}_{#1}\@DefaultSet}% +\else \ensuremath{H_{#1}\@DefaultSet@Div}\fi% +} +% \end{macrocode} +% The ``|\Hdiv|< command is defined so that it calls the previous command, +% or typesets the output itself, similarly to the |\H| command above. +% \begin{macrocode} +\newcommand{\Hdiv}{% +\@ifnextchar0{\@Hdiv@quadra[0]\DoNothing@zero}{\@ifnextchar[{\@Hdiv@quadra}{% +\if@DivAsExp \ensuremath{H^{\mathrm{div}}\@DefaultSet}% +\else \ensuremath{H\@DefaultSet@Div}\fi}}% +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\L} +% First the old command |\L| (which prints an ``L'' whith a bar +% superimposed) is saved in |\Lbar|. +% Then |\L| is redefined to print an ``L'' in math-mode with its +% argument as a superscript, followed by the output of |\@DefaultSet|. +% All this is deferred at the ``|\begin{document}|'' in order to +% avoid conflicts with other packages. +% \begin{macrocode} +%% +\AtBeginDocument{% +\let\Lbar=\L +\renewcommand{\L}[1]{\ensuremath{L^{#1}\@DefaultSet}}% +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\W} +% The command |\W| is defined to print a ``W'' in math-mode with its +% two arguments as a superscript (separated by a comma) and followed +% by the output of |\@DefaultSet|. +% It is deferred at the ``|\begin{document}|'' in order to +% avoid conflicts with other packages. +% \begin{macrocode} +%% +\AtBeginDocument{% +\newcommand\W[2]{\ensuremath{W^{#1,#2}\@DefaultSet}} +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\D} +% The command |\D| is defined to print a calligraphic ``D'' in +% math-mode, followed by the output of |\@DefaultSet|. +% In order to allow for the proper treatment of the \emph{prime} +% symbol which can follow the command, the command |\InsiemeD@Primo| +% is defined: it is authomatically invoked by the command |\D| when +% followed by a prime. It differs only in that a prime is output +% \emph{before} invoking |\@DefaultSet|. +% This is deferred at the ``|\begin{document}|'' in order to +% avoid conflicts with other packages. +% \begin{macrocode} +%% +\def\InsiemeD@Primo'{\ensuremath{\mathcal{D}'\@DefaultSet}} +\AtBeginDocument{% +\newcommand{\D}{\@ifnextchar'{\InsiemeD@Primo}{% +\ensuremath{\mathcal{D}\@DefaultSet}}% +}} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\Norm} +% The command |\Norm| prints its argument surrounded by a +% double-pipe delimiter of adjustable size. +% If an optional argument is present, it is used as a whole subscript. +% \begin{macrocode} +%% +\def\@Norma@Exp#1#2^#3{\ensuremath{\left\|#1\right\|_{#2}^{#3}}} +\def\@Norma#1[#2]{% +\@ifnextchar^{\@Norma@Exp{#1}{#2}}{\ensuremath{\left\|#1\right\|_{#2}}}% +} +\newcommand{\Norm}[1]{% +\@ifnextchar[{\@Norma{#1}}{\ensuremath{\left\|#1\right\|}}% +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\SemiNorm} +% The command |\SemiNorm| prints its argument surrounded by a +% single-pipe delimiter of adjustable size. +% If an optional argument is present, it is used as a whole subscript. +% \begin{macrocode} +%% +\def\@SemiNorma@Exp#1#2^#3{\ensuremath{\left|#1\right|_{#2}^{#3}}} +\def\@SemiNorma#1[#2]{% +\@ifnextchar^{\@SemiNorma@Exp{#1}{#2}}{\ensuremath{\left|#1\right|_{#2}}}% +} +\newcommand{\SemiNorm}[1]{% +\@ifnextchar[{\@SemiNorma{#1}}{\ensuremath{\left|#1\right|}}% +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\Scalar} +% The command |\Scalar| requires two arguments; a third optional +% argument (which is used as a whole subscript) may follow inside +% square brackets. +% The output consists of the two arguments separated by a comma and +% enclosed in a pair of adjustable-size brackets, with the optional +% argument placed as a subscript. +% \begin{macrocode} +%% +\def\@ProdottoScalare#1#2[#3]{\ensuremath{\left(#1,#2\right)_{#3}}} +\newcommand\Scalar[2]{% +\@ifnextchar[{\@ProdottoScalare{#1}{#2}}{\ensuremath{\left(#1,#2\right)}}% +} +% \end{macrocode} +% \end{macro} +% +% \begin{macro}{\Crochet} +% The command |\Crochet| requires two arguments; a third optional +% argument (which is used as a whole subscript) may follow inside +% square brackets. +% The output consists of the two arguments separated by a comma and +% enclosed in a pair of adjustable-size angular-parenthesys, with +% the optional argument placed as a subscript. +% \begin{macrocode} +%% +\def\Inner@Crochet#1#2[#3]{\ensuremath{\left\langle#1,#2\right\rangle_{#3}}} +\newcommand\Crochet[2]{% +\@ifnextchar[{\Inner@Crochet{#1}{#2}}{% +\ensuremath{\left\langle#1,#2\right\rangle}}% +} +% \end{macrocode} +% \end{macro} +% +% +% \CheckSum{179} +% \Finale +% +\endinput + diff --git a/macros/latex/contrib/bosisio/sobolev.html b/macros/latex/contrib/bosisio/sobolev.html new file mode 100644 index 0000000000..4161264afe --- /dev/null +++ b/macros/latex/contrib/bosisio/sobolev.html @@ -0,0 +1,317 @@ +<html> +<!-- ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +| Copyright(C) 1997-2010 by F. Bosisio | +| | +| This program can be redistributed and/or modified under | +| the terms 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 LaTeX distributions | +| version 2005/12/01 or later. | +| | +| This work has the LPPL maintenance status `maintained'. | +| The Current Maintainer of this work is F. Bosisio. | +| | +| This work consists of files sobolev.dtx and sobolev.html | +| and of the derived files sobolev.sty and sobolev.pdf. | +| | +| E-mail: fbosisio@bigfoot.com | +| CTAN location: macros/latex/contrib/bosisio/ | ++ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +--> +<head> + <title>Package sobolev</title> +</head> +<body> + +<h1 align="CENTER"> +Package <tt>sobolev</tt><br /> +<small> +This is version 2.2, last revised 1997/11/14; documentation date 2005/04/09. +</small> +</h1> + +<p align="CENTER"> +<strong> +Author: <i>F. Bosisio</i><br /> +<small> +E-mail: <a href="mailto:fbosisio@bigfoot.com"> + <tt>fbosisio@bigfoot.com</tt> + </a><br /> +CTAN location: <a href="http://mirror.ctan.org/macros/latex/contrib/bosisio"> + <tt>macros/latex/contrib/bosisio</tt> + </a> +</small> +</strong> +</p> + +<p align="LEFT"></p> + +<!------------------------------------------------------------------------> + +<h3>Abstract:</h3> +<div> +Documentation for the package <tt>sobolev</tt>. +</div> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2>Table of contents</h2> + +<ul> + <li><a href="#SECTION01">Introduction</a></li> + <li><a href="#SECTION02">The options</a></li> + <li><a href="#SECTION03">The commands</a> + <ul> + <li><a href="#SECTION03a">The <tt>\H</tt> command</a></li> + <li><a href="#SECTION03b">The <tt>\Hdiv</tt> command</a></li> + <li><a href="#SECTION03c">The <tt>\L</tt> command</a></li> + <li><a href="#SECTION03d">The <tt>\W</tt> command</a></li> + <li><a href="#SECTION03e">The <tt>\D</tt> command</a></li> + <li><a href="#SECTION03f">The <tt>\Norm</tt> command</a></li> + <li><a href="#SECTION03g">The <tt>\SemiNorm</tt> command</a></li> + <li><a href="#SECTION03h">The <tt>\Scalar</tt> command</a></li> + <li><a href="#SECTION03i">The <tt>\Crochet</tt> command</a></li> + </ul></li> +</ul> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<h2> +<a name="SECTION01">Introduction</a> +</h2> + +<p> +This package provides some commands which are useful when dealing with +Sobolev spaces and their relatives. + +<p> +In particular some commands are redefined, so care should be taken, +expecially when including this package in an already existent LaTeX file. + +<p> +The redefined commands are <tt>\H</tt> and <tt>\L</tt>. +The effect of ``<tt>\H</tt>'' (which is a type of accent) can now be achieved +by the command ``<tt>\HAccent</tt>'', whilst the job of ``<tt>\L</tt>'' +(i.e. print an ``L'' with a superimposed bar) is now done by the command +``<tt>\Lbar</tt>''. + +<h2> +<a name="SECTION02">The options</a> +</h2> + +<p> +Two options are available at the moment: <tt>DivInBrackets</tt> and +<tt>DivAsExponent</tt>. +They only affect the output of the ``<tt>\Hdiv</tt>'' command. + +<p> +The firt options (<tt>DivInBrackets</tt>, which is the default) makes +<tt>\Hdiv</tt> behave like ``<tt>H(div;</tt>...<tt>)</tt>'', while the +second one (<tt>DivAsExponent</tt>) makes <tt>\Hdiv</tt> expand to +``<tt>H^{div}(</tt>...<tt>)</tt>''. + +<h1> +<a name="SECTION03">The commands</a> +</h1> + +<p> +Most of the subsequent space-generating commands have mandatory arguments to +indicate the type of the space. +Often this argument consists of a single digit: in this case it is <em>not</em> +necessary to enclose it in brackets, since in LaTeX the names of commands +consists of letters only, and so a digit following it is certainly an argument. +This saves a lot of typing and is the only reason that makes these commans +useful (if you always had to type the brackets, then it would have been simpler +to type the expansion of the command than the command itself !). +In other words, you can think as if several commands exist (like <tt>\H</tt>, +<tt>\H1</tt>, <tt>\H10</tt>, etc.), the ones with the digit beeing a sort of +abbreviation for the general one. + +<h3> +<a name="SECTION03a">The <tt>\H</tt> command</a> +</h3> + +<p> +The <tt>\H</tt> command is used to generate the symbol of sobolev spaces. +It takes a mandatory argument, which is used as a superscript, and an optional +argument, which is used as a subscript. + +<p> +As explained above, if the mandatory argument is a digit, it need not be +enclosed in brackets. +Moreover, if the optional argument is the digit ``0'', it can be typed without +the square brackets. + +<p> +Here are some examples (whith the <tt>\DefaultSet</tt> set to its default +value <tt>\Omega</tt>): +<pre> + \H2 ==> H<sup>2</sup>(\Omega) + \H10 ==> H<sup>1</sup><sub>0</sub>(\Omega) + \H1[\Gamma_D] ==> H<sup>1</sup><sub>\Gamma<sub>D</sub></sub>(\Omega) + + \H^{-1/2} ==> H<sup>-1/2</sup>(\Omega) +</pre> + +<h3> +<a name="SECTION03b">The <tt>\Hdiv</tt> command</a> +</h3> + +<p> +The <tt>\Hdiv</tt> command is used to generate the sobolev space +called ``H div''. +It takes only an optional argument, which is used as a subscript and which +need not to be surrounded by the square brackets if it is the digit ``0''. + +<p> +If the (default) option <tt>DivInBrackets</tt> is in effect, it differs from +the command <tt>\H</tt> in that the word ``div'' is printed (in roman type) +inside brackets, before the set. +If, instead, the option <tt>DivAsExponent</tt> is active, then it is simply +an abbreviation for <tt>\Hdiv</tt>. + +<p> +Here are some examples: +<pre> + DivInBrackets DivAsExponent + \Hdiv ==> H(div;\Omega) H<sup>div</sup>(\Omega) + \Hdiv0 ==> H<sub>0</sub>(div;\Omega) H<sup>div</sup><sub>0</sub>(\Omega) + \Hdiv[\Gamma_D] ==> H<sub>\Gamma<sub>D</sub></sub>(div;\Omega) H<sup>div</sup><sub>\Gamma<sub>D</sub></sub>(\Omega) +</pre> + +<h3> +<a name="SECTION03c">The <tt>\L</tt> command</a> +</h3> + +<p> +The <tt>\L</tt> command is used to generate the symbol of Lebesgue-measurable +functions. +It has one argument which is the exponent of the L-space. +Again, if this argument is a digit (or a single symbol, +like ``<tt>\infty</tt>'') the surrounding braces are optional. +Like for the <tt>\H</tt> command, the output of <tt>\DefaultSet</tt> +is appended. + +<p> +Here are some examples: +<pre> + \L2 ==> L<sup>2</sup>(\Omega) + \L{10} ==> L<sup>10</sup>(\Omega) + \L\infty ==> L<sup>\infty</sup>(\Omega) +</pre> + +<h3> +<a name="SECTION03d">The <tt>\W</tt> command</a> +</h3> + +<p> +The <tt>\W</tt> command is completly analogous, except that it prints a ``W'' +insted af an ``L'' and that it has two argument, both printed as a supercript, +separated by a comma. +It is used for the generalized Sobolev spaces. + +<p> +Here is an example of how it is used: +<pre> + \W{k}{p} ==> W<sup>k,p</sup>(\Omega) + \W1\infty ==> W<sup>1,\infty</sup>(\Omega) +</pre> + +<h3> +<a name="SECTION03e">The <tt>\D</tt> command</a> +</h3> + +<p> +The <tt>\D</tt> command is used in the theory of distributions: +it prints the space of distributions over the <tt>\DefaultSet</tt> if +followed by a prime symbol, or its dual space, otherwise. +<pre> + \D ==> <i>D</i>(\Omega) + \D' ==> <i>D</i>'(\Omega) +</pre> + +<h3> +<a name="SECTION03f">The <tt>\Norm</tt> command</a> +</h3> + +<p> +The <tt>\Norm</tt> command has a mandatory and an optional argument; +it generates the norm of the mandatory argument, with the optional argument, +if present, as a whole subscript, to denote the space within which the norm +is taken. + +<p> +Some examples: +<pre> + \Norm{f(x)} ==> || f(x) || + \Norm{g}[L^2] ==> || g ||<sub>L<sup>2</sup></sub> +</pre> + +<h3> +<a name="SECTION03g">The <tt>\SemiNorm</tt> command</a> +</h3> + +<p> +The <tt>\SemiNorm</tt> command is completly analoguos, but generates the +semi-norm instead of the norm. + +<p> +Some examples: +<pre> + \SemiNorm{f(x)} ==> |f(x)| + \SemiNorm{g[H^1]} ==> |g|<sub>H<sup>1</sup></sub> +</pre> + +<h3> +<a name="SECTION03h">The <tt>\Scalar</tt> command</a> +</h3> + +<p> +The <tt>\Scalar</tt> command has two arguments; a third optional argument +(which is used as a whole subscript) may follow inside square brackets. +The output consists of the two arguments separated by a comma and enclosed +in a pair of adjustable-size brackets, with the optional argument placed as +a subscript (to denote the space inside which the scalr product is taken). + +<p> +Some examples: +<pre> + \Scalar{f}{g} ==> (f,g) + \Scalar{u}{v}[L^2] ==> (u,v)<sub>L<sup>2</sup></sub> +</pre> + +<h3> +<a name="SECTION03i">The <tt>\Crochet</tt> command</a> +</h3> + +<p> +The <tt>\Crochet</tt> command has two arguments; a third optional argument +(which is used as a whole subscript) may follow inside square brackets. +The output consists of the two arguments separated by a comma and enclosed +in a pair of adjustable-size angular-parenthesys, with the optional argument +placed as a subscript (to denote the space inside which the duality is taken). + +<p> +Some examples: +<pre> + \Crochet{f}{g} ==> <f,G> + \Crochet{u}{v}[D] ==> <u,v><sub>D</sub> +</pre> + +<hr /><br /> +<!------------------------------------------------------------------------> + +<address> + <i>F. Bosisio</i><br /> + E-mail: <a href="mailto:fbosisio@bigfoot.com"><tt>fbosisio@bigfoot.com</tt></a> +</address> + +<!------------------------------------------------------------------------> + +</body> +</html> diff --git a/macros/latex/contrib/bosisio/sobolev.pdf b/macros/latex/contrib/bosisio/sobolev.pdf Binary files differnew file mode 100644 index 0000000000..e1ce58ebb9 --- /dev/null +++ b/macros/latex/contrib/bosisio/sobolev.pdf |