New answers tagged

1

Do you looking for domething like thi: \documentclass{article} \usepackage{amsmath, amssymb} \begin{document} \begin{align} \mathrm{Var}(X + c) & = && \text{rel. 184 pag. 62} \\ & = && \text{proprietà 1 pag. 61} \end{align} \end{document}


1

Taking like an example the answer of @Philippe Goutet, where where I have made some small changes, considering also the answer of @Mico, you can define your B calligraphic letters: \documentclass[a4paper,12pt]{article} \usepackage{mathtools} \usepackage[cal=mt]{mathalfa} \DeclareSymbolFont{mathscrUC}{U}{rsfs}{m}{n} %%%% from the answer and http://ctan.epst-...


2

I suggest you load the mathalfa package with the options cal=mt and scr=kp. The former option assigns the Math Time Pro calligraphic font face to \mathcal -- note, though, that the mtpro2 package isn't free of charge -- and the KP fonts script font face to \mathscr. Do check out pp. 8 and 9 of the user guide of the mathalfa package for other possible choices ...


4

Smash, but keep the height of the lowercase letter and of the symbol you're typesetting. \newcommand{\lowoverline}[1]{% \overline{\smash{#1}\vphantom{x}}\vphantom{#1}% } Full example. \documentclass{article} \usepackage{amsmath} \newcommand{\lowoverline}[1]{% \overline{\smash{#1}\vphantom{x}}\vphantom{#1}% } \begin{document} \begin{equation*} \...


1

You can use \smash{b} to set the height of b to zero, and then \vphantom{a} to make something with zero width and the height of an a. \documentclass[12pt]{minimal} \newcommand{\ol}[1]{\overline{\smash{#1}\vphantom{a}}} \begin{document} $\overline{a} + \overline{b}$ $\ol{a} + \ol{b}$ \end{document}


3

By smashing things. In the following example, the argument b is vertically smashed (its height doesn't count). The \lowoverline gets its height from the optional argument, which defaults to a. This argument is horizontally smashed and made invisible by \phantom. \documentclass{article} \usepackage{mathtools} \newcommand\lowoverline[2][a]{\ensuremath\overline{...


4

The problem is that amsart loads amsfonts, which changes the definition of the wide accents. Use the noamsfonts option that disable loading the package, which is not needed anyway. \documentclass[noamsfonts]{amsart} \usepackage{kpfonts} \begin{document} \[\widetilde{bigtilde} \quad \widehat{bighat}\] \end{document} You'll have to live with an annoying ...


0

You could define a beweis environment which begins a tcolorbox and adds your QED symbol before it closes. \documentclass[a4paper, 11pt]{book} \usepackage{tcolorbox} \usepackage{lipsum} \usepackage{amsmath} \usepackage{amssymb} \usepackage{ragged2e} \newenvironment{beweis}[1] {% \tcolorbox[title=#1]% }% { \begin{FlushRight} $\...


0

Verbosus.com is also a good alternative like Overleaf


1

https://Mathcha.io Works well specially if they are no computer geek.


1

You can use this adaption of the code from @Bernard answer here. So credits to him. EDIT: Added the arrow \documentclass[11pt]{article} \usepackage[utf8]{inputenc} \usepackage{geometry} \usepackage{xcolor} \usepackage{array, booktabs} \parindent=0pt \pagestyle{empty} \usepackage{tikz} \usetikzlibrary{positioning,matrix, arrows.meta} \begin{document} \[ ...


0

You need an additional & to switch the alignment: \documentclass{article} \usepackage{amsmath} \begin{document} \begin{equation} \left.\begin{aligned} x &= y &&\text{in $a$}, \\ x' &= y' &&\text{in $a$, $b$}, \\ x'' &= y'' &&\text{in $a$, $b$, $c$}, \\ x''' &...


1

I have created a minimal working example (with a comma between the two matrices) to have the matrices on the same line in LaTeX. However I would to use a small matrix when you use $...$. \documentclass[a4paper,12pt]{article} \usepackage{amsmath,amssymb} \begin{document} Some $\begin{bmatrix} u_1 & u_2\\ u_3 & u_4 \end{bmatrix}, \begin{bmatrix}...


2

Please, always provide complete small document called MWE (Minimal Working Example) which reproduce your problem. your question is not entirely clear, so I guess, that you after the following: MWE: \documentclass{article} \usepackage{amsmath} \begin{document} \[ \begin{bmatrix} u_1 & u_2\\ u_3 & u_4 \end{bmatrix}% \begin{bmatrix} ...


4

You can use a low level alignment tool. \documentclass{article} \usepackage{amsmath,amssymb} \makeatletter \DeclareRobustCommand{\bumpeqplus}{\mathrel{\mathpalette\bumpeq@{+}}} \newcommand{\bumpeq@}[2]{% \vtop{\offinterlineskip \ialign{\hfil##\hfil\cr $\m@th#1\bumpeq$\cr % top \noalign{\sbox\z@{$\m@th#1\mkern2mu$}\kern-\wd\z@} $\m@th\...


2

There is $ around \pm missing. See the following corrected MWE: \documentclass{article} \usepackage{geometry} \geometry{ a4paper, total={150mm,247mm}, left=30mm, top=30mm, } \usepackage{imakeidx} \usepackage{listings} \usepackage{graphicx} \usepackage{float} \begin{document} \begin{table}[ht] \centering \caption{Stellar parameters of G 160-62} \label{...


2

It always helps to provide a complete test document not fragments: \documentclass{article} \usepackage{geometry} \usepackage{geometry} \geometry{ a4paper, total={150mm,247mm}, left=30mm, top=30mm, } \usepackage{imakeidx} \usepackage{listings} \usepackage{graphicx} \usepackage{float} \begin{document} \begin{table}[ht] \centering \caption{Stellar ...


2

Optional arguments aren't quite the same as mandatory ones. They start with a [, and they are delimited by the next ] (that's important). When you do \Cop[\G[H]] % 1 2 34 \Cop is processed first, and its optional argument starts with the first [ (1), and is delimited by the next ] (3), so its argument is what's between [ (1) and ] (3), that is, \G[H. ...


8

Maybe something like \documentclass{article} \usepackage{amsmath} \usepackage{graphicx} \makeatletter \newcommand{\xnrightarrow}[2][]{% \mathrel{% \vphantom{\xrightarrow[#1]{#2}}% \ooalign{\hidewidth\neg@arrow\hidewidth\cr$\m@th\xrightarrow[#1]{#2}$\cr}% }% } \newcommand{\neg@arrow}{% $\m@th\vcenter{\hbox{% \rotatebox[origin=c]{-45}{\...


2

The group is essentially forcing an extra math node wrapper which is acting like a box and will affect positioning in various ways, arguably not for the better. For example it avoids a double superscript error by moving the superscript to the outer node but it also does the same for a subscript which would have been placed (and kerned) on the inner character ...


4

Maybe \substack is an option for you: \documentclass{article} \usepackage{amsmath} \usepackage{mathtools} \usepackage{amssymb} \begin{document} \[ \substack{Hello\\\nrightarrow} \] \end{document}


2

The align environment is defined by the amsmath package that you have not loaded.


2

Here are two possible solutions, the first with and the second without the large parentheses. Speaking for myself, I'd prefer the second solution, as the large parentheses are not needed to begin with. Your readers will likely appreciate your efforts to reduce visual clutter. \documentclass{article} \usepackage{mathtools} % for '\DeclarePairedDelimiter' ...


2

\implies has an explicit \; in its definition which adds a muskip length which is incompatible with standard skip (length) commands. You can hide that with an extra set of braces \documentclass{beamer} \begin{document} \begin{frame} $\alert<1>{{\implies}}$ %% \alert<1>{$\implies$} % Works! %% $\alert<1>{\Longrightarrow}$ % ...


4

Here is a TikZ solution similar to @Vincent's but with somewhat simplified TikZ code and slightly improved horizontal spacing. The command usage is \mathcircled[<style>]{<limit>}{<circled math>}. The optional argument has default \displaystyle. \[\lim_{x\to\infty} \frac{\sin x}{x}= \mathcircled{0}{\frac{\sin x}{x}}=1\] If your circled ...


6

I propose a solution with pstricks: \documentclass[svgnames]{article} \usepackage{amsmath} \usepackage{pst-node, pst-arrow} \begin{document} \[\lim_{x\to\infty} \frac{\sin x}{x}= \circlenode[linewidth=0.6pt, linecolor=Tomato, framesep=0pt]{A}{\frac{\sin x}{x}}=1 \uput{32pt}[ur](A){\Rnode{B}{1}} \ncline[linecolor=Tomato, arrowinset=0, arrowscale=...


6

This seems to be close to what you're looking for. It doesn't look that good in a fraction, but I don't really see how such a construction could really look better in this context. \documentclass{article} \usepackage{amsmath} \usepackage{tikz} \usetikzlibrary{arrows.meta} \newcommand\mathcircled[3][\displaystyle]{% \mathord{% \begin{tikzpicture}[...


1

\documentclass{article} \usepackage{amsmath} \usepackage{tikz} \usetikzlibrary{arrows.meta} \makeatletter \newcommand\mathcircled[1]{% \mathpalette\@mathcircled{#1}% } \newcommand\@mathcircled[2]{% \tikz[baseline=(math.base)] {\node[draw,circle,inner sep=1pt] (math) {$\m@th#1#2$}; \draw[-{Triangle[open]}] (math.north east) -- +(0.3,0.3)}% } \makeatother \...


3

I would avoid a math alphabet for this. \documentclass{article} \usepackage{lmodern} \usepackage{amsmath} \usepackage{fixcmex} \usepackage{microtype} \DeclareFontFamily{U}{BOONDOX-calo}{\skewchar\font=45 } \DeclareFontShape{U}{BOONDOX-calo}{m}{n}{ <-> s*[1.05] BOONDOX-r-calo}{} \DeclareFontShape{U}{BOONDOX-calo}{b}{n}{ <-> s*[1.05] BOONDOX-b-...


3

I would replace \usepackage{mathrsfs} \usepackage{bbold} \usepackage{dsfont} \usepackage{amsfonts} with \usepackage[bb=esstix, scr=rsfs, cal=euler]{mathalfa} The mathalfa package (the spelling "mathalpha" is ok too...) provides a very nice interface for choosing from lots and lots of blackboard-bold, fraktur, calligraphic, and script math fonts. ...


4

It only has to do with the particular blackboard bold font (that used with \mathbb) you're using. In your MWE, the package bbold defines the blackboard bold font and the S you're seeing comes from this font. To change the font, simply change the package that loads it. I especially like to use mathalpha, because it allows to choose easily between many ...


1

There are several ways, choose the one you prefer. \documentclass{article} \usepackage{amsmath} \renewcommand{\arraystretch}{1.5} % just to make the lines spread out \begin{document} \begin{tabular}{lll} \verb|$a\equiv b \pmod{n}$| & $a\equiv b \pmod{n}$ \\ \verb|$a\equiv b \mod{n}$| & $a\equiv b \mod{n}$ \\ \verb|$a\equiv b \pod{n}$| & $a\...


1

I gather that \sol isn't the name of a LaTeX macro but, rather, a shorthand expression for a longer, possibly multi-row, derivation of some mathematical result involving the partial derivative(s) of a function f(x,y). Assuming that the solution for f_x(x,y) fits in an otherwise invisible box whose width is less than 0.5\textwidth, I can think of (at least) ...


3

Short code, without use of any library: \documentclass[margin=3.141592]{standalone} \usepackage{tikz} \begin{document} \begin{tikzpicture} \draw[fill=cyan!30] (0,0) -- coordinate (a) ++ (+60:5) -- coordinate (b) ++ (-60:5) -- coordinate (c) cycle; \draw[red] (a) -- (b) -- (c) -- cycle; \end{tikzpicture} \end{document}


2

How about this? \documentclass[tikz,border=5mm]{standalone} \begin{document} \begin{tikzpicture} \def\mytriangle{(90:1)--(210:1)--(-30:1)--cycle} \draw[fill=yellow!50] \mytriangle; \draw[yscale=-1,scale=.5] \mytriangle; \end{tikzpicture} \end{document} PS: Long time ago, we made a tutorial on drawing equilateral triangle with TikZ. There are several ...


1

It's not very difficult with tikz, in two lines. A reading of the first part of the manual is enough to draw much more complex diagrams. \documentclass[crop=true]{standalone} \usepackage{tikz} \usetikzlibrary{intersections} \usetikzlibrary{positioning,calc} \begin{document} \centering \begin{tikzpicture} \draw (0,0) coordinate(O) -- ++ (60:5) coordinate(A) ...


1

New Solution I defined a command \mathquote{...} that inserts quotation marks depending on the vertical size of its content. Code \documentclass{article} \usepackage{amsmath} \newlength{\mqheight} \newlength{\mqnormalheight} \settoheight{\mqnormalheight}{\hbox{gM}}% \newcommand{\mathquote}[1]{% \settoheight{\mqheight}{\hbox{\ensuremath{#1}}}% \...


1

align is centred by default, if you want flush left displays use [fleqn] (and set \mathindent to zero)


3

With use of the new LaTeX-3 package tabularray, siunitx for S column type (invoked by option si={...}) and slightly redesigned table lines. By defining new child selector are drawn each second \hline in table body and reduced rowsep: \documentclass{article} \usepackage{tabularray} \UseTblrLibrary{diagbox, siunitx} \usepackage[skip=1ex, font=...


4

Add another row with the pm values and decrease the space between the last two rows. \documentclass[sigconf,natbib=false]{acmart} \usepackage{diagbox} \usepackage{multirow} \title{Test} \author{Michael Sidorov} \date{S\today} \begin{document} \begin{table*} \centering \renewcommand{\arraystretch}{1.2} \begin{tabular}{|c||*{3}{l|}} ...


4

\usepackage{makecell} is your friend: \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{hhline} \usepackage{multirow} \usepackage{diagbox} \usepackage{makecell} \begin{document} \begin{table*} \centering \renewcommand{\arraystretch}{1.2} \begin{tabular}{|l||*{3}{c|}} \hline \backslashbox{\textbf{Model}}{\textbf{Data Set}} & ...


8

From my comment...here there is the solution. \documentclass[12pt]{article} \usepackage{amsmath,amssymb} \begin{document} \begin{equation} \begin{split} \frac{\partial W}{\partial x} &= 0,1 - 2 \lambda \sigma_x^2 x - 2\lambda\sigma_x\sigma_y\rho_{xy}y - \mu = 0\\ \frac{\partial W}{\partial y}& = 0,5 - 2 \lambda \sigma_y^2 y - 2\lambda\sigma_x\...


1

To eliminate the extra vertical space in both uses of fullwidth, it is necessary to define a new environment --similar to fullwidth-- to be be used when align* is included. Of course, if you want to simulate the behavior when fullwidth is not used, use it only the first time (same paragraph). \documentclass{caesar_book} \newenvironment{fullwidthx} % ...


3

The package mathptmx provides Times-like fonts, but it's a 35-year-old hack and for Greek letter it uses glyph from the slanted Symbol font. You get better results with NewTX. \documentclass[12pt]{report} \usepackage[T1]{fontenc} \usepackage[ngerman]{babel} \usepackage[a4paper,width=150mm,top=25mm,bottom=25mm,bindingoffset=6mm]{geometry} \usepackage{...


6

Following a request in the comments, I provide an expl3 solution based on splitting a comma list. \documentclass{article} \ExplSyntaxOn \NewDocumentCommand{\widecomma}{ m }{ \clist_use:nn { #1 } { {,}\ } % since ~ means space in expl3 } \ExplSyntaxOff \begin{document} \( \widecomma{a, b, c} \) \end{document} EDIT: I guess one could use \def, \...


0

Since this is a problem which is annoying me every time, let me put my two cents in. A solution which may not be that elegant, but that I like for its outcome, is to use a \phantom command to make all the other = signs as large and as high as the incriminated one, as in the following \begin{align*} S_n & \stackrel{\phantom{\mathrm{IH}}}{=} 2^iS_{n-i}+2^i-...


9

It's a bit more complicated than your attempt. Better to make the character math active rather than active tout court, so no category code is changed and \widecomma can also be used in the argument to another command. The instruction \let\comma=, doesn't work, mainly because you want to save the math code of the comma. \documentclass{article} % save the ...


3

The # has a special meaning in LaTeX (since it's used in macro definitions to stand for the arguments as #1, #2, etc.) therefore it can't be used directly as a character. If you want a literal #, you have to add a backslash (\#): \documentclass{scrartcl} \begin{document} $a = \# + 2$ \end{document} Independently of that, surrounding your sources with $ ...


1

Not an answer. I was wondering if you could cut and paste from one PDF into another. Alas, no. You lose a lot of details in the process. \documentclass{article} \usepackage{eforms} \newsavebox{\tempbox} \begin{document} This is a test to see if I can cut and paste ( $\sqrt{\alpha^2}$ ) into \textField{test}{1in}{1.5\baselineskip}. In fact, you can't ...


9

Do you want to stack the objects? In this case a version of \atop can do it (using \genfrac, of course). The trick is to force \textstyle when the object is found in \displaystyle, otherwise the standard action is good. \documentclass{article} \usepackage{amsmath} \makeatletter \newcommand{\stk}[2]{\mathinner{\!\mathpalette\stk@{{#1}{#2}}\!}} \newcommand{\...


Top 50 recent answers are included