# Tag Info

## Hot answers tagged mathtools

38

Had the same issue. For me it worked after I synchronized manually with the repository using the MikTeX Package Manager (Admin) tool and under the Repository menu using the synchronize. Then the issue is resolved and the mathtools package appears under the package list.

27

The problem is this: \Longrigtharrow (over which \implies is defined) is built with two characters that come from different fonts. The equals sign for lengthening the arrow is taken from \textfont0 (the normal text font), while the arrow (\Rightarrow) is taken from \textfont2 (the math symbol font). When a current font size is 10pt, lmodern defines \...

25

With the usual definition, \setlength{<parameter>}{<value>} is just a wrapper for <parameter>=<value>\relax so \setlength{\medmuskip}{0mu} is legal, because it translates to \medmuskip=0mu\relax which is perfectly legal, as \medmuskip should be assigned values only in mu units (also fil, fill or filll units for the plus and ...

25

First, I have to recall that \bf is a plain TeX macro. It is not bad practice to use it but it isn't needed anymore since \bfseries was intoduced with LaTeX and its syntax is exactly the same as for good old \bf. Second, don't change your markup! (by exploiting a search and replace routine). If you wrote \vec in your manuscript you did it because the ...

23


22


18

You have \nablaf which is probably undefined, I guess you wanted \nabla f (Please always post a complete document that generates the error, it is much easier to debug then)

18

The problem is that you're trying to use displaystyle limits in text mode. Which is not that good, as I explain below. I don't know if it's typographically correct but the code is $\sum\limits_{i=0}^n f(x)$ The \limits command allows the limits to be positioned above and below the symbol. The fact that inline math has "text style" limits is just that ...

17

You don't really need to use \mathclap, you can just place what you want to center in a box of the appropriate width. \documentclass{article} \usepackage{amsmath} \usepackage{calc} \newcommand*{\mask}[2]{% \mathord{\makebox[\widthof{$$#1$$}]{$$#2$$}}% } \begin{document} \begin{gather*} 1 + \mask{ABC}{B} + 2 \\ 1 + ABC + 2 \end{gather*} \end{...

15

The following example defines \xtwoheadrightarrow and \xtwoheadleftarrow similar to the definitions of \xrightarrow and \xleftarrow: \documentclass{article} \usepackage{amssymb} \usepackage{amsmath} \makeatletter \providecommand*{\twoheadrightarrowfill@}{% \arrowfill@\relbar\relbar\twoheadrightarrow } \providecommand*{\twoheadleftarrowfill@}{% \...

15


12

You could change meaning of \vec, but that would be very bad pratice. What I would do: Define new command with style like: \newcommand{\vectorstyle}[1]{\mathbf{#1}} Use Find and Replace feature of your text editor/IDE to replace \vec{ for \vectorstyle{ In the event of next chage, just replace the definiton of the \vectorstyle P.S. Do not use \bf. It's bad ...

12

The proper way of doing this would be to use a search-and-replace command in your text editor in connection with a custom macro, e.g. \myvec. However, if you insist on having a quick solution inside your document (which I discourage), you could add the following to your document's preamble: \let\oldvec=\vec \renewcommand{\vec}[1]{\oldvec{\mathbf{#1}}} If ...

12

multi-question questions don't really fit the site format but.. Do you think that it is Ok to recommend the mathtools package instead of amsmath package. The mathtools package calls the amsmath package and improves it as far as I understand. Yes What about the empheq package It's OK but more of a "contrib" package than mathtools which aims to be ...

12

Analysis Let's see what physics.sty does. First, the definition of \norm: \DeclareDocumentCommand\norm{ l m }{\braces#1{\lVert}{\rVert}{#2}} % Norm The l argument type collects everything up to (and excluding) the first {. Now let's look at \braces: \DeclareDocumentCommand\braces{}{{\ifnum\z@=`}\fi\@braces} I see no reason for this \ifnum; anyway, it ...

12

Encouraged by David Carlisle, I eventually resolved to post this answer. I had begun to write a comprehensive one that explained how the solution works, but I soon realized that it would have largely exceeded the 30000 character limit—indeed, only the code amounts to a total of more than 26000 bytes! Maybe I’ll post the explanations as a separate answer, ...

12


Only top voted, non community-wiki answers of a minimum length are eligible