summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/glossaries-extra/sample-fmt.tex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2017-02-05 23:22:17 +0000
committerKarl Berry <karl@freefriends.org>2017-02-05 23:22:17 +0000
commit17efbb93c3c280ebec43438b10c53601758ef11e (patch)
treea113323608fcf1d4538b75835d3d28b8b6bae6be /Master/texmf-dist/doc/latex/glossaries-extra/sample-fmt.tex
parent9cb0c9d7ad125c5b287bfc285ebf1bf94749494a (diff)
glossaries-extra (4feb17)
git-svn-id: svn://tug.org/texlive/trunk@43152 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex/glossaries-extra/sample-fmt.tex')
-rw-r--r--Master/texmf-dist/doc/latex/glossaries-extra/sample-fmt.tex58
1 files changed, 58 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/glossaries-extra/sample-fmt.tex b/Master/texmf-dist/doc/latex/glossaries-extra/sample-fmt.tex
new file mode 100644
index 00000000000..2c96d8a1fb9
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/glossaries-extra/sample-fmt.tex
@@ -0,0 +1,58 @@
+% arara: pdflatex
+% arara: makeglossaries
+% arara: pdflatex
+\documentclass{article}
+
+\usepackage[T1]{fontenc}
+\usepackage{amsmath}
+\usepackage[colorlinks]{hyperref}
+\usepackage[postdot,style=index]{glossaries-extra}
+
+\makeglossaries
+
+\newcommand*{\mtx}[1]{\boldsymbol{#1}}
+\newcommand*{\mtxinv}[1]{\mtx{#1}\sp{-1}}
+
+\newglossaryentry{matrix}{%
+ name={matrix},
+ symbol={\ensuremath{\mtx{M}}},
+ plural={matrices},
+ user1={mtx},
+ description={rectangular array of values}
+}
+
+\newglossaryentry{identitymatrix}{%
+ name={identity matrix},
+ symbol={\ensuremath{\mtx{I}}},
+ plural={identity matrices},
+ description={a diagonal matrix with all diagonal elements equal to
+1 and all other elements equal to 0}
+}
+
+\newglossaryentry{matrixinv}{%
+ name={matrix inverse},
+ symbol={\ensuremath{\mtxinv{M}}},
+ user1={mtxinv},
+ description={a square \gls{matrix} such that
+ $\mtx{M}\mtxinv{M}=\glssymbol{identitymatrix}$}
+}
+
+\renewcommand{\GlsXtrFmtDefaultOptions}{hyper=false,noindex}
+
+\begin{document}
+A \gls{matrix} is denoted \glssymbol{matrix}.
+The inverse is denoted \glssymbol{matrixinv}.
+
+\newpage
+
+\[
+ \glsxtrfmt{matrix}{A}
+ \glsxtrfmt{matrixinv}{A}
+ =
+ \glssymbol{identitymatrix}
+\]
+
+\newpage
+
+\printglossaries
+\end{document}