Questions tagged [mathtools]

{mathtools} is an extension package to amsmath. It provides bugfixes and adds useful tools for mathematical typesetting.

Filter by
Sorted by
Tagged with
0
votes
0answers
38 views

A program for quick and easy typesetting of formulas in latex

Is there an additional toolbox for a simpler set of formulas in latex? After all, it is difficult and not visual to type this using symbols. Also interested in the same for creating tables. It ...
2
votes
1answer
48 views

Mathtools package cramped command

Within the mathtools package, \cramped is defined as follows. \providecommand*\cramped[1][\@empty]{ \ifx\@empty#1\@empty \expandafter \mathpalette \expandafter \MT_cramped_internal:Nn \else ...
1
vote
1answer
31 views

flalign in algorithm

This question is a bit related to the answer provided here: How can I use an align environment flush left? I use algorithm2e and mathtools to write an algorithm with an equation inside. I want it to ...
2
votes
1answer
45 views

How to get the same size for all the characters in an equation?

I need to have the same size for all characters inside an equation. I did some research and i found a solution using align* instead of equation but in my case it doesn't work, I need to use equation. ...
2
votes
2answers
30 views

Big floor brackets size around fraction with small denominator

i'm having issues with bracket formatting around fractions. For example, this code : \documentclass{article} \usepackage{mathtools} \DeclarePairedDelimiter\floor{\lfloor}{\rfloor} \begin{document} ...
2
votes
2answers
78 views

How to be consistent with delimiters in mathtools

I'm trying to create a few commands to handle conditional probabilities. So far I am using the mathtools DeclarePairedDelimiter family of commands. Also, as far as I am aware, mathtools does not allow ...
4
votes
2answers
111 views

Vertical Spacing Before and After “Cases” Environment

I'm using TexShop on macOS and I'm hoping someone could tell me how to increase the spacing before and after the cases environment as below: \documentclass[12pt,a4paper,reqno]{amsart} \usepackage{...
3
votes
1answer
41 views

Added whitespace when putting brackets around fractions with splitfrac

I'm using splitfrac from mathtools to break up a particularly long line in the numerator of a fraction. When I put brackets around the fraction, however, they leave a line of whitespace in the ...
0
votes
0answers
33 views

Adjusting bar length of dbar

I am trying to recreate the following symbols. At first I tried the \dbar command below, but it didn't seem like it was the right length and thickness. How can I adjust those parameters? Possibly a ...
4
votes
2answers
85 views

tex4ht gives \catcode`\^^ error when loading mathtools

I do not know if this is new error, caused by latest TL update. But this is first time I see it. This MWE compiles with no problem with lualatex, but gives (/usr/local/texlive/2020/texmf-dist/tex/...
3
votes
1answer
34 views

Adding Binary Overflow Character

How would I show a 1 carry over an empty space? Such as this; Currently I have this as code; \usepackage{array,mathtools} \newcommand*{\carry}[1][1]{\overset{#1}} \newcolumntype{B}[1]{r*{#1}{@{\,}r}} ...
3
votes
2answers
124 views

\cramped in fraction denominator doesn’t line up with regular fraction

In a display, the denominator of a fraction is set in “cramped” \textstyle, which can be emulated with \cramped[\textstyle]{...} from the mathtools package. But sometimes the emulation is perfect, ...
0
votes
0answers
58 views

cannot compile matrix to pdf

I have a problem knitting my rmd to pdf. I have tried copying the code that works for others from this forum but it is not working for me. I keep receiving: !LaTeX Error: Can be used only in preamble. ...
4
votes
1answer
57 views

Underbracket and overbracket intersecting each other

I cannot seem to find a way to achieve the result I want which is best portrayed by this sketch diagram: This is because if I add an overbracket it is closed by the underbracket } before it gets to ...
4
votes
3answers
63 views

Aligning several \begin{bmatrix*} to have same “column width”

I have 4 \begin{bmatrix} matrices. Because the matrix values are different the overall 4x4 matrices have different column widths. Is there a way to align them so that all columns have the same width ...
0
votes
0answers
53 views

How to print a symbol for a code (in coding theory) in Latex

I am trying to generate a symbol for a code in coding theory in Latex. I tried \mathcal{C}, but it did not give me the expected output. Can Anyone give me some command or Latex packages I can use? PD: ...
4
votes
1answer
102 views

Suppress warning by unicode-math regarding mathtools

When using the packages unicode-math and mathtools, I always get warnings Package unicode-math Warning: Using \overbracket and \underbracket from (unicode-math) `mathtools' package. (...
2
votes
0answers
41 views

drcases of mathtools package

Considered my little ability in English I would like to know what is the use of drcases and what are the advantages or disadvantages of this command. \begin{drcases} 〈math_column〉 & 〈math_column〉 \...
1
vote
1answer
31 views

\boxed math expression makes font too large when used in nested fractions or exponents [duplicate]

Using the \boxed environment in mathtools seems to ignore the default size considerations LaTeX makes with nested fractions: \[ \frac{\frac{1}{2}}{\boxed{\frac{1}{2}}} \] I would like the \boxed 1/2 ...
2
votes
3answers
201 views

Why does a left curly brace impact the flalign alignment?

I've a pretty long text commenting several sets of short equations. This leads me to some presentation constraints that I'd like to better handle: flush the equation sets to the left (short text in ...
3
votes
1answer
66 views

Define semantic size for \DeclarePairedDelimiter

To better separate content and presentation, how can I define semantic sizes for the optional sizing argument to \DeclarePairedDelimiter? Here are two attempts to define "bulkysize" as \Big: ...
1
vote
1answer
27 views

mathools with lineno

The following MWE \documentclass{article} \usepackage{lineno,lipsum} \usepackage{mathtools} % commenting this resolves the issue \linenumbers \begin{document} \lipsum[1] \lipsum[2] \[A=B\] \...
4
votes
3answers
122 views

smashoperator seems to break beamer transparency

I am using beamer and smashoperator as follows: \documentclass[xcolor={rgb}]{beamer} \setbeamercovered{transparent} \beamertemplatenavigationsymbolsempty \setbeamersize{text margin left=10mm,text ...
3
votes
1answer
42 views

Align a box in the formula

The following code provides this result: I would like to get a small "{" fitting the text and not the upper and down box. Any idea? \documentclass[preview]{standalone} \usepackage{...
6
votes
1answer
146 views

Adjusting the vertical position of the limits of a sum

Is there a way to vertically adjust the lower limits of the two sums below, such that 'p' and 'q' are vertically aligned? \sum_{p=1}^{\mathcal{M}}\sum_{q\in\mathfrak{N}_p^+} EDIT: As per egreg's ...
1
vote
1answer
25 views

How to nest alignments while give subnested equations independent numbering?

I am trying to get alignment environments to be nested appropriately inside each other. We see Eq. 2 (using aligned) nested sucessfully inside alignat. Two shortcomings arise due to this such ...
3
votes
0answers
37 views

Spacing in mathastext package

I have this MWE, using mathastext package. \documentclass[12pt]{article} \usepackage[T1]{fontenc} \usepackage{mathtools} \usepackage{newtxtext} \usepackage[italic,defaultmathsizes,symbolgreek]{...
8
votes
2answers
568 views

How to make underbracket thinner

Consider this code, \documentclass{article} \usepackage{mathtools} \begin{document} \[ C(s)=\underbracket{\frac{K_1}{s}}_{\text{forced}}+\underbracket{\frac{K_2}{s+2}+\frac{K_3}{s+4}+\frac{K_4}{s+5}}_{...
9
votes
1answer
779 views

What is the difference between \\* and \\ *?

I used a * in a bsmallmatrix and found a curious effect. If I write \\* the * is not printed whereas with \\ * it is. Do you guys know why this happens? My tiny example and screenshot follow below: \...
0
votes
3answers
85 views

How can I prevent \mathclap from quadrupling \stepcounter

When I want to iterate a counter using \stepcounter inside \mathllap , \mathclap or \mathrlap the counter iterates by 4 instead of by 1. E.g, the following MWE \documentclass{article} \usepackage{...
0
votes
1answer
45 views

Derivative package: does it include square brackets with comment?

This question is only an information on the derivative package. Just a curiosity does it include square brackets (see the green arrows) where is it possibile to put a comment (see pag. 26 of the .pdf ...
3
votes
1answer
41 views

Refinement of nested cases / aligned equations

For the following two approaches or sets of equations, I would like to 1- (in the first set) make the first for align with the two fors below 2- (in the second set) keep the font and interspaces the ...
1
vote
1answer
58 views

Why math equation creates error in document?

In my latex document as long as I use this formula, it throws tons of unrelated errors which is working without the formula. Although it is creating a formula on the document, but the problem is, ...
2
votes
3answers
153 views

Editing a tabular:

So I have been working on an article about integration and its techniques, and at the ending I decided to add a tabular contains the most frequently functions and its antiderivatives, but the problem ...
0
votes
1answer
42 views

Mathtools and Tikz are incompatible because of colon

I tried to use tikz and https://tex.stackexchange.com/a/270007/161413 to color arrows with several colors. But I was also using mathtools, and found out that tikz and mathtools are not compatible as ...
4
votes
3answers
325 views

Matrix in double-struck square bracket style

We can use \llbracket \rrbracket using the \usepackage{stmaryrd} to generate double bracket. My question is: how we can generate a matrix with double bracket (in the same style as the \llbracket \...
2
votes
1answer
246 views

Double-struck parentheses

We can use \llbracket and \rrbracket (provided by the stmaryrd package) to generate double brackets. My questions are: how we can generate double-struck parentheses in the same style as the single-...
4
votes
0answers
204 views

Underbraces are ruined by mathtools (and maybe unicode-math?). How do I keep both?

In writing my thesis (using XeLaTeX) I use multiple math-related packages, all for different reasons. Since introducing unicode-math and mathtools, the underbraces I applied earlier are ruined. I ...
2
votes
2answers
123 views

ddot and hline problem

I am new to latex. Readability of the below equation is not good enough because of \hline and \ddot how may I fix it? \begin{equation}\label{eq2} \underbrace{\left[ \begin{array}{c} \ddot{x_{cp}} \\ \...
1
vote
0answers
58 views

eqref - showonlyrefs

I have equations and I want to reference some of them. Also, I would like to number only the equations that I reference. For some reason when I use \mathtoolsset{showonlyrefs=true} - nothing works and ...
1
vote
2answers
47 views

Right alignment in flalign environment

I'm compiling a list of math exercises with solutions: I would like to left-align the exercise numbers and to right-align the results. I have tried the flalign* environment, but it doesn't work well. ...
0
votes
1answer
40 views

Why is my math equation font style appearing different than normal?

Hello I am trying to write a simple limit here within brackets using this line, $(-\pi, \pi)$, But I want to get styling like this, I am not sure where I have made mistake or do I need to use a ...
6
votes
2answers
556 views

How to make text appear in the middle of a phantom in math mode?

I want to make a part of an equation to appear in the center of a (horizontal) phantom. This would be awesome for example for making bra-kets that are all of the same width and still look natural. ...
0
votes
2answers
49 views

Restoring missing space before large parentheses in `newtxmath`?

As shown by the difference between the two lines of the image below, for sufficiently large pairs of parentheses in newtxmath, the space in front of the left parenthesis disappears. This results in ...
3
votes
2answers
171 views

“Missing $ inserted” error when using “cases” inside an equation environment

I have the following piece of latex code \begin{equation*} G(z,w) = \begin{cases*} \frac{\rho (g_{\bar{\lambda}}(z),g_{\bar{\lambda}}(w))}{\rho (z,w)} & for z \neq w \\ |f'|_{\...
0
votes
1answer
546 views

Environment bmatrix undefined. \begin{bmatrix} in Latex

I've been using this thisspringer format latex document and wanted to add a matrix in the paper and I've been bumping into this error for a while now. \documentclass[a4paper]{article} \usepackage{...
1
vote
3answers
54 views

subscripted matrices operation

I need to manage how to work with several matrices in line, each one with its own left and right subscripts (like in the image). \prescript suited me for a single matrix, but didn't work with 2 ...
2
votes
2answers
59 views

Aligning and line-breaking a set of long equations in both single- and two-column modes with proportional vertical spacing

For the following set of long equations, how to 1- aesthetically align and line-break them in a single- and two-column modes without crossing the single column dedicated space and 2- separately ...
0
votes
1answer
38 views

How to properly halve the inter-line distance in a math block environment

... of amsmath or mathtools? In other words, how to properly halve \jot? Options: \setlength{\jot}{.5\jot\relax} \setlength{\jot}{\dimexpr.5\jot\relax} \setlength{\jot}{\dimexpr\jot*.5\relax} \...
1
vote
1answer
27 views

repair bad vertical spacing of underbrace label when using newtxtext, newtxmath, and mathtools

Feeding \documentclass{article} \pagestyle{empty} \usepackage{newtxtext,newtxmath} \usepackage{mathtools} \begin{document} For an arbitrary $n\in M^B$ we have $\varphi_M(\underbrace{\langle 0\rangle ...

1
2 3 4 5
9