New answers tagged

0 votes

Independent format and position inside another command

Defined a new 5-argument command (some could be empty) \cveventv{<role>}{<sub role>}{<company came>}{<date interval>}{<location>} Using \newcommand{\fmtRole}{<font and ...
  • 30.2k
0 votes
Accepted

Continuing Alignment After Text

I suppose that this is what you are after: \documentclass{report} \usepackage{amsmath} \usepackage{amsfonts} \begin{document} \begin{align*} \mathbb{E}X &= \sum_{k=0}^\infty k\mathbb{P}(k)\\ &=...
0 votes

How to left align \title on general page?

\title{\flushleft\Huge My Sample Title \endgraf\rule{\textwidth}{1pt}} You can simply use the \flushleft as shown above.
0 votes
Accepted

\dot horizontal alignment with amsmath

This works fine: \documentclass{article} \usepackage{amsmath} \let\olddot\dot \gdef\dot{\expandafter\olddot} \begin{document} \def\ab{a_b} $$\dot a_b$$ $$\dot\ab$$ $$\dot{\ab}$$ \end{document}
  • 1,001
1 vote
Accepted

How to center this picture?

Just omit the \rlap and \llap wrappers. Of course, this only works if there’s enough space between the two \Longstack objects —- which, happily is the case for the document at hand. \documentclass[...
  • 449k
1 vote
Accepted

Problem with cell content centering in longtable

Welcome to TeX.SE! The first column should be slightly wider then the rest two, that contents can be proper centered If you convert table code to tabularray table and use siunitx package for units in ...
  • 261k
1 vote

How to write multiple lines of text in math mode and keep them centered?

The answer I came up with (while Clara was posting) is similar to Clara's, but with regular tabular's and @{}'s to eliminate extra padding on the sides of the tabular. \documentclass{article} \begin{...
  • 38.6k
1 vote

How to write multiple lines of text in math mode and keep them centered?

\documentclass{article} \usepackage{tabularray} \usepackage{amsmath} \begin{document} \section{array} \begin{equation} \left\{ \begin{array}{@{\hskip2pt}c@{\hskip2pt}} \text{morphisms from } V \...
  • 1,567
0 votes

Title not centered on titlepage beamer

You can shift the content of your title page by .5\beamersidebarwidth: \documentclass{beamer} \usepackage{textpos} % package for the positioning \usepackage{graphicx} \usepackage{tikz} \usetikzlibrary{...
1 vote

Horizontally centering beamer columns with custom totalwidth

You could redefine the totalwidth key like this: \documentclass{beamer} \makeatletter \define@key{beamer@col}{totalwidth}{% \def\beamer@colentrycode{\hfill\hbox to#1\bgroup\ignorespaces}% \def\...
1 vote
Accepted

Left margin is unexpectedly reduced

the center environment is working, but the width of the algorithm is equal to the width of the text, so you don't see any difference. If you decrease the width of the algorithm, you will see the ...
2 votes

Set position of equation for cases

We have to set markers in front of the first line and in front of \begin{dcases}. \documentclass{article} \usepackage{mathtools} \begin{document} \begin{align} \begin{split} &f=(1+1+1+1)\\ &\...
  • 231
4 votes
Accepted

Set position of equation for cases

Is it something like this you want? I removed the split environment and used aligned nested in equation, specifying the alignment points: \documentclass{article} \usepackage{mathtools} \...
  • 264k
0 votes
Accepted

How to align multiple pgfplots vertically and horizontally in multiple columns?

If you want a tabulated data, use tabular environment instead of a mix of multicol and enumerate. I changed the scale of all pictures to 0.8 to fit all graphs in the grid and left font size as default....
  • 3,137
1 vote

How to left align comments in algpseudocode?

You can measure the comments on the first run and save the widest in the aux file. At the next run, the comments will be typeset in a box of the desired width. \documentclass{article} \usepackage{...
  • 1.0m
1 vote

How to left align comments in algpseudocode?

\documentclass{article} \usepackage{algorithm} \usepackage{algpseudocode} \newlength{\commentlen} \begin{document} \begin{algorithm} \caption{Euclid’s algorithm}\label{euclid} \setlength{\...
  • 1,567
1 vote

How to align multiple pgfplots vertically and horizontally in multiple columns?

First, I reduced the size of your plots. Second, [scale only axis] provides more consistent results. Finally, I expanded the bounding boxes by 5pt in both directions relative to the lower left ...
  • 71.3k
2 votes
Accepted

How can I get this indentation?

I agree with @Clara that you should familiarize with some of the algorithm-related packages, especially if you have more than one or two algorithms you need to typeset. For a quick and not so dirty ...
  • 449k
2 votes
Accepted

Double Aligning equations

You need a nested aligned. \documentclass{article} \usepackage{amsmath} \newcommand{\Acal}{\mathcal{A}} \newcommand{\Jcal}{\mathcal{J}} \begin{document} \begin{equation*} \begin{aligned} \Delta^...
  • 1.0m
1 vote

\raggedright column yields "\midrule ->\noalign"

I feel like an...extremely unintelligent person. The problem is solved by replacing all \\ with \tabularnewline: \documentclass{article} \usepackage{calc} \usepackage{array} \usepackage{booktabs} \...
0 votes

Equation alignement with different numbers of columns - spacing issues

You can use \IEEEeqnarray from IEEEtrantools. See a manual at https://moser-isi.ethz.ch/docs/typeset_equations.pdf \documentclass{article} \usepackage{amsmath} \usepackage{IEEEtrantools} \begin{...
  • 1.0m
0 votes
Accepted

Equation alignement with different numbers of columns - spacing issues

Something like this? Example 1. Code to the Example 1. \documentclass{article} \usepackage{mathtools} \usepackage{kantlipsum} \begin{document} \kant*[1][1-2] \begin{subequations} \begin{alignat}{2} ...
  • 3,137
1 vote
Accepted

Problem with boxes distribution in poster format (baposter)

Follow this template to add the material. The bottom row must be defined at the beginning so that other boxes can use it as a reference (such as "introduction"); then "materials" ...
  • 30.2k
3 votes
Accepted

Why \substack doesn't honor the horizontal spaces around its argument?

You should first look at the definition of \iff in amsmath.sty, namely \renewcommand{\iff}{\DOTSB\;\Longleftrightarrow\;} Now you can define a \doubleiff command along the same lines, rather than ...
  • 1.0m
2 votes
Accepted

Is \inferrule* inside gather* not centered?

From playing around with the code, from what I can tell, this seems to be the result of a spurious space added at the end of the starred version of \inferrule inside the macro \mpr@inferstar@. It ...
  • 38.6k
1 vote
Accepted

overlapping due to many entries in Tikz trees

Here is a solution using forest, which has a somewhat simpler syntax and distributes the nodes efficiently without overlapping them. The forked edges option uses the edges library. There are two ...
  • 23.7k
1 vote
Accepted

How to left-align code in listing package?

Instead of moving the numbers into the text area with numbersep = -6.5pt, you could change the xleftmargin to have the numbers aligned with the surrounding text: \documentclass[aspectratio=169,xcolor =...

Top 50 recent answers are included