title: How to resolve the error "deselaers/logos/rwthaachenuniversity-whitegray not found" in beamer poster?

text: I was using the following code for preparation of a poster in Latex using **TeXstudio 2.6.6**               \documentclass[final,hyperref={pdfpagelabels=false}]{beamer}     \usepackage{grffile}     \usepackage{graphicx}     \mode<presentation>{\usetheme{I6pd2}}     \usepackage[english]{babel}     \usepackage[latin1]{inputenc}     \usepackage{amsmath,amsthm,amssymb,latexsym}     \boldmath     \usepackage[orientation=landscape,size=a0,scale=1.4,debug]{beamerposter}     \newcommand{\R}{{\mathbb R}}     \usepackage{array,booktabs,tabularx}     \newcolumntype{Z}{>{\centering\arraybackslash}X} % centered tabularx columns     \newcommand{\pphantom}{\textcolor{ta3aluminium}} % phantom introduces a vertical space in p formatted table columns??!!     \listfiles     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     \graphicspath{{figures/}}      \title{\huge Comparisons of   $B_{row}$-splittings  of Matrices}     \author{ \vspace{.2cm} {\bf \large{ author}}\\ \vspace{.2cm} Research Supervisor- prof john\\ \vspace{.2cm} School of statistics}     \institute{institute name}     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     \newlength{\columnheight}     \setlength{\columnheight}{105cm}     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     \begin{document}     \begin{frame}       \begin{columns}     \begin{column}{.49\textwidth}       \begin{beamercolorbox}[center,wd=\textwidth]{postercolumn}         \begin{minipage}[T]{.95\textwidth}  % tweaks the width, makes a new \textwidth           \parbox[t][\columnheight]{\textwidth}{             \begin{block}{INTRODUCTION}     In many practical problems we come across the problem of computing a      solution to a system of linear equations in $n$ unknowns \textcolor{blue}     {\begin{eqnarray}\label{eq0}     Ax=b,\end{eqnarray}     }     where $A$ is a real rectangular $m\times n$ matrix and $b$ is a real $m$-vector.      In a wide variety of such problems, including the Neumann problem  and those      for elastic bodies with free surfaces, the finite difference formulations lead to      a singular, consistent linear system (\ref{eq0}) where $A$ is large and sparse.      Here the general method of solution is iterative in nature. Iterative methods      where $A$ is rectangular or inconsistent, have been studied     in \cite{bpcones}. The authors  used generalized matrix     inverses for computing least square solutions in the inconsistent     \textcolor{blue}{     \begin{eqnarray}\label{eq01}     x^{(i+1)}=U^{\dag}Vx^{(i)}+U^{\dag}b,     \end{eqnarray}     }     where $U^{\dag}$ is the Moore-Penrose inverse of $U$.      \vspace{.5cm}     The above scheme is said to be convergent if the spectral radius of     $U^{\dag}V$ is less than 1. For a proper splitting, the authors of      \cite{bpcones} have shown that  $x=A^{\dag}b$ for any initial     vector $x^{0}$ if and only if (\ref{eq01}) is convergent.     \end{block}             \vfill             \begin{block}{PRELIMINARIES}     \textcolor{darkgreen}{Moore-Penrose inverse}\\     The  Moore-Penrose inverse of $A\in {\R}^{m\times n}$     is the unique matrix $A^{\dag}\in {\R}^{n\times m}$ that satisfies the following four         equations:     $$AA^{\dag}A=A,~~~~A^{\dag}AA^{\dag}=A^{\dag},~~~~(AA^{\dag})^{T}=AA^{\dag}~~\mbox{and}     ~~(A^{\dag}A)^{T}=A^{\dag}A.$$     If $A^{\dag}\geq 0$, then it is semimonotone. Berman and Plemmons, \cite{bpmonotono}       showed that      $A^{\dag}\geq 0$  if and only if $ Ax\in {\R}^m_+ +N(A^T) ~~\mbox{and}~~x \in     R(A^{T})$ imply  $x\geq 0.$           \textcolor{darkgreen}{Row monotone matrix}\\      $A\in {\R}^{m\times n}$ is said to be row monotone \cite{bpmonotono} if  $ Ax\geq 0        ~~\mbox{and}~~x \in     R(A^{T})$ imply  $x\geq 0.$ \\            $A$ is row monotone if and only if $A$ is      $\{1,4\}$-monotone. ($\{1,4\}$-monotone means there is a nonnegative $G$ satisfying       $AGA=A$ and $(GA)^T=GA$.)     If $A^{\dag} \geq 0$,  then $A$ and $A^T$ are  row monotone.      However, the converse is not true. \\           A  decomposition $A=U-V$ of $A\in {\R}^{m\times n}$ is called       \textcolor{blue}{{\it positive}}  if $U\geq 0$ and $V\geq 0$. \\     \vspace{.2cm}          \textcolor{darkgreen}{ $B_{row}$-splitting (Definition 2.6, \cite{mis})}\\     A positive   proper splitting $A=U-V$ of $A\in {\R}^{m\times n}$ is called a $B_{row}$-       splitting if it satisfies the following conditions: \\     (i) $VU^{\dag}\geq 0$, and \\     (ii) $ Ax,~ Ux\geq 0 ~~\mbox{and}~~x \in R(A^{T})$ imply  $x\geq 0.$\\          \vspace{.2cm}     \textcolor{darkgreen}{Theorem 1} (Theorem 2.7, \cite{mis})\\     Let $A\in {\R}^{m\times n}$. Suppose that $R(A) \cap int(\mathbb{R}^m_+) \neq        \emptyset$. Consider the following statements:\\     (a) $A$ is row monotone.\\     (b) $ {\R}_{+}^{m}\cap R(A) \subseteq A{\R}_{+}^{n}$.\\     (c) There exists $x^{0}\in {\R}_{+}^{n}$ such that $Ax^{0} \in int({\R}_{+}^{m})$.\\     Then, we have (a) $\Rightarrow$ (b) $\Rightarrow$ (c).\\     Suppose that $A$ has a $B_{row}$-splitting. Then each of the above is equivalent to the        following:\\     (d) $\rho(VU^{\dag})<1$.          \vspace{.2cm}          \textcolor{darkgreen}{Theorem 2} (Theorem 2.12, \cite{mis})\\     Suppose that $A$ is row monotone and $R(A) \cap int({\R}^{m}_{+}) \neq \emptyset$ for        $A\in {\R}^{m\times n}$.      Further, let $A^{\dag}A\geq 0$. Then $A$ possesses a  $B_{row}$-splitting $A=U-V$  with          $\rho(VU^{\dag})<1$.     \end{block}     \vfill      \begin{block}{OBJECTIVE}     To  present a more general       convergence theorem for $B_{row}$-splitting and to  compare two $B_{row}$-splittings.     \end{block}           }         \end{minipage}       \end{beamercolorbox}     \end{column}     % ---------------------------------------------------------%     % end the column          % ---------------------------------------------------------%     % Set up a column      \begin{column}{.49\textwidth}       \begin{beamercolorbox}[center,wd=\textwidth]{postercolumn}         \begin{minipage}[T]{.95\textwidth} % tweaks the width, makes a new \textwidth           \parbox[t][\columnheight]{\textwidth}{ % must be some better way to set the the height, width and textwidth simultaneously             % Since all columns are the same length, it is all nice and tidy.  You have to get the height empirically             % ---------------------------------------------------------%             % fill each column with content                 \begin{block}{MAIN RESULTS}     We begin with the following lemma which is useful to prove our main results of this section.     \vspace{.4cm}     \textcolor{yellow}{LEMMA 3}\\     \textcolor{blue}{(a) If $A$ is row monotone, $V\geq 0$ and $R(V)\subseteq R(A)$, then       $A^{\dag}V\geq 0$.\\     (b) If $A^T$ is row monotone, $V\geq 0$ and $N(A)\subseteq N(V)$, then $VA^{\dag}\geq      0$.}          \vspace{.4cm}     Now, we obtain a new  convergence theorem for  $B_{row}$-splittings which holds      even without the assumption $R(A) \cap int({\R}^{m}_{+}) \neq \emptyset$. Thus, the       present one is more general  than the earlier one (Theorem 2).          \vspace{.4cm}     \textcolor{yellow}{THEOREM  4}\\     \textcolor{blue}{ Let  $A=U-V$ be a  $B_{row}$-splitting of $A\in {\R}^{m\times n}$. If       $A$ is row monotone,then\\     (a) $A^{\dag}\geq U^{\dag}$;\\     (b) $\rho(VA^{\dag})\geq \rho(VU^{\dag})$;\\     (c) $\rho(VU^{\dag})=\rho(U^{\dag}V)=\frac{\rho(A^{\dag}V)}{1+\rho(A^{\dag}V)}<1$.}          \vspace{.4cm}     Theorem 2 enables us that there exist several $B_{row}$-splittings of a given matrix.     In this direction, we  present  two comparison theorems for  $B_{row}$-splittings.          \vspace{.4cm}     \textcolor{yellow}{THEOREM 5}\\     \textcolor{blue}{ Let  $A=U_{1}-V_{1}=U_{2}-V_{2}$ be two  $B_{row}$-splittings of     $A$. If  $A$ is  row monotone and $V_{2}\geq V_{1}$, then     $$1> \rho(U_{2}^{\dag}V_{2}) \geq \rho(U_{1}^{\dag}V_{1}).$$}          \vspace{.4cm}     \textcolor{yellow}{EXAMPLE 6 }     Let $A=\left(          \begin{array}{cc}            1 & 1 \\            1 & 1 \\          \end{array}        \right)     $. Clearly $A$ is row monotone. Setting     $U_{1}=3A$ and $U_{2}=4A$.  We  then have $0\leq V_{1}=2A\leq 3A=V_{2}$.  Hence     $\rho(V_{1}U_{1}^{\dag})=\frac{2}{3}\leq \frac{3}{4}=\rho(V_{2}U_{2}^{\dag})<1$.          \vspace{.4cm}     The condition $V_2\geq V_1$ can not be dropped. For example, set $V_{1}=3A$ and        $V_{2}=2A$.Then the implication $$\rho(U_{1}^{\dag}V_{1}) \leq \rho(U_{2}^{\dag}V_{2}) <       1$$ does not hold. Similarly,the assumption  $U_{1}^{\dag}\geq U_{2}^{\dag}$ in the       Theorem given below can not be dropped.          \vspace{.4cm}     \textcolor{yellow}{THEOREM 7}\\     \textcolor{blue}{ Let $A\in {\R}^{m\times n}$ be such that $A$ and $A^T$ are row        monotone. Let $A=U_{1}-V_{1}=U_{2}-V_{2}$ also be   two  $B_{row}$-splittings of     $A$.  If $U_{1}^{\dag}\geq U_{2}^{\dag}$,then $$1>\rho(U_{2}^{\dag}V_{2}) \geq       \rho(U_{1}^{\dag}V_{1}).$$ }     \end{block}     \vfill     \begin{block}{CONCLUSIONS}     A convergence theorem and comparison theorems for  $B_{row}$-splittings are presented.      \end{block}     \vfill     \begin{block}{PUBLICATIONS}     {Jena, L. and Mishra, D.},      \emph{Comparisons of   $B_{row}$-splittings and $B_{ran}$-splittings of Matrices},     Linear and Multilinear Algebra, DOI 10.1080/03081087.2012.661426     \end{block}     \vfill     \begin{block}{ACKNOWLEDGEMENTS}     I thank my research supervisor  prof. john    for his  encouragement.      \end{block}     \vfill     \begin{block}{REFERENCES}               \begin{thebibliography}{10}     \bibitem{bpcones} {Berman, A.; Plemmons, R. J.},      \emph{Cones and iterative methods for best square least squares solutions of linear       systems},SIAM J. Numer. Anal., 11 (1974) 145-154.          \bibitem{bpmonotono} {Berman, A.; Plemmons, R. J.},     \emph{Monotonicity and the generalized inverse},SIAM J. Appl. Math.  22 (1972) 155-161.               \bibitem{mis} {  Mishra, D.;  Sivakumar, K. C.},     \emph{Generalizations of matrix monotonicity and their relationships with      certain subclasses of proper splittings},     Linear Algebra Appl. DOI:10.1016/j.laa.2011.11.016 .          \bibitem{per} {Peris, J. E.},      \emph{A new characterization of inverse-positive matrices},      Linear Algebra Appl.  154/156  (1991) 45-58.          \bibitem{var} {Varga, R. S.},     \emph{Matrix Iterative Analysis},  Springer-Verlag, Berlin, 2000.          \end{thebibliography}     \end{block}     }         \end{minipage}       \end{beamercolorbox}     \end{column}     % ---------------------------------------------------------%     % end the column     \end{columns}       \end{frame}      \end{document}      I am getting the following errors               File `deselaers/logos/rwthaachenuniversity-whitegray' not found.      Package xcolor Error: Undefined color `darkgreen' \end{frame}     Package xcolor Error: Undefined color `darkgreen' \end{frame}     Package xcolor Error: Undefined color `darkgreen' \end{frame}     Package xcolor Error: Undefined color `darkgreen' \end{frame}     Package xcolor Error: Undefined color `darkgreen' \end{frame}     File `deselaers/logos/rwthaachenuniversity-whitegray' not found. \end{frame}      I don't know why these errors are there. I need the help of experts.


title: Drawing simple graph pattern with Tikz

text: I've been using LaTeX since three years, but I've always avoided the Tikz package for drawing. Now I am writing my degree thesis and I'm forced to use it to achieve a better result. The problem is just I don't have time right now to start a deep walkthrough. I have to draw these simple pattern of graphs: a triangle and a complete bipartite graph (see picture below). I found the sample code of a simple triangle graph on the web and I tried to rearrange nodes using relative positioning, but the result was simply awful! This is my try.               \begin{tikzpicture}[->,>=stealth',shorten >=1pt,auto,node distance=3cm,             thick,main node/.style={circle,fill=blue!20,draw,minimum size=1cm,inner sep=0pt]}]              \node[main node] (1) {$1$};         \node[main node] (2) [below left of=1]  {$2$};         \node[main node] (3) [below right of=1] {$3$};              \path[-]         (1) edge node {} (2)             edge node {} (3)         (2) edge node {} (1)             edge node {} (3)         (3) edge node {} (1)             edge node {} (2);     \end{tikzpicture}      Could you give me any help to improve this result? Thank you. ![Graph pattern](http://i.stack.imgur.com/GBKQc.jpg)


title: Can we extract the points making the character from the font file?

text: Rather than tracing the border of a magnified character to find some critical points making the character as follows, ![enter image description here](http://i.stack.imgur.com/tL7r6.png)               \documentclass[pstricks,border=12pt]{standalone}     \usepackage{pst-text,pst-eucl}          \DeclareFixedFont{\ps}{U}{psy}{m}{n}{12cm}% the symbol font     \DeclareFixedFont{\PS}{T1}{ptm}{m}{n}{11cm}% the times font          \def\x{4}          \psset     {         showpoints=true,         linecolor=red,         PointName=none,         dotscale=0.5,     }          \newpsstyle{gridstyle}     {         subgriddiv=10,         subgridcolor=lightgray,         subgridwidth=0.05pt,         subgriddots=0,         gridcolor=black,         gridwidth=0.1pt,         griddots=0,         gridlabels=5pt,         gridlabelcolor=red,     }     \begin{document}          \begin{pspicture}[showgrid](-\x,\x)(\x,-\x)         \rput(0,0){\pscharpath[linecolor=blue,linewidth=0.1pt]{\PS R}}         \pstGeonode         (-3.483, 3.700){n1}         (-0.800, 3.700){n2}         ( 1.260, 3.700){c1}         ( 2.340, 3.200){c2}         ( 2.340, 1.700){n3}              \psline(n1)(n2)         \psbezier(n2)(c1)(c2)(n3)     \end{pspicture}          \end{document}      I want to extract such points directly from the font file. Is it possible to do that? The objective is to recreate such a character to be used for clipping discussed in my previous question How to fill a region bounded by a character and a graphic object with a color?


title: Passing changing (in a loop) parameters to Pgfplot function

text: Usually I just use TikZ for plots but was hoping Pgfplots would simplify life (axis, labels, etc...) but I can not find what is the right syntax to pass parameters to the function. Here is the MWE:               \documentclass[12pt]{article}     \usepackage{tikz}     \usepackage{pgfplots}     \begin{document}        \pgfplotsset{compat=1.10}        \begin{tikzpicture}           \begin{axis}[            title=Test,            xlabel=$x$,            ylabel=$f$,            ]               \foreach \y in {0,1,2,3}                  {\addplot[                  red,                  domain=0:1,                  samples=4,                   ]                   {x+\y};                  }          \end{axis}       \end{tikzpicture}     \end{document}


title: Why can't I compare a string with \par?

text: First of all: the package `xstring` cannot recognize a `\par` as argument. When I for example do this:               \usepackage{xstring}          \def\apar{\par}     \def\str{a string}          \IfStrEq{\str}{\par}{% true part     }{% false part     }      It results in an error. Why that the package specially made for strings has not got a check on that, I have no clue.. * * * Another way of checking if a string is equal to `\par` can be achieved by using `\ifx`, but this has limits too. Look at the following example:               \def\apar{\par}     \def\str{\par}          First case:\\     \ifx\str\apar  % compare \str with a variable       Str is a par.     \else       Str is not a par.     \fi     \par     Second case:\\     \ifx\str\par  % compare \str with \par       Str is a par.     \else       Str is not a par.     \fi      This gives the output: > First case:   >  Str is a par   > > > Second case:   >  Str is not a par Not that I have problems with it, but I'm just asking myself why this is..


title: Strange behaviour on redefining \contentsname

text: I'm using `amsart` class. I know how to change the value of `\contentsname` (default is _Contents_ ). We can make use of `\def` or `\renewcommand`. But I'd like to know why it does not work if I use those commands on preamble? I only can change its value using, for example, `\renewcommand\contentsname{List of Abstracts}` after `\begin{document}`. **Why??**


title: Hoefler Text Swashes under Windows 7 XeTex

text: I'm using XeTeX on Windows 7 from the MiKTeX 2.9 package and I want to use the swashes from Hoefler Text. The common ligatures rendering well but I can't get the swashes. Here's the code I am using:               \documentclass[10pt]{article}     \usepackage{fontspec,xltxtra}     \setromanfont[Mapping=tex-text]{Hoefler Text}          \begin{document}     \fontspec[Ligatures={Common,Rare,Historic}, Alternate=1]{Hoefler Text}     \fontsize{24pt}{30pt}\selectfont      \noindent     Que dictes \emph{vous} de mon appel, \\     Toute beste \& garde sa pel \\     ff fl fi ffl ffi     \end{document}      The result looks like this ("Q" without swash): ![without swashes](http://i.stack.imgur.com/ndgDx.jpg) But it should look like this: ![with swashes](http://i.stack.imgur.com/6E3nv.jpg) More samples: http://www.typography.com/fonts/hoefler-text/features/hoefler- text-grand-italics


title: Wrap text using m{...cm} and array package does not work

text: I am trying to wrap the text using the command `m{2.7cm}` with array package in this table, but this does not work together. If I use `p{2.7cm}` without array package it works, but the text is not centralized inside the cell. Please, somebody can help me?               \begin{table}[h!]     \begin{center}          \caption{Reported trends regarding the temperature cycle.}     \label{Trends_temp_cycle} \smallskip \smallskip           \begin{tabular}{|c||*{3}{m{2.7cm}|}}\hline          \backslashbox{\vspace{1mm}Modified\\ variable}{\\\vspace{1mm}Affected\\ variable}     &\makebox[3em]{$T_{c}$}&\makebox[3em]{$T_{d}$}&\makebox[3em]{$\eta_{h0}$}\\\hline\hline     $\uparrow$$\dot\gamma_{h}$ & $\approx$ constant \cite[]{webber-99} & -- & --\\\hline     $\uparrow$$\dot T_{h}$ & $\downarrow$\cite[]{webber-99} & $\approx$ constant \cite[]{webber-99} & $\uparrow$\cite[]{webber-99}\\\hline          \end{tabular}          \end{center}     \end{table}


title: marker on every n points only in pgfplots

text: I use the following command to plot data from a file using `pgfplots`.               \addplot table [x expr=\coordindex+1,y index=0]{file.txt}      I have around 8 curves in the same plot and lot of data points in the files that when I plot the graph, the graph is very thick and the different curves cannot be distinguished from each other. As a solution, how to make the marker appear only on every `n` points?


title: Error message when using biber

text: Great site here. I have a question regarding Biblatex and Biber. My current .tex file structure looks like this in TeXworks:               \documentclass{article}      \usepackage[T1]{fontenc}      \usepackage{inputenc}      \usepackage[backend=biber,style=authoryear]{biblatex}      \addbibresource{mybib.bib}           \begin{document}      \printbibliography     \end{document}      When I run the Biber typeset, I get the following error:               INFO - This is biber 0.9.3     INFO - Logfile is 'myfile.blg'     FATAL - Cannot find control file 'myfile.bcf'! - did you pass the "backend=biber" option to BibLaTeX?      What am I doing wrong? Thanks in advance! _**___ ___ __ ___ __ ___ __ ___ __ ___ __ ___ __ ___ __ ___ __ ___ __ ___ __ ___** (Edit by Richard 06/24/2011) I applied the changes suggested below and although it worked for a single citation, when I include more than one, I get a PDF that only reads "Some text [A01]". Here is what I have now:               \listfiles          \documentclass{article}          \usepackage[backend=biber]{biblatex}          \usepackage{filecontents}          \begin{filecontents}{\jobname.bib}     @article{Lees:2011zi,           author         = "Lees, J.P. and others",           title          = "{Cross Sections for the Reactions $e^+e^- \to K^+ K^-                         \pi^+\pi^-,\, K^+ K^- \pi^0\pi^0$, and $K^+ K^- K^+ K^-$                         Measured Using Initial-State Radiation}",           collaboration  = "The BABAR Collaboration",           year           = "2011",           note           = "* Temporary entry *",           eprint         = "1103.3001",           archivePrefix  = "arXiv",           primaryClass   = "hep-ex",     }               @article{delAmoSanchez:2010fd,       author         = "del Amo Sanchez, P. and others",       title          = "{Analysis of the $D^+ \to K^- \pi^+ e^+ \nu_e$ decay                         channel}",       collaboration  = "The BABAR Collaboration",       journal        = "Phys.Rev.",       volume         = "D83",       pages          = "072001",       doi            = "10.1103/PhysRevD.83.072001",       year           = "2011",       eprint         = "1012.1810",       archivePrefix  = "arXiv",       primaryClass   = "hep-ex",     }               @article{delAmoSanchez:2010yp,       author         = "del Amo Sanchez, P. and others",       title          = "{Dalitz plot analysis of $D_s^+ \to K^+ K^- \pi^+$}",       collaboration  = "The BABAR Collaboration",       journal        = "Phys.Rev.",       volume         = "D83",       pages          = "052001",       doi            = "10.1103/PhysRevD.83.052001",       year           = "2011",       eprint         = "1011.4190",       archivePrefix  = "arXiv",       primaryClass   = "hep-ex",     }               @article{delAmoSanchez:2010bx,       author         = "del Amo Sanchez, P. and others",       title          = "{Search for the Decay $B^{0} \to \gamma \gamma$}",       collaboration  = "The BABAR Collaboration",       journal        = "Phys.Rev.",       volume         = "D83",       pages          = "032006",       doi            = "10.1103/PhysRevD.83.032006",       year           = "2011",       eprint         = "1010.2229",       archivePrefix  = "arXiv",       primaryClass   = "hep-ex",     }               @article{delAmoSanchez:2010zd,       author         = "del Amo Sanchez, P. and others",       title          = "{Measurement of the $B^0 \to \pi^\ell \ell^+ \nu$ and                         $B^+ \to \eta^{(')} \ell^+ \nu$ Branching Fractions, the                         $B^0 \to \pi^- \ell^+ \nu$ and $B^+ \to \eta \ell^+ \nu$                         Form-Factor Shapes, and Determination of $|V_{ub}|$}",       collaboration  = "BABAR Collaboration",       journal        = "Phys.Rev.",       volume         = "D83",       pages          = "052011",       doi            = "10.1103/PhysRevD.83.052011",       year           = "2011",       eprint         = "1010.0987",       archivePrefix  = "arXiv",       primaryClass   = "hep-ex",     }               @article{delAmoSanchez:2010bk,       author         = "del Amo Sanchez, P. and others",       title          = "{Search for the Rare Decay $B \to K \nu \bar{nu}$}",       collaboration  = "BABAR Collaboration",       journal        = "Phys.Rev.",       volume         = "D82",       pages          = "112002",       doi            = "10.1103/PhysRevD.82.112002",       year           = "2010",       eprint         = "1009.1529",       archivePrefix  = "arXiv",       primaryClass   = "hep-ex",     }          @article{delAmoSanchez:2010vq,       author         = "del Amo Sanchez, P. and others",       title          = "{Observation of new resonances decaying to $D\pi$ and                         $D^*\pi$ in inclusive $e^+e^-$ collisions near                         $\sqrt{s}=$10.58 GeV}",       collaboration  = "The BABAR Collaboration",       journal        = "Phys.Rev.",       volume         = "D82",       pages          = "111101",       doi            = "10.1103/PhysRevD.82.111101",       year           = "2010",       eprint         = "1009.2076",       archivePrefix  = "arXiv",       primaryClass   = "hep-ex",     }      \end{filecontents}          \addbibresource{\jobname.bib}          \begin{document}          Some text \autocite{A01}.          \printbibliography          \end{document}      _**___ ___ __ ___ __ ___ __ ___ __ ___ __ ___ ____**(EDIT BY RICHARD 06/27/2011) When I compile this, I get almost perfect results, however there seems to be several "¿" throughout the document. Also, [hep-ex] is always displayed after each citation (I guess it prints the primaryClass at the end). Can I somehow disable the [hep-ex] from showing? Also, would it be worth it to run XeTeX instead of latex when I compile? I'm looking for the best way to get unicode characters (preserve sub/superscripts, etc). Should I add the line, \usepackage[utf8]{inputenc} if I do this? Thanks for all your help.               \listfiles          \documentclass{article}          \usepackage[backend=biber]{biblatex}          \usepackage{filecontents}          \usepackage[utf8x]{inputenc}          \begin{filecontents}{\jobname.bib}               @Article{Aubert:2007sea,          author    = "Aubert, Bernard and others",          collaboration = "BABAR",          title     = "{Evidence for b ---> d gamma Transitions From a Sum of                   Exclusive Final States in the Hadronic Final State Mass                   Range 1.0-GeV/c**2 < M(X(d)) < 1.8-GeV/c**2}",          year      = "2007",          eprint    = "0708.1652",          archivePrefix = "arXiv",          primaryClass  =  "hep-ex",          SLACcitation  = "%%CITATION = 0708.1652;%%"     }          @Article{:2010ip,          author    = "del Amo Sanchez, P. and others",          collaboration = "BABAR",          title     = "{Dalitz-plot Analysis of B0 --> D0bar pi+ pi-}",          journal   = "PoS",          volume    = "ICHEP2010",          year      = "2010",          pages     = "250",          eprint    = "1007.4464",          archivePrefix = "arXiv",          primaryClass  =  "hep-ex",          SLACcitation  = "%%CITATION = 1007.4464;%%"     }               @Article{delAmoSanchez:2010rq,         author    = "del Amo Sanchez, P. and others",         collaboration = "BABAR",         title     = "{Evidence for direct CP violation in the measurement of the                   Cabibbo-Kobayashi-Maskawa angle gamma with B-+ --> D(*)                   K(*)-+ decays}",         journal   = "Phys. Rev. Lett.",         volume    = "105",         year      = "2010",         pages     = "121801",         eprint    = "1005.1096",         archivePrefix = "arXiv",         primaryClass  =  "hep-ex",         doi       = "10.1103/PhysRevLett.105.121801",         SLACcitation  = "%%CITATION = 1005.1096;%%"     }               \end{filecontents}          \addbibresource{\jobname.bib}          \begin{document}          \nocite{*}          \printbibliography          \end{document}


title: Expand away empty macros within ifthenelse

text: I want to test whether a string, when it is finally printed, is empty. The following illustrates my problem,               \documentclass{article}     \usepackage{ifthen}     \newcommand{\isempty}[1]%     {       \ifthenelse{\equal{#1}{}}%         {EMPTY}% if #1 is empty         {FULL, it contains the string '#1'}% if #1 is not empty     }          \newcommand{\Something}{Something}     \newcommand{\Nothing}{}               \begin{document}          First the buffer is \isempty{\Something}.          Second the buffer is \isempty{\Nothing}.          {\em So far so good.} But          Third the buffer is \isempty{{\Nothing}}.          Forth the buffer is \isempty{\bf{\Nothing}}.          It says the string is Full with ''!     \end{document}      The output is               First the buffer is FULL, it contains the string ’Something’.     Second the buffer is EMPTY.     So far so good. But     Third the buffer is FULL, it contains the string ’’.     Forth the buffer is FULL, it contains the string ’’.     It says the string is Full with ”!


title: Formatting a LaTeX article to look really good

text: I have been using LaTeX to write scientific articles for about 6-months now. I know quite well now how to manipulate and create great content but don’t really understand the formatting/style side to Latex. I need to submit a document soon which I want to make it look really good and professional much like this Nature article: http://www.nature.com/nature/journal/v424/n6950/pdf/nature01935.pdf I want to know more specifically how to:   * Colour titles   * Add a background frame to all figures and captions   * Drop cap the first letter of the introduction I know this question is very general but any help or pointers of how or where I could find out would be much appreciated! Are there templates on-line which you can download and just apply to your document for these sort of things?


title: Using Sublime Text 2 for LaTeX

text: Is anybody using Sublime Text 2? I use it quite frequently for coding, it by far my favourite editor. But I never used it for LaTeX. There is a package called LaTeXTools for editing and viewing LaTeX files, but I can't get it to compile and view on Linux. The author seems to be focusing on Windows and OS X. Has anybody used Sublime Text 2 for LaTeX? Does anybody know how to make it work for Linux?


title: Pass an integer value to TikZ in LuaLaTeX

text: I want to draw a rectangle with `\luacode`. For rectangle points, the coordinates values will be taken from code. I try the following code. For rectangle, points are defined as `'(0,0) and (1,1)`. But i want to pass the `xmin, xmax, ymin, ymax` values into the `\tikzpicture` code. When i changed the related lines as `tp("\\\draw [ultra thick] (xmin,ymin) rectangle (xmax,ymax);")`, the error gives that               Package PGF Math Error: Unknown function `xmin' (in 'xmin').      How to pass the values? Any suggestions are welcome.               \documentclass{article}     \usepackage[utf8x]{inputenc}     \usepackage{luacode}     \usepackage{amsmath,tikz}              \begin{document}         \luaexec{         tp = tex.print         local xmin = 0         local xmax = 1         local ymin = 0         local ymax = 1         tp(xmin.." "..xmax.." "..ymin.." "..ymax)         tp("\\\\")         tp("\\begin{center}")         tp("\\begin{tikzpicture}")         tp("\\draw [ultra thick] (0,0) rectangle (1,1);")         tp("\\end{tikzpicture}")         tp("\\end{center}")         }              \end{document}


title: Latex: Longtable always starts in a new page leaving the previous page nearly empty (IEEE format )

text: Im new to using LaTeX. I am writing a Longtable that spread across 2 pages. But LaTeX always adds starts the table in a new page and so I end up with a long break in the previous page. Same thing happens after the table. The text continues on the next page. I am writting for IEEE format paper. So am using `\onecolumn` and `\twocolumn` enclosing the longtable code. Any help appreciated.


title: How to find the intersection of two `path3[]`

text: I'm using **Asymptote** to draw some figures and I need to put a dot on the intersection of two `path3[]` but the command `intersectionpoint()` doesn't work for `path3[]`. What can I do?


title: Setting up a flash drive suitable for 'TeX Missionaries'

text: I'd like to stick a complete TeX system on a flash drive to be able to quickly demonstrate and disseminate TeX and its distributions, but I'd like to keep the total file size small since the medium would be a 4-8GB flash drive. ### Goals:   * Have at least one complete TeX distribution that will work out-of-the-box for each major OS (Windows, Mac, Linux) (That is, at least one per.)   * Able to be installed and functional without an internet connection or non-default (and not-included, e.g. TeXLive needs _and includes_ Perl) dependencies. (That is, batteries included.)   * Ability to demonstrate a reasonable amount of ([Lua|Xe])(La)TeX's functionality on-the-fly regardless of OS (restriction to the major players is probably necessary here). Since the vast majority of each TeX distribution is in fact duplicated among each one, I'd _like_ to avoid such reduplication. That said, TeX Live should install TeX Live; MikTeX should install MikTeX; MacTeX should install MacTeX. Is there any way to rig this up, short of putting each offline installer and live system on the flash drive (which would be _way_ over 4GB, and probably over 8GB)?


title: Setup a newenviroment for figure with includegraphics and caption

text: Here is my MWE, I want to 'refactor' the code so that I do not need to write so much when I import source code into my document:               \documentclass[12pt,a4paper]{article}     \usepackage[demo]{graphicx}     \usepackage{caption}     \usepackage{wrapfig}     \usepackage{lipsum}          \begin{document}          \begin{wrapfigure}{r}{0.5\textwidth}       \begin{center}         \includegraphics[width=0.6\textwidth]{foo}       \end{center}       \caption{The foo describes the bar}       \label{img:foo}     \end{wrapfigure}          \lipsum          \end{document}      Ideally I would prefer to just do:               \begin{mygraphic}{r}{0.5\textwidth}{The foo describes the bar}{img:foo}         \includegraphics[width=0.6\textwidth]{foo}     \end{mygraphic}      I assume I need to do something like:               \makeatletter     \newenvironment{mygraphic}[4]     {%begin part     \begin{wrapfigure}{#1}{#2}       \begin{center}     }     {%end part       \end{center}       \caption{#3}       \label{#4}     \end{wrapfigure}}     \makeatother      However that doesn't work. It complains about caption and label parameters, so I moved those up into the begin part but that didn't work.


title: Citing with Bibtex

text: After using Google for 1 hour I gave up. All I wanted is: This style for my citation : > (First AUTHOR et al. , YEAR) Why is this so complicated ?


title: Vertical Spacing of Exponent when using \cancel in the Denominator of a Fraction

text: For some reason, using \cancel in the denominator of a fraction adds a certain height to the exponent (see minimal example below). Observe that it does not happen if the expression is in the numerator. Although the change is minimal, it becomes annoying (at least to me) when I use overlay in beamer. Is there any way to fix this?               \documentclass{beamer}     \usetheme[width=0.6in]{Hannover}     \usepackage{amsmath}                       \usepackage{amsfonts}                      \usepackage{amssymb}                       \usepackage{mathrsfs}                      \usepackage{cancel}                          \usepackage[english]{babel}          \begin{document}       \begin{frame}[t]         $\dfrac{{\cancel{2^2}}\;2^2}{3^3\;\cancel{3^3}}$                          \medskip $\dfrac{\vphantom{\cancel{2^2}}\only<2->{\cancel{2^2}}\only<1>{2^2}}         {\vphantom{\cancel{3^3}}\only<1>{3^3}\only<2->{\cancel{3^3}}}$       \end{frame}     \end{document}


title: Arithmetic overflow error using custom theme in pdfLaTex

text: I am attempting to compile a 70 frame `beamer` presentation in TeXworks (on Ubuntu 11.10). The theme I am using is called `beamer-goddard` (located at the bottom of This Page) . When I compile I receive this console error:               ! Arithmetic overflow.     \goddard@progressbar ... by \goddard@temp@count@a                                                        \divide \goddard@temp@dime...      as well as this LaTeX error: > Package hyperref Warning: Option `pdfpagelabels' is turned off (hyperref) > because \thepage is undefined.                \documentclass[xcolor=table,serif,8pt]{beamer}      \setbeamertemplate{footline}[page number]{}           \usepackage[american]{babel}      \usepackage[T1]{fontenc}      \usepackage{listings}      \usepackage{lmodern}      \usepackage{textcomp}      \usepackage{wrapfig}      \usepackage[pdf]{pstricks}      \usetheme{Goddard}           \newcommand{\filepath}{\texttt}      \newcommand{\command}{\texttt}      \newcommand{\email}[1]{\href{mailto:#1}{\texttt{#1}}}      \newcommand{\latexcode}{\texttt}      \newcommand{\parameter}[1]{\textlangle #1\textrangle}                \lstset{basicstyle=\ttfamily,keywordstyle\color{goddardblue}               \bfseries,commentstyle=\color{goddardblue!75}\itshape,columns=flexible}           \rowcolors{1}{goddardblue!50}{goddardblue!30}        ...           \end{document}      I am guessing some values may need to be modified in the `\divide` portion of the `goddard@theme`.


title: TeXLive dependents?

text: I know this might not be a question for this forum but for SS; however, someone might give me a hint. This problem happens to me both in Ubuntu and in OS X. When I want to install something (e.g., `rubber` or the gedit LaTeX plugin) I am required to install TeXLive components (texlive-base, etc.). The problem is that I already have the TeXLive system install---indeed, I have a newer version that the one found at the default system's repository (be that Ubuntu's or the Mac Ports'). What I have done to override this behaviour is to download the main files of the program I want to install (e.g., `sudo apt-get download rubber`), and then install it without dependencies (e.g., `sudo dpkg -i rubber 1.1-2.4ubuntu1`). Sometimes this works, but other times I get error messages regarding corruption in the repository database. Is there a way of making my systems understand that I already got a newer version of TeXLive installed?


title: I am trying to animate in two different coordinates using layers. But the animation happens in the same spot

text: \documentclass{beamer}          \usepackage{tikz}          \usepackage{animate}               \newcommand\layerp{%     \begin{tikzpicture}      \path  (1,.5)          (1.5,.75);       \end{tikzpicture}     }     \newcommand\layerq{%     \begin{tikzpicture}      \path  (4,.5)          (4.5,.75);       \end{tikzpicture}     }     \newcommand\layerx{%     \begin{tikzpicture}          \draw (0,0) rectangle (5,3);          \draw (2.5,3) -- (2.5,1);           \draw (1.25, 2.75) node  {Cell 1};          \draw (3.75, 2.75) node  {Cell 2};     \layerp     \layerq          \end{tikzpicture}     }          \newcommand\layerb{%     \begin{tikzpicture}         \fill[blue!40] (1,.5) circle (.1);     \end{tikzpicture}     }     \newcommand\layerc{%     \begin{tikzpicture}         \fill[red!40] (1,.5) circle (.1);     \end{tikzpicture}     }     \newcommand\layerd{%     \begin{tikzpicture}         \fill[yellow!40] (4,.5) circle (.1);     \end{tikzpicture}     }     \newcommand\layere{%     \begin{tikzpicture}         \fill[green!40] (4,.5) circle (.1);     \end{tikzpicture}     }          \begin{document}     \begin{center}               \begin{frame}     \begin{figure}[h!]          %\includegraphics[width=5mm]{empty.jpg}          \layerx          \end{figure}     \begin{animateinline}[autoplay,loop]{1}         \layerp         \newframe        \layerp     \newframe         \layerb     \newframe         \layerc         \newframe         \layerq     \newframe         \layerd         \newframe         \layere               \end{animateinline}     \end{frame}     \end{center}     \end{document}


title: How can I colourfuly highlight some lines of an algorithm using algorithm2e?

text: I am trying to achieve something like this: ![enter image description here](http://i.stack.imgur.com/mRuQL.png) This image is linked from this answer. This answer also provides a solution and seems simpler. Both answers deal with the `algorithmicx` package however. I am interested in the solution for the `algorithm2e` package. I read the documentation of the `algorithm2e` package but didn't find an answer. How can I achieve the colored effect? EDIT: Here is sample code to create a minimum working example.               \documentclass{article}          \usepackage[ruled]{algorithm2e} % http://www.ctan.org/pkg/algorithm2e          \begin{document}          \begin{algorithm}[h]      \caption{Evolutionary algorithm}       initialize population \;      \For( \emph{Evolutionary loop}){$g := 1$ to $G_{max}$}      {         do things \;         evolve population \;      }      celebrate \;     \end{algorithm}          \end{document}


title: Centering with \includegraphics not with \begin{figure}?

text: I mess up with things when I try to use the figure-thing: the picture is not appearing with the correct alignment (apparently because I forget the `float` package). Now I want to use only the `graphicx` package with `\includegraphics`. How can I center the `\includegraphics` without figure? Not working or doing centering to the document afterwards.               \includegraphics[width=0.5 \textwidth]{./Pictures/r.png}{\centering}     \includegraphics[width=0.5 \textwidth]{./Pictures/r.png}\centering


title: New command with if/then statement conditioned on non-integer number?

text: In LaTeX, how do I declare a new command that gives different output depending no the result of a test with non-integer numbers? Specifically, I'd like to a command to compare a number with 0.01 (the numbers would come from a different script): if the number is greater than or equal to 0.01, print `p = 0.45` (or whatever number p is); if the number if less than 0.01, print `p < 0.01`. I have looked at `ifnumless` in `etoolbox` but it only takes integers and dimensions. How do I do this with numbers with decimal points? Thanks.


title: How to center multiple tabular entries in different centered environments?

text: I am about to pull my hair out. I was wondering if anyone could give me some tips or guide me to the proper way to correctly format my centered tabular entries. I just want the my centered tabular sections to be aligned but they always change based on the amount of text I enter. I was wondering if there was a quick fix to this problem. I have included my document in code below.               \documentclass{article}     \usepackage[top=2cm, bottom=2cm, left=1.5cm, right=1cm,headsep=1cm]    {geometry}     \usepackage{fancyhdr}     \usepackage{calc}     \usepackage{comment}     \pagestyle{fancy}     \parindent=0pt     \fancyfoot{}     \begin{document}     \lhead{{\Huge Robert Plummer II}       \hfill     \begin{tabular}{ l c  }     337-353-9679 &2609 South Vienna Street\\     rgp005@latech.edu &Ruston, La 71270  \\     \end{tabular}}           {\bf\Large Education:}       \begin{center}     \begin{tabular}{ l c r  }     {\bf Louisiana Tech University \hspace{1in}2008-2012} \hfill \\       \hspace{.25in}Bachelor of Science Degree, Computer Science Expected 5/12\\     \hspace{.25in}Minor: Mathematics\\      \hspace{.25in}Computer Science GPA: 3.06\\     \hspace{.25in}Cumulative GPA: 2.8\\      \hfill\\      {\bf Curriculum Highlights} \hfill \\      \hspace{.25in}System Programming\\       \hspace{.25in}Operating Systems\\      \hspace{.25in}Advanced Algorithm Design\\      \hspace{.25in}Networking\\      \hspace{.25in}Digital Design and Computer Architecture\\     \hspace{.25in}Digital Forensics\\     \hspace{.25in}Cyber Security\\     \hfill\\     \end{tabular}     \end{center}          {\bf\Large Technical Skills:} \\      \begin{center}     \begin{tabular}{ l c r  }     {\bf Programming Languages} \hfill\\     \hspace{.25in} Experience using C/C++, Python, Java, Javascript, HTML, CSS, PHP.\\     \hfill\\     {\bf Platforms} \hfill \\     \hspace{.25in} Comfortable working on a Windows, OS X, or Unix machine.\\     \end{tabular}     \end{center}          {\bf\Large Coursework/Projects:} \\      \begin{center}     \begin{tabular}{ l c r  }     {\bf Networking} \hfill \\     \hspace{.25in}Implemented a chat program that uses TCP to communicate.\\     \hspace{.25in}Used raw sockets to implement TCP.\\      \hfill\\     {\bf Digital Forensics} \hfill \\     \hspace{.25in}Implemented a Windows Recycle Bin .info/R-I parser\\      \hspace{.25in}Windows registry extractor that is compatible with Windows XP, Vista, and 7.\\     \hfill\\     {\bf Software Engineering} \hfill \\     \hspace{.25in}Project Manager for new Computer Science website for Louisiana Tech University.\\     \hspace{.25in}Responsible for creating a web interface to interact with the SQL database for the new website.\\     \hspace{.25in}Wrote code that used AJAX and PHP to generate the web pages that use content from a database.     \end{tabular}     \end{center}          \begin{center} References available upon request \end{center}          \end{document}      Sorry if this is too much code but I wanted to make sure everyone could see the problem. Thank you for your time.


title: Misplaced \omit. \multispan with \newcommand

text: I'm trying to build my own cookbook-style, which has an ingredient makro. Sometimes the ingredients should be seperated and have a headline, so I tryed with an optional argument. A minumum example looks like this:               \documentclass{scrartcl}     \newcommand{\ingredient}[3][]{         #1 #2 & #3 \\     }     \begin{document}         \begin{tabular}{r|l}                     \ingredient[\multicolumn{2}{l}{Head} \\]{test1}{test2}             \ingredient[test3]{test4}{test5}             \ingredient{test6}{test7}         \end{tabular}     \end{document}      What's wrong with this code? I get the following error message:               ! Misplaced \omit.     \multispan ->\omit                         \@multispan      l.7 ...[\multicolumn{2}{l}{Head} \\]{test1}{test2}


title: TeX Live installs Makefiles as documentation

text: On my TeX Live installation there are about 200 Makefiles installed in the `texmf-dist/doc` subtree. They, of course, hardly count as documentation. Even strangier their placement seems in light of that every TeX Live package also has a source archive, where (and only where) the Makefiles would normally go. However, this doesn't seem to be an unnoticed mistake, as even `texdoc` knows enough about them to have an exception rule:               > texdoc -d impatient     . . .     texdoc debug-score: Start scoring /data/texlive/texmf-dist/doc/plain/impatient/Makefile     texdoc debug-score: Name used: impatient/makefile     texdoc debug-score: Start heuristic scoring with pattern: impatient     texdoc debug-score: New heuristic score: 1. Reason: subword match     texdoc debug-score: New heuristic score: 0.1. Reason: bad extension     texdoc debug-score: New heuristic score: 1.6. Reason: directory bonus     texdoc debug-score: Final heuristic score: 1.6     texdoc debug-score: Max pattern score: 1.6     texdoc debug-score: Adjust by -1000 from global pattern '/makefile'  <===     texdoc debug-score: Final score: -998.4     . . .      Why are the Makefiles placed in the documentation subtree?


title: Forcing `et al.` in selected places

text: I am using `XeLaTeX` together with `biblatex`. I am typesetting a table where a citation goes into one of the column headers, namely I put `\citet{ref1}` into the table. `ref1` has two authors and normally the citation `AuthorA and AuthorB (2013)` looks fine in the text; however, in the table it is too wide so I was hoping to force `biblatex` to shorten it to `AuthorA et al. (2013)`. Is there a way to do that? Note that I do not want to do it document-wide, only within the particular table. _NOTE:_ Using `\citeauthor` produces both names. ## MWE               \documentclass{article}          \usepackage[style=authoryear-comp, natbib=true, backend=biber, sorting=nyt, autolang=hyphen]{biblatex}          \begin{filecontents}{literature.bib}     @ARTICLE{ref1,       AUTHOR = {AuthorA, A. and AuthorB, B.},       JOURNALTITLE = {{Journal of Testing}},       PAGES = {1--2},       TITLE = {{Test Reference}},       VOLUME = 1,       NUMBER = 1,       YEAR = 2013     }     \end{filecontents}     \addbibresource{literature.bib}          \begin{document}          \citet{ref1}          \end{document}


title: Shrinking verbatim text

text: Heiko Oberdiek helped me a lot by finding a solution for shrinking text when needed. I want to apply this method to verbatim text as in the example below, but this is somehow forbidden (Something's wrong--perhaps a missing \item.). Is there another way to shrink `verbatim` text to fit the `\linewidth`?               \documentclass{article}     \usepackage{graphicx}          \newcommand*{\restrictlinewidthbox}[1]{%       \begingroup         \sbox0{#1}%         \ifdim\wd0>\linewidth           \resizebox{\linewidth}{!}{\copy0}%         \else           \copy0 %         \fi       \endgroup     }          \setlength{\parindent}{0pt}          \begin{document}          \restrictlinewidthbox{%     \begin{verbatim}     \begin{tabular}            {|lc|c|c|c|}\hline              & \textbf{Input}  & Cnstrnt 1  &  Cnstrnt 2& Cnstrnt 3\\ \hline\hline           & candidate 1     & *!         &           &          \\ \hline           & candidate 2     &            &  *        &          \\ \hline     \hand & candidate 3     &            &           &  *       \\ \hline     \end{tabular}     \end{verbatim}     }               \end{document}


title: Drawing cylinder with PSTricks

text: I am trying to draw a simple cylinder with PSTricks, similar to what is attached. Is there a smart way to do this, or do I just have to manually draw each line? If there is no other way, then it is way to cumbersome and time- consuming for me. ![enter image description here](http://i.stack.imgur.com/ce2nt.jpg)


title: pdfpages remove empty page after included pdf

text: I have a one-page `.pdf` file that I need to include in my latex document. The included pdf must be the first page of the document. Actually I'm using the `pdfpages` package, but after the included page there is an empty page that I want to remove. My main `.tex` file looks like this:               \documentclass[a4paper,11pt]{book}     \usepackage[utf8]{inputenc}     \usepackage[italian]{babel}     ...     \usepackage{pdfpages}               \begin{document}          \frontmatter           \includepdf{front.pdf}  % one-page external pdf          \tableofcontents          \mainmatter                 \include{tex/intro}     \include{tex/chap1}     \include{tex/chap2}     ...          \backmatter          \bibliographystyle{plain}     \bibliography{reference}          \end{document}      My output document looks like this:               1. included page from external pdf --> Ok     2. empty page --> I wanna remove it!     3. Table of Content --> Ok     4. Chapters, bibliography, etc. --> Ok      I'm sure that I have to use some options of the `\includepdf` command, but what options?


title: Controlling the white space: distance between headrule, text and footrule inconsistent

text: How to control the distance of white space between the rules and the body text?               \documentclass{article}     \usepackage{fancyhdr}     \usepackage{lipsum}     \fancypagestyle{plain}{     \renewcommand{\headrulewidth}{.4pt}     \renewcommand{\footrulewidth}{.4pt}     }     \begin{document}     \thispagestyle{plain}     \lipsum[1-8]     \end{document}      As you can see, the distance between headrule and text is inconsistent with the distance between text and footrule. I'm mostly in need of a solution for the distance between footrule and text, as the solution for headrule and text is already given here, but doesn't quite work here (?). See the image: ![enter image description here](http://i.stack.imgur.com/POGus.png?2)


title: Partially transparent text box

text: I am trying to make a poster using `beamer`. Can any one please reply me, my question is: How can I make my boxes **partially transparent** so that my background will be visible through the boxes?


title: Why the pmatrix environment get a higher parenthese than pmatrix command?

text: I found the `amsmath` package's `pmatrix` environment have a bit difference with LaTeX's `pmatrix` command. You can see it from:               \documentclass{article}     % \usepackage{amsmath}     \linespread{1.3}     \begin{document}     $\pmatrix{A&B\cr C&D\cr}$     % $\begin{pmatrix}A&B\cr C&D\cr\end{pmatrix}$     \end{document}      and:               \documentclass{article}     \usepackage{amsmath}     \linespread{1.3}     \begin{document}     % $\pmatrix{A&B\cr C&D\cr}$     $\begin{pmatrix}A&B\cr C&D\cr\end{pmatrix}$     \end{document}      Is this a feature of `amsmath`?


title: How to disable null device while usin dev.off() in R and latex?

text: How to disable message null device when using R and latex.               <<echo=FALSE ,results=tex>>=     data<-read.table("test",sep="\t",header=TRUE,check.names=FALSE)     names(data)<-substr(names(data),1,20)     pdf("image.pdf")     par(las=2)     par(mar=c(2,12,2,2))     barplot(as.matrix(disease_data),beside=TRUE, col=c("burlywood1 ","orange2"), horiz=TRUE,cex.names=1.0, border ="white")     dev.off()     @      I have already disable echo but null device is on image. How can i avoid it? Regards Regards


title: h! nor H working for table floats

text: I'm trying to get a table in to a section I want but it wont play ball, The first table shows above the allowed paragraph and the second table in the allowed paragraph, how can I fix it? I use the `\usepackage{float}` package. Thanks               \paragraph{Allowed}     \begin{table}[h!]     \begin{tabular}{lll}     Rule & Who & Controlled \\      &  &  \\      &  &  \\      &  &  \\      &  &  \\      &  &      \end{tabular}     \end{table}     \paragraph{Not allowed}     \begin{table}[h!]     \begin{tabular}{lll}     Rule & Who & Controlled \\      &  &  \\      &  &  \\      &  &  \\      &  &  \\      &  &      \end{tabular}     \end{table}


title: How can I draw a landscape picture using PSTricks?

text: I need to draw a figure using PSTricks which is quite a bit wider than than it is long. Is there anyway I can draw a pic like that in a landscape mode? Right now my pic starts at the top of a regular page and expands as it goes down but only has 8.5 inches to expand (in an A4 paper 8.5x11 ) into but if I could draw it landscape then I would have 11 inches for my bottom row. I need to write more stuff into it than is written in the MWE and that's why I would love to be able to draw my tree Landscape. I hope I am making sense here. MWE:               \documentclass[12pt]{article}          \usepackage[margin=1in]{geometry}  % set the margins to 1in on all sides     \usepackage{graphicx}              % to include figures     \usepackage{amsmath}               % great math stuff     \usepackage{amsfonts}              % for blackboard bold, etc     \usepackage{amsthm}                % better theorem environments     \usepackage{pstricks,pst-node,pst-tree}     \usepackage{auto-pst-pdf}     \usepackage{pdflscape}     \usepackage{rotating}          \begin{document}               \begin{figure}     \begin{pspicture}(14,22)     %\psgrid(14,22)     \rput(7,21){\ovalnode{0}{Alpha}}     \rput(3,17){\ovalnode{01}{Beta 1}}     \rput(11,17){\ovalnode{02}{Beta 2}}     \rput(0,13){\ovalnode{011}{Gamma 1}}     \rput(4,13){\ovalnode{012}{Gamma 2}}     \rput(8,13){\ovalnode{021}{Gamma 3}}     \rput(13,13){\ovalnode{022}{Gamma 4}}     \ncline{->}{0}{01}\mput*{Choice 1}     \ncline{->}{0}{02}\mput*{Choice 2}     \ncline{->}{01}{011}\mput*{Choice 1}     \ncline{->}{01}{012}\mput*{Choice 2}     \ncline{->}{02}{021}\mput*{Choice 1}     \ncline{->}{02}{022}\mput*{Choice 2}     \end{pspicture}          \end{figure}                \end{document}      This is what it looks like right now: ![enter image description here](http://i.stack.imgur.com/wgWA2.png) This is what I want it to look like: ![enter image description here](http://i.stack.imgur.com/5FmLW.jpg) I'd really appreciate it if you can tell me how to do it inside my Latex code.


title: Word 2010 on typesetting math

text: I tried to find that online, but all I found was: "Word bad, (La)TeX good! Word ugly, (La)TeX pretty!". I want an honest take from someone who used the new Math system in Word 2010, preferably who knows TeX/LaTeX/ConTeXt/etc, about how stable and reliable it is. Word also seems to import/export MathML, which is nice thing to have. I tried the new equation system on Word 2010 and so far it seemed pretty reasonable. I have NO previous latex (or tex) experience. I tried to learn Latex and it was a living hell to make sense of all the packages. Now I'm taking on ConTeXt, it seems to be clearer and more to my taste, but it still is demanding a lot of work and the learning curve is still pretty steep. I'm used to make proper Word documents (using styles, inheritance, etc), and even thought it is not a typesetting engine I can still make my documents look better than would be expected (maybe almost book level quality), so, if I can be assured that Word can handle Math nicely, I don't really see a point to moving to ConTeXt. BTW: I don't really care how eficient is TeX justification algorithm. **EDIT** : When I mentioned "steep learning curve", I'm not talking about the Math typesetting. I have tables from AMS packages telling me which symbols or commands to use. The problem is doing EVERYTHING else. If I'm trying to find the text "SOMETHING ELSE" in a TeX document, and this happen to be like `{bold something {em else}}`, I will never find it.


title: Wrapping two column text around a centering picture

text: > **Possible Duplicate:**   >  How do you create pull quotes?   >  Two-column text with circular insert I'ld like to wrap text around a picture which is in the middle of the page, but I don't wanna let emtpy space next to it. So I mean something like this: https://mail- attachment.googleusercontent.com/attachment/u/0/?ui=2&ik=1bc55d42c8&view=att&th=13b27ce82e811de6&attid=0.1&disp=inline&realattid=f_h9ts3uk40&safe=1&zw&saduie=AG9B_P828RkLDfGpDuIR_iNWBYDB&sadet=1353582607216&sads=GVM_m- x_ksm9hdKW25mG8fkfgC0 I've tried wrapfig environment, but usually it worked only with one column text for me. Can anyone help? I'ld really apriciate. Dénes from Hungary


title: How do you create pull quotes?

text: Does anyone know a package for pull quotes? ![enter image description here](http://i.stack.imgur.com/E5qW6.png) Failing that, is anyone interested in writing a command to create one? I'm thinking of something that would have optional and configurable separators above and below (e.g., lines or large quotation marks), and option to float left, right, or center. Ideally the command should print the argument _and_ the pull quote so you do not have to duplicate the text that you want to quote. To avoid duplicating existing questions, perhaps we should focus on single column documents, so that the pull quote has to be boxed?


title: Remove formatting

text: I currently use latex `newcommand` to store (and format) "variables", like so:               \newcommand{\someVariable}{\emph{value}}      I do this for key words that I want to be formatted a certain way every time they appear, by typing `\someVariable{}` Is there a way to remove the formatting from `\someVariable{}` for certain times that I do NOT want any special formatting, something like `\removeFormatting{\someVariable{}}`. Of course I could just manually type the text `value`, but I prefer to keep it in a command so that I can change all occurrences of it easily.


title: Figure environment not working with included file (extra } or forgotten endgroup)

text: I've spent hours on this issue. I hope someone can help me. I'm running into some kind of interference when I try to use the figure environment (Likewise for table, might be related to floats). I finally narrowed the problem down to one line-- where I include another file in the preamble that allows me to later include python code and have Latex color code it. The code I'm trying to compile is:               \documentclass[10pt]{article}     \include{pythonperfect}     \usepackage{graphicx}     \begin{document}     \begin{figure}      blah blah blah     \end{figure}     \end{document}      where "pythonperfect" is:               \usepackage{color}     \usepackage[procnames]{listings}     \usepackage{textcomp}     \usepackage{setspace}     \usepackage{palatino}     \renewcommand{\lstlistlistingname}{Code Listings}     \renewcommand{\lstlistingname}{Code Listing}     \definecolor{gray}{gray}{0.5}     \definecolor{green}{rgb}{0,0.5,0}     \definecolor{lightgreen}{rgb}{0,0.7,0}     \definecolor{purple}{rgb}{0.5,0,0.5}     \definecolor{darkred}{rgb}{0.5,0,0}     \definecolor{orange}{rgb}{1,0.5,0}     %\lstnewenvironment{python}[1][]{     \lstset{     language=python,     basicstyle=\ttfamily\small\setstretch{1},     stringstyle=\color{green},     showstringspaces=false,     alsoletter={1234567890},     otherkeywords={\ , \}, \{},     keywordstyle=\color{blue},     emph={access,and,as,break,class,continue,def,del,elif,else,%     except,exec,finally,for,from,global,if,import,in,is,%     lambda,not,or,pass,print,raise,return,try,while,assert},     emphstyle=\color{orange}\bfseries,     emph={[2]self},     emphstyle=[2]\color{gray},     emph={[4]ArithmeticError,AssertionError,AttributeError,BaseException,%     DeprecationWarning,EOFError,Ellipsis,EnvironmentError,Exception,%     False,FloatingPointError,FutureWarning,GeneratorExit,IOError,%     ImportError,ImportWarning,IndentationError,IndexError,KeyError,%     KeyboardInterrupt,LookupError,MemoryError,NameError,None,%     NotImplemented,NotImplementedError,OSError,OverflowError,%     PendingDeprecationWarning,ReferenceError,RuntimeError,RuntimeWarning,%     StandardError,StopIteration,SyntaxError,SyntaxWarning,SystemError,%     SystemExit,TabError,True,TypeError,UnboundLocalError,UnicodeDecodeError,%     UnicodeEncodeError,UnicodeError,UnicodeTranslateError,UnicodeWarning,%     UserWarning,ValueError,Warning,ZeroDivisionError,abs,all,any,apply,%     basestring,bool,buffer,callable,chr,classmethod,cmp,coerce,compile,%     complex,copyright,credits,delattr,dict,dir,divmod,enumerate,eval,%     execfile,exit,file,filter,float,frozenset,getattr,globals,hasattr,%     hash,help,hex,id,input,int,intern,isinstance,issubclass,iter,len,%     license,list,locals,long,map,max,min,object,oct,open,ord,pow,property,%     quit,range,raw_input,reduce,reload,repr,reversed,round,set,setattr,%     slice,sorted,staticmethod,str,sum,super,tuple,type,unichr,unicode,%     vars,xrange,zip},     emphstyle=[4]\color{purple}\bfseries,     upquote=true,     morecomment=[s][\color{lightgreen}]{"""}{"""},     commentstyle=\color{red}\slshape,     literate={>>>}{\textbf{\textcolor{darkred}{>{>}>}}}3%              {...}{{\textcolor{gray}{...}}}3,     procnamekeys={def,class},     procnamestyle=\color{blue}\textbf,     %framexleftmargin=1mm, framextopmargin=1mm, frame=shadowbox,     %rulesepcolor=\color{blue},     breaklines=true,     }{}      The error I get is:               ! Too many }'s.     \color@endbox->\color@endgroup \egroup     l.10 \end{figure}     You've closed more groups than you opened.     Such booboos are generally harmless, so keep going.     ! LaTeX Error: \begin{document} ended by \end{figure}.      In any case, I've used "pythonperfect" for a while, and never ran into an issue until today when I tried to include a figure. The problem is that I don't really understand most of what's happening in that file, I found it somewhere on the web (I don't remember where) and made a few changes to make it work for me. But I don't really understand it. So I can't figure out what's wrong. I'd really appreciate any help. Thank you very much.


title: How to enumerate equations?

text: I want to enumerate equations in the following way:   * An equation is in the same line as the bullet sign.   * All equations are align to the left.   * The number of an equation is align to the right. Any suggestions how to make it?


title: Chapters inside LoF and LoT?

text: I was wondering if it was possible to section the LoF (and similarly LoT) by Parts and/or Chapters. Currently, I have : > List of Figures > > 1.1 blablabla > > 1.2 blablabla > > 1.3 blablabla > > 2.1 blablabla > > 2.2 blablabla > > 1.1 blablabla > > 1.2 blablabla And I'd like to obtain : > **Part 1** > > _Chapter 1_ > > 1.1 blablabla > > 1.2 blablabla > > 1.3 blablabla > > _Chapter 2_ > > 2.1 blablabla > > 2.2 blablabla > > **Part 2** > > _Chapter 1_ > > 1.1 blablabla > > 1.2 blablabla * * *


title: Variables for hiding or showing text in Latex

text: I would like to have some variables for showing or hiding text in Latex. For example, I would like to have two versions of a document. A short version and a long version by changing a variable at the top of the latex document. For example: I want to set a variable long - true and in the text I would like to use if long == true show text (long version) else if false do not show the text (short version). Any examples?


title: table into page width in a double columns page

text: I am writing a paper with double columns pages and I like to insert a table across the width of the page. This is my attempt but its output is not what I look for : the table and the text are layered !!                   \begin{table}[H]         \caption{\label{aprio} Comparison results according to the a priori  error rate}         \begin{center}              \begin{tabular*}{\textwidth}{|c|p{1.5cm}p{1.5cm}p{1.5cm}||p{1.5cm}p{1.5cm}p{1.5cm}|}         \hline         \multirow{4}*{Data sets} & \multicolumn{6}{c|}{A prior error rate}\\         \cline{2-7} & \multicolumn{3}{c||}{Majority class} & \multicolumn{3}{c|}{Minority class} \\         \cline{2-7}& Gini's index & Asym. entropy & Proposed entropy& Gini's index & Asym. entropy & Proposed entropy\\         \hline          Vertebral& &   &       &   &   &\\          Haberman&  &   &   &   &   &\\          Ion&            &  &   &   &   &\\          Breast&         &  &       &   &   &\\          Transfusion&   &   &       &   &       &\\          MagicGamma&     &  &   &   &       &\\         \hline         \end{tabular*}         \end{center}      \end{table}


title: Debian packages

text: I'm using Moodle and have LaTeX filter enabled, one of teacher will like to use `\fs{2}` command in LaTeX filter but it is not working. I'm guessing that it is because this library is not loaded. Do you know what Debian packages I have to load to server so that this command work?


title: Is it possible to break up an align environment and keep the tab positions?

text: I'd like to take notes for a math class such that I can typeset a series of equations with the `\align` environment and make some text notes in between some of the lines. As far as I can tell, though... by using `\end{align*}`, typing some text notes about the process, and then starting a new `\begin{align*}`, I won't be able to align the = symbols in the above environment with & anymore. The best I could come up with is to use `\text{}` in the middle of the equations, but that doesn't place the text along the left margin of the document.               \documentclass{article}          \usepackage[fleqn]{mathtools}          \begin{document}       This is a series of equations:       \begin{align*}         x^{2}+y^{2}&=0\\         y&=mx+b\\         \text{This is a note about the above lines}\\         &\text{This is another note}\\         x^{2}&=1       \end{align*}     \end{document}


> **Possible Duplicate:**   >  inserting sentences between subequations I am proving a math theory in a gather block. I would like to annotate my proof. For instance,               \begin{gather}     ... \\     By the inductive step,     ... \\     \end{gather}      However, when I do so, the text meshes together in the generated pdf. How do I put annotations within my gather block?


title: Aligning several \begin{align} blocks in LaTeX

text: Just a quick question regarding aligning equations in LaTeX. Basically, this is a snippet of my source code:               \begin{align*}       dU&=\partial Q - \partial W \\       \partial Q &= dU + \partial W     \end{align*}     Since $U_E$ was already calculated, $U_A$ can be calculated using equation (1.1) as well:     \begin{align*}       U_A&=\frac{3}{2}PV \\       U_A&=\frac{3}{2}*10^5*10^{-3}\\       U_A&=150J     \end{align*}      Now, the problem I'm facing is that the first `align*` tag is not aligned with the second one, I mean the equations are shifted. I'm not 100% sure why this happens or how to fix this.


title: Aligning equation with another equation after text

text: I was just wondering, if it was possible to align equations if there are text between them ? I mean, if you have several equations right after each other you can use the `\begin{align}` command with `&` where you want them to align. But lets say I have the following:               This equation is good:          [equation 1]          But this is also good:          [equation 2]          But these 2 are the best equations ever produced:          [equation 3]          [equation 4]      Is there any way to align all the 4 equations with each other then ?


title: I want to align two consecutive align environments

text: Here is what I have:               \documentclass{article}     \usepackage{amsmath}          \begin{document}     \begin{align*}      &f(x) = y \\      &f(g(x)) = g(y) \\      &15     \end{align*}     Here is some text commenting on the similarity of these two sets of equations    .     \begin{align*}      &f'(x) = y' \\      &f'(g'(x)) = g'(y) \\      &15000     \end{align*}     But now the bottom align* is just a tiny bit to the left of the top one, which looks wierd.     \end{document}      Is there a good way to make these two aligns line up horizontally? Let me know if it's not clear what I'm going for here. I'm open to using something other than align* of course.


title: Formatting equations and text in amsmath

text: I'm working on a document on how to solve some basic integral problems. However, I'm having difficulty getting `\begin{equation}\end{equation}` to do what I need it to do. I would like all of my equations to be aligned (why I started looking at the equation environment) and numbered, but I would also like to put lines of text between parts of the equation to document what is happening. My problem is, lines of text are inline with equations no matter what I type. Here's what I've tried.               \begin{equation}     \vec{F_{net}} = m \vec{a}\\     \text{This is a basic equation, and is also on the same line as the previous example}     \end{equation}      This code compiles fine, but everything is on one line and runs off the page. What's the best way to fix this?


title: Aligning \text{} on the left

text: > **Possible Duplicate:**   >  How can I break an align environment for a paragraph? I am new here, and quite new to LaTeX. I did search for an answer to this as I think it should be trivial, but I didn't find the answer yet. I have something like               \begin{align*}     y &= mx + c \\     \text{some text here. So} \\     c &= y-mx \\     \text{but } \\     1+2 &\neq 2 \\     \text{Finally} \\     3 &= 1+2\\     \end{align*}      My question is: How to I make all the `\text{}` be aligned on the left instead of the middle? Sorry for my ignorance!


title: How can I break an align environment for a paragraph?

text: I would like to have two displayed equations, broken by a short paragraph, but with aligned equal signs (as if using the `align` environment). Is there some way to "break" the `align` environment temporarily?


title: Bibtex installed on MikTeX, but does not work on another .sty file

text: I am currently transferring all of my work that is written for article publication format (different `.tex`) to dissertation `.tex` (using a `.sty` class given by school). For my article, the class file already has `natbib.sty` loaded by default. So I use               \bibliographystyle{mla}     \bibliography{SUPPLD}      to create bibiliography and citations. For this, when I run the `.tex` file, I get all references. Coming to the new file, I already installed the style files for thesis and it comes with preloaded fonts, spacing etc. I have two `.tex` files, one for actual thesis and the other for including chapters. In the chapters `.tex` file this is what they have where I would have to manually enter each reference which would be cumbersome.               \begin{thebibliography}{99}     %----------books--------------     \bibitem{dsim}         %difference equation algorithms         Tom T. Hartley, Guy O. Beale, Stephen P. Chicatelli,         \emph{             Digital Simulation of Dynamic Systems, A Control Theory Approach.         }         Englewood Cliffs, New Jersey, Prentice Hall, 1994.     \end{thebibliography}      so I tried using               \bibliographystyle{mla}     \bibliography{SUPPLD}      I thought it would run, but it does not. I understand that the `.tex` file is not reading any bibliography styles at all, but my miktex does have all `natbib` and `.bib` files. If I need to install, what and where should I install appropriate files. Any help would be appreciated!


title: What is the latest progress in the realm of TeX?

text: ## Motivation TeX.SE as well as external resources contain information from as far as 2010 regarding e.g. `LuaTeX`, `XeLaTeX`, `microtype`, and popular dilemmas such as `KOMA`/`memoir` or `babel`/`polyglossia`, which seem to be outdated… or are they? ## Overview For example, `XeLaTeX` is still labeled as beta and the last version seems to be from 28 May 2013 while `microtype` 2.5 alpha has been around since 23 May 2013. `LaTeX3` also seems to be halting – the last issue of _`LaTeX3` news_ was published on 27 July 2012, but there has been a promise of two updates per year. The last available `unicode-math` (0.7e) was released on 4 April 2013 and the list continues. The only apparently actively developed one is `LuaTeX`, but it has already been _7 years_ since the initial release and yet a stable release is not even in sight (0.78.2 preview was published on 13 January 2014). It was originally expected to reach 1.0 in 2002, the LuaTeX reference manual indicates it is due spring 2014 (which is now), and the most recent roadmap expects LuaTeX 1.0 bundled with TeX Live 2016, which is basically a **14 year delay**. ## Question What is currently the most modern way of TeX-based typesetting? It should include microtypographic features, UTF-8 support, preferably OTF fonts and compatibility with most basic classes like `KOMA`/`memoir` and packages such as `pgfplots` and `biblatex` with the use of `biber`. ## Addendum I tried to clarify this question as much as I could but I am having trouble defining the issue which could either be a sign of my irrational motives or the result of overall vagueness in this area. Yes, I believe it is vague and confusing – ranging from popular TeX.SE answers that include superfluous settings and abstract substantiation for preferring one of the alternatives (“`babel` is _more complete_ than `polyglossia`, which is _more modern_ ”), to obscure information and the never ending confusion about TeX/LaTeX/LaTeX2e/LaTeX3/Xe(La)TeX/Lua(La)TeX/pdf(La)TeX/eTeX/ConTeXt/whatever else is out there. I have decided to ignore XeLaTeX and experiment with LuaLaTeX with the option of switching back to pdfLaTeX should things go wrong. Thanks for your patience and apologies for the blabbering. :-)


title: RTL orienting TOC and typesetting Estern Arabic Numberals in Arabxetex

text: I am using arabxetex package and need my TOC oriented from right-to-left as well as to have page numbers be in Eastern Arabic Numberals i.e (٠ ١ ٢ ٣ ٤ ٥ ٦ ٧ ٨ ٩)? Table of Contents should look like this: (صصض....... ٣) Here is a minimal example:                   \documentclass[a4paper]{article}     \usepackage{hyperref}     \usepackage{multicol}     \usepackage{fancyhdr}     \makeatletter     \makeatother     \usepackage{hyperref}     \hypersetup{         colorlinks,         citecolor=black,         filecolor=black,         linkcolor=black,         urlcolor=black     }     \usepackage[margin=0.08in, paperwidth=3.56in, paperheight=5.95in]{geometry}     \usepackage{arabxetex}     \usepackage{setspace}         \renewcommand*\contentsname{}          \begin{document}     \tableofcontents     \newpage          \phantomsection     \addcontentsline{toc}{section}{AAA} % Instead of AAA, I need Arabic text ننن     \begin{arab}[utf]     نتنتنهه     \end{arab}          \newpage     \phantomsection     \addcontentsline{toc}{section}{\textarab[utf]{ يسيس}} % Instead of BBB, I need Arabic text ههه     \begin{arab}[utf]     منسة     \end{arab}          \end{document}


title: Different command definitions with and without optional argument

text: I want to define a command that expands to two completely different things depending on whether I supply, or not, an optional argument. For example,               \mycmd{normal}            ->  something(normal)     \mycmd[optional]{normal}  ->  anotherthing(normal, optional)      How can I do this?


title: Customizing the style of the "Table of Contents" title

text: I used `titlesec` for customizing chapter titles. How can I put the _Table of contents_ title **above** the horizontal line? (I am trying to customize the place of the title, not the title) Added figure is the result I get, from my existing code. ![How can i take the Table of contents title above the line?](http://i.stack.imgur.com/1XgFd.png)               \usepackage{titlesec}     \titleformat{\chapter}[display]     {\bfseries\large}     {\filleft\MakeUppercase{\chaptertitlename} \large\thechapter}     {2ex}     {\titlerule     \vspace{2ex}%     \filleft}     \titlespacing*{\chapter}{0pt}{120pt}{6pt}


title: latex table border dont appear / to big / to small

text: still working on that table. Here's my new question reguarding the table borders: It appears, that i do something wrong setting boarders. Here is my code, and a screenshot:               \documentclass{article}     \usepackage{multirow} % Used for the vertical cells     \usepackage{rotating} % Used for the vertical cells          \usepackage{xcolor} % Used for cell-colors     \usepackage{colortbl} % Used for cell-colors          \usepackage[a4paper]{geometry}% Used to set the pdf margins manually     \newgeometry{left=2cm,bottom=0.1cm}          \definecolor{grey}{HTML}{F2F2F2} % Define grey for the cells     \definecolor{red}{HTML}{FF0000} % Define red for testing          \begin{document}     \scriptsize % Use a small font size          \begin{tabular}{|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0.6cm}|p{0,6cm}|}          \cline{10-17}          \multicolumn{9}{|c|}{} & \multicolumn{2}{p{\dimexpr (0.6cm)*2+2\arrayrulewidth+2\tabcolsep\relax}|}{\cellcolor{grey}Work to retired ratio} & \multicolumn{4}{p{\dimexpr (0.6cm)*4+1\arrayrulewidth+2\tabcolsep\relax}|}{Health care sizing (per thousand)} & \multicolumn{2}{p{\dimexpr (0.6cm)*2+1\arrayrulewidth+2\tabcolsep\relax}|}{\cellcolor{grey}Inverse dependency ratio}\\\cline{3-9}          \multicolumn{2}{|c|}{} & \multicolumn{4}{c|}{\cellcolor{grey}Population (mio.)} & \multicolumn{3}{c}{Workforce (1000)}  & \multicolumn{2}{|c|}{\cellcolor{grey}} & \multicolumn{2}{l|}{Physicians by} & \multicolumn{2}{l}{Nurses by} & \multicolumn{2}{|l|}{\cellcolor{grey}Old agers by}\\\hline          \multicolumn{2}{|c|}{} & \begin{sideways}\cellcolor{grey}\parbox{4cm}{Overall}\end{sideways} & \begin{sideways}\cellcolor{grey}\parbox{4cm}{Young age}\end{sideways} & \begin{sideways}\cellcolor{grey}\parbox{4cm}{Working age}\end{sideways} & \begin{sideways}\cellcolor{grey}\parbox{4cm}{Old age}\end{sideways} & \begin{sideways}\parbox{4cm}{Overall}\end{sideways} & \begin{sideways}\parbox{4cm}{Physicians (Proj: 2025)}\end{sideways} & \begin{sideways}\parbox{4cm}{Nurses (Proj: 2030)}\end{sideways} & \begin{sideways}\parbox{4cm}{\cellcolor{grey}Working age by Old age}\end{sideways} & \begin{sideways}\parbox{4cm}{\cellcolor{grey}Work force by Old age}\end{sideways} & \begin{sideways}\parbox{4cm}{Workforce}\end{sideways} & \begin{sideways}\parbox{4cm}{Working age}\end{sideways} & \begin{sideways}\parbox{4cm}{Workforce}\end{sideways} & \begin{sideways}\parbox{4cm}{Working age}\end{sideways} & \begin{sideways}\parbox{4cm}{\cellcolor{grey}1 physicians}\end{sideways} & \begin{sideways}\parbox{4cm}{\cellcolor{grey}1 nurse}\end{sideways}\\\hline          \multicolumn{2}{|l}{USA} & \multicolumn{4}{l}{\cellcolor{grey}} & \multicolumn{3}{l}{} & \multicolumn{2}{l}{\cellcolor{grey}} & \multicolumn{4}{l}{} & \multicolumn{2}{l|}{\cellcolor{grey}}\\\hline          1990/1 & & 248,6 & 71,3 & 146,1 & 31,2 & 127.500 & 615,4 & 1491,6 & 4,68 & 4,09 & 4,83 & 4,21 & 11,70 & 10,21 & 50,7 & 20,9\\\hline          1 & 2 & 3 \\\hline          \end{tabular}          \end{document}      ![enter image description here](http://i.stack.imgur.com/O3VRl.png) On 1 the Top border of Population is not visible although i did used `\\\\\cline{3-9}\cline{12-17}` on that line. In 2 both borders are pushed a bit to the right for no reason i can see. And in 3 again the top borders are not visible despite using `\cline{10-17}` on that line. What did i do wrong? Thanks!


title: Automatic line and page breaking - how to turn it off?

text: I am using MiKTeX 2.9 , I want to turn off automatic line and page breaking , I was trying to use {verbatim} , {alltt} and \verb+...+ , it works , but doesn't keep original font (I am using gfsartemisia-euler font , from here: http://www.tug.dk/FontCatalogue/gfsartemisia-euler/). Can anybody help? I need solution with keeping original formating of math's formulas. For example: I don't want to see \int instead of traditional symbol of an integral. Problem can be solved by \nopagebreak or \nolinebreak, but using them is rather burdensome.


title: One hyperref per acronym per page

text: Currently, I'm using the `acronym` package to keep my thesis clear and understandable, because it is quite heavy on the use of acronyms in some parts. Because of this, some pages have so many acronyms, that they more or less look like someone went haywire with a blue text coloring tool. So my question is: is it possible for either the `acronym` package, or the `hyperref` package, to only use one hyperref per acronym per page? So if one encounters an acronym for the first time on a page, he will be able to click on it and taken to the acronym definition list. The rest of the same acronyms on the same page will be printed without link. I do not know if it is even possible for `LaTeX` to have this kind of 'reflection' on pages and links while compiling the document. Searching on this provided no results, which is why I'm resorting to the gurus over here.


title: Left and right quotation marks aren't correct when using fontspec

text: Using XeLaTeX the following document produces the correct result if `\setmainfont{Arial}` is never called (the quotation marks are proper left- and right-quotation marks). Once I try to set a font (even if it has the proper glyphs!) the output appears improperly as ```Quote me!''`.               \documentclass{article}     \usepackage{fontspec}     \setmainfont{Arial}     \begin{document}     ``Quote me!''     \end{document}


title: What is the best way for a list of nomenclature?

text: My problem with the `nomencl` package is that I have to call `\nomenclature` manually every time I use a new symbol. For example the following code               \documentclass{article}     \usepackage{xspace,ifthen}          \usepackage[intoc]{nomencl}     \renewcommand{\nomname}{List of Notations}     \renewcommand*{\pagedeclaration}[1]{\dotfill\hyperpage{#1}}     \renewcommand{\nomgroup}[1]{%       \ifthenelse{\equal{#1}{R}}{\item[\textbf{Roman Symbols}]}{%         \ifthenelse{\equal{#1}{G}}{\item[\textbf{Greek Symbols}]}{%           \ifthenelse{\equal{#1}{P}}{\item[\textbf{Superscripts}]}{%             \ifthenelse{\equal{#1}{B}}{\item[\textbf{Subscripts}]}{%               \ifthenelse{\equal{#1}{S}}{\item[\textbf{Symbols}]}{%           }}}}}}          \makenomenclature          \newcommand{\symbI}{\ensuremath{F}\xspace}     \newcommand{\symbII}{\ensuremath{M}\xspace}     \newcommand{\symbIII}{\ensuremath{\alpha}\xspace}     \newcommand{\symbIV}{\ensuremath{U}\xspace}          \begin{document}          \printnomenclature[1.5cm]          \section*{Math section}          \begin{equation}        \symbI = \symbII \symbIII     \end{equation}     \nomenclature[rsymbI ]{\symbI}{some explanation for F}     \nomenclature[rsymbII ]{\symbII}{some explanation for M}     \nomenclature[gsymbIII ]{\symbIII}{some explanation for \alpha}          \end{document}      would produce ![enter image description here](http://i.stack.imgur.com/LSabJ.png) Is there any way, let say, that one defines all the symbols once and only those that used in the text appear in the list of nomenclature? Something similar to citation maybe. For example to have the following way in order to produce the above nomenclature list?               \documentclass{article}          \usepackage{xspace}          \anicecommand{\symbI}{Roman sympbol}{\ensuremath{F}\xspace}{some explanation for $F$}     \anicecommand{\symbII}{Roman sympbol}{\ensuremath{M}\xspace}{some explanation for $M$}     \anicecommand{\symbIII}{Greek sympbol}{\ensuremath{\alpha}\xspace}{some explanation for $\alpha$}     \anicecommand{\symbIV}{Roman sympbol}{\ensuremath{U}\xspace}{some explanation for $U$}          \begin{document}          \printnomenclature[1.5cm]          \section*{Math section}          \begin{equation}        \symbI = \symbII \symbIII     \end{equation}          \end{document}


title: Multiply defined labels with \usebox

text: I want to duplicate some content without re-defining its labels. For example,               \newbox{\foobox}     \sbox{\foobox}{\vbox{\section{Foo}\label{sec:foo}}     \usebox{\foobox}     \usebox{\foobox}      will emit a warning, because `sec:foo` is defined more than once. Is there any way to prevent the second `\usebox` from writing to the aux file?


title: Lyx: SVG files on PDF

text: I'm having trouble getting an SVG diagram to appear in a PDF. From researching online it looks like it should be simple enough, but I'm yet to discover what I'm doing wrong. I'm working in LyX, and inserting graphics I drew in Inkscape. The image does then appear in my LyX code. However, when I compile to a PDF (pdfLaTeX - though other compilers don't work either), there is only a blank space where the image file should be. Very frustrating, since it took some time to even get the image to appear in LyX, and I assumed that had solved the problem. **Long story short:** Working in LyX, I can insert an SVG file I made in Inkscape - it appears in LyX's gui but it doesn't appear when compiled by pdfLaTeX.


title: How come the numbering of my section titles is coming as 0.1.x and not 1.x etc

text: I am using a thesis package given by my university. Surprisingly the section numbers of thesis are coming as 0.1, 0.1.1 and not 1, 1.1 etc. Please see this pdf and this main tex file I will be thankful for your suggestion.


title: How to organize labels when there are too many equations?

text: I'm writing a moderately long text using LaTeX, and it's great to be able to organize chapters, sections, appendices, and everything else almost automatically. One thing has been bothering me though. This text has a lot of equations (multi or single-lined), and I can't find a convenient way to handle the labels. Since the text is still being written, I can't tell whether I'll need to reference a given equation later on, so I'm just labeling all of then. What I'd like though, is for latex to only number the equations that are cited somewhere in the text. I'm using the align environment (since most equations are multi-line). After researching a bit, I've found the following options:   1. **Use the`align*` environment instead, and manually `\tag` the equations.** This is not very convenient, since the tagging is done manually as well as the citing. Also, I'm constantly going back and adding equations, which would force me to change every tag that comes after the added equation in that section (not as bad as I thought at first).    2. **Keep using`align` and `\label`, but `\notag` each line, and then remove the `\notag` once I realize I want to cite that equation.** This is the best I could find, but it is still cumbersome. Emacs automatically adds the labels, but not the notags. Is this really it? LaTeX always manages to surprise me in how there's a package for everything. Isn't there one that hides the labels unless it's been called by an `\eqref`?


title: How do I number equations only if they are referred to in the text?

text: I have a paper where all equations are numbered, but I want to number equations only if they are actually referred to in the .tex file using `\ref{}`. How can I make that happen? Alternatively, how can I make all equations that have no `\label` next to them (because then I know I don't refer to them) not have a number? Do I have to use `\nonumber` separately for each such equation?


title: Turn off numbering on unused equations

text: > **Possible Duplicate:**   >  How do I number equations only if they are referred to in the text? While I am writing a document, I like to use `align` rather than `align*` and `label` them for all equations that I write in case I need to refer to them later in the document. I end up not referencing some of the equations I have `label`ed. I was wondering if there is an easy way to strip equation numbers for equations that are not called using `eqref` anywhere in the document? I can imagine this can be a difficult task where LaTeX will have to keep a list of `label`s and a list of `eqref`s and then unless the document is changed between compilations, "un-number" the ones in its list of `label`s that are not found in the list of `eqref`s. Well, worth asking anyway! :)


title: Selective equation numbering in LaTeX

text: > **Possible Duplicate:**   >  How do I number equations only if they are referred to in the text? I would like to number only the equations I actually refer in a manuscript. I know plenty of ways to do this manually, but as the manuscript progresses and I change which equations I refer to later I am likely to forget to change the display style of those equations. I would really like a way to make latex automatically recognize that an equations is being referred and typeset all equations not referred unnumbered, and typeset all equations that are referred using `\ref{}` with numbers in the right margin.


title: Suppress equation number when not refered to

text: Is is possible to use only `equation` or `align` environments without the `*` and then automatically suppress the equation number if there is nothing refering to that equation? It would make the LaTeX-life much easier I think.


title: Change the order in ModernCV banking

text: When using classic theme vs using banking theme, the classic highlights the job title whereas banking highlights the employer. ![Classic](http://i.stack.imgur.com/lK2u1.jpg) ![Banking](http://i.stack.imgur.com/tYyO4.jpg) How do I make it so that banking highlights the job title instead of the employer, and comes in the order of job title and then employer like in classic theme. The MWE is the following: (change the style from classic to banking for the change in the order of job title and employer}                \documentclass[11pt,a4paper,sans]{moderncv}           \moderncvstyle{classic}      %\moderncvstyle{banking}      \moderncvcolor{blue}      \usepackage[scale=0.75]{geometry}           \name{John}{Doe}      \title{Resumé title}      \address{street and number}{postcode city}{country}      \phone[mobile]{+1~(234)~567~890}      \phone[fixed]{+2~(345)~678~901}      \phone[fax]{+3~(456)~789~012}          \begin{document}           \section{Experience}      \subsection{Vocational}      \cventry{year--year}{Job title}{Employer}{City}{}{General description no longer than 1--2 lines.\newline{}%      }      \end{document}


title: Using latexdiff in MiKTeX

text: I am trying to use `latexdiff` to compare two .tex files, producing a .pdf with a markup similar to the "track changes" function in Microsoft Word (see https://www.sharelatex.com/blog/2013/02/16/using-latexdiff-for-marking- changes-to-tex-documents.html). I have downloaded the `latexdiff` files from CTAN and I have also downloaded Strawberry Perl. I am using MiKTeX to compile my two tex documents. In the command line (DOS prompt) I have been trying to instruct `latexdiff` to compare two very simple .tex files: `SAMPLE4.tex` and `SAMPLE5.tex`. I have been following the instructions in the USAGE section of the first URL I list here ("...using latexdiff..."), specifically: > "Usage > > To compare two documents simply run latexdiff in the command line like so: >   >   >     latexdiff draft.tex revision.tex > diff.tex" >   However, when I enter the following into the command line:               C:\Users\Kathryn\latexdiff SAMPLE4.tex SAMPLE5.tex > diff.tex       I get the following error message: > >     Input file SAMPLE$.tex does not exist. at >     C:\Program Files\MiKTeX 2.9\scripts\latexdiff\latexdiff line 513, <DATA> > line 20026. >   I suspect the problem is that the computer cannot find the file `SAMPLE4.tex` and that I need to make `SAMPLE4.tex` (and presumably also `SAMPLE5.tex`) available in a directory that I can accurately specify in DOS. I tried putting my two .tex files in `C:\Program Files\MikTeX 2.9\latexdiff` but this did not work. Can anyone here offer me some advice?


title: article document class: remove boldface from all titles

text: My question relates to remove boldface from chapter titles, section and subsection names on removing boldface from `chapter` titles, `section` and `subsection` names, the difference being that I need to remove boldface from `chapter` titles, `section` and `subsection` names from an `article` class document.


title: "Remapping" a single glyph

text: I am using the excellent Heuristica typeface, but I don't like the way the old style "1" looks. It looks more like an "I" in small caps than an actual number, unlike the Adobe original. Like so: ![enter image description here](http://i.stack.imgur.com/sUEtz.png) Is there a way to remap this single character to use a different font, or a not incredibly painful way to edit the font itself? (since I'm using the text figures for section numberings and the like, I would prefer a document wide solution) EDIT: Minimal working example:               \documentclass[letterpaper,12pt]{amsart}          \usepackage[osf,scaled=.92]{heuristica}          \begin{document}       012782     \end{document}


title: Installation of GhostView needed before installing MiKTeX?

text: I want to install MiKTeX 2.9.3959 (on WinXP in order to create PS files). Do I need (or better, should I) install GhostScript and GhostView first, before installing MiKTeX?


title: modifying vector arrow definition plain tex for esvect package

text: what does               \kern, \mkern, \traitfill, \m@th, \mathpalette       & what does attaching a `@` symbol after `\def` mean? for example               \def\vectfill@{whatever}       or               \def\traitfill@#1#2#3#4


title: Line break in math environment

text: I've typed this: `$A,A+k,A+2k,\ldots,A+nk,B$, kde $k$ je \textit{krok}` and the line breaks in the middle of `A+2k`. Is it OK or should I break the line manually before this expression?


title: How to makeglossaries with TeXworks?

text: I am using TeXworks to edit my LaTeX files. I currently use the `pdfLatex+MakeIndex+BibTeX` which calls the texify (it is the standard configuration). How to configure this option to call the makeglossaries program?


title: How would I trim a bounding box?

text: How do I trim the bounding box of an `.eps` figure?               \documentclass{article}     \usepackage[caption = false]{subfig}     \usepackage[demo]{graphicx}     \begin{document}     \begin{figure}[H]       \centering       \includegraphics[width = 5in]{something.eps}     \end{figure}     \end{document}      ![enter image description here](http://i.stack.imgur.com/9M9Rr.png) I want to trim the top portion so the spacing between the equation and the figure isn't too much.


title: Subfigures with TikZ on the same line?

text: I am trying to get my subfigures on the same line. Right now I successfully use the subfigure and TikZ packages to have a Fig. 1 (a) and Fig 1. (b). However, no matter what I have tried they are stacked one above the other. I would like the two subfigures to be side by side.               \documentclass{article}      \usepackage{subfigure,tikz}     \usetikzlibrary{backgrounds,automata}     \begin{document}          \begin{figure}     \centering      \subfigure[Before]     {%     \begin{tikzpicture}[show background rectangle, scale=.5]     \draw[rounded corners=5pt] (0,0) rectangle (6,8);     \draw[rounded corners=5pt] (1,2) rectangle (5,6);     \draw [dashed] (3,2) to[line to] (3,6);          \node[state] (a) at (3,7) {$a$};     \node[state] (b_x) at (2,5) {$b_x$};     \node[state] (b_y) at (4,5) {$b_y$};     \node[state] (c_x) at (2,3) {$c_x$};     \node[state] (c_y) at (4,3) {$c_y$};     \node[state] (d) at (3,1) {$d$};     \draw (1.25,5.75) node {$x$};     \draw (3.25,5.75) node {$y$};     \draw (0.25,7.75) node {$z$};     \end{tikzpicture}     }     \subfigure[After]     {%     \begin{tikzpicture}[show background rectangle, scale = 0.5]     \draw[rounded corners=5pt] (0,0) rectangle (4,8);     \draw [dashed] (2,0) to[line to] (2,8);     \node[state] (a_x) at (1,7) {$a_x$};     \node[state] (a_y) at (3,7) {$a_y$};     \node[state] (b_x) at (1,5) {$b_x$};     \node[state] (b_y) at (3,5) {$b_y$};     \node[state] (c_x) at (1,3) {$c_x$};     \node[state] (c_y) at (3,3) {$c_y$};     \node[state] (d_x) at (1,1) {$d_x$};     \node[state] (d_y) at (3,1) {$d_y$};     \draw (0.25,7.75) node {$x$};     \draw (2.25,7.75) node {$y$};     \end{tikzpicture}     }     \caption{An example of the procedure} \end{figure}          \end{document}