# Tag Info

1

The natural thing to do would be to use \begin{center}...\end{center}, but you have to use a trick for content larger than the current textwidth: wrap it in \makebox[0pt]{...}, to trick LaTeX into centering it. \item \leavevmode\vadjust{\vspace{\baselineskip}}\newline \begin{center} \makebox[0pt]{ \begin{tikzpicture}[>=stealth',node distance=2cm,on ...

0

aligned equations are typically centered by default, so without more information about your preamble it's hard to know for certain what the problem is. That said, it's most likely that the problem arises from passing fleqn as an option to the document class. Removing this makes display math (including align environments) centered instead of left-aligned. ...

0

In your code are several errors. First of all you have a lot of packages called not neccessary for this problem. Next time please delete all such packages. Second you called several packages twice. Please do not do this. If you copy things from templates do only use packages you know and be sure not to call packages twice or more. Third \bf is outdated ...

0

\documentclass{book} \usepackage[a4paper]{geometry}% just for the example \usepackage{rotating} \usepackage{caption} \usepackage{tabularx} \usepackage[tableposition=below]{caption} \setlength{\rotFPtop}{0pt plus 2fil } \captionsetup{compatibility=false} ...

3

touhami's suggestion in the comments made me find an answer for this admittedly niche problem. The solution is to construct the paragraph as if it was being normally typeset and then handle the positioning of the last paragraph manually. Here's how it goes: \textbf{CENTRED / NOT SMALL}\par { % Typeset as we did previously for the "regular / not small" ...

3

The problem is mostly due to the .png images having extra wide space around them. Please check your images or try to upload them in your post. Here is your code with experimental images: \documentclass{article} %Document type \usepackage{amssymb,amsmath} %Inserting symbols \usepackage{graphicx} %Inserting graphics \usepackage{fullpage} ...

3

You have several possibilities to do what you want. Because I'm not sure if centering is always the best I will show you two other possibilities for the layout. One is using the usual block (please see the hyphenation!), one is to use \raggedright, that means left justified text and all centered. The code (with your used class memoir): ...

3

The following should provide you with what you need: \documentclass{article} \begin{document} \noindent \begin{tabular}{@{}p{2.5in}p{2.5in}@{}} \dotfill & \dotfill \\ Some name & Date \\[5\bigskipamount] \hrulefill & \hrulefill \\ Some other name & Date \\ \centering Some lengthy designation that makes the above-mentioned ...

3

This with list is not possible (at least simple) to achieve. I sugest to use flalign math environment: \documentclass{book} \usepackage{amsmath,amsfonts,amssymb,amsthm} \usepackage{mathptmx} \begin{document} \begin{flalign*} \textbf{(a)} && P(1) & = 3.1479 && \\ && K(1) & ...

4


2

In the end I went with \parshape instead of \shapepar, which didn't work in TikZ. So I used the background package for background image and picture enviroment for absolute positioning. \documentclass{article} \usepackage[a6paper]{geometry} \usepackage{graphicx} \usepackage{fontspec} \usepackage{background} \usepackage{pst-barcode} ...

2

With array you can obtain the following: \documentclass{article} \usepackage{amsmath} \begin{document} \arraycolsep=1pt \begin{array}{cccc} \mathbf{A} & \mathbf{x} & = & \mathbf{b} \\ \begin{bmatrix} 1 & 0 \\ 0 & 1 \\ \end{bmatrix} & \begin{bmatrix} x_1 \\ x_2 ...

2

You're forgetting some &: \documentclass{article} \usepackage{showframe}% just for the example \usepackage{amsmath,amsfonts,amssymb,amsthm, bm} \begin{document} \begin{flalign} &\text{For the \emph{steady-state filter system}} & \bm{\Phi}_{f} & = (\mathbf{I}-\bar{\mathbf{K}}\mathbf{h}')\bm{\Phi} &&\\ &\text{For the ...

1

Since the input in the OP's question has the appearance of a spreadsheet, it is possible that the OP would prefer a tabular solution, rather than one set in mathematical notation. The only twist for adapting it was the introduction of \mybig{rows}{glyph} for making large parens. Currently, column alignments are centered, but that is easily customized. ...

3

You can use the matrix library of TikZ together with the positioning library to achieve something like this: Code \documentclass[tikz, border=2mm]{standalone} \usetikzlibrary{matrix, positioning} \begin{document} %\matrix (m) [matrix of math nodes,left delimiter=(,right delimiter=), % inner sep=2pt,outer sep=0pt]{ % a & b & [1em] 0 \\ % c ...

6

One way to achieve your layout objective is to use pmatrix* environments (in order to right-align all columns), \hphantom statements (to widen various columns as needed), and \mkern directives (to align the left-hand most columns of the Z, V, and R matrices/row vectors). If you're not comfortable with \hphantom directives inside pmatrix* environments, you ...

5

It's a bit late at night for hacking shapepar internals but it is easy enough to fix this manually, and getting a good position perhaps needs manual control anyway to interact with the border: \documentclass[border=0,margin=0,multi,tikz]{standalone} \usepackage{graphicx} \usepackage{fontspec} \usepackage{tikz} \usepackage{shapepar} ...

0

As a variation on Hupfer's solution: \documentclass[a4paper,oneside, 12pt]{book} \usepackage{xcolor} \usepackage{showframe} \usepackage{blindtext} \newcommand{\mysection}[1]{\section[#1]% {\hfill{#1}\hfill{\color{white}\quad\thesection}}} \begin{document} \tableofcontents \mysection{Ukarranta} \blindtext[2] \end{document}

2

You could provide the following instructions in the preamble: \usepackage{sectsty} \allsectionsfont{\centering} This will center all section, subsection, and subsubsection headers. If you want to center only section-level headers, change the second command to \sectionfont{\centering}

1

This works out of the box (remove \usepackage{showframe} later on!) \documentclass[a4paper,oneside, 12pt]{book} \usepackage{xcolor} \usepackage{showframe} \usepackage{blindtext} \begin{document} \section{\protect\centering\textcolor{blue}{Ukaaranta}} \section*{\centering\textcolor{blue}{Ukaaranta}} \blindtext[2] \end{document}

1

You can simply modify some parameters of a description environment: \documentclass{article} \usepackage{enumitem} \begin{document} \begin{description}[labelwidth=4em,leftmargin =\dimexpr\labelwidth+\labelsep\relax, font=\sffamily\mdseries] \item[Email:] my@email.com \item[Address:] Street name\\ City\\ Country ...

1

You may want to use tabbing: \documentclass{article} \begin{document} \begin{tabbing} Address: \=\kill Email: \> my@email.com \\[1ex] Address: \> Street name \\ \> City \\ \> Country \\[1ex] Phone: \> My phone number \end{tabbing} \end{document} If you have to compile a directory, use \\* instead of \\ so no page ...

3

Another solution : \documentclass[12pt,a4paper]{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage[french]{babel} \usepackage{enumitem} \begin{document} \begin{enumerate}[align=parleft, labelsep=2cm,] \item[test1:] premier item; \item[Coucou:] deuxième item;\\ line 2 \item[test\_auto:] troisième item. \end{enumerate} \end{document} ...

0

for this use can just use \item[•] \documentclass{article} \usepackage{enumitem} \begin{document} \begin{enumerate}[leftmargin=*] \item[Email:] my@email.com \item[Address:] Street name\\ City\\ Country \item[Phone:] My phone number \end{enumerate} \end{document}

1

Design own list! From "The LaTeX Companion": \documentclass{article} \usepackage{calc} \usepackage{hyperref} \newcommand{\entrylabel}[1]{% \makebox[\labelwidth][l]{\parbox[t]{\labelwidth}{\raggedleft#1}}% }% end of definition \newenvironment{entry}[1]% {\begin{list}{}{% ...

1

A beamer "inner theme" dictates the style of the frame elements traditionally set in the "body" of each slide. This includes the footnotes. Viewing beamerinnerthememetropolis.dtx, we see \setbeamertemplate{footnote}{% \parindent 0em\noindent% \raggedright \usebeamercolor{footnote}\hbox to 0.8em{\hfil\insertfootnotemark}\insertfootnotetext\par% } ...

1

I just solved the problem using: \put(-175,25){ \parbox{4cm}{\centering This text is \\too long }}

1

Smaller bullets can indeed be a good stylistic choice. However, just \tiny\textbullet (that's essentially the same as \tiny$\bullet$) will print the small bullet too low. One can raise it automatically by exploiting \vcenter: \documentclass{article} \renewcommand{\labelitemi}{% $\vcenter{\hbox{\tiny\textbullet}}$% } \begin{document} Compare ...

3

This uses enumitem and it's label=... feature within \setlist, which does not require to set the label each time. It's set for all itemize environments then. If this is not requested, a new list can cloned. \documentclass{article} \usepackage{enumitem} \setlist[itemize,1]{label={\tiny\textbullet}} \usepackage{pgffor} \begin{document} \begin{itemize} ...

1

In these three case, I us \tclap (top-center lap) to place the above image right after the ! of NOW!. In the first case, the image is centered to the right hand edge of the !, while in the 2nd and 3rd cases, the 2cm image is moved 1cm to the right of the !, resulting in an image left aligned to the right-hand edge of !. In the 3rd case, since the marker ...

3

Yes, you can save the x (and y) coordinate on the page and use that in a calculation elsewhere. Under pdfLaTeX you can use zref's savepos module to perform expandable calculations: \documentclass{article} \usepackage{graphicx,zref-savepos} \setlength{\parindent}{0pt}% Just for this example \begin{document} Exact centre of text block: ...

3

\documentclass{book} \usepackage{pgfplotstable} \usepackage{longtable} \usepackage{booktabs} \usepackage{array} \usepackage[a4paper,top=4in,bottom=4in,right=1in,left=1in]{geometry} \usepackage{filecontents} \begin{filecontents}{good.csv} Iter dr21 dr31 dr22 dr32 1 0.4900713 0.5051498 0.4907129 0.5064977 2 0.4900256 0.5046520 0.4902557 ...

1

\hspace*{\fill} will do what you ask but you shouldn't normally need to have such spacing in the document, perhaps \begin{flushleft} 10 \end{flushleft} is what you want? Or perhaps for the usecase mentioned in comments moving into the margin might be better than flush left within the text block: \marginpar{10}

2

Add group name=ape to the the group style, then you can place nodes relative to the corners of the subplots, e.g. \foreach \row in {1,2,3} \path (ape c1r\row.south east) --node[below=0.5cm]{Number of recursions} (ape c2r\row.south west); \path (ape c1r1.north east) --node[above]{$\mathbf{N(0,1000^2)}$} (ape c2r1.north west); \path (ape c1r2.north east) ...

1

Here are two possibilities, usng the makecell package, which allows line breaks for the \rotcell command: \documentclass[]{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{geometry} \usepackage{booktabs} \usepackage{array, multirow} \usepackage{rotating, graphicx} \usepackage{makecell} \setcellgapes{4pt} \begin{document} ...

2

You can try this (using pdftex): \newdimen\tstrutdim \def\tstrut{\lower.3\tstrutdim\vbox to\tstrutdim{}} \def\crl{\cr\noalign{\hrule}} \def\rotitem#1{\noalign{\setbox0=\hbox{ #1 }\global\tstrutdim=.5\wd0} \ \pdfsave\pdfsetmatrix{0 1 -1 0}\llap{ #1 \kern-.7\tstrutdim}\pdfrestore } \vbox{\offinterlineskip \tstrutdim=16pt ...

0

As supplement to @Andrew Arnold answer (and for my exercise :-)) ... \documentclass{article} \usepackage{siunitx} \usepackage{array,booktabs} \usepackage{stackengine} \usepackage{etoolbox} \usepackage[margin=30mm,showframe]{geometry} \newcommand{\mc}[1]{\multicolumn{1}{c}{#1}} % non-extended bold font ...

2

Note that the main tabular has the first column alignment specified as @{} l which removes the column spacing to the left of the left-aligned column (due to @{}). \multicolumn{.}{l} re-formats the column specification to l without the removal of the column spacing on the left. So you should either use \begin{tabular}{ l ... } ... ...

4

In your column specification you have @{} at the start: this suppresses that space to the left of the first column. You need to add this into the column specifier you pass to multicolumn. When added to your code you get the following: \documentclass[12pt]{article} \usepackage{booktabs} \usepackage{dcolumn} \newcolumntype{d}[1]{D.{\mbox{.}}{#1}} ...

1

For my exercises and for see similar, however slightly different approach how to typeset tables with math contents: \documentclass{article} \usepackage{amsmath} \usepackage{array,booktabs,makecell} \renewcommand\theadfont{\bfseries} \usepackage{siunitx} \begin{document} \begin{center}% if table is in float environment, than replace with ...

1

Here, I use TABstacks to set each column, which allows me to get various alignments... not only in the equation column, but also for the decimal columns, too. Additionally, I set the baseline-skip of the stacks to 2.5 the \normalbaselineskip. \documentclass{article} \usepackage{amsmath} \usepackage{booktabs} \usepackage{tabstackengine} ...

1

What about this? \documentclass{article} \usepackage{amsmath} \usepackage{booktabs} \usepackage{siunitx} \newcommand\pdiff[2]{\frac{\partial #1}{\partial #2}} \begin{document} \begin{tabular}{c r @{$${}={}$$} l S S} \toprule \bfseries Variable & \multicolumn{2}{c}{\bfseries Partial} & {\bfseries Sensitivity} & {\bfseries Contribution} ...

2

I'm sure there is a more elegant way, but a crude approach is to calculate the difference in width between each of the smaller left compounds (the first two) and the largest (the last) and add that as \hspace before the start of the smaller reactions. Showing each step: \documentclass[a4paper,pdftex,ngerman,12pt]{article} \usepackage{chemfig} ...

2

Add this to the preamble to handle both the preprint and final options: \usepackage{etoolbox} \patchcmd{\pprintMaketitle}{\begin{center}}{\begin{flushleft}}{}{} \patchcmd{\pprintMaketitle}{\end{center}}{\end{flushleft}}{}{} \patchcmd{\MaketitleBox}{\begin{center}}{\begin{flushleft}}{}{} \patchcmd{\MaketitleBox}{\end{center}}{\end{flushleft}}{}{} For your ...

5

4

1st Try Try the tabbing environment and next time please provide a complete example (including documentclass etc.) The first line defines the tab position. \documentclass{article} \begin{document} \begin{tabbing} longestlongest \= long \kill % kill -> do not print this line good \> padding \\ notbad \> padding \\ it overlaps ...

2

Well, Harish Kumar was faster than me ..., anyway, since as a matter of fact give answer in my comment, I just "publish" my redrawing of your circuits. I simplified it a bit, however in general it is similar to Harish Kumar answer: \documentclass{article} \usepackage[hmargin={30mm,30mm}, height=247mm, a4paper]{geometry} ...

3

I have changed the coordinates so that the picture is wide enough to be fitted inside the text width. Also, I have brought the equation node to right by a little. \documentclass{article} \usepackage[european]{circuitikz} \usepackage{amsmath,showframe} %% showframe just for demo \begin{document} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ...

Top 50 recent answers are included