title: the \percent macro is not working in siunitx package

text: I get error when I use the `\percent` macro in the `siunitx` package. Here is the code :                             \documentclass[]{beamer}                   \usetheme{CambridgeUS}                   \usepackage{siunitx}                   \setbeamercolor{title}{bg=red!65!black,fg=white}                   \begin{document}                   \title{Risk Management in Software Engineering}                   \author{S.Subham Soni}                   \institute[P.E.C]{Department of Computer Science and Engineering\\      Pondicherry Engineering College}                   \date{January 6, 2014}                        \begin{frame}                   \begin{tabular}{|r|r|}                   \hline                   \textbf{Risk}&\textbf{Percentage} \\                   \hline                    Very Low&$\textless10\%$ \\                    \hline                    Low&10\percent-25\percent \\                    \hline                  \end{tabular}                  \end{frame}                  \end{doccument}      Here the `\percent` is throwing the error as symbol not found. The code is a part of the full code so there might be some continuation gap....


title: Span TikZ Picture Across Two Columns

text: I'm restricted to writing a paper with`\documentclass[twocolumn,11pt]{article}`, but I want to create a `tikzpicture` that spans across both of the columns, filling the width of the page. I have tried placing it in a `figure` and using `figure*`, and other figure options, but none of that works. The code for my `tikzpicture` is here.               \definecolor {processblue}{cmyk}{0.96,0,0,0}     \begin {center}     \begin {tikzpicture}[-latex ,auto ,node distance =1.8cm and 1.5cm ,on grid ,     semithick ,     state/.style ={ circle ,top color =white , bottom color = processblue!20 ,     draw,processblue , text=blue , minimum width =1 cm}]     \node[state] (S) {$S$};     \node[state] (W) [above right =of S] {$W$};     \node[state] (X) [right =of W] {$X$};     \node[state] (Y) [right =of X] {$Y$};     \node[state] (Z) [right =of Y] {$Z$};     \node[state] (D) [below right =of Z] {$D$};     \path (S) edge [bend left =0] node[above left = .3 cm] {$R_{sw}$} (W);     \path (W) edge  [bend right =0](S);     \path (W) edge [bend left =0] node[above = .3 cm] {$R_{wx}$}(X);     \path (X) edge [bend right =0](W);     \path (X) edge [bend left =0] node[above = .3 cm] {$R_{xy}$}(Y);     \path (Y) edge [bend right =0](X);     \path (Y) edge [bend left =0] node[above = .3 cm] {$R_{yz}$}(Z);     \path (Z) edge [bend right =0](Y);     \path (Z) edge [bend left =0] node[above right = .3 cm] {$R_{zd}$}(D);     \path (D) edge [bend right =0](Z);     {\tiny }\end{tikzpicture}     \end{center}


title: \centering\arraybackslash with an array environment?

text: The following code gives me an error:               \documentclass[12pt]{article}     \usepackage[margin=2cm]{geometry}     \usepackage [english]{babel}     \usepackage{amsmath, amssymb}     \usepackage{enumitem, array}     \begin{document}     {\begin{minipage}[t]{\textwidth}     \begin{enumerate}[label=(\roman*)]     {\setlength\itemindent{10pt}\item      \begin{equation*}     \begin{array}{>{\centering\arraybackslash}m{1.5cm}>{\centering\arraybackslash}m{1.5cm}>{\centering\arraybackslash}m{1.5cm}>{\centering\arraybackslash}m{1.5cm}>{\centering\arraybackslash}m{1.5cm}}          \hline     x & l_{[x]} & d_{[x]} & l_{x+1} & \mathring{e}_{[x]} \\     \hline     \end{array}     \end{equation*}}     \end{enumerate}     \end{minipage}}     \end{document}      Note: for various reasons, I have to keep `minipage` there. For some reason, this code gives me an error when it compiles. It gives the following output: ![enter image description here](http://i.stack.imgur.com/ZfPZ9.png) The errors either say there is a `}` missing or a `$` missing. My eyes don't see such a thing!


title: How do I get full or abbreviated citations to appear automatically in Tufte footnotes (sidenotes)?

text: I'm experimenting with a promising approach to generate generate abbreviated citations in Tufte documents automatically using \cite alone, once a reference has already been used. But I've encounters some difficulties and limitations that I'm not sure how to fix:   1. I'm experiencing a bug, in which citations are abbreviated even when a references has not yet been cited.   2. The solution as it is does not work within `\footnotes` (sidenotes). References there are not recognized as having been cited before, so full citations are always inserted. This also highlights what may be a bug in the Tufte classes: these full citations "jump out" of the footnote into their own (footnote paragraph).   3. Finally, in a perfect world, I'd like to omit URLs and full author lists from citations, while keeping them in the bibliography. Here's what I'm getting: ![Example output showing citation behavior](http://i.stack.imgur.com/LAems.png) * * * I'm using bibtex and building my MWE in TeXShop (though I'm building my documents using LyX).               \documentclass[]{tufte-handout}          %From --- http://tex.stackexchange.com/a/45878/7844     % Redefine some footnote code to support additional features:     \usepackage{etoolbox}% provides some support for comma-separated lists          \makeatletter     % We'll keep track of the old/seen bibkeys here.     \def\@tufte@old@bibkeys{}          % This macro prints the full citation if it's the first time it's been used     % and a shorter citation if it's been used before.     \newcommand{\@tufte@print@margin@citation}[1]{%       % print full citation if bibkey is not in the old bibkeys list       \ifinlist{#1}{\@tufte@old@bibkeys}{%         \citealp{#1}% print short entry       }{%         \bibentry{#1}% print full entry       }%       % add bibkey to the old bibkeys list       \listgadd{\@tufte@old@bibkeys}{#1}%     }          % We've modified this Tufte-LaTeX macro to call \@tufte@print@margin@citation     % instead of \bibentry.     \renewcommand{\@tufte@normal@cite}[2][0pt]{%       % Snag the last bibentry in the list for later comparison       \let\@temp@last@bibkey\@empty%       \@for\@temp@bibkey:=#2\do{\let\@temp@last@bibkey\@temp@bibkey}%       \sidenote[][#1]{%         % Loop through all the bibentries, separating them with semicolons and spaces         \normalsize\normalfont\@tufte@citation@font%         \setcounter{@tufte@num@bibkeys}{0}%         \@for\@temp@bibkeyx:=#2\do{%           \ifthenelse{\equal{\@temp@last@bibkey}{\@temp@bibkeyx}}{%             \ifthenelse{\equal{\value{@tufte@num@bibkeys}}{0}}{}{and\ }%             \@tufte@trim@spaces\@temp@bibkeyx% trim spaces around bibkey             \@tufte@print@margin@citation{\@temp@bibkeyx}%           }{%             \@tufte@trim@spaces\@temp@bibkeyx% trim spaces around bibkey             \@tufte@print@margin@citation{\@temp@bibkeyx};\space           }%           \stepcounter{@tufte@num@bibkeys}%         }%       }%     }\begin{document}     %end From          This is the first occurrence of a citation,\cite{Deutsch:2002} which works as expected. I would also ideally like to be able to cite the same paper again, and have it appear automatically in some abbreviated form. Whereas before I had to do this manually with a footnote and ERT\footnote{\citealp{Deutsch:2002}} that now happens automatically\cite{Deutsch:2002}, thanks to "godbyk".           But although these basics work, I'm still having problems getting this to work quite the way I'd like (or that it seems they should in general):     \begin{enumerate}     \item First, what seems to be a bug: even in cases were a reference has not been used before, I'm getting abbreviated citations.\cite{Sarukkai:2005}\cite{Neeley:1907}     \item Second, citations \textit{within footnotes} (a key feature of the Tufte books) don't behave as they should. Those that appear in full, "jump out" of the note into a new paragraph within the note\footnote{There should be a full citation right here,\cite{OConnell:2010} but it's down there.}, and those that should appear as abbreviated citations (since the've been cited before) are still cited in full (and again, "jump out" of the note).\footnote{This\cite{Deutsch:2002} (look below) should be abbreviated, but it isn't.}     \item Finally, I'd like to be able to exclude URLs and full author lists from (initial, full) citations, but keep them in the bibliography (ideally on their own line), though that may be to much to ask.     \end{enumerate}     Thanks again for any assistance!     \bibliographystyle{unsrtnat}     \bibliography{References}          \end{document}     %See edit history for .bib contents


title: Connecting two nodes with lines through a point in tikz

text: I'm trying to make a very simple flowchart using tikz. Here is what it looks like now: ![Flowchart as it currently looks](http://i.stack.imgur.com/sKq61.png) And here is what I need it to look like: ![Flowchart as I want it to look](http://i.stack.imgur.com/lsICe.png) I've found an example of a flowchart online using tikz, and here is my style definition:               \tikzstyle{decision} = [diamond, draw, fill=blue!20, text width=4.5em, text badly centered, node distance=3cm, inner sep=0pt]     \tikzstyle{block}    = [rectangle, draw, fill=black!25, text width=5em, text centered, rounded corners, minimum height=4em]     \tikzstyle{line}     = [draw, -latex']     \tikzstyle{cloud}    = [draw, ellipse,fill=red!20, node distance=3cm, minimum height=2em]      and here is my flowchart code:               \begin{figure}[!h]         \centering         \begin{tikzpicture}[node distance = 2cm, auto]             \node [block] (st1) {Stage 1};             \node [block, right of=st1, node distance=3cm] (st2) {Stage 2};             \node [block, right of=st2, node distance=3cm] (st3) {Stage 3};             \path [line] (st1) -- (st2);             \path [line] (st2) -- (st3);         \end{tikzpicture}     \end{figure}      If I had just built the image using co-ordinate based shapes, it would have been time consuming but simple just to add the lines and text I need. But since I'm adding these nodes and connecting nodes, I don't know how to add a line with 2 bends.


title: How can I add zero lines to a groupplot?

text: I'd like to add zero lines to a groupplot by defining them _once_ in the `groupplot` environment. I of course based this on the clues and replies I found on here & in the manual, but so far I couldn't get it to work. ## MWE               \documentclass[     a4paper     ]{scrartcl}          \usepackage{     lmodern,     amsmath,     tikz,     pgfplots,     pgfplotstable     }          \usepackage[T1]{fontenc}     \usepackage[utf8]{inputenc}          \usepgfplotslibrary{groupplots}          \begin{document}     \begin{center}     \begin{tikzpicture}[font=\small]     \begin{groupplot}[     group style={     group size=1 by 2,     horizontal sep=0cm,     vertical sep=1.5cm     },     %     execute at begin axis/.append code={ %<-this line works for the normal 'axis'     %the following 3 do not produce an error but do not work either:     %execute at every axis/.append code={     %execute at every plot/.append code={     %execute at begin plot/.append code={     \draw[thin] (axis cs:\pgfkeysvalueof{/pgfplots/xmin},0) -- (axis cs:\pgfkeysvalueof{/pgfplots/xmax},0);     \draw[thin] (axis cs:0,\pgfkeysvalueof{/pgfplots/ymin}) -- (axis cs:0,\pgfkeysvalueof{/pgfplots/ymax});     },     %     height=6cm,     width=14cm,     %     scaled x ticks=true,     scaled y ticks=false,     %     xlabel={The label for the x-axis},     ylabel={Some y-values},     ]     \nextgroupplot     \addplot {rand};     %     \nextgroupplot     \addplot {rand};     \end{groupplot}     \end{tikzpicture}     \end{center}     \end{document}


title: How can i use eclipse to use the date and version in my output filename

text: This is less a direct LaTeX question than it is about compiling LaTeX. I am using eclipse and in my project properties i set `Output File = document.pdf` . My demoproject compiles and outputs the File. What i want is to define something like `document_$DATE$_$VERSION$.pdf` . I want eclipse to generate the Date and i want my demoproject to set the Version.               \documentclass{article}     \Version{A}     \begin{document}     This is my document.     \end{document}      How would i do something like that?


title: Is it possible to compile asymptote(.asy) file without displaying the figure

text: Today I want to draw several 3D schematic diagrams that could be inserted in my LaTeX files. And I chose asymptote because of its widely known 3D rendering advantage over other tools. I configured "asy-mode" in my favorable Emacs to code my first script. However, when I press C-c C-c to compile, the compilation process will open the output file(.eps or .pdf) and will half untile I close that file. That is really a trouble to close preview every time. When I compile tex files, the compiler only parses and processes and won't open the .dvi file and wait for me to preview. Instead, after the compilation, yap can detect the change and automatically reload it. Many pdf viewers also have auto reload feature. That's particularly convenient when I'm using a computer with two screens. But now every time "asy" will open the preview file and I have to close it to proceed. I notice the command for the compilation is               asy -V -wait file.asy      I tried many ways, but nothing prevents "asy" from opening the output files. I edited asy-mode.el to delete the -wait parameters; I compile it manually outside Emacs trying all possible parameters, like               asy -silent file.asy      the window keeps jumping out after successful execution of the command. That's really frustrated. Do you guys have any solutions or work around? I'm using Emacs 23.4 on Windows 7 and the asymptote version is 2.24. Thanks in advance.


title: Citation issue, author comma date

text: I've had a good search around Internet but can't really find anything relevant to what I'm looking for. In Lyx, when selecting a citation options the style closest to what I need is: > (Author, Date) As per my universities referencing guidelines, all citations such as this should be: > (Author Date) omitting the comma. I am using the authordate1.bst, however I have tried 1 through 4 to see if they made any difference. I did wonder if any of this code here (from the file named above) is responsible. I toyed around with it but noticed no difference, is it just for the bibliography rather than citations?               FUNCTION {format.names}     { 's :=       #1 'nameptr :=       s num.names$ 'numnames :=       numnames 'namesleft :=         { namesleft #0 > }         { s nameptr "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=           nameptr #1 >             { namesleft #1 >                 { ", " * t * }                 { t "others" =                     { ", {\em et~al.\ }\relax" * }                     { ", \& " * t * }                           %  Butcher, pages                   if$                                           %  186-189.                 }               if$             }             't           if$           nameptr #1 + 'nameptr :=           namesleft #1 - 'namesleft :=         }       while$     }          FUNCTION {format.authors}     { author empty$         { "" }         { author format.names }       if$     }      Is this citation style even defined by the .bst file, or is it something hard coded into Lyx? **Edit:** Problem solved (thanks @TorbjørnT.) As said, adding this to the preamble solved the problem, assuming you are using natbib (Bibliography settings > Citation style).               \setcitestyle{aysep={ }}


title: How to change the current point to the tip of an arrow without using \moveto?

text: Consider the following code.               \documentclass[pstricks,border=12pt]{standalone}     \usepackage{pst-plot}     \begin{document}     \begin{pspicture}(0,-1)(3,1)         \pscustom[linejoin=1,arrows=->]         {             \psline(0,-1)(1,0)             \psplot[algebraic,plotpoints=100]{1}{2.25}{.25*sin(2*Pi*x/.25)}             %\moveto(2.25,0)             \psline(3,0)         }     \end{pspicture}     \end{document}      ![enter image description here](http://i.stack.imgur.com/coLkr.png) The objective is to move the current point used by `\psline(3,0)` to the tip of the second arrow such that `\psline(3,0)` is parallel to the horizontal line. How to move such a current point without using `\moveto(2.25,0)`? It seems the `\psplot` behaves abnormally, correct if I am wrong.


title: Make a little space after a longtable and before a caption

text: I'm trying to make a table which is not centered in the page, so I've used this structure to define it. But, I need to make a little vertical space between the bottom of that table and its caption. How do I to deal that please ? I can't find a solution.               \lipsum[2]     \begingroup     \setlength{\LTleft}{-20cm plus -1fill}     \setlength{\LTright}{\LTleft}     \begin{longtable}{|p{3cm}|p{4cm}|p{7cm}|}     \hline     COL1 & COL2 & COL3 \\     \hline     1 & 2 & 3     \hline     \caption[]{Hi title.}     \end{longtable}     \endgroup     \lipsum[2]      Thanks in advance.


title: dot2texi cannot handle large graphs

text: I'm trying to create a graph like this, but bigger: ![enter image description here](http://i.stack.imgur.com/SRXhJ.png) . That's generated from radius2.tex using dot2texi (under MiKTeX on WinXP). However, when I try to make the graph any larger, as in rewritegraph.tex, the tex file won't compile. (No error message; pdflatex just freezes up.) dot2texi created a file called rewritegraph-dot2tex-fig1.dot which seemed to contain just hte graph; I opened it up and added '$'s to the labels to create test.dot . 'dot2tex test.dot --autosize' works, but running pdflatex on the resultant file (test.tex) creates an error: ! Dimension too large. \relax l.28 \draw [->] (36290bp,71.966bp) .. controls (36252bp,61.909bp) and (362... ? Googling and searching here suggests that it's very hard to get TeX to deal with dimensions this large. But I feel like **there must be some way to scale down all the numbers,** including the font sizes... fiddling with Graphviz options doesn't seem to do the trick. I'd be very grateful for any advice. **Edit:** See this and this for a solution courtesy of Emden R. Gansner: ![enter image description here](http://i.stack.imgur.com/y3B4Q.png) http://www.graphviz.org/misc/formula.pdf.


title: Make 3x4 figures from pictures in a folder

text: Assume you have 777 pictures. You want to present them on 3x4 A4s. Doing `\begin{figure}...\end{figure}` takes much time and space. Is there any other way to present these figures in a folder in such a way? Like make this presentation from all these figures in the this folder.


title: Templates for Books on Grammar, Phonetics for Language Learning

text: I want to make a book about the grammar of a indigenous language and use it for language learning, so far I got some templates but it seems they are for plays and math. I would appreciate information about templates or manuals on how to prepare books about grammar, phonetics, of a language. Thanks.


title: forest trees: rounded rectangle nodes overlap

text: I am drawing a tree with the help of the `forest` package. Some of my nodes use TikZ's `rounded rectangle` style (see manual p.458).   However, the round sides of those nodes overlap. How do I fix that? ![overlapping nodes](http://i.stack.imgur.com/CFu6h.png)               \documentclass{standalone}          \usepackage{forest}          \begin{document}          \begin{forest}         point/.style={             coordinate,         },         symbol/.style={             draw=black,             text height=1.5ex,             text depth=.25ex,         },         terminal/.style={             symbol,         },         nonterminal/.style={             symbol,             rounded corners,         },         operation/.style={             symbol,             rounded rectangle,         },     [{Sequential},nonterminal         [{Sequential},nonterminal             [{$F_i$},operation]             [{$F_{i+1}$},operation]         ]         [{},point             [{$F_{i+2}$},operation]]     ]     \end{forest}          \end{document}      PS: I'm using TikZ v3.


title: How to draw multiple lines inside the circle

text: I wish to draw the picture like below, however, I don't know how to add multiple lines in side the circle. ![enter image description here](http://i.stack.imgur.com/TbdTx.jpg) This is my code:               \documentclass[tikz]{standalone}     \usetikzlibrary{         shapes.geometric,         positioning,         fit,         calc     }     \usepackage{tikz}     \begin{document}     \tikzset{      block/.style = {circle, draw,         text width=1em,align=center,inner sep=0pt},       line/.style = {draw,thick,->},     }     \begin{tikzpicture}     \node [block,fill=yellow] (s1) {3};     \end{tikzpicture}     \end{document}


title: How to solve the problem "bookmarks are not allowed" when submit a paper?

text: I need to upload a paper (pdf). But the system informed me that "bookmarks are not allowed". However, I have no idea how to forbid bookmarks in the Tex file. Should I add any command? Thank you in advance. p.s., the packages I load are:               \documentclass[conference]{IEEEtran}     \usepackage[cmex10]{amsmath}     \usepackage{psfrag}     \usepackage{amsfonts,amssymb,cite,graphicx,delarray,subfig}     \usepackage{multirow}     \DeclareGraphicsRule{*}{eps}{*}{}     \IEEEoverridecommandlockouts


title: How do you Right-Justify Page Numbers and get them in the header?

text: When I made PDFs with Texmaker the page numbers are by default at the bottom of the page (i.e. in the footer) and are centred. How do I change this?


title: komascript/scrpage2: odd page header in passages without a \section (two-sided docs)

text: Suppose you have a two-sided document. The even page's header contains the title of the current chapter; the odd page's header contains the title of the current section. Nothing too fancy, and pretty easily done using the scr* classes and scrpage2.               \documentclass[paper=a5,headinclude=true,pagesize,twoside=true]{scrreprt}     \usepackage[automark]{scrpage2}     \usepackage{blindtext}          \pagestyle{scrheadings}          \begin{document}     \chapter{Chapter one}     %\renewcommand*{\sectionmarkformat}{} %removes section number     %\sectionmark{\thechapter\enskip Chapter one} %sets odd header     \Blindtext\Blindtext\Blindtext\Blindtext     \section{Section one}     \Blindtext\Blindtext\Blindtext\Blindtext     \end{document}      ![everything in its right place](http://i.stack.imgur.com/oCFF7.png) Things get difficult in the introductory passages of chapters. Say you have three or more pages of text at the beginning of a chapter before the first `\section` starts, which is something I do quite often to provide readers with some signposting. Now, in the above setup, the odd page headers will remain empty, which is what you'd expect, but I'd like to change it -- so the odd page header will have the chapter's title until a section is available. I do know how to manually modify `\sectionmark`, which I can use to insert anything I want. See the two comment lines in the MWE. But of course you'd usually want a more automated solution. For example, is there a way to ›grab‹ the current chapter title and pass it on to `\sectionmark`? I tried               \sectionmark{\leftmark},      too, but to no avail. Thanks in advance!


title: Creating level labels for (horizontal) tikz trees

text: I want to create labels and the corresponding lines cutting through the branch levels of a (horizontal) tikz-qtree. Here's the idea. ![enter image description here](http://i.stack.imgur.com/SpmyJ.jpg) I tried for quite some time and searched the net, but could not find anything for further progress... The following code produces the original tikz-tree.               \begin{figure}[bh!]     \centering     \begin{tikzpicture}[ level distance=1cm, growth parent anchor=east, grow=right,scale=0.78,      level distance=1cm,     ]          \tikzstyle{every node}=[font=\footnotesize, text width=5mm,anchor=east]          \Tree[.{0} [.{1} [.{1} [.{1} [.{1} [.{2} [.{7} [.{9} [.{4} [.{33} ] [.{474} ] ] [.{478} ] ] [.{487} ] ] [.{494} ] ] [.{496} ] ] [.{497} ] ] [.{498} ] ] [.{499} ] ] [.{4} [.{13} [.{4} [.{4} [.{7} [.{25} [.{9} [.{120} [.{314} ] [.{314} ] ] [.{434} ] ] [.{443} ] ] [.{468} ] ] [.{475} ] ] [.{479} ] ] [.{483} ] ] [.{496} ] ] [.{1} [.{2} [.{18} [.{39} [.{2} [.{55} [.{56} [.{327} ] [.{327} ] ] [.{383} ] ] [.{438} ] ] [.{440} ] ] [.{479} ] ] [.{497} ] ] [.{499} ] ] [.{3} [.{10} [.{2} [.{3} [.{6} [.{8} [.{7} [.{16} [.{32} ] [.{445} ] ] [.{461} ] ] [.{468} ] ] [.{476} ] ] [.{482} ] ] [.{485} ] ] [.{487} ] ] [.{497} ] ] [.{6} [.{9} [.{7} [.{1} [.{3} [.{3} [.{9} [.{14} [.{24} ] [.{448} ] ] [.{462} ] ] [.{471} ] ] [.{474} ] ] [.{477} ] ] [.{478} ] ] [.{485} ] ] [.{494} ] ] [.{444} [.{56} ] [.{56} ] ] ]          \end{tikzpicture}     \end{figure}


title: Institute name in beamer presentation

text: I am trying to put the name of the institution in a beamer presentation               \documentclass{beamer}     \institution{XYZ}     ...     \begin{document}     \maketitle      However I get the error that it is an `undefined control sequence`. What possibly is the mistake?


title: FontLab Studio and font editing

text: I trying to editing some font using FontLab Studio 5.1 but when i have finished and i save the work, one time that i have close the program and i try to reopen the .otf file, it is remained at the older version without any change. Is Python needed?


title: Pushing siblings together in tikz tree

text: I tried several approaches, but none of them worked... Here is my tree code:               \begin{figure}[bh!]     \centering     \begin{tikzpicture}[ level distance=1cm, growth parent anchor=east, grow=right,scale=0.78,      level distance=1cm,     ]          \tikzstyle{every node}=[font=\footnotesize, text width=5mm,anchor=east]          \Tree[.{0} [.{1} [.{1} [.{1} [.{1} [.{2} [.{7} [.{9} [.{4} [.{33} ] [.{474} ] ] [.{478} ] ] [.{487} ] ] [.{494} ] ] [.{496} ] ] [.{497} ] ] [.{498} ] ] [.{499} ] ] [.{4} [.{13} [.{4} [.{4} [.{7} [.{25} [.{9} [.{120} [.{314} ] [.{314} ] ] [.{434} ] ] [.{443} ] ] [.{468} ] ] [.{475} ] ] [.{479} ] ] [.{483} ] ] [.{496} ] ] [.{1} [.{2} [.{18} [.{39} [.{2} [.{55} [.{56} [.{327} ] [.{327} ] ] [.{383} ] ] [.{438} ] ] [.{440} ] ] [.{479} ] ] [.{497} ] ] [.{499} ] ] [.{3} [.{10} [.{2} [.{3} [.{6} [.{8} [.{7} [.{16} [.{32} ] [.{445} ] ] [.{461} ] ] [.{468} ] ] [.{476} ] ] [.{482} ] ] [.{485} ] ] [.{487} ] ] [.{497} ] ] [.{6} [.{9} [.{7} [.{1} [.{3} [.{3} [.{9} [.{14} [.{24} ] [.{448} ] ] [.{462} ] ] [.{471} ] ] [.{474} ] ] [.{477} ] ] [.{478} ] ] [.{485} ] ] [.{494} ] ] [.{444} [.{56} ] [.{56} ] ] ]          \end{tikzpicture}     \end{figure}      and here is how it looks like: ![enter image description here](http://i.stack.imgur.com/mmE2T.png) I want it to be narrower, i.e., pushing together the siblings at level one so there is no free space between the branches - or at least a bit less space...


title: How to include graphics from parent directory using \graphicspath?

text: To include graphics from parent directory I am using               \usepackage{graphicx}     \graphicspath{{../pop/}{../graph/}}      This works fine for MiKTeX but seems to fail for TeX live installed on the same computer (compiler did not find graphics files). **What I'm doing wrong?** The directories `PoP` and `Graph` are located on the same level as the working directory with the source LaTeX file. Update: Directory structure (for test purposes I put same graphics files in PoP and Graph subdirecrtories)               ECRH      |- OS2012     |  |- ECRH(proc).tex     |- PoP     |  |- ECRH-Fig1.pdf     |  |- ECRH-Fig2.pdf     |  |- ...     |- Graph        |- ECRH-Fig1.pdf        |- ECRH-Fig2.pdf        |- ...


title: footnote in Math Environment

text: \documentclass[12pt]{article}      \usepackage{amstext, amsmath}     \usepackage{chemarrow}          \begin{document}     \let\rightarrow\chemarrow     Begin $\xrightarrow[\text{Text below the arrow}\footnote{this is footnote}]{\text{Text above the arrow}}$ end     \end{document}      It shows the footnote number but does not actually show the footnote at the bottom


title: How do I create a book with separately produced chapters?

text: I want to create a book type file, where each chapter is separatly compiled. That is I get the whole thing as well as each individual chapters in pdf or dvi or ps format. How do I do that?


title: How to delete extra information?

text: When I compile the following :               \documentclass{article}     \usepackage{chessboard}     \usepackage{diagram}     \usepackage[ps]{skak}     \begin{document}     \begin{diagram}[4x4]     \pieces{}     \end{diagram}     \begin{diagram}[3x4]     \pieces{}     \end{diagram}     \end{document}      ![enter image description here](http://i.stack.imgur.com/Tx8d8.jpg) appears information that do not interest me. How to delete them?


title: Draw a longitudinal wave in TikZ

text: I'm trying to obtain this longitudinal wave with TikZ: ![enter image description here](http://i.stack.imgur.com/RstJd.jpg) Here's my code               \documentclass{article}     \usepackage{tikz}          \begin{document}            \usetikzlibrary{decorations.pathmorphing}          \begin{tikzpicture}[decoration={coil}]          \draw[decorate, decoration={aspect=0.3, segment length=3mm, amplitude=3mm}] (0,0) --(3,0);     \draw[decorate, decoration={aspect=0.3, segment length=0.5mm, amplitude=3mm}] (3,0) -- (3.5,0);      \draw[decorate, decoration={aspect=0.3, segment length=3mm, amplitude=3mm}] (3.5,0) -- (5,0);          \end{tikzpicture}     \end{document}      but so there are the junctions between one line and the others that interrupt the continuity of the coil. How can improve it?


title: Is it possible to re-insert a LaTeX equation by label?

text: Is it possible to re-insert an equation in LaTeX via referencing the original equation by label? I already know, it is possible to:   * reuse the original equation numbering via `\tag{}` as described here   * re-insert an equation by "boxing" the original one as said here But isn't it possible to reuse the whole equation (i.e. its text and numbering) just using the label? Wouldn't it be natural to do so, instead of artificially creating additional labels by "boxing"? I'm feeling there must be a better way, or is my intuition wrong?


title: lastpage package: incompatibility with nameref package

text: When I try to use the nameref package together with the lastpage package (version earlier than 2013/01/28, of course) I have following two errors:               ! Package lastpage Error: no auxiliary file allowed     ! Extra \else      But without the _nameref_ package (and referencing chapters by names) my LaTeX document builds without problems.   What does this error mean? And what are possible causes? My document file:               \documentclass[a4paper,oneside,12pt]{report}     \usepackage[polish]{babel}     \usepackage[latin2]{inputenc}     \usepackage[T1]{fontenc}     \usepackage{graphicx}     \usepackage{setspace}     \usepackage{indentfirst}     \usepackage{titlesec}     \usepackage{nameref}     \usepackage{lastpage}     \usepackage{fancyhdr}     \onehalfspacing     \titleformat*{\section}{\normalsize\bfseries}     \setlength{\parindent}{1cm}     \begin{document}     \pagestyle{plain}     Text.     %\input{./title.tex}     \pagenumbering{arabic}     \fancypagestyle{plain}{%          \fancyhf{}             \fancyfoot[C]{Strona \normalsize\thepage\ z \pageref{LastPage}}         \renewcommand{\headrulewidth}{0pt} % remove line between header and main text     }     \tableofcontents     \listoffigures     \pagestyle{plain}     Text.     %\input{./ch1.tex}     %\input{./ch2.tex}     %\input{./ch3.tex}     %\input{./ch4.tex}     %\input{./biblio.tex}     \end{document}


title: Follow Up Question : multiple lines format for ifthen or ifbool compound statements

text: Follow up question to How do I add multiple macro definition inside an \ifbool compound statement? Ok if you look at the last post, people fixed my format for the ifthen / ifbool statement format to switch between two sets of macros. How do I place multiple lines of \newcommand statements into those conditional branches: Example: doofus.sty               \NeedsTeXFormat{LaTeX2e}     \ProvidesPackage{doofus}%     [2014/01/01 v0.01a LaTeX doofus package]%\filedate\space\fileversion\space      \typeout{Package doofus, \csname ver@doofus.sty\endcsname%     ^^ Copyright (C) 2014 ^^J}          \RequirePackage{calc}     \RequirePackage{xkeyval}[2006/11/18]     \usepackage{ifthen}     \usepackage{etoolbox}          \newbool{@epubstate}     \boolfalse{@epubstate}     \DeclareOption{epub}{\booltrue{@epubstate}}     \ProcessOptions%          \ifbool{@epubstate}{\newcommand{\doofus}{\textcolor{black}{7\spadesuit}}     \newcommand{\doofustwo}{\textcolor{black}{6\spadesuit}}}     {\newcommand{\doofus}{\textcolor{red}{7\heartsuit}}\newcommand{\doofustwo}{\textcolor{red}{6\heartsuit}}}      this works for two but I get errors for 50 \newcommands in the same structure. Now the original doofus.tex with multiple commands:               \documentclass[english]{letter}     \usepackage[T1]{fontenc}     \usepackage{color}          \makeatletter     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.     \usepackage[]{doofus}     \usepackage{color}     \usepackage{etoolbox}          \makeatother     \begin{document}     This is a test document for the the doofus boolean example;          Which one appears when I type $\doofus   \doofustwo $?     \end{document}      What am I missing? Thanks


title: I am a latex enthusiast, I am finding it very difficult to produce documents

text: Can anyone help with producing documents with ease? I am using Miktex and winEdt. I am finding it difficult with the following 1. Setting margins 2. Getting poor spacing after paragraphs etc 3. Compiling(there would be some small stopping, I usually use 'h' for help, resolve it if I can or I use 'r' for non stop compilation)


title: Serial key in pdf document

text: I don't know if it is a question to be asked here, but there is: I'm writting a ebook and I'm gonna to sell it soon. I'd sell it at Google Play Store, but here in Brazil they don't accept PayPal as payment (and many brazilian don't have a credit card), so I think that the best option is to sell it by myself. I could sell it also at Amazon, but the Kindle format just sucks when you work with (a lot of) equations. But, of course, there's a problem about sending the pdf file to the buyer. My friend suggested me to lock it with a serial key - like a software. Then a person could open it just in one or three computers. I know there's a package that lock the pdf file with a password (that I create), but I'd like to have a way that block this password when it's used a lot of times - really like a software. Is it possible? Do you have any other ideas to protect a pdf file? I'm gonna take the copyright of my ebook here in Brazil and I know that I can't protect it totally, but I'm trying to do everything I can do to protect it. There's also a brazilian site (www.hotmart.com.br) where you can publish anything you want and they say that, about pdf files, they print in each page the document number of that one who bought my ebook. Thanks! :)


title: Place two A5 pages on A4 using memoir

text: I was trying ConTeXt out and found out about imposition. I'm specifically interested in the 2UP schema, so I can just print on a regular A4 and trim. I have a book typeset using LaTeX and `memoir`. Then I took a look at `memman.pdf`, to try to find information about how this could be accomplished. I tried using `a4paper` and `landscape` class option, then `\pageav`, but that just got me a A4 sheet with a A5 page inside it. How can it be done? I read something about `pdfpages` but didn't try it just yet, because I think there is a native way of doing so using `memoir`.


title: ConTeXt: Superscript for Citation

text: # Background I would like to cite bibliography references using superscript. # Example The setup code so far:               \setupbibtex[database=sources]     \setuppublications[       refcommand=num,       numbering=yes     ]          \setupcite[num][       left=\empty,       right=\empty,     ]      A bibliography entry in `sources.bib`:               @inproceedings{kattamuri@debate,      author = {Kattamuri, Kishore and Silaghi, Marius and Kaner, Cem and Stansifer, Ryan and Zanker, Markus},      title = {Supporting Debates over Citizen Initiatives},      booktitle = {Proceedings of the 2005 National Conference on Digital Government Research},      series = {dg.o '05},      year = {2005},      location = {Atlanta, Georgia},      pages = {279--280},      numpages = {2},      url = {https://repository.lib.fit.edu/bitstream/handle/11141/150/cs-2005-03.pdf},      acmid = {1065321},      publisher = {Digital Government Society of North America},     }      Example document:               \starttext       Citation.\cite[kattamuri@debate]     \stoptext      # Problem There does not appear to be a way to make the citation number superscript. I tried:               \setupcite[num][       left=\empty,       right=\empty,       textstyle=\textsuperscript,     ]      I looked in `bibl-bib.mkiv` and `bibl-tra.mkiv` but could not see how to hook into the citation macros. I spotted `\bibtexnumref` and think it might be useful:               \def\bibtexnumref[#1]%       {\dontleavehmode        \begingroup        \bibtexcitationparameter\v!left        \penalty\plustenthousand        \ctxlua{bibtex.hacks.resolve("","\number\bibtexblock","#1")}%        \bibtexcitationparameter\v!right        \endgroup}      # Question How can ConTeXt produce superscript citation numbers? # Related Related LaTeX questions:   * Biblatex \textcite using a superscript reference number   * Parentheses around superscript citations in article


title: xelatex: I can't write on file `test.pdf'.

text: Every so often I'll be working and all of a sudden `xelatex` won't work, saying "I can't write on file `test.pdf'". But why not? Is it something I did? Did I insult xelatex? Now it won't even compile my test.tex. This is XeTeX, Version 3.1415926-2.2-0.9995.2 (TeX Live 2009/Debian) (format=xelatex 2011.4.22). Ubuntu 10.04. # The input               \documentclass{article}     \usepackage{fontspec,xltxtra,xunicode}     \setmainfont{Inconsolata}     \begin{document}     hello world     \end{document}      # The error               LaTeX Font Info:    Overwriting math alphabet `\mathsf' in version `bold'     (Font)                  OT1/cmss/bx/n --> EU1/lmss/bx/n on input line 4.     LaTeX Font Info:    Overwriting math alphabet `\mathtt' in version `bold'     (Font)                  OT1/cmtt/m/n --> EU1/lmtt/bx/n on input line 4.      [1     ! I can't write on file `test.pdf'.     (Press Enter to retry, or Control-D to exit; default file extension is `.pdf')     Please type another file name for output:      ! Emergency stop.     <to be read again>                         \endgroup \set@typeset@protect      l.6 \end{document}          End of file on the terminal!               Here is how much of TeX's memory you used:      5003 strings out of 495724      81422 string characters out of 1189346      150108 words of memory out of 3000000      8144 multiletter control sequences out of 15000+50000      3664 words of font info for 17 fonts, out of 3000000 for 9000      28 hyphenation exceptions out of 8191      40i,4n,27p,455b,147s stack positions out of 5000i,500n,10000p,200000b,50000s     No pages of output.      # The inconsistency of it all Ten minutes later (now), after tinkering around, it works. So I delete the contents of the file, and paste what I posted here, and, it works. Then I delete `test.*` except for the tex file, try xelatex again, and it doesn't work. The tinkering was to change the tex file to this:               \documentclass[12pt,letterpaper]{article}           \usepackage{fontspec}% provides font selecting commands      \usepackage{xunicode}% provides unicode character macros      \usepackage{xltxtra} % provides some fixes/extras           \setromanfont[Mapping=tex-text]{Inconsolata}     \begin{document}     hello world     \end{document}      # `strace -f` Strace shows a memory error right before the "cannot create pdf" line. I'm experimenting with adding more swap. Currently my system is down its last 300-400 MiB of ram, and I'm seeing `xelatex` using upwards of 200 MiB. Which means a couple more browser tabs or another pdf window could foul things up..               clone(child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0xb7887738) = -1 ENOMEM (Cannot allocate memory)`.


title: Insert \nobreak into subsection title in titletoc's \titlecontents star version

text: I want the label and title of subsection typsetting as a paragraph but NEVER break down in a subsection title. Say, the code below               \documentclass{article}     \usepackage{titletoc}          \titlecontents*     {subsection}     {}     {\thecontentslabel:\nobreakspace}{}     {\nobreakspace(\thepage)}[.\quad]          \begin{document}     \tableofcontents                    \section{A section}     \subsection{A subsection}     \subsection{Another subsection}     \subsection{A very long subsection}     \subsection{Again a subsection}     \subsection{A longest subsection in the article!}          \end{document}      I want the label of subsection 1.3 and 1.5 start in a new line respectively, like               1.1: A subsection (1)   1.2: Another subsection (1)     1.3: A very long subsection (1)   1.4: Again a subsection (1)     1.5: A longest subsection in the article! (1).


title: How do I align these equations?

text: $\frac{dP}{dr}=\frac{-\Big(P+\rho (P)c^2 \Big)} {2} \frac {d\nu} {dr}\]$\\     \newline     $$\Rightarrow d\nu = \frac {-2dP} {P+\rho (P) c^2}$$\\     \bigskip \newline     $$ \nu (r) = - \int_{0}^{P(r)} \frac {2dP}{P+\rho (P) c^2} + \nu (r_b)$$     \newline     \newline     \newline     $$ e^{\nu(r)} &= e^{\nu(r_b) -  \int_{0}^{P(r)} \frac {2dP}{P+\rho (P) c^2} }$$     \newline               $$ e^ {\nu (r)}= e^{\nu(r_b)} exp \Big[-\int_{0}^{P(r)} \frac {2dP}{P+\rho (P) c^2} \Big]$$      I am New to Latex so my codes look trivial , can you please align these equations for me ?


title: A length macro in display math and inline math and \text command

text: I want a length macro, named `\mymathspace`, which is changeable in inline math (including `\text` command) and display math. For example,               Text mode $inline\ math\vert\mymathspace\vert{}inline\ math$      get a space 6mu between the `\vert`s; and               \[display\ math\vert\mymathspace\vert{}display\ math\]      get a space 18mu between the `\vert`s; while               \[display\ math\text{Text mode $math\ in\ text\ command     \vert\mymathspace\vert$}display\ math\]      get a space 6mu between the `\vert`s. But I can't obtain this by `\if@display` and `\ifmmode`.


title: Align two nodes of different tikzpicture at the center of the page

text: I have a problem with the alignment of two tikzpicture environments.               \documentclass[14pt,spanish]{extarticle}     \usepackage{fontspec}     \setmainfont[Mapping=tex-text]{Ubuntu}     \usepackage{geometry}     \geometry{verbose,tmargin=2cm,bmargin=2cm,lmargin=2cm,rmargin=2cm}     \usepackage{subscript}          \makeatletter     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.     \usepackage{amsmath}     \usepackage{tikz}     \usepackage{textgreek}     \usepackage{mhchem}          \usetikzlibrary{shapes.geometric, arrows}          \tikzstyle{inicio} = [rectangle, rounded corners, minimum width=3cm, minimum height=1cm,text centered, draw=black, fill=yellow]     \tikzstyle{nodo} = [rectangle, rounded corners, minimum width=3cm, minimum height=1cm,text centered, draw=black]     \tikzstyle{arrow} = [thick,->,>=stealth]          \makeatother          \usepackage{babel}     \addto\shorthandsspanish{\spanishdeactivate{~<>}}          \usepackage{xunicode}     \begin{document}          \begin{figure}[h!]         \centering         \begin{tikzpicture}[node distance=2cm]               \node (fosforo) [inicio] {Fósforo};                  \node (ortofosfato) [nodo, below of=fosforo] {Ortofosfato (\ce{P-PO_4^{3-}})}; \draw [arrow] (fosforo) -- node [anchor=west] {medido como} (ortofosfato);         \end{tikzpicture}     \end{figure}          \begin{figure}[h!]         \centering         \begin{tikzpicture}[node distance=2cm]             \node (nitrogeno) [inicio] {Nitrógeno};                  \node (nitrato) [nodo, below of=nitrogeno, xshift=-2.5cm] {Nitrato (\ce{N-NO_3^{-}})}; \draw [arrow] (nitrogeno) -- node [anchor=east,xshift=-0.5cm] {medido como} (nitrato);             \node (amonio) [nodo, below of=nitrogeno, xshift=2.5cm] {Amonio (\ce{N-NH_4^+})}; \draw [arrow] (nitrogeno) -- node [anchor=west,xshift=0.5cm] {medido como} (amonio);         \end{tikzpicture}     \end{figure}          \end{document}      I want that the nodes "fosforo" and "nitrogeno" get aligned horizontally in the center of the page. How can I do that?


title: What is the intelligent way of setting the text width for a specific theorem in \newtheoremstyle?

text: I'm using a `\newtheoremstyle` to generate a `\newtheorem` called **Example**. However, I want the Example (the theorem) and the text, everything, to have a smaller text width than the normal text, and I don't know the efficient way of doing this, and avoid repeating code each time. Is there an intelligent way to do this in the `\newtheoremstyle`? Or elsewhere?


title: TeXworks can't compile any .tex document

text: I've just installed TeXworks on new computer (with ubuntu 10.4). It seems all required texlive packages are installed, in any case I can compile .tex documents using terminal. But in TeXworks while trying to run pdfLaTeX appears:               This is pdfTeX, Version 3.1415926-1.40.10 (TeX Live 2009/Debian)      restricted \write18 enabled.     entering extended mode     (./Szarfi.tex     ! Undefined control sequence.     l.2 \documentclass                       {book}     ?       Preamble is:               %& --translate-file=utf-8     \documentclass{book}     \usepackage[polish]{babel}     \usepackage[T1]{fontenc}     \usepackage[utf8x]{inputenc}     \begin{document}           here goes the text          \end{document}      I've uninstalled and installed once again TeXworks, the problem persist. I had before more general problem with the system, I thought I've resolved it with help of askubuntu, the thread is here: http://askubuntu.com/questions/28195/untrusted-packages-could-compromise-your- systems-security-appears-while-tryin, I don't know if there is any connection between those problems. Thanks in advance for any suggestions


title: Different image in every page's footer

text: I found Using fancyhdr to create an image based header and footer which is helpful and gave some ideas but I want to basically put in the bottom right or center of the footer a different image file (pdf or jpg) for each page in a latex document. Any suggestions? Thanks a lot! P.S. Sorry, I typically use article class with lots of mathtools in latex or xelatex, but I am very flexible!


title: Make pgfplots typeset axis units as reciprocals using siunitx

text: `pgfplots` has a library `units` that allows to typeset units in axis labels provided through `x unit=<unit>`. Through the key `\pgfplotsset{unit code/.code={\si{#1}}}`, it can be made to typeset the units using the excellent `siunitx`. My problem is the following: When I provide units with negative exponents, such as `\metre\per\second`, they are typeset as `m/s`, and not `ms^{-1}` as I would like (and as is the standard behaviour of `siunitx`). I've tried setting the `unit code` to `\si[per-mode=reciprocal]{#1}`, but it doesn't change the output. If I supply the unit using `x unit=\si{\metre\per\second}`, I get the desired output, but I would rather not call the `\si` command explicitly, as in my eyes it would defeat the purpose of using the `units` library if I end up typesetting the units myself anyway. MWE:               \documentclass{article}     \usepackage{siunitx}     \usepackage{pgfplots}     \usepgfplotslibrary{units}     \pgfplotsset{unit code/.code={\si{#1}}}     \begin{document}     \begin{tikzpicture}     \begin{axis}[     x unit=\metre\per\second, %This doesn't do what I want     y unit=\si{\metre\per\second}] %This does, but I don't want to type "\si{...}"     \end{axis}     \end{tikzpicture}     \end{document}      ![enter image description here](http://i.stack.imgur.com/jPynH.png)


title: Generate .1 files from MetaUML .mp files automatically with latexmk

text: I'm currently creating a personal `LaTeX` package and base .tex document that I can use to typeset my Computer Science reports at my university. One of the features I would like to have is to make `UML` diagrams in `MetaUML`. I would like to to generate the .1 files from the .mp files every time I run latexmk instead of doing it manually. Beneath I have made a minimal example of the directory structure I am using. Is it be possible to use latexmk to run mpost on the mp files in the images directory automatically or on demand? Or would I have to use an external makefile/script? My directory structure looks like this:               |-mainDocument.tex     |-createPDF.sh     |     |\styles     | |-myStyle.sty     |      |\images     | |-strategyPattern.mp     |      |\output     | |-generated PDF and fls file     |      |\tmp     | |-generated aux etc.      This is the content of myStyle.sty:               \NeedsTeXFormat{LaTeX2e}     \ProvidesPackage{myStyle}[2014/02/27]          \RequirePackage[a4paper]{geometry}     \RequirePackage[utf8]{inputenc}     \RequirePackage{graphicx}     \graphicspath{{./images/}}      this is the content of mainDocument.tex:               \documentclass[a4paper,10pt]{report}     \RequirePackage{./styles/myStyle}     \DeclareGraphicsRule{.1}{mps}{*}{}          \begin{document}         \begin{figure}           \centering             \includegraphics[width=\textwidth]{images/strategyPattern.1}           \caption{A picture of a uml.}         \end{figure}     \end{document}      strategyPattern.mp contains the content of this link and createPDF.sh is a wrapper around `latexmk -pdf -shell-escape -auxdir=tmp -output- directory=output mainDocument.tex` # Update After @Thruston comment I have been digging through the `latexmk` repository and found this file http://archive.cs.uu.nl/mirror/CTAN/support/latexmk/example_rcfiles/mpost_latexmkrc. I have added this to my `latexmkrc` file, however it never seems to run the subroutine. # Update 2 `strategyPattern.1` gets generated when I put `strategyPattern.mp` in the root directory, however it gives a error during the first pass of `latexmk`, the second pass is succesfull. I'm closing in on the problem, but my `LaTeX` and `Perl` skills are not sufficient enough to get it working with the `strategyPattern.mp` file in `/images`


title: Best and recommended way to write prime on i in $i^{th}$

text: I have two `$i^{th}$` and `$i^{\prime th}$` and it is hard to see prime in `$i^{\prime th}$`. I would like to know the opinion of expert LaTeX users about this. I wonder what is the best and recommend way to write `$i^{th}$` and `$i^{\prime th}$`.


title: How to ignore .latexmkrc

text: I usually love my .latexmkrc settings. However I am trying to play with `Template Toolkit` to build a LaTeX file, then compile it with `latexmk` (all of this inside a perl script) and thus I would like to use the default latexmk settings (i.e. no preview continuously etc). I would like to keep my .latexmkrc for personal use, therefore I am looking for a way to tell `latexmk` to ignore my `$HOME/.latexmkrc` file (via the -r flag?). Is this possible?


title: A macro with either one or two arguments

text: I am trying to define a macro with variable number of arguments. For example I want to define a macro with two arguments that can work with one argument as well. So the same macro works in two ways.               \textcolor{red}{sample text}      This would limit the red color to the sample text and whereas just calling `\textcolor{red}` would turn on the red color until the end of the document. So the second way of using the macro would be               \textcolor{red}      I was trying to implement the macro using `\@ifnextchar`. I am not having much success. Could you please give me some hints? Based on @Joseph's suggestion below I modified my toy code and it works. I still have problem understanding the actual execution flow in the code. Here is my code.               \documentclass[12pt]{article}     \makeatletter     \def\oneortwoargs#1{%     \@ifnextchar\bgroup%        {\twoargs@aux{#1}}        {\onearg@only{#1}}     }          \def\onearg@only#1{%        Only argument provided: #1 %     }          \def\twoargs@aux#1#2{%        Two arguments are provided. \\%        First argument: #1 \\ %        Second argument: #2%     }     \makeatother          \begin{document}     \oneortwoargs{gg}{fff}     \oneortwoargs{qq}     \end{document}      As @Joseph explained below one token is left in the input stream. What is confusing me is that `\onearg@only` and `\twoargs@aux` are invoked the same way with only one argument.


title: Defining shortcuts in LyX

text: I am used to typing in Tex (since am a member of math.stackexhange), I decided to use an editor to help my with the typing and based on recommendations I installed LyX (I am very new to this and a search in this forum didn't return a usefull results..). My question is this : I have words that I constatly type (like \mathbb{R} etc'), can I create some kind of a shortcut so I would only type something like \fR (field R) or any other usefull tricks to not type the same thing over and over again ?


title: Redefine underscore to produce roman subscript

text: I would like to redefine the underscore `_` to automatically set subscripts in math mode in roman type, as I currently find myself almost always using `_\mathrm{}`. I can't find a way of redefining what `_` does:   `\renewcommand_` gives               ! Missing control sequence inserted.     <inserted text>                      \inaccessible       and `\show_` just tells me               subscript character _.      I found a description of how to make `_` an active character on Anthony Lieken's website, but that just brings `_` and `^` to text mode and does not change the behaviour in math mode. Question: How do I make `_x` behave like `_\mathrm{x}`?


title: How to define a command to feed the contents of a list into an \ifcase construct?

text: It's common to use an `\ifcase` construct to redefine a command depending on the value of a counter. The following example illustrates this:               \documentclass{article}     \usepackage{xcolor}     \usepackage{etoolbox}          \newcommand\sectioncolor{}          \renewcommand\sectioncolor{%       \ifcase\value{section} brown\or red\or blue\else olive\fi}     \pretocmd{\section}{\color{\sectioncolor}}{}{}          \begin{document}          \section{Section One}     \section{Section Two}     \section{Section Three}     \section{Section Four}          \end{document}      The above redefinition of `\sectioncolor` using `\ifcase` implies manually feeding the colors in the `\ifcase` construct. What I would like to achieve is to have a command, say `\ColorList`, having as argument a comma separated list of variable length containing the colors to be used, and then redefine `\sectioncolor` to use the colors of the list depending on the section counter. So for example, referring to my sample code, using               \ColorList{brown,red,blue,olive}      would be equivalent to               \renewcommand\sectioncolor{%       \ifcase\value{section} brown\or red\or blue\else olive\fi}      and               \ColorList{yellow,magenta,cyan,orange,blue}      would be equivalent to               \renewcommand\sectioncolor{%       \ifcase\value{section} yellow\or magenta\or cyan\or orange \else blue\fi}      but. of course, without having to manually feed the colors into the `\ifcase`. How can this be done?


title: Suppressing = on a line in the align environment

text: How do I produce the following in `align` environment?               \begin{eqnarray*}& & abcd \\     &=& defg\\     &=& hijk     \end{eqnarray*}      I try               \begin{align*}&  abcd \\     &= defg\\     &= hijk     \end{align*}      But the result is not what I wanted.


title: How to change title style bibtex bibliography?

text: How to change font variant of title to italics? Currently only books have titles in italics but `misc`, `article` and `booklet` have normal font variant. I'm using plain BIBTeX style.


title: Thumb index for parts

text: I found this script but couldn't manage to adjust it for parts. Here's what I got so far:               \documentclass{book}     \usepackage{background}     \usetikzlibrary{calc}     \usepackage{ifthen}     \usepackage{lipsum}          \pagestyle{plain}          % background common settings     \SetBgScale{1}     \SetBgAngle{0}     \SetBgOpacity{1}     \SetBgContents{}          % auxiliary counter     \newcounter{partshift}     \addtocounter{partshift}{-1}          \definecolor{mp}{RGB}{240,240,240}          \let\Oldpart\part     \newcommand{\parttitle}{}     \renewcommand{\part}[1]{\Oldpart{#1}\pf\renewcommand{\parttitle}{#1}}          % the main command; the mandatory argument sets the color of the vertical box     \makeatletter     \newcommand\pf{%     \AddEverypageHook{%     \ifthenelse{\isodd{\thepage}}     {\SetBgContents{%       \begin{tikzpicture}[overlay,remember picture]       \node[fill=mp,inner sep=0pt,rectangle,text width=2cm,         text height=4cm,align=center,anchor=north east]        at ($ (current page.north east) + (-0cm,-2*\thepartshift cm) $)        {\rotatebox{90}{\hspace*{.3cm}\parbox[c][1.5cm][t]{3.4cm}{%         \raggedright\textcolor{black}{\parttitle}}}};       \end{tikzpicture}}%     }     {\SetBgContents{%       \begin{tikzpicture}[overlay,remember picture]       \node[fill=mp,inner sep=0pt,rectangle,text width=2cm,         text height=4cm,align=center,anchor=north west]        at ($ (current page.north west) + (-0cm,-2*\thepartshift cm) $)        {\rotatebox{90}{\hspace*{.3cm}\parbox[c][1.5cm][t]{3.4cm}{%         \raggedright\textcolor{black}{\parttitle}}}};       \end{tikzpicture}}     }     \bg@material}%       \stepcounter{partshift}     }     \makeatother          \begin{document}          \part{A}     \chapter{a1}     \lipsum[1-7]          \part{B}     \chapter{b1}     \lipsum[1-7]          \part{C}     \chapter{c1}     \lipsum[1-7]          \end{document}


title: Xindy with XeLaTeX gives error message

text: I would like to run XeLaTeX with Xindy. Therefore I copied the example in question How to use xindy with XeTeX/LuaTeX?. I used the code from where this is written (Herbert’s answer), but I used XeLaTeX instead:               xelatex <file>     xindy -C utf8 -I latex -M myModuleE <file>.idx     xelatex <file>      Using these command codes I get: > >     Unsupported input markup latex. >   When I remove `-I latex` I get the following error message. Unfortunately I do not get Xindy running anD I get an error message: > >     *** - PROGN: variable MYMODULEE.XDY has no value >   The module "MYMODULEE.XDY" is created and is in the directory of the TeX project. When I tried different other approaches (including different codes) always this error message appears, even though the relevant `*.xdy` is present and not empty. Has anyone an idea what goes wrong? I use a Windows 7 computer with the newest version of TeXworks, and a MacBook with Mac OS X 10.9.1 and TeXworks for mac. I never before used Xindy, so think it is still a configuration problem. So far I used LaTeX and MakeIndex, but u have many international characters, that is the reason why I would like to switch.


title: Citing a speech in BibTex

text: I would like to cite Alan Greenspan's speech from 1996. What should the appropriate bibtex entry look like?


title: transferring inline citations from MS word to LaTex

text: I'm converting a MS Word document into a LaTeX document. I have >100 references and would like to know the easiest way to convert all the inline citations from my MS Word document to my LaTeX document. I've already generated by BibTeX library and can convert each citation individually by hand if necessary. Is there a way that I can convert all my MS Word inline citations to the `\cite{author,date}` LaTeX format so that when I copy and paste into LaTeX the citations are recognized automatically? Do you have any other suggestions?


title: Latex Subfloat has odd text next to figures

text: I'm using template from sigchi http://www.sigchi.org/publications/chipubform/sigchi-papers-latex- template/view I'm having problem with subfloats. I have three figures and they look like this:               chch IMAGE1 chch IMAGE2 chch IMAGE3       Here is a screenshot: ![enter image description here](http://i.stack.imgur.com/KOeAu.png) Here is my code:               \begin{figure*}     \centering     \subfloat[A]         {\includegraphics[width=2.0inch]{images/MEMS3D}         \label{WIIMOTESENSOR}}     \subfloat[B]         {\includegraphics[width=2.0inch]{images/raymond}         \label{SPACESENSOR}}     \subfloat[C]         {\includegraphics[width=2.0inch]{images/raymond}         \label{SPACESENSOR2}}         \caption{Gyro}         \label{SENSORS}     \end{figure*}      Thanks!


title: Change bullet point symbol without changing \item

text: I have the following code:                \documentclass{beamer}                         \usepackage{pifont}               \begin {document}     \frame{         \frametitle{Test}     \begin{itemize}     \item test     \item test     \end{itemize}     }          \end{document}      Now I want to change the bullet points to another form, using `\ding{111}` and pifont:               \usepackage{pifont}      According to this thread I tried               \newcommand{\myitem}{\item[\checkmark]}      but than I have to change every `\item` in my presentation to `\myitem`, so how can I do this without needing to change the `\item`?


title: xelatex hangs when using fontspec

text: I'm using TexStudio 2.5.1 on Windows 7 with MiKTeX. The following brief .tex file will cause xelatex to hang:               \documentclass[12pt]{article}     \usepackage{fontspec}     \begin{document}     Test     \end{document}      Using this command to compile:               xelatex.exe -synctex=1 -interaction=nonstopmode "test".tex      By 'hang', I mean that the xelatex process will take up an entire core and 200+ MB of memory, and not finish after several minutes. I get no error messages because the process never finishes. If I comment out the fontspec line, it doesn't hang. But I'd like to use the fontspec package in my document. Why does it hang and how can I fix it? * * * As a side note, using lualatex instead of xelatex will succeed, but then using `\setmainfont{Georgia}` will make that hang as well.


title: show only play button with animategraphics

text: I transformed a gif in a serie of png files and I animated it in my pdf with the command `\animategraphics`. I want to have only a play button shown, not all the controls. Is there a way of doing this? Here is the full command that I used at the moment: `\animategraphics[loop,width=\textwidth]{50}{./figures/sim_gif/res_gl_animation_}{0}{399}` Thanks. Edit: Here's a MWE:               \documentclass[letterpaper, 12pt, final]{article}     \usepackage{graphicx}     \usepackage{animate}          \begin{document}          \begin{figure}         \centering         \animategraphics[loop,width=\textwidth]{50}{./figures/sim_gif/res_gl_animation_}{0}{399}         \caption{Some animation for MWE}     \end{figure}          \end{document}


title: Problem inserting pages from a PDF into a Lyx document

text: I want to insert one page from a PDF file into my Lyx presentation file. I use Insert-->File-->External, PDFPages, select the PDF file, then I go to Options and type 'pages={1}' to select the first page from the PDF. The result looks like a jumbled overlaid mess of all 7 pages of the PDF. This jumbled image does not show up at all in a compiled pdflatex output file. And it also causes an error when I try to preview the file by hitting command-t; the error reads "LaTex Error: File `' not found." I am new to Beamer in Lyx (though not entirely new to Lyx), I might be missing something basic. Do I need to install a package or something? Thank you for your help.


title: How to change the color scheme to make this figure more elegant?

text: Here different colors means different weight of the edge, and the color of the points is arbitrary. The tex code:                 \documentclass[aps,prl,superscriptaddress]{revtex4}       \usepackage{subfigure}       \usepackage{tikz}       \usepackage{pgfplots}       \usetikzlibrary{shapes.geometric, calc}       \usepackage[standard]{ntheorem}       \def\endproof{\vrule height6pt width6pt depth0pt}       \usepackage{color}       %%%%%%%%%%%%%%%%%%The color scheme begins       \definecolor{dsblue}{RGB}{65,105,225}       \definecolor{spgreen}{RGB}{46,139,87}       \definecolor{tored}{RGB}{220,20,60}       \definecolor{glyellow}{RGB}{218,165,32}       \definecolor{botcolor}{RGB}{119,136,153}       \definecolor{linecolor}{RGB}{128,128,128}       \definecolor{topcolor}{RGB}{0,0,139}       \tikzstyle{mypoint}=[shape=circle,draw,white,bottom color=botcolor,top color= topcolor]       \tikzstyle{myline}=[linecolor,thin]       \tikzstyle{mythick}=[thick]       %%%%%%%%%%%%%%%%%%The color scheme ends       \begin{document}       \begin{tikzpicture}[inner sep=0.55mm,scale=0.6]       \node at (0,1) [mypoint] (a10) {};       \node at (0,2) [mypoint] (a11) {};       \node at (0,3) [mypoint] (a12) {};       \node at (0,4) [mypoint] (a13) {};       \node at (0,5) [mypoint] (a14) {};       \node at (0,-1) [mypoint] (a20) {};       \node at (0,-2) [mypoint] (a21) {};       \node at (0,-3) [mypoint] (a22) {};       \node at (0,-4) [mypoint] (a23) {};       \node at (0,-5) [mypoint] (a24) {};       \node at (1,0) [mypoint] (b10) {};       \node at (2,0) [mypoint] (b11) {};       \node at (3,0) [mypoint] (b12) {};       \node at (4,0) [mypoint] (b13) {};       \node at (5,0) [mypoint] (b14) {};       \node at (-1,0) [mypoint] (b20) {};       \node at (-2,0) [mypoint] (b21) {};       \node at (-3,0) [mypoint] (b22) {};       \node at (-4,0) [mypoint] (b23) {};       \node at (-5,0) [mypoint] (b24) {};       %%%%%%%%%%%a1-b1=0=a2-b2=b2-a1,a2-b1=0,b1-a2-1=-1=4,4-4=0       \foreach \n/\m in {0/0,1/1,2/2,3/3,4/4} {      \draw [glyellow,mythick] (a1\n) -- (b1\m);      \draw [glyellow,mythick] (a2\n) -- (b2\m);      \draw [glyellow,mythick] (b2\n) -- (a1\m);       }       %%%%%%%%%%%a1-b1=-1=4=a2-b2=b2-a1,a2-b1=-1,b1-a2-1=0,4-0=4       \foreach \n/\m in {0/1,1/2,2/3,3/0} {       \draw [glyellow,mythick] (a2\n) -- (b1\m);       }       %%%%%%%%%%%a1-b1=1=a2-b2=b2-a1,a2-b1=1,b1-a2-1=-2=3,4-3=1       \foreach \n/\m in {1/0,2/1,3/2,4/3,0/4} {       \draw [spgreen,mythick] (a2\n) -- (b1\m);       \draw [tored,mythick] (a1\n) -- (b1\m);       \draw [tored,mythick] (a2\n) -- (b2\m);       \draw [tored,mythick] (b2\n) -- (a1\m);       }       %%%%%%%%%%%a1-b1=2=a2-b2=b2-a1,a2-b1=2,b1-a2-1=-3=2,4-2=2       \foreach \n/\m in {2/0,3/1,4/2,0/3} {       \draw [dsblue,mythick] (a2\n) -- (b1\m);       \draw [dsblue,mythick] (a1\n) -- (b1\m);       \draw [dsblue,mythick] (a2\n) -- (b2\m);       \draw [dsblue,mythick] (b2\n) -- (a1\m);       }       %%%%%%%%%%%a1-b1=3=a2-b2=b2-a1,a2-b1=3,b1-a2-1=-4=1,4-1=3       \foreach \n/\m in {3/0,4/1,0/2,1/3} {       \draw [tored,mythick] (a2\n) -- (b1\m);       \draw [spgreen,mythick] (a1\n) -- (b1\m);       \draw [spgreen,mythick] (a2\n) -- (b2\m);       \draw [spgreen,mythick] (b2\n) -- (a1\m);       }       \foreach \n/\m in {0/1,1/2,2/3,3/4} {       \draw [linecolor,thin] (a1\n) -- (a1\m);       \draw [linecolor,thin] (a2\n) -- (a2\m);       \draw [linecolor,thin] (b1\n) -- (b1\m);       \draw [linecolor,thin] (b2\n) -- (b2\m);       }       \node [above] at (a14) {$A_1$};       \node [below] at (a24) {$A_2$};       \node [right] at (b14) {$B_1$};       \node [left] at (b24) {$B_2$};       \end{tikzpicture}       \end{document}      ![enter image description here](http://i.stack.imgur.com/Cay7C.png)


title: How to remove margin notes space in book class?

text: By default, the "book" class produces a layout with a big space for margin notes. One consequence of this behavior is the binding side has a smaller margin than the other side (with the twoside option which is the default behavior). I don't use margin notes (at all) and I'm wondering if there is a way to say it to `LaTeX`. I would like _not only_ that the margin notes space would be removed but _also_ that `LaTeX` rearranges the other settings in consequence (for example, by increasing the binding side size). I could use `geometry` package (example below) or other way of define my own margins.               \usepackage{geometry}     \geometry{bindingoffset=2cm}      However I prefer to stay as close as possible to the default behavior. Like it is not so common to use margin notes (in academic books for example), there should be a option to deactivate margin notes. I didn't find it, perhaps someone does... Reminder : the default layout of book class : ![enter image description here](http://i.stack.imgur.com/12xVR.png)


title: Using `mathbb` fonts from other packages

text: I am currently using a combination of `mathpazo` and `mathspec` for my maths typesetting. To be specific, my preamble contains the following:               \usepackage{amssymb}          \usepackage{mathrsfs}     \usepackage{mathpazo}          \usepackage{mathtools}          \usepackage{mathspec}          \usepackage{xltxtra,xunicode}     \defaultfontfeatures{Mapping=tex-text}          \setmainfont[Numbers=OldStyle]{Palatino Linotype}     \setsansfont{Optima}     \setmonofont{Consolas}     \setmathsf{Optima}     \setmathfont(Greek){Palatino Linotype}          \exchangeforms{phi} However, I would like the option of using, say, the AMS blackboard bold fonts for `mathbb`, or the ones provided by STIX (or any other Unicode maths font) instead of the ones provided by `mathpazo`. So far nothing I've tried with `\setmathbb` has worked. I have a similar problem with `\setmathcal`, and I notice that if I use `calrsfs` instead of `mathrsfs` there is no effect whatsoever.


title: Creating a punktchain or flow diagram in tikz/pgf latex that is two column then merges to one and back to two

text: I have update the example code with some of the comments to get really close to what I want. Now I just want two lines coming out of filter 1 and filter 2 inline and with the same line style as already there for the smaller blocks. I assume this should be relatively easy but I can only figure out how to get the lines out of the center of the block.               \makeatletter     \tikzset{west above/.code=\tikz@lib@place@handle@{#1}{south west}{0}{1}{north west}{1}}     \tikzset{west below/.code=\tikz@lib@place@handle@{#1}{north west}{0}{-1}{south west}{1}}     \tikzset{east above/.code=\tikz@lib@place@handle@{#1}{south east}{0}{1}{north east}{1}}     \tikzset{east below/.code=\tikz@lib@place@handle@{#1}{north east}{0}{-1}{south east}{1}}     \makeatother     \fontsize{8pt}{9pt}\selectfont     \begin{tikzpicture}[       every node/.style={         rectangle,          rounded corners,          % fill=black!10,         draw=black, very thick,         minimum height=2em,          inner sep=2pt,         text centered,          align=center       },       big node/.style={text width=8cm},       small node/.style={text width=3.5cm},       >=latex, %Make the arrow tips latex       myline/.style={draw, very thick,black, <-, node distance=1.1cm},       mylinedot/.style={draw, very thick, blue!100!black!70, densely dotted, <-, node distance=1cm},       shorter/.style={shorten <=1mm,shorten >=0.5mm},       node distance=0.75cm,       |*/.style={to path=(\tikztostart.south) -- (\tikztostart.south|-\tikztotarget.north)},       *|/.style={to path=(\tikztostart.south-|\tikztotarget.north) -- (\tikztotarget.north)}       ]     \begin{scope}[every node/.append style={big node}]       \node (B) {\textbf{Filter process 1}};       \node[below=of B] (C) {\textbf{Filter process 2}};       \node[below=of C] (D) {\textbf{Filter process 3}};     \end{scope}     \begin{scope}[every node/.append style={small node}]       \node[west above=of B] (A1) {\textsc{Training Waveform}};       \node[east above=of B] (A2) {\textsc{Testing Waveform}};            \node[west below=of D] (E1) {\textbf{Reduced Model}};       \node[east below=of D] (E2) {\textbf{Full Model}};          \end{scope}     % \path (A1) -- node[F5 node] {F5} (A2);          \path[myline,->,shorter]  {[|*] (A1) edge (B)}                                     (B)  edge (C)                                     (C)  edge (D)                               {[*|] (D)  edge (E1)}                              ;     \path[mylinedot,->,shorter]  {[|*] (A2) edge (B) }                               {[*|] (D) edge (E2)}                               (E1) edge (E2)                              ;     \end{tikzpicture}      ![Flow Diagram](http://i.stack.imgur.com/i6mH2.png) This is the final solution but I get a miscellaneous arrow that I am not sure how to get rid of. All I did was change to the two path lines below from the above code with no other changes. Code is here:               \path[myline,->,shorter]  {[|*] (A1) edge (B)}                                   ([shift={(-2.25cm,0)}]B.south)  edge ([shift={(-2.25cm,0)}]C.north)                                   ([shift={(-2.25cm,0)}]C.south)  edge ([shift={(-2.25cm,0)}]D.north)                               {[*|] (D)  edge (E1)}                              ;     \path[mylinedot,->,shorter]  {[|*] (A2) edge (B) }                                   ([shift={(2.25cm,0)}]B.south)  edge ([shift={(2.25cm,0)}]C.north)                                   ([shift={(2.25cm,0)}]C.south)  edge ([shift={(2.25cm,0)}]D.north)                               {[*|] (D) edge (E2)}                               (E1) edge (E2)                              ;      ![Flow Diagram2](http://i.stack.imgur.com/4hqLD.png)


title: Video not playing

text: I want to play video in pdf using latex. Following is my sample code. When I try to play it, just an empty screen comes and video is not played. My basic requirement is that it should display picture with play/pause and when I play it should play. I could not understand much from media9 package file. Please help               \documentclass{article}          \usepackage{media9}          \begin{document}          \includemedia[label=videofile, width=1.0\textwidth, addresource=srs.mp4,     flashvars={source=srs.mp4}]{\includegraphics[width=1.0\textwidth]     {views}}{VPlayer.swf}           \end{document}


title: Manual for Presentation typesetting in ConTeXt

text: Is there a manual similar to the Beamer manual but for presentation in ConTeXt? I found this: http://wiki.contextgarden.net/Presentations but I feel it lacks many information, for example on navigation systems and themes. I also found some blog articles but they seem more focused on specific aspects and many of them are very old.


title: IEEE-Template: Algorithm over both columns

text: I'm currently working on a paper using the IEEEtran template. I do have a pseudocode I would like to put into this paper. In a former paper I saw that it is possible to put this algorithm in a box which is in a figure and fills up both columns of the paper. I want to do it the same way, however, I was not able to manage it. Could anyone help me out please?


title: Alter only one branch properties

text: I have a diagram in tikz-qtree like figure A, but I'd like something like figure B. Is it possibe, to alter the properties of only one brach? (these figures made with Dia and arrows not important) ![](http://i.stack.imgur.com/CpgAQ.png) **edit:** (added my modified code, based on Alan Munn's answer)                    \begin{center}     \begin{tikzpicture}[grow'=right,level distance=1.45in,sibling distance=.2in]          \tikzset{edge from parent/.style=      {thick, draw, edge from parent fork right},       every tree node/.style=         {draw,minimum width=1.3in,text width=1.15in,align=center}     }     \Tree        [.parent         [.child0           grandchild0-0           grandchild0-1           [[.{grandchild0-2}              {greatgrandchild0}              {greatgrandchild0}             {greatgrandchild0}              {greatgrandchild0}           ]]            grandchild0-3         ]          [.child1           [.grandchild1-0 ]            [.grandchild1-1 ]          ]        ]     \end{tikzpicture}     \end{center}


title: Trim image by number of pixels

text: Is it possible to trim an image by a certain number of pixels rather than a length? I have a set of images that I'm including, and in one figure, a trim of 135 on the bottom works nicely, but a second version of the same images that has undergone some image processing got saved with a different DPI (not a different size), so the same trim appears to trim them quite differently. However, both sets of images are 512x384, so is it possbile to just specify a trim in terms of image pixels, e.g. 100px? Thanks.


title: Forcing exactly the same column widths in table

text: Based on Writing descriptions of columns of table               \documentclass{article}     \usepackage{polski}     \usepackage[utf8]{inputenc}     \begin{document}     \begin{figure}\label{fig:ieee754single}     \centering\sf\setlength{\tabcolsep}{1.45pt}     \begin{tabular}{|*{32}{c|}}     \multicolumn{32}{|l}{\small  Bit}\\     \multicolumn{1}{|c}{\footnotesize  31}&\multicolumn{6}{c}{}&\multicolumn{1}{c|}{\footnotesize  24}&     \multicolumn{1}{|c}{\footnotesize  23}&\multicolumn{6}{c}{}&\multicolumn{1}{c|}{\footnotesize  16}&     \multicolumn{1}{|c}{\footnotesize  15}&\multicolumn{6}{c}{}&\multicolumn{1}{c|}{\footnotesize  8}&     \multicolumn{1}{|c}{\footnotesize  7}&\multicolumn{6}{c}{}&\multicolumn{1}{c|}{\footnotesize  0}\\     \hline     S &     E & E & E & E & E & E & E & E &     M & M & M & M & M & M & M & M &     M & M & M & M & M & M & M & M &     M & M & M & M & M & M & M \\     \hline     \multicolumn{1}{|c|}{}&     \multicolumn{8}{c|}{Wykładnik} &     \multicolumn{23}{c|}{Mantysa} \\     \cline{2-32}     \multicolumn{5}{|c}{\raisebox{-0.3ex}{Znak}} & \multicolumn{27}{c}{}\\     \cline{1-5}     \end{tabular}     \rm\caption{IEEE754 single}     \end{figure}     \end{document}      How can I force column widths to be the same. I like the width of E under 23.


title: Rearranging the table and making identical with the attached image

text: \documentclass[12pt,a4paper]{article}     \usepackage{amsmath}     \usepackage{amssymb}     \usepackage{graphicx}          \usepackage[left=1.25in, right=1.0in, top=1.25in, bottom=1.0in]{geometry}          \newcommand{\piRsquare}{\pi r^2}                  \title{{\bf Your Research Title}}     \author{Your Name }          \date{December 17, 2013}                         %     \begin{document} \baselineskip=22pt     \maketitle     %     \begin{abstract}     You have to write the abstract here.     \end{abstract}       %     \tableofcontents          %     \section{Introduction}     \begin{center}     \begin{tabular}{| l | l | l | l | l |}     \hline     Rank  & $\alpha$ & $\beta$ & $D_{Crisis}$ & Adj. $R^2$\\ \hline     Low  & 0.70 (0.22) & -0.35***(-43.92) & -5.96 (-1.07) &  36.36\\ \hline     2 & -7.86** (-2.33) & -0.35***(-41.65) & 2.15 (0.36) & 34.02\\ \hline     3 & -4.37 (-1.19) & -0.47*** (-51.19) & 3.81 (0.59) & 43.80 \\ \hline     4 & 2.21 (0.55) &-0.56*** (-55.55) & -4.50 (-0.64) & 47.79\\ \hline     5 & -2.26 (-0.53) & -0.53*** (-49.62) & 8.18 (1.08) & 42.31 \\ \hline     6 & 1.67 (0.36) & -0.59*** (-51.15) & -4.72 (-0.58) & 43.69\\ \hline     7 & 1.84 (0.42) & -0.67*** (-61.42) & 1.89 (0.24) & 52.85\\ \hline     8 & 0.27 (0.6) & -0.67***(-55.98)  & -9.75(-1.15) & 48.15\\ \hline     9 & -2.27 (-0.47) & -0.80*** (-55.18) & 11.85 (1.16) & 47.56\\ \hline     High & 1.68 (-0.23) & -0.98*** (-54.36) & 29.97**(2.36) & 46.92\\ \hline     High- Low & 0.99 (0.13) & -0.63*** (-32.39) & 35.93***(2.61) & 24.03\\ \hline     \end{tabular}     \end{center}          \end{document}      ![enter image description here](http://i.stack.imgur.com/aIQEM.png) **I want to get that   1. output of the table as I attached the image. So I need one number in up and other one below. They will not be aside. 2. First row and last row will be highlighted as the image looks.**


title: LuaLaTeX does not work anymore since last MiKTeX 2.9 update ("fatal format file error")

text: I just recently updated Miktex via the update wizard, and after that LuaLaTeX fails to generate any output. At first I thought it would have to do something with SIunitx, because I received an error there and it was used in the file I tried to employ LuaTeX on (SIunitx, was located into another package I think), but that wasn't the case. (SIunitx still doesn't work, because MiKTeX reports               "Message: Unknown archive file size.     Data: expl3     Source: libraries\miktex\packagemanager\internal.h     [...]"      when I try to get expl3 via the package manager. Anyway, I then tried to use as few packages as possible to rule out some incompatibilities introduced by the new update or something like that, and tried to use LuaLaTeX on the following file:               \documentclass{minimal}     \begin{document}     Test     \end{document}      And all I get is               This is LuaTeX, Version beta-0.70.1-2011052811 <rev 4277>          <Fatal format file error; I'm stymied>      No log-file, no output, nada, only this error message. pdfTeX and the latex- dvips-ps2pdf-way both work without any problems (at least on the above file). I could really use some help, since everything worked just fine about two weeks ago until my last update. Please let me know if you want to get further information or anything like that to help me with my problem. Oh, I almost forgot (in case it's important): OS: Windows Vista Home Premium (32bit), MiKTeX 2.9 (just updated :/) * * * I don't know whether I should make another separate question out of this, but I've got another problem with `luatex`, but only indirectly. I think I already know the cause, so I, more or less, just want to verify whether this is an issue of my own local installation, or a "global" problem: Not a long time ago, there was another MiKTeX-Update, so I updated. But then I tried to compile another document with `lualatex` that worked before, but `lualatex` didn't create a document at all, while not reporting any real problems (at least not via Texmaker). So I looked into the folder of the file, and voila, `lualatex`or `luatex`(:O) created a folder, named "luatex-cache" and a log file, but nothing more. I then tried to isolate the problem by making a minimal example and first found out, that it probably isn't a `luatex`-problem itself, since sth. like:               \documentclass{minimal}     \begin{document}     Test     \end{document}      was compiled without any problems. I then continuously added more packages and I think the troublemaker could be `luatextra`. Again, the only output of               \documentclass{minimal}     \usepackage[T1]{fontenc}     \usepackage{luatextra}     \begin{document}     Test.     \end{document}      was: a folder named "luatex-cache" with an empty subfolder named "generic" and a log-file. The last 4 lines of the log-file can be seen below (I hope these are sufficient):               .     .     .     Lua module: luaotfload 2011/04/21 1.25 OpenType layout system.     luaotfload: loading file C:/Program Files/MiKTeX 2.9/tex/luatex/luaotfload/otfl     -luat-dum.lua.     quiting: fix your readable cache path      If the moderators think this is important enough to post it as a separate question, I'm happy to do that. :D


title: What fonts are used in this formula?

text: I have been trying to match the following style for some work I am doing but can't see to match the various font weights very well. Does anyone know which fonts are being used? ![enter image description here](http://i.stack.imgur.com/BkuA2.png) In particular I can't seem to get the curly l, the 5 pointed asterisk and the right kerning between the fn and x.


title: \renewcommand{\refname}{} does not remove "References"

text: I have a file of class "article" with bibliography style "nature" Since I want to have the references in the table of contents with a section number, i have set a section with the references inside and now want to hide the automatically set title "References" As far as I know, `\renewcommand{\refname}{}` should do the magic, but it doesn't. What am I missing?


title: Error when using \autocite within \section

text: When I load `hyperref` and use the `\autocite{...}` command within a `\section{...}`, my `.log` file reveals the following warning:               Package hyperref Warning: Token not allowed in a PDF string (PDFDocEncoding):     (hyperref)                removing `\autocite' on input line 27.      I wish to cite an entire section, as it will be adapted from another source (i.e., an experimental procedure). Could someone explain this warning and how to fix it? Searching similar questions didn't lead to a solution, so forgive me if this is a duplicate. MWE to reproduce the warning:               \documentclass{article}     \usepackage[backend=biber]{biblatex}     \addbibresource{\jobname.bib}     \usepackage{filecontents}     \begin{filecontents*}{\jobname.bib}     @BOOK{example,       author    = {Example E. Example},       title     = {The Complete Example Reference},       publisher = {The Example Companies, Inc.},       year      = {2012},       address   = {New York},       isbn      = {000-0-00-000000-0},       pages     = {1--10}     }     \end{filecontents*}     \usepackage{hyperref}     \hypersetup{colorlinks=true}     \begin{document}     \section{Example\autocite{example}}     This entire section is to be cited!     \nocite{*}     \printbibliography     \end{document}


title: Allow [ characters in tables without entering math-mode (from R)

text: I have R code that produces latex code like:               \begin{tabular}{D{.}{.}{7}D{.}{.}{7}}     \toprule     \multicolumn{1}{c}{x} & \multicolumn{1}{c}{y} \\     \midrule     [1, 5) &  1 \\     [1, 5) &  2 \\     [5, 8) &  5 \\     [5, 8) &  7 \\     [8,10] &  8 \\     [8,10] & 10 \\     \bottomrule     \end{tabular}      And this is producing math errors:               ! LaTeX Error: Bad math environment delimiter.      How do I prevent this from happening? I'd like the square brackets to be printed as-is since they represent intervals - previously in the office a workaround of switching to a { has been done but it looks terrible! I've read around but not seen anything specific about preventing latex from entering math-mode. However, I'm new to this so I'm probably using the wrong keywords! **Example** I'm producing the code inside knitr chunks with the following parameters:               <<tab-example,echo=FALSE,cache=FALSE,results='asis'>>=     example<-data.frame(cbind(x=1:10,y=1:10))     example$x<-cut(example$x,3)     toLatex(example)     @      **Packages currently used**               \usepackage{fancyhdr,dcolumn,booktabs,float,titlesec}     \usepackage[margin=0.7in]{geometry}     \usepackage[us,12hr]{datetime}


title: Chronology - year in first item

text: In the following `chronology` example, how should it be written, when I need number of year in first comma? In my case I need 1980 to show. EDIT BY LOCKSTEP (copied from edit of now-deleted post by OP): Stephan Lukasczyk --> Thanks. Here is all needed LaTeX code.               \documentclass[11pt,titlepage]{article}          \usepackage{a4wide}     \usepackage[czech]{babel}     \usepackage[utf8]{inputenc}     \usepackage{chronology}          \begin {document}         \begin{chronology}[5]{1980}{2015}{3ex}{\textwidth}             \event{1984}{first}             \event[1985]{1986}{two}             \event{\decimaldate{25}{12}{2001}}{three}         \end{chronology}     \end{document}


title: \captionof messes with paragraph indent

text: \documentclass{mwrep}     \usepackage[font=small,compatibility=false]{caption}     \usepackage[chapter]{minted}     \usepackage{lipsum}     \begin{document}     \chapter{Test}     \lipsum[2-3]     \captionof{listing}{Caption of listing}          \lipsum[2-3]     \end{document}      In the provided example, using of `\captionof` causes all paragraph indents to disappear (after `\captionof`). How can it be fixed?


title: How can I remove an empty caption line

text: I'm generating LaTex automagically from a lengthy document that is written in the multimarkdown language, compiled by a software package called Scrivener. It's a workflow that works well, but this is one of the issues I'm hitting. I don't want to have to replace / delete numerous caption command each time I compile to LaTex. The MWE below illustrates the issue. This remove `Figure n:` and caption from included graphic. However, it leaves a blank line, which makes the images spacing appear gauche. Is there a simple way to remove the blank line , without inserting space adjustments, each time a figure is used Thanks.               \documentclass{memoir}          \usepackage{mwe}                    %   for dummy images     \usepackage[labelformat=empty]{caption} %   remove figure captions          \begin{document}           \begin{figure}[!ht]       \centering       \includegraphics[width=0.5\textwidth]{image}                          \caption{}       \end{figure}        This is first text after caption.          \end{document}


title: longtable: avoiding multiple captions

text: I have some problems using `longtable` with a caption. The caption repeats every page therefore multiple entries are created in the _list of tables_. I only want one caption per table - for the following example there should be one caption and one entry in the list of tables - not three. How can this be achieved?               \documentclass{scrbook}     \usepackage{longtable}     \begin{document}     \listoftables          \renewcommand{\arraystretch}{5.0}     \begin{longtable}[htb]{|p{1in}|p{1in}|}     \caption{my table}\\         \hline          1 & 2 \\         \endhead         \hline  a & b  \\ \hline c & d \\ \hline e & f \\         \hline  a & b  \\ \hline c & d \\ \hline e & f \\         \hline  a & b  \\ \hline c & d \\ \hline e & f \\         \hline  a & b  \\ \hline c & d \\ \hline e & f \\         \hline  a & b  \\ \hline c & d \\ \hline e & f \\     \end{longtable}     \end{document}


title: Remove box in beamer slides

text: Given the following minimal example of my presentation                   \documentclass[10pt]{beamer}     \usepackage{beamerthemeshadow}     \usepackage[english]{babel}     \usepackage[utf8]{inputenc}                    \begin{document}          \title{Nice talk}               \frame{\titlepage}                \frame{\frametitle{Agenda}\tableofcontents}                %%%%%%%%%%%%%%%%%%%%%%     \section{Introduction}      \frame{\tableofcontents[currentsection]}               \subsection{beginning}      \frame{ \frametitle{state of the art}          some explanation          }               %%%%%%%%%%%%%%%%%%%%%%     \section{Results}      \frame{\tableofcontents[currentsection]}               \subsection{outcome}      \frame{ \frametitle{results obtained}          some results           }               \end{document}      I wonder what is the name of the box that appears above all slides (Table of contents?) and how can I remove it completely on this case (without changing the style -colors, etc-)


title: How to put one cartoon in the background of one book

text: I would like to add one cartoon in the right margin of odd pages in one book. More precisely, ...   * ... the page #1 must contain the picture #1,   * ... the page #3 must contain the picture #2,   * ... the page #5 must contain the picture #3,   * ... and so on. How can I achieve this ?


title: Robust colored background for parts of the document

text: I would like to set off certain parts of my document by giving them a colored background. With the help of `adjustbox` I was able to write an environment that does more or less what I want: It puts its contents in a borderless, unpadded box with a colored background.               \usepackage{adjustbox}     \newenvironment{shaded}       {\par\noindent\adjustbox{frame=0pt,bgcolor=yellow,minipage=\textwidth}\bgroup}       {\egroup\par}      The problem is that this is, well, a box. It cannot be broken across pages, and it doesn't play nice with floats etc., which cannot be encountered while creating a box. (Thanks to the `minipage` option, footnotes are captured at the bottom of the shaded area instead of disappearing entirely). For my particular use, restructuring the document to avoid these problems is not an option. So the question is: Are there any solutions for creating a colored background that are as transparent as possible? I've seen a number of answers for coloring tables, code snippets, boxing that supports page breaks, complete pages(a, b), etc., but nothing I can see how to adapt for more general use. Complete MWE:               \documentclass{article}          \usepackage{xcolor,adjustbox}          \newenvironment{shaded}       {\par\noindent\adjustbox{frame=0pt,bgcolor=yellow,minipage=\textwidth}\bgroup}       {\egroup\par}          \begin{document}          \section{Regular section}     This section is not highlighted.      This text is just padding to indicate the natural line length.           \begin{shaded}     This is set with a colored background.          \section{Highlighted section}     This entire section is,      actually.\footnote{This footnote is trapped in the minipage.}          \begin{table}     This float triggers an error and disappears.     \end{table}          \end{shaded}          \section{The rest of the document}     \end{document}


title: font size of \footcite of biblatex in beamer

text: I have unsuccessfully tried to control the font size of `\footcite` with `\renewcommand{\bibfont}{\tiny}`? Is there any other way?


title: PGFPlots x-axis problem

text: I've been stumped on how to get the y-axis to turn off, but to have the x-axis have a set domain. Every time I run the two code samples, the x-axis domain is always 0->1. The goal is to set the x-axis domain to 1->10. Help?               \documentclass[]{article}     \usepackage{tikz}     \usepackage{pgfplots}     \pgfplotsset{compat=1.7}          \begin{document}          \begin{tikzpicture}      \begin{axis}[         domain=1:10,         hide y axis,         axis x line=middle     ]          \draw[line width=2] (axis cs:0, 0) -- (axis cs: 1, 0);          \end{axis}     \end{tikzpicture}          \begin{tikzpicture}      \begin{axis}[         xmin=1,         xmax=10,         axis y line=none,         axis x line=middle     ]          \draw[line width=2] (axis cs:0, 0) -- (axis cs: 1, 0);          \end{axis}     \end{tikzpicture}          \end{document}


title: How do I align enumerate items inside empty description?

text: I have an `enumerate` list inside an empty `description` item. The minimal file is,               \documentclass[11pt]{article}               \begin{document}     \begin{description}     \item [A Label:]            \begin{enumerate}       \item A1.       \item A2.       \item A3.       \end{enumerate}     \end{description}                    \end{document}      The problem is, A1 comes after the colon (:). As you can see here, ![enter image description here](http://i.stack.imgur.com/iUAiH.png) But I want A1 in a new line, with 1. aligned with 2. I tried putting a `\relax` in the empty `description` item. Nothing was improved. Any suggestion will be appreciated.


title: How do I make a dashed or dotted checkmark?

text: How do I get a dashed or dotted checkmark in LaTeX (either math mode or text mode is fine). I'm looking for a symbol approximately like ![enter image description here](http://i.stack.imgur.com/eTA1E.png)


title: minitoc package: overfull \hbox

text: Does anyone of you know how to format a ToC created with the `minitoc` package in LaTeX? My problem is that I always get the following warning:               ./hauptdokument.mtc.1:21:Overfull \hbox (2.83262 pt too wide) detected      This happens if the page number is greater than 10 e. g. 1-10 or 1-12. I've read the `minitoc` documentation but I didn't find a solution to widen the box around the page numbers so I appreciate any help you could give. I use the following commands to format my minitoc:               \mtcselectlanguage{german}          \renewcommand{\mtcSfont}{\small\rm}          \dominitoc


title: Problem with loop-generated pkgkeys containing a space

text: I'm trying to use `\pgfkeys` in the following setting:               \documentclass{article}          \usepackage{tikz}     \usepackage{pgfkeys}          \begin{document}     \begin{tikzpicture}[%         m1 color/.initial=red,         m2 color/.initial=green,         m3 color/.initial=blue,       ]       \foreach \i in {1, ..., 3} {%         \pgfkeys{/tikz/m\i color/.get=\c}         \node at (0, \i) [color=\c] {\i};       }     \end{tikzpicture}     \end{document}      And when I compile it, I get the following error:               ! Package xcolor Error: Undefined color `\c '.      If I change the code to not use `\i` to select the key, i.e.:               \documentclass{article}          \usepackage{tikz}     \usepackage{pgfkeys}          \begin{document}     \begin{tikzpicture}[%         m1 color/.initial=red,         m2 color/.initial=green,         m3 color/.initial=blue,       ]       \foreach \i in {1, ..., 3} {%         \pgfkeys{/tikz/m1 color/.get=\c}         \node at (0, \i) [color=\c] {\i};       }     \end{tikzpicture}     \end{document}      then it compiles, but now I can't iterate over the keys. I also noticed that _this_ actually works:               \documentclass{article}          \usepackage{tikz}     \usepackage{pgfkeys}          \begin{document}     \begin{tikzpicture}[%         color1/.initial=red,         color2/.initial=green,         color3/.initial=blue,       ]       \foreach \i in {1, ..., 3} {%         \pgfkeys{/tikz/color\i/.get=\c}         \node at (0, \i) [color=\c] {\i};       }     \end{tikzpicture}     \end{document}      So what's the problem with the first example? Just for curiosity, I tried changing `m1 color` to `m1_color`, and _now_ it works. Hence, it appears to have something to do with the spaces. But what?