summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/physics2/physics2.tex
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/physics2/physics2.tex')
-rw-r--r--macros/latex/contrib/physics2/physics2.tex30
1 files changed, 28 insertions, 2 deletions
diff --git a/macros/latex/contrib/physics2/physics2.tex b/macros/latex/contrib/physics2/physics2.tex
index c643ab72f9..02458f4cc0 100644
--- a/macros/latex/contrib/physics2/physics2.tex
+++ b/macros/latex/contrib/physics2/physics2.tex
@@ -169,6 +169,19 @@ Always remember, do not put an \cs{ab} separately at the end of math mode like
\verb|$\ab$|, because \cs{ab} will try to absorb the following math shift
character (\verb|$|) as its argument.
+\pardanger
+\textbf{Important Note:} The \modu{ab} module uses ``document commands''
+module of \LaTeXe{} kernel (source file: ltcmd.dtx). This \LaTeXe{} kernel
+module provides a document-level command parser. \cs{ab} is a complex
+encapsulation of some internal document-level commands. Take an example,
+if you define a document-level command like this:
+\begin{Verbatim}
+\NewDocumentCommand \foo { r() } {::#1::}
+\end{Verbatim}
+You can write \verb|\foo(bar)| legally, but \verb|\foo(()| will be regarded
+illegal when you write another document-level command or end the paragraph.
+Similarly, things like \verb|\ab(()| will also cause errors.
+
The \modu{ab} module also provides \texttt{\textbackslash}$X$\texttt{ab}
commands, where $X$ can be \opt{p}, \opt{b}, \opt{B}, \opt{a}, \opt{v} and
\opt{V}. These commands take a normal argument but not an argument delimited
@@ -266,6 +279,18 @@ is almost no such need). It is quite different from \verb|\mathrel{>}| or
\verb|\mathrel{<}| because in these commands' argument, \opt{>} and \opt{<}
will be redefined.
+\pardanger
+\textbf{Important Notes:} Commands provided by \modu{ab.braket} should NOT
+be placed barely in \meta{subformula} of \cs{ab}\texttt|\meta{subformula}\texttt|.
+Errors will arise if you write such code. To avoid the errors, you can write
+like this:
+\begin{example}
+\[
+ \ab| { \braket<\psi|\hat H|\psi> } |
+\]
+\end{example}
+Just add the braces.
+
Next, the \modu{braket} module will be introduced. Please notice that
\modu{braket} is conflict with \modu{ab.braket}, they cannot be used together.
@@ -338,7 +363,7 @@ be separated by commas. The \opt{empty} option is optional, with default value
\opt{0}. For example,
\begin{example}
\[
- \diagmat { 1, 2, 3 }
+ \diagmat { 1, \sqrt2, \sqrt[3]4 }
\]
\end{example}
\cs{pdiagmat}, \cs{bdiagmat}, \cs{Bdiagmat}, \cs{vdiagmat} and \cs{Vdiagmat}
@@ -570,6 +595,7 @@ redefine \cs{Re} and \cs{Im}. If you want to reserve the definition of
\subsection{The \modu{qtext.legacy} module}
This module was written just to offer a method to maintain documents written
with the legacy \pkg{physics} package. See \S\ref*{lega-subsec:qtext} of
-\href{./physics2-legacy.pdf}{physics2-legacy} for more information.
+\href{./physics2-legacy.pdf}{\texttt{texdoc physics2-legacy}} for
+more information.
\end{document} \ No newline at end of file